Marc-Andre Lemburg m...@egenix.com added the comment:
Alexander Belopolsky wrote:
I am not sure PyUnicode_Decode() should treat NULL as an empty string.
Definitely not. That would hide programming errors.
--
nosy: +lemburg
title: Some trivial python 2.x pickles fails to load in
Duncan Booth kupu...@gmail.com added the comment:
If anyone knows how to reproduce the two bugs with a short Python
script, I can try to convert it into a test.
If you don't mind kicking off some sub-processes then here's a script that
shows the bugs.
I couldn't figure out how to do a
New submission from Raymond Hettinger rhettin...@users.sourceforge.net:
Attaching a documentation patch.
--
assignee: rhettinger
files: chainmap.diff
keywords: patch
messages: 129161
nosy: rhettinger
priority: low
severity: normal
status: open
title: Make ChainMap() public in the
Antoine Pitrou pit...@free.fr added the comment:
This is nice, but IMO there is some information lacking, e.g.:
- when an underlying mapping is mutated, does the ChainMap get updated too?
- does it work with arbitrary mappings or only with dicts or dicts subclasses?
I think new_child() isn't
Antoine Pitrou pit...@free.fr added the comment:
(too specialized, sorry)
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11297
___
___
Antoine Pitrou pit...@free.fr added the comment:
I am not sure PyUnicode_Decode() should treat NULL as an empty string.
Definitely not. That would hide programming errors.
Well, this could break some third-party code.
--
title: Some trivial python 2.x pickles fails to load in
Stefan Krah stefan-use...@bytereef.org added the comment:
Works fine for me (Windows 7, 64-bit, 32-bit Python-3.2). I do have the
plain US English version. Do you have localized versions?
--
nosy: +skrah
___
Python tracker rep...@bugs.python.org
Marc-Andre Lemburg m...@egenix.com added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
I am not sure PyUnicode_Decode() should treat NULL as an empty string.
Definitely not. That would hide programming errors.
Well, this could break some
Antoine Pitrou pit...@free.fr added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
I am not sure PyUnicode_Decode() should treat NULL as an empty string.
Definitely not. That would hide programming errors.
Well, this could break some
Marc-Andre Lemburg m...@egenix.com added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
I am not sure PyUnicode_Decode() should treat NULL as an empty string.
Definitely not.
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment:
Hmm. Note that this problem does *not* occur if i don't install Python but run
it in place, e.g. 'cd Lib/test; ../../python.exe -m test -v -uall test_iter'
works just perfect.
--
___
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment:
... and the problem is all gone with 8c2935f180fa/r88525.
So i'm faitful now and close this early alpha-stage problem.
One of the nosy ones may add a nice description, re-open it or so.
--
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment:
(.. should close it, then.)
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11285
___
Antoine Pitrou pit...@free.fr added the comment:
PyUnicode_Decode() et al. are conversion functions and these
require valid content to work on. Passing in a NULL pointer
does not fit that specification and so allowing for this
would hide programming errors.
Valid content doesn't mean a lot
Antoine Pitrou pit...@free.fr added the comment:
For the record:
e.g. 'cd Lib/test; ../../python.exe -m test -v -uall test_iter' works
just perfect.
You don't need to cd. Just ./python -m test (etc.).
See http://docs.python.org/devguide/runtests.html for more information.
--
Changes by Antoine Pitrou pit...@free.fr:
--
resolution: - works for me
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11285
___
___
Marc-Andre Lemburg m...@egenix.com added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
PyUnicode_Decode() et al. are conversion functions and these
require valid content to work on. Passing in a NULL pointer
does not fit that specification and so
Antoine Pitrou pit...@free.fr added the comment:
So, IMO, practicality beats purity here. Especially since it is bound to
land in a bugfix release (3.2.1), which users don't expect to produce
regressions in their own code.
Nope. Your suggestion would be a new feature and those are not
New submission from blokeley bloke...@gmail.com:
`python -m unittest discover` caught me out.
I had a test module called `test-foo.py` and no test was loaded.
When I renamed to `test_foo.py` it worked.
The documentation says For a project’s tests to be compatible with test
discovery they
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment:
I append a doc_lib_mmap.patch which may be helpful for those poor creatures who
plan to write Python scripts for Mac OS X. (It may be a useful add-on anyway.)
--
Added file:
Lars Gustäbel l...@gustaebel.de added the comment:
Thanks for your great report. This is fixed now in r88528 (py3k) and r88529
(release32-maint).
--
keywords: +3.2regression
resolution: - accepted
stage: - committed/rejected
status: open - closed
versions: +Python 3.3
Michael Foord mich...@voidspace.org.uk added the comment:
Sounds like a good change to the docs. Care to provide a patch?
--
nosy: +michael.foord
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
___
STINNER Victor victor.stin...@haypocalc.com added the comment:
Fixed in 3.3 (r88530) and 3.2 (r88531). Others versions are not affected.
Thanks Duncan Booth, I added tests based on your stdintests.py script. I used
directly stdin argument of Popen() instead of using cmd.exe to create the pipe
STINNER Victor victor.stin...@haypocalc.com added the comment:
Fixed in 3.2 too (r88532).
--
resolution: - fixed
status: pending - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10830
Changes by Steffen Daode Nurpmeso sdao...@googlemail.com:
Removed file: http://bugs.python.org/file20859/doc_lib_mmap.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11277
___
Jesús Cea Avión j...@jcea.es added the comment:
What if we commit Antoine patch for 3.2.x, and the correct patch for py3k
trunk?.
I am actually +1 to Marc-Andre. I feel in my guts that the provided patch is
hidding a deeper issue. But avoiding surprises for third parties in 3.2.1 is a
good
Changes by SilentGhost ghost@gmail.com:
Added file: http://bugs.python.org/file20860/test_re.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2650
___
Changes by SilentGhost ghost@gmail.com:
Removed file: http://bugs.python.org/file20389/test_re.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2650
___
Antoine Pitrou pit...@free.fr added the comment:
Nope. Your suggestion would be a new feature and those are not
allowed in patch level releases.
What new feature are you talking about? I think you misunderstood the
actual issue: NULL as an empty string *worked* in 3.1
And, with a very
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment:
Sorry, i've got that kid running around which sometimes doesn't know what it is
doing. But this documentation patch may really be a help. It's my first
doc-patch, so it surely needs to be revised, if interest exists in such a
Antoine Pitrou pit...@free.fr added the comment:
This new failure is perhaps related:
http://www.python.org/dev/buildbot/all/builders/AMD64%20Windows%20Server%202008%203.x/builds/572/steps/test/logs/stdio
==
FAIL: test_module
Marc-Andre Lemburg m...@egenix.com added the comment:
Please go with Alexander's solution of fixing the higher level code rather than
silently trying to introduce a new feature in PyUnicode_Decode() that hides
programming errors.
Thanks.
--
___
David Beazley d...@dabeaz.com added the comment:
Bump. This is still broken in Python 3.2.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10791
___
Antoine Pitrou pit...@free.fr added the comment:
Please go with Alexander's solution of fixing the higher level code
rather than silently trying to introduce a new feature in
PyUnicode_Decode() that hides programming errors.
I'm sorry, I'm perfectly fine with my own patch, so someone else
blokeley bloke...@gmail.com added the comment:
Will do but I haven't submitted a patch before and it's impossible to tell from
python.org/dev whether to use the svn or hg repositories.
If possible, please just let me know the URL of the hg repository against which
I should make the patch (I
Ezio Melotti ezio.melo...@gmail.com added the comment:
http://code.python.org/hg/branches/py3k/
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
Bartosz sspame...@gmail.com added the comment:
I've got English version too. Python is 32 bit and operating system is also 32
bit.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11288
___
Marc-Andre Lemburg m...@egenix.com added the comment:
Jesús Cea Avión wrote:
Jesús Cea Avión j...@jcea.es added the comment:
What if we commit Antoine patch for 3.2.x, and the correct patch for py3k
trunk?.
I am actually +1 to Marc-Andre. I feel in my guts that the provided patch is
Antoine Pitrou pit...@free.fr added the comment:
Oops, I hadn't seen Alexander's patch. Sorry.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11286
___
Bartosz sspame...@gmail.com added the comment:
I have found a problem and sollution:
previously I have used Python 2.x and when I removed that version and next
installed Python32, PYTHONPATH in system variabled indicated still to
Python2.x. Removing all python paths to old version solved the
Antoine Pitrou pit...@free.fr added the comment:
So, about Alexander's patch:
- it lacks a test
- it doesn't solve the issue with PyUnicode_Decode's confusing error message
when a NULL is passed (ValueError: operation forbidden on released memoryview
object); if we want to disallow NULL, we
STINNER Victor victor.stin...@haypocalc.com added the comment:
This new failure is perhaps related: (...) test_reprlib
Ah yes, yesterday, I tried to remember which test was impacted by the module
change, but all tests passed on Linux. Anyway, it's now fixed by r88533.
--
Changes by blokeley bloke...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file20862/py3k_rev9921_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
Changes by blokeley bloke...@gmail.com:
Removed file: http://bugs.python.org/file20862/py3k_rev9921_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
Changes by blokeley bloke...@gmail.com:
Added file: http://bugs.python.org/file20863/py3k_rev9921_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
Michael Foord mich...@voidspace.org.uk added the comment:
Thanks blokely, looks good. Needs applying to 2.7 / 3.2 and 3.3 branches.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
R. David Murray rdmur...@bitdance.com added the comment:
If a patch had been proposed it probably would have gotten in to 3.2. Maybe
someone (perhaps you?) will find the time before 3.2.1.
Someone has decided to work on the bz2 rewrite, by the way (issue 5863).
--
David Beazley d...@dabeaz.com added the comment:
If I can find some time, I may took a look at this. I just noticed that
similar problems arise trying to wrap TextIOWrapper around the file-like
objects returned by urllib.request.urlopen as well.
In the big picture, some discussion of what
Changes by Ram Rachum cool...@cool-rr.com:
--
versions: +Python 3.3 -Python 3.2
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8289
___
___
STINNER Victor victor.stin...@haypocalc.com added the comment:
What is the problem with Python 3.2? It works correctly here:
$ cat bla.txt
bli
blo
bla
$ gzip bla.txt
$ ./python
Python 3.3a0 (unknown, Feb 23 2011, 13:03:50)
import gzip, io
f =
David Beazley d...@dabeaz.com added the comment:
Python 3.2 (r32:88445, Feb 20 2011, 21:51:21)
[GCC 4.2.1 (Apple Inc. build 5664)] on darwin
Type help, copyright, credits or license for more information.
import gzip
import io
f = io.TextIOWrapper(gzip.open(file.gz),encoding='latin-1')
Ram Rachum cool...@cool-rr.com added the comment:
I also miss being able to pickle unbound methods on Python 3. I don't think
there's an interest in pickling the actual code objects. In my opinion, unbound
methods should be pickled exactly like all the other Python definitions, such
as bound
Changes by Ram Rachum cool...@cool-rr.com:
--
versions: +Python 3.3 -Python 3.2
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9276
___
___
R. David Murray rdmur...@bitdance.com added the comment:
Yes, a clear definition of the minimum requirements for being wrapped by
TextIOWrapper sounds like a necessary thing to have (and I'd be inclined to
agree with your assertion, but I didn't work on the IO library :). It would be
best to
Matthew Funke go4...@gmail.com added the comment:
Changing the environment variables did the trick! Thank you very much!
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11288
___
STINNER Victor victor.stin...@haypocalc.com added the comment:
Yes, a clear definition of the minimum requirements for being wrapped
by TextIOWrapper sounds like a necessary thing to have
About that: is read1() argument mandatory or not?
In _pyio, BufferedIOBase.read1() argument is optional
Alexander Belopolsky belopol...@users.sourceforge.net added the comment:
Antoine is right, my patch is only of discussion quality and if my approach
gets support, I will produce a more polished patch.
While I am fairly certain that this bug should be fixed where it was
introduced, namely in
Antoine Pitrou pit...@free.fr added the comment:
It may be better to modify _Unpickler_Read() so that it returns
self-input_buffer (or even self-input_buffer + self-next_read_idx)
for zero n.
I agree this would be better for readability and maintainability.
On the other hand, my patch also
Alexander Belopolsky belopol...@users.sourceforge.net added the comment:
On Wed, Feb 23, 2011 at 10:22 AM, Antoine Pitrou rep...@bugs.python.org wrote:
..
Well, a theoretical argument could be made that some codec could return
a non-empty string when asked to decode an empty bytestring, but
Changes by Alexander Belopolsky belopol...@users.sourceforge.net:
--
assignee: - belopolsky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11286
___
blokeley bloke...@gmail.com added the comment:
Added release2.7-maint patch.
--
Added file:
http://bugs.python.org/file20864/py2.7-maint_rev45852_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
Changes by blokeley bloke...@gmail.com:
Removed file:
http://bugs.python.org/file20864/py2.7-maint_rev45852_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
___
blokeley bloke...@gmail.com added the comment:
Added release2.7-maint patch.
--
Added file:
http://bugs.python.org/file20865/py2.7-maint_rev45852_issue11298.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
blokeley bloke...@gmail.com added the comment:
Added release3.2-maint patch.
I created the patches by cloning the corresponding hg repo from
http://code.python.org/hg If this is the wrong thing to do, let me know.
I have no idea where the 3.3 branch is. Please advise.
--
Added file:
Michael Foord mich...@voidspace.org.uk added the comment:
Hey, blokeley the same patch will apply cleanly against 3.2 / 3.3 so no worries.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11298
New submission from Ram Rachum cool...@cool-rr.com:
Please allow to deepcopy and to pickle paused generators, including all their
state.
This is implemented in Pypy:
Python 2.5.2 (335e875cb0fe, Dec 28 2010, 20:31:56)
[PyPy 1.4.1] on win32
Type copyright, credits or
Ram Rachum cool...@cool-rr.com added the comment:
P.S. I'm willing to write a test-case if it will help.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11299
___
Changes by Daniel Urban urban.dani...@gmail.com:
--
nosy: +durban
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11297
___
___
Python-bugs-list
Antoine Pitrou pit...@free.fr added the comment:
It would probably be ok to fallback on read() when read1() isn't implemented.
read1() is supposed to be implemented by all BufferedIO-compliant classes, but
in all honesty I don't think it's very useful in practice. It's supposed to be
an
R. David Murray rdmur...@bitdance.com added the comment:
I don't think that new_child and parents are too specialized at all, indeed
they are essential to one of the primary use cases for the construct. I find
Django's push and pop much more intuitive than new_child and parents, however,
and
Alex alex.gay...@gmail.com added the comment:
An important distinction with Django's push/pop is that they mutate the Context
(ChainMap) rather than return a fresh instance.
--
nosy: +alex
___
Python tracker rep...@bugs.python.org
Changes by Alex alex.gay...@gmail.com:
--
nosy: +alex
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10791
___
___
Python-bugs-list mailing list
R. David Murray rdmur...@bitdance.com added the comment:
Yes, that's part of what I find more intuitive about it. I think of the
chainmap as a stack. Perhaps if I had a different application (I would use it
for either configuration or namespace management) I'd want a different API, but
for
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11227
___
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11239
___
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11232
___
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11292
___
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11293
___
Changes by Sandro Tosi sandro.t...@gmail.com:
--
assignee: sandro.tosi - docs@python
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11294
___
Martin v. Löwis mar...@v.loewis.de added the comment:
Ok, closing this as invalid then - it's not a bug in the installer, but a
misconfiguration of the local system. Thanks to Bartosz for the analysis!
--
resolution: - invalid
status: open - closed
Raymond Hettinger rhettin...@users.sourceforge.net added the comment:
FWIW, the new_child() and parents() part of the API was modeled after contexts
in ANLTR where they are needed to overcome the limitations of Django's push/pop
style which precludes a context from having multiple, independent
New submission from Steffen Daode Nurpmeso sdao...@googlemail.com:
Issue 11277 was closed upon the generally accepted conclusion that the failure
is that mmap(2) on Mac OS X has a long time known bug (see msg129107, or
directly
Łukasz Langa luk...@langa.pl added the comment:
OK, now I know more about glob than I ever wanted to! :) Basically it comes
down to this:
unix os.path.split('\\')
('', '\\')
win32 os.path.split('\\')
('\\', '')
This is why \ is recognized as the root directory on Win32 and as a
non-existent
New submission from Mike Cencula m...@cencula.com:
I'm trying to use cookielib.LWPCookieJar.save() to save cookies from a website.
The cookie file is created with a header line, but the cookies are not stored.
Example program attached.
Python version:
2.5.2 (r252:60911, Jan 24 2010,
Mike Cencula m...@cencula.com added the comment:
User error indeed. Adding ignore_discard=True, ignore_expires=True cured the
issue.
Thank you.
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11301
New submission from Vincent Legoll vincent.leg...@gmail.com:
While working to improve pypy's compliance with cpython2.7
I added more tests to the ast module test suite.
They may be of interest here too...
--
components: Tests
files: add-more-tests-for-ast_py.patch
keywords: patch
Alexander Belopolsky belopol...@users.sourceforge.net added the comment:
I am attaching a new version of issue11286.diff which fixes the issue by
removing special handling of n == 0 case from _Unpickler_Read(). Note that
_Unpickler_Read() (formerly known as unpickler_read()) only started to
Changes by Alexander Belopolsky belopol...@users.sourceforge.net:
Removed file: http://bugs.python.org/file20856/issue11286.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11286
___
Changes by Jake jake.coff...@gmail.com:
--
nosy: +Jake.Coffman
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue4376
___
___
Python-bugs-list mailing
New submission from Alexander Belopolsky belopol...@users.sourceforge.net:
$ ./python.exe -m timeit b'x'.decode('latin1')
10 loops, best of 3: 2.57 usec per loop
$ ./python.exe -m timeit b'x'.decode('latin-1')
100 loops, best of 3: 0.336 usec per loop
The reason for this behavior is
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
versions: +Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11303
___
___
New submission from Sandro Tosi sandro.t...@gmail.com:
Following up http://mail.python.org/pipermail/docs/2011-January/002974.html
here's a patch to fix it.
--
assignee: docs@python
components: Documentation
keywords: patch
messages: 129228
nosy: docs@python, sandro.tosi
priority: low
Charles-Francois Natali neolo...@free.fr added the comment:
Alright, it's normal behaviour, but since it doesn't seem to be documented, it
can be quite surprising.
A queue works like this:
- when you call queue.put(data), the data is added to a deque, which can grow
and shrink forever
- then a
SilentGhost ghost@gmail.com added the comment:
Sandro, you didn't attach anything.
--
nosy: +SilentGhost
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11304
___
Changes by Raymond Hettinger rhettin...@users.sourceforge.net:
--
assignee: docs@python - rhettinger
nosy: +rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11304
___
Raymond Hettinger rhettin...@users.sourceforge.net added the comment:
Fixed in r88356, r88537, and r88538.
Thanks for the report.
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
Changes by SilentGhost ghost@gmail.com:
--
Removed message: http://bugs.python.org/msg129230
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11304
___
Changes by SilentGhost ghost@gmail.com:
--
nosy: -SilentGhost
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11304
___
___
Python-bugs-list
Alexander Belopolsky belopol...@users.sourceforge.net added the comment:
In issue11303.diff, I add similar optimization for encode('latin1') and for
'utf8' variant of utf-8. I don't think dash-less variants of utf-16 and utf-32
are common enough to justify special-casing.
--
Added
1 - 100 of 126 matches
Mail list logo