[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > There seems to be a problem with the patch: when you store the getvalue() > result somewhere (instead of discarding it), things get much slower: This problem exists with the new patch? -- ___ Python tracker

[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > Under Windows (64-bit Windows 7 on a VirtualBox VM), the patch increases > performance slightly but not as much as under Linux: Thank you, Antoine. This is an expected result. > And the join() approach is 10x faster (!): > C:\t\cpython>pc\VS9.0\amd64\pyt

[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: > > There seems to be a problem with the patch: when you store the > getvalue() result somewhere (instead of discarding it), things get > much slower: > > This problem exists with the new patch? I think you can run the benchmark yourself (I ran it under Linux)

[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > I think you can run the benchmark yourself (I ran it under Linux). I don't see any differences. -- ___ Python tracker ___

[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Well, with the latest patch I get: $ ./python -m timeit -s "import io; n=2000; d=[b'a'*n,b'bb'*n,b'ccc'*n]*1000" "s=io.BytesIO(); w=s.write" "for x in d: w(x)" "s.getvalue()" 1000 loops, best of 3: 982 usec per loop $ ./python -m timeit -s "import io; n=20

[issue15409] Deprecation Warning fix on cookiejar module

2012-07-20 Thread Flávio Ribeiro
Flávio Ribeiro added the comment: wow :) thank you! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue15360] Behavior of assigning to __dict__ is not documented

2012-07-20 Thread Davide Rizzo
Davide Rizzo added the comment: Amaury, I don't honestly know, I would have proposed something otherwise. I have been advised on #python (Freenode) not to assign to obj.__dict__ because its behaviour changes between versions and implementations, but I wouldn't know what has changed between CP

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: There are spurious print() calls in the 2.7 patch. -- ___ Python tracker ___ ___ Python-bugs-list m

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: test needed -> commit review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 034ff986019d by Antoine Pitrou in branch '3.2': Issue #14579: Fix CVE-2012-2135: vulnerability in the utf-16 decoder after error handling. http://hg.python.org/cpython/rev/034ff986019d New changeset 118fe0ee6921 by Antoine Pitrou in branch 'defaul

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4cadf91aaddd by Antoine Pitrou in branch '2.7': Issue #14579: Fix error handling bug in the utf-16 decoder. http://hg.python.org/cpython/rev/4cadf91aaddd -- ___ Python tracker

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks for the patches, Serhiy! They're now pushed. -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker _

[issue15409] Deprecation Warning fix on cookiejar module

2012-07-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset ea8078365d3b by Meador Inge in branch 'default': Issue #15409: Replace use of deprecated urllib.request.Request methods in http.cookijar http://hg.python.org/cpython/rev/ea8078365d3b -- nosy: +python-dev __

[issue15409] Deprecation Warning fix on cookiejar module

2012-07-20 Thread Meador Inge
Meador Inge added the comment: Thanks for the patch! -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___ __

[issue15410] urllib.request.Request.is_unverifiable deprecation documentation is incorrect

2012-07-20 Thread Meador Inge
New submission from Meador Inge : While reviewing the change for issue15409 I noticed that the 'urlib.request' documentation has an error in the deprecation note for 'urllib.request.Request.is_unverifiable' [1]: """ Deprecated in 3.3, use Request.is_unverifiable. """ The deprecation text of '

[issue15410] urllib.request.Request.is_unverifiable deprecation documentation is incorrect

2012-07-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset f39895c55699 by Meador Inge in branch 'default': Issue #15410: Fix the urllib.request.Request.is_unverifiable deprecation documentation. http://hg.python.org/cpython/rev/f39895c55699 -- nosy: +python-dev __

[issue15410] urllib.request.Request.is_unverifiable deprecation documentation is incorrect

2012-07-20 Thread Meador Inge
Changes by Meador Inge : -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker ___ _

[issue3367] Uninitialized value read in parsetok.c

2012-07-20 Thread Meador Inge
Meador Inge added the comment: I can still reproduce the parsetok.c problem on the 'default' branch using the CTRL+D method Stefan described. -- ___ Python tracker ___ _

[issue15063] Source code links for JSON documentation

2012-07-20 Thread Senthil Kumaran
Senthil Kumaran added the comment: I am with Éric on this. Looking at json/decoder.py and json/encoder.py, I too feel that source link may not be helpful as much as it is helpful for others. Docs are best here. I am closing this report. Thanks! -- nosy: +orsenthil resolution: -> wont

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-07-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > There are spurious print() calls in the 2.7 patch. Oh, my inattentiveness. Thank you for pushing, Antoine. And thank Martin for review. -- ___ Python tracker ___

[issue15381] Optimize BytesIO to so less reallocations when written, similarly to StringIO

2012-07-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Hmm. Without the ability to reproduce this effect, it will be difficult for me to get rid of him. What times for StringIO, append/join, unpatched BytesIO? Do this happen with a little different numbers (n=1500, 1600,...,3000)? -- _

<    1   2