[issue23796] BufferedReader.peek() crashes if closed

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you want provide a patch Martin? -- assignee: -> serhiy.storchaka nosy: +serhiy.storchaka stage: -> needs patch ___ Python tracker ___ __

[issue23430] socketserver.BaseServer.handle_error() should not catch exiting exceptions

2015-03-27 Thread Martin Panter
Martin Panter added the comment: Oops I forgot to refresh the patch. Patch v4 also closes the server in the tests. -- Added file: http://bugs.python.org/file38718/socketserver-exit.v4.patch ___ Python tracker

[issue23430] socketserver.BaseServer.handle_error() should not catch exiting exceptions

2015-03-27 Thread Martin Panter
Martin Panter added the comment: Patch v3: * Changed the structure of exception handling for the forking server so that there is only one os._exit(status) call site * Rewrote tests to log results to a temporary file. This avoids sending a string of code to a Python subprocess. I use threading.

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0850452048ec by Victor Stinner in branch 'default': Issue #22117: Fix _PyTime_GetMonotonicClock() and https://hg.python.org/cpython/rev/0850452048ec -- ___ Python tracker

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 930be74bbae5 by Victor Stinner in branch 'default': Issue #22117: Use the new _PyTime_t API in the select module https://hg.python.org/cpython/rev/930be74bbae5 New changeset 5aa39b88bd55 by Victor Stinner in branch 'default': Issue #22117: Use the _

[issue17909] Autodetecting JSON encoding

2015-03-27 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset adbc9e6162fe by Victor Stinner in branch 'default': Issue #22117: The thread module uses the new _PyTime_t timestamp API https://hg.python.org/cpython/rev/adbc9e6162fe -- ___ Python tracker

[issue23796] BufferedReader.peek() crashes if closed

2015-03-27 Thread Martin Panter
Martin Panter added the comment: Confirmed it does indeed affect the current 3.5 (default) branch. -- ___ Python tracker ___ ___ Pytho

[issue23529] Limit decompressed data when reading from LZMAFile and BZ2File

2015-03-27 Thread Martin Panter
Martin Panter added the comment: Yes my patch should be ready, unless we want to work on factoring more common logic out of the gzip read() method. -- ___ Python tracker ___ ___

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 7605d9d262ca by Victor Stinner in branch 'default': Issue #22117: remove _PyTime_INTERVAL() macro https://hg.python.org/cpython/rev/7605d9d262ca New changeset d1ef5ff79125 by Victor Stinner in branch 'default': Issue #22117: Fix ssl to use _PyTime_t

[issue23794] http package should support HTTP/2

2015-03-27 Thread Ian Cordasco
Changes by Ian Cordasco : -- nosy: +Lukasa ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

[issue23794] http package should support HTTP/2

2015-03-27 Thread Martin Panter
Martin Panter added the comment: This project may be of use for the client side of things: (apparently MIT licensed). -- nosy: +vadmium ___ Python tracker

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread Martin Panter
Martin Panter added the comment: I suspect you also need ignore signals while piping data to the child process. Similar to how the POSIX system() call ignores SIGINT and SIGQUIT soon after spawning the child, until after the child has exited. Try with a large help text on Linux, like import _

[issue23796] BufferedReader.peek() crashes if closed

2015-03-27 Thread Martin Panter
New submission from Martin Panter: If the BufferedReader object has already been closed, calling peek() can cause a strange error message or a crash: $ python3 -bWall Python 3.4.2 (default, Oct 8 2014, 14:33:30) [GCC 4.9.1 20140903 (prerelease)] on linux Type "help", "copyright", "credits" or

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset f841d3bc30ee by Victor Stinner in branch 'default': Issue #23618, #22117: refactor socketmodule.c https://hg.python.org/cpython/rev/f841d3bc30ee New changeset ae551abe398d by Victor Stinner in branch 'default': Issue #22117: Write unit tests for _Py

[issue23618] PEP 475: handle EINTR in the socket module

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset f841d3bc30ee by Victor Stinner in branch 'default': Issue #23618, #22117: refactor socketmodule.c https://hg.python.org/cpython/rev/f841d3bc30ee -- nosy: +python-dev ___ Python tracker

[issue23720] __del__() order is broken since 3.4.0

2015-03-27 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: -> pitrou priority: normal -> low resolution: -> not a bug ___ Python tracker ___ ___ Py

[issue23762] python.org page on new-style classes should be updated

2015-03-27 Thread Berker Peksag
Berker Peksag added the comment: IMHO, it can stay as a historical document. We just need to add a note to point out the correct documentation. So I think this can be handled on GitHub. I can't update the content since I don't have edit rights, so please open a new issue at https://github.com/

[issue23550] Add to unicodedata a function to query the "Quick_Check" property for a character

2015-03-27 Thread Hammerite
Hammerite added the comment: My remark about the arrays not being static is not entirely accurate. _PyUnicode_CategoryNames, _PyUnicode_BidirectionalNames and _PyUnicode_EastAsianWidthNames are not static, however decomp_prefix is static. It would not add any significant bulk to the patch to m

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 45d9093d259d by Victor Stinner in branch 'default': Issue #22117: time.monotonic() now uses the new _PyTime_t API https://hg.python.org/cpython/rev/45d9093d259d New changeset a88735cbeb50 by Victor Stinner in branch 'default': Issue #22117: time.tim

[issue23791] Identify Moved Lines with difflib

2015-03-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- stage: -> test needed versions: -Python 2.7, Python 3.2, Python 3.3, Python 3.4, Python 3.6 ___ Python tracker ___ __

[issue23762] python.org page on new-style classes should be updated

2015-03-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: This tracker can only handle changes to the docs. Deleting a web page would be an issue for the python.org tracker on github. But we should not make a request there until the docs have been checked and we are sure it should go. -- stage: -> needs pa

[issue23762] python.org page on new-style classes should be updated

2015-03-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: "Unfortunately, new-style classes have not yet been integrated into Python's standard documention" is not even true for 2.7. I think the page should be deleted. Any of the reverences that are both useful and not in the docs could be added to the docs. -

[issue23760] Tkinter in Python 3.4 on Windows don't post internal clipboard data to the Windows clipboard on exit

2015-03-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- nosy: +serhiy.storchaka, terry.reedy stage: -> test needed ___ Python tracker ___ ___ Python-bugs-list

[issue23720] __del__() order is broken since 3.4.0

2015-03-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: While this is not a bug, Antoine said he might look at improving the situation, so I leave it to him to close it or not. -- nosy: +terry.reedy stage: -> needs patch type: behavior -> performance versions: -Python 3.4 _

[issue22672] float arguments in scientific notation not supported by argparse

2015-03-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- resolution: -> duplicate stage: patch review -> resolved superseder: -> argparse does not accept options taking arguments beginning with dash (regression from optparse) ___ Python tracker

[issue22500] Argparse always stores True for positional arguments

2015-03-27 Thread paul j3
Changes by paul j3 : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyt

[issue22672] float arguments in scientific notation not supported by argparse

2015-03-27 Thread paul j3
paul j3 added the comment: closed with reference to #9334 -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailin

[issue9334] argparse does not accept options taking arguments beginning with dash (regression from optparse)

2015-03-27 Thread paul j3
paul j3 added the comment: http://bugs.python.org/issue22672 float arguments in scientific notation not supported by argparse is a newer complaint about the same issue. I've closed it with link to here. -- ___ Python tracker

[issue23555] behavioural change in argparse set_defaults in python 2.7.9

2015-03-27 Thread paul j3
Changes by paul j3 : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyt

[issue23555] behavioural change in argparse set_defaults in python 2.7.9

2015-03-27 Thread paul j3
paul j3 added the comment: This is another manifestation of the http://bugs.python.org/issue9351 partial patch (on how the namespace of the parser relates to the namespace of the subparser). see also http://bugs.python.org/issue23058 -- ___ Python

[issue9351] argparse set_defaults on subcommands should override top level set_defaults

2015-03-27 Thread Rémi Rampin
Changes by Rémi Rampin : -- nosy: +remram ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.or

[issue23058] argparse silently ignores arguments

2015-03-27 Thread paul j3
paul j3 added the comment: Without actually running this case I think it is caused by the http://bugs.python.org/issue9351 patch. You can check the __call__ method for class _SubParsersAction and how it handles invocation of the subparser. Does it get the existing namespace, or a new one (

[issue23058] argparse silently ignores arguments

2015-03-27 Thread paul j3
Changes by paul j3 : -- nosy: +paul.j3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/

[issue23795] argparse -- incorrect usage for mutually exclusive

2015-03-27 Thread paul j3
paul j3 added the comment: I can't reproduce this with either 3.4.2 or the latest development 'argparse.py' file (that I just downloaded). There have been some issues with the method used format the usage line, _format_actions_usage. It formats the line with all the group brackets, and then

[issue23787] sum() function docstring lists arguments incorrectly

2015-03-27 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- keywords: +patch Added file: http://bugs.python.org/file38716/sum_doc.diff ___ Python tracker ___ __

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
Changes by R. David Murray : -- stage: patch review -> commit review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
R. David Murray added the comment: Updated patch. -- Added file: http://bugs.python.org/file38715/keyboardinterrupt_in_pydoc_pager.patch ___ Python tracker ___ _

[issue23789] decimal.Decimal: __format__ behaviour

2015-03-27 Thread Mark Dickinson
Mark Dickinson added the comment: > I believe it's the way it is because Python follows the Standard Decimal > Specification Yes, exactly. This is behaving as designed and as tested. -- nosy: +mark.dickinson resolution: -> not a bug status: open -> closed ___

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
R. David Murray added the comment: The print of KeyboardInterrupt whould be dropped. less itself does nothing if you press ctl-c, and the pager is used when pydoc is called from the shell command line, and printing KeyboardInterrupt there just looks wrong. --

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread Ezio Melotti
Ezio Melotti added the comment: Patch WFM too. -- stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
R. David Murray added the comment: The attached patch fixes the issue for me. -- keywords: +patch Added file: http://bugs.python.org/file38714/keyboardinterrupt_in_pydoc_pager.patch ___ Python tracker

[issue23793] Support __add__ for deques.

2015-03-27 Thread Raymond Hettinger
Changes by Raymond Hettinger : Added file: http://bugs.python.org/file38713/deque_add5.diff ___ Python tracker ___ ___ Python-bugs-list mailin

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
R. David Murray added the comment: I do see the anomalous behavior inside python, but on my gentoo system when I exit python the terminal is fine. -- ___ Python tracker ___

[issue23794] http package should support HTTP/2

2015-03-27 Thread Ian Cordasco
Changes by Ian Cordasco : -- nosy: +icordasc ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue23795] argparse -- incorrect usage for mutually exclusive

2015-03-27 Thread João Ferreira
New submission from João Ferreira: The usage that is printed by argparse with the "--help" argument is slightly incorrect when using mutually exclusive groups. This happens in version 3.4.3 but did not happen in version 3.4.0. I have this minimal example: import argparse p = argparse.Argumen

[issue23794] http package should support HTTP/2

2015-03-27 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag stage: -> needs patch type: -> enhancement versions: +Python 3.6 ___ Python tracker ___ _

[issue23794] http package should support HTTP/2

2015-03-27 Thread Alex Gaynor
New submission from Alex Gaynor: The spec is available at https://http2.github.io/ -- components: Library (Lib) messages: 239424 nosy: alex priority: normal severity: normal status: open title: http package should support HTTP/2 ___ Python tracker

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread Berker Peksag
Berker Peksag added the comment: This looks like a duplicate of issue 21398. I can reproduce it with Python 3.4.1 (compiled myself) on Ubuntu 12.04. >>> help(str) Ctrl-C :Traceback (most recent call last): File "", line 1, in File "/usr/local/lib/python3.4/_sitebuiltins.py", line 103, in

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread Ezio Melotti
Ezio Melotti added the comment: I can reproduce on Python 3 on Ubuntu 14.10. When I hit Ctrl+C I get: >>> help(range) ... | __hash__(self, /) | Return hash(self). | :Traceback (most recent call last): File "", line 1, in File "/home/wolf/dev/py/py3k/Lib/_sitebuiltins.py", line 103

[issue23790] When xdrlib.Packer().pack_string() fails, the Packer is corrupted

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I doubt that this issue is worth fixing. It is common that when error is happen inside complex operation, the output can be incomplete. When you pickle a list containing non-pickleable data, resulting file content will be not unpickleable. When you write a n

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread R. David Murray
R. David Murray added the comment: I can't reproduce this. Maybe it is a debian bug? -- nosy: +r.david.murray ___ Python tracker ___

[issue23793] Support __add__ for deques.

2015-03-27 Thread Raymond Hettinger
New submission from Raymond Hettinger: One more step towards making the deque API a little closer to that for lists: >>> deque('abc') + deque('def') deque(['a', 'b', 'c', 'd', 'e', 'f']) -- assignee: rhettinger components: Extension Modules files: deque_add4.diff keywords: pat

[issue23790] When xdrlib.Packer().pack_string() fails, the Packer is corrupted

2015-03-27 Thread Oskar Hahn
Oskar Hahn added the comment: I would prefer the reset_buffer.patch because I do not like argument testing at the begin of a function/method. -- ___ Python tracker ___ _

[issue23792] help crash leaves terminal in raw mode

2015-03-27 Thread Rusi
New submission from Rusi: Start python3.4 Do help(something) which invokes the pager Ctrl-C A backtrace results and after that the terminal is in raw mode even after exiting python [python 3.4 under debian testing with xfce4] -- components: IDLE messages: 239417 nosy: RusiMody priority

[issue23791] Identify Moved Lines with difflib

2015-03-27 Thread Brian
New submission from Brian: It would be a helpful feature to incorporate logic into the difflib module to optionally identify and ignore identical, but relocated lines when doing a diff. This would be used when the order of lines in a document is not critical, but rather just the overall conten

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0378c10ba164 by Victor Stinner in branch 'default': Issue #22117: Fix rounding in _PyTime_FromSecondsObject() https://hg.python.org/cpython/rev/0378c10ba164 -- ___ Python tracker

[issue23671] string.Template doesn't work with the self keyword argument

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It matches error messages generated by builtin unbound methods. >>> str.format() Traceback (most recent call last): File "", line 1, in TypeError: descriptor 'format' of 'str' object needs an argument It would be incorrect to say "substitute method wants x

[issue23787] sum() function docstring lists arguments incorrectly

2015-03-27 Thread Valentine Sinitsyn
Valentine Sinitsyn added the comment: Yes, strings aren't an issue. I only used them as an example. I came across this issue during code review, discussing if it is okay to pass generator expression to sum() (like sum(x*2 for x in xrange(5)) or is it better to convert it to the list first (sum

[issue23671] string.Template doesn't work with the self keyword argument

2015-03-27 Thread Éric Araujo
Éric Araujo added the comment: "descriptor 'substitute' of 'Template' object needs an argument" These error messages don’t seem very user-friendly. I think the style in the rest of the module is like "substitute method wants x y z". -- nosy: +eric.araujo _

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: Can you try simply: socket.create_connection(("sadflkjsasf.i.nvali.d.", 80)) Here is raise: socket.gaierror: [Errno -2] Name or service not known And what are your DNS servers? cat /etc/resolv.conf -- ___ Py

[issue23790] When xdrlib.Packer().pack_string() fails, the Packer is corrupted

2015-03-27 Thread R. David Murray
R. David Murray added the comment: Your patches are great, thanks. Now we have to decide which to use :) -- nosy: +r.david.murray ___ Python tracker ___

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread R. David Murray
R. David Murray added the comment: How did you determine it was that commit? It's a doc update, so it can't be affecting the code. The test passes for me, on linux. -- nosy: +r.david.murray ___ Python tracker __

[issue23789] decimal.Decimal: __format__ behaviour

2015-03-27 Thread R. David Murray
Changes by R. David Murray : -- nosy: +skrah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue23787] sum() function docstring lists arguments incorrectly

2015-03-27 Thread R. David Murray
R. David Murray added the comment: In python3 the docstring does say iterable. It wouldn't be a bad thing to change it in 2.7, but it is not much of a priority. iterable vs sequence makes no difference to the str question: a string is an iterable. The docstring explicitly says strings are e

[issue23445] Use -Og for debug builds

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: > Done. It shouldn't break anything. You're change skipped some test_gdb tests. I fixed the check in test_gdb/test.support. -- nosy: +haypo ___ Python tracker ___

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset b0b4c4d365b1 by Victor Stinner in branch 'default': Issue #22117: Fix test_gdb for the new time.sleep() https://hg.python.org/cpython/rev/b0b4c4d365b1 -- ___ Python tracker

[issue23445] Use -Og for debug builds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset c663dbb84c8c by Victor Stinner in branch '3.4': Issue #23445: Fix test.support.python_is_optimized() for CFLAGS=-Og https://hg.python.org/cpython/rev/c663dbb84c8c New changeset 5b5a22b9327b by Victor Stinner in branch '2.7': Issue #23445: Fix test_g

[issue23789] decimal.Decimal: __format__ behaviour

2015-03-27 Thread Paul Moore
Paul Moore added the comment: I believe it's the way it is because Python follows the Standard Decimal Specification, which includes tests for conformance to the current formatting behaviour. -- nosy: +paul.moore ___ Python tracker

[issue23715] PEP 475: handle EINTR in the signal module

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 35bc15fa4930 by Victor Stinner in branch 'default': Issue #23715: Fix test_sigtimedwait() of test_eintr https://hg.python.org/cpython/rev/35bc15fa4930 -- ___ Python tracker

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset f64d0b99d405 by Victor Stinner in branch 'default': Issue #23451, #22117: Python 3.5 now requires Windows Vista or newer, so https://hg.python.org/cpython/rev/f64d0b99d405 -- ___ Python tracker

[issue23451] Deprecation warnings building 3.5 Visual Studio Windows 8.1 64 bit

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset f64d0b99d405 by Victor Stinner in branch 'default': Issue #23451, #22117: Python 3.5 now requires Windows Vista or newer, so https://hg.python.org/cpython/rev/f64d0b99d405 -- ___ Python tracker

[issue7511] msvc9compiler.py: ValueError when trying to compile with VC Express

2015-03-27 Thread Zachary Ware
Zachary Ware added the comment: Paul Moore added the comment: > > Note that in spite of the name, the process should also work for Python > 3.2 and 3.3, which also use VS2008 (but I haven't tested that explicitly). > Just 3.2; 3.3 was the first version to use VS2010. -- ___

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Peter
Peter added the comment: Hi haypo, I just realized you had created a patch too, the fnv_memcpy.patch worked! $ LD_LIBRARY_PATH=/usr/local/src/Python-3.4.3 ./python -m test test_hash [1/1] test_hash 1 test OK. Running the full regression test now, but I bet everything passes. -- _

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread Raniere Silva
Raniere Silva added the comment: > Can you please complete your bug report? Can you specifiy your OS? GNU/Linux. $ uname -a Linux pupunha 3.19.2-1-ARCH #1 SMP PREEMPT Wed Mar 18 16:21:02 CET 2015 x86_64 GNU/Linux $ gcc --version gcc (GCC) 4.9.2 20150304 (prerelease) > Can you try to rerun the

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Peter
Peter added the comment: Sorry I copied the wrong term buffer :-) This is the output after I commented out the HashEqualityTestCase class which causes the core dump. LD_LIBRARY_PATH=/usr/local/src/Python-3.4.3 ./python -m test -v test_hash == CPython 3.4.3 (default, Mar 27 2015, 08:45:04) [GCC

[issue23790] When xdrlib.Packer().pack_string() fails, the Packer is corrupted

2015-03-27 Thread Oskar Hahn
Changes by Oskar Hahn : Added file: http://bugs.python.org/file38711/reset_buffer.patch ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue23790] When xdrlib.Packer().pack_string() fails, the Packer is corrupted

2015-03-27 Thread Oskar Hahn
New submission from Oskar Hahn: When xdrlib.Packer().pack_string() is called with an unsupported value, it raises a TypeError. But it calles self.pack_uint(n) before it raises the exception so the buffer is changed. There are two possible solutions to solve this behaviour. The argument s can b

[issue23789] decimal.Decimal: __format__ behaviour

2015-03-27 Thread Paul Eckhardt
New submission from Paul Eckhardt: The bahaviour of __format__ for decimal.Decimal type differs in one detail from float: The minimum number of digits used for the exponent is 1 for Decimal, and 2 for float. e.g.: "{:8.2E}".format(1.0) --> "1.00E+00" "{:8.2E}".format(Decimal(1.0)) --> " 1

[issue22117] Rewrite pytime.h to work on nanoseconds

2015-03-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 2309597e7a00 by Victor Stinner in branch 'default': Issue #22117: Add a new Python timestamp format _PyTime_t to pytime.h https://hg.python.org/cpython/rev/2309597e7a00 -- nosy: +python-dev ___ Python tra

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Peter
Peter added the comment: OK I recompiled with "./configure --prefix=/usr/local --enable-shared --with-pydebug" and reran the test, unfortunately... $ LD_LIBRARY_PATH=/usr/local/src/Python-3.4.3 ./python -m test test_hash [1/1] test_hash 1 test OK. I then applied the patch in msg239385, this

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: Hi, Can you please complete your bug report? Can you specifiy your OS? Can you try to rerun the test manually with "./python -m test -u all test_urllib2_localnet"? The test: def test_bad_address(self): # Make sure proper exception is raised when c

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: > Starting from Git commit 1996f3038458df2b6443c23e4705478ff5db43f8 https://github.com/python/cpython/commit/1996f3038458df2b6443c23e4705478ff5db43f8 => https://hg.python.org/cpython/rev/b7c0137cccbe -- nosy: +haypo ___

[issue23788] test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen

2015-03-27 Thread STINNER Victor
Changes by STINNER Victor : -- title: test_bad_address fails -> test_urllib2_localnet.test_bad_address fails: OSError not raised by urlopen ___ Python tracker ___ __

[issue23788] test_bad_address fails

2015-03-27 Thread Raniere Silva
New submission from Raniere Silva: Starting from Git commit 1996f3038458df2b6443c23e4705478ff5db43f8 $ ./configure $ make $ make test == FAIL: test_bad_address (test.test_urllib2_localnet.TestUrlopen) ---

[issue23611] Pickle nested names with protocols < 4

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Issue23403. But looks it is early yet for this. Note that this patch doesn't modify protocols. It just makes the pickler more smart and able to serialize more objects with existing protocols. It is the same as add pickle support for some type that didn't sup

[issue23787] sum() function docstring lists arguments incorrectly

2015-03-27 Thread Valentine Sinitsyn
New submission from Valentine Sinitsyn: sum() function doctstring describes expected arguments as follows (Python 2.7.6): sum(...) sum(sequence[, start]) -> value ... This implies sum() should accept str, unicode, list, tuple, bytearray, buffer, and xrange. However, you clearly can't use

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: AFAIK it conforms the C standard and should be portable (but weird compiler bugs or misconfiguration can make it broken). With Py_MEMCPY() the code is less optimal. Don't add regression on common platforms. -- __

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: The union trick is not portable, using memcpy() is safer. Compilers should be able to optimize it. Use Py_MEMCPY() for the stupid Visual Studio compiler unable to optimize memcpy() for small sizes. -- keywords: +patch Added file: http://bugs.python.org

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Or may be better to use explicit alignment 8 if this is 32-bit platform. diff -r a417d89fbc38 Python/pyhash.c --- a/Python/pyhash.c Thu Mar 26 09:37:23 2015 +0100 +++ b/Python/pyhash.c Fri Mar 27 12:02:55 2015 +0200 @@ -247,7 +247,7 @@ fnv(const void *src,

[issue23786] test_unaligned_buffers (test.test_hash.HashEqualityTestCase) ... Fatal Python error: Bus error

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What if add double field in the block union? (And may be compile with -munaligned-doubles) diff -r a417d89fbc38 Python/pyhash.c --- a/Python/pyhash.c Thu Mar 26 09:37:23 2015 +0100 +++ b/Python/pyhash.c Fri Mar 27 11:52:25 2015 +0200 @@ -247,6 +247,7 @@

[issue7511] msvc9compiler.py: ValueError when trying to compile with VC Express

2015-03-27 Thread Paul Moore
Paul Moore added the comment: The correct solution to this issue now is to install the Microsoft supplied "Visual C++ Compiler for Python 2.7" package (available as a free download from MSDN). That has all the components needed to build 32 and 64-bit extensions. Your setup.py needs to use setu

[issue18898] Apply the setobject optimizations to dictionaries

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: Hi, what's the status of this issue? Is anyone working one it? -- ___ Python tracker ___ ___ Python-

[issue23290] Faster set copying

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > I didn't expect that it's still possible to enhance set. Raymond made a lot of set optimizations recently. > By the way, is it possible to report latest enhancement to the dict type? I > don't remember if tou tried that richard? May be when Raymond port hi

[issue7511] msvc9compiler.py: ValueError when trying to compile with VC Express

2015-03-27 Thread Florian Bruhin
Changes by Florian Bruhin : -- nosy: +The Compiler ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue23509] Speed up Counter operators

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Added explanation comments to address Victor's comment. -- Added file: http://bugs.python.org/file38708/counter_faster_2.patch ___ Python tracker

[issue23488] Random objects twice as big as necessary on 64-bit builds

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Updated patch addresses some Victor's comments. -- Added file: http://bugs.python.org/file38707/random_uint32_2.patch ___ Python tracker ___ _

[issue23290] Faster set copying

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: New patch looks good to me. Great job on speedup. I didn't expect that it's still possible to enhance set. By the way, is it possible to report latest enhancement to the dict type? I don't remember if tou tried that richard? --

[issue23605] Use the new os.scandir() function in os.walk()

2015-03-27 Thread STINNER Victor
STINNER Victor added the comment: Ben Hoyt added the comment: > 1) The new implementation is more complex. Of course, most of this is necessary due to the topdown directory issue. Sure, correctness matters more than performances. > However, one thing I'm not sure about is why you create scandi

[issue23290] Faster set copying

2015-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Updated patch addresses Victor's comment. Thank you for your review Victor. > Is msg234811 the result of set_faster_copy_3.patch? Yes, it is. There are tests for sets with small and large number of hash conflicts, with and without dummy objects. The patch af

  1   2   >