[issue24404] Python 2.7.0's BZ2File does not support with-statements

2015-06-07 Thread Fabian
New submission from Fabian: I had a weird bug recently where someone tried to use the with-statement on a BZ2File. According to the documentation it was added in 2.7 and looking at https://hg.python.org/cpython/rev/5d5d9074f4ca it looks like it was added together with the support in gzip.

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Is there any performance difference? -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20186 ___

[issue22865] Document how to make pty.spawn not copy data

2015-06-07 Thread Geoff Shannon
Geoff Shannon added the comment: Hey, pinging this issue. Hoping someone has time to take a look at it. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22865 ___

[issue19915] int.bit_at(n) - Accessing a single bit in O(1)

2015-06-07 Thread Steven D'Aprano
Changes by Steven D'Aprano steve+pyt...@pearwood.info: -- nosy: +steven.daprano ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19915 ___ ___

[issue8232] webbrowser.open incomplete on Windows

2015-06-07 Thread Brandon Milam
Brandon Milam added the comment: Moved the 64 bit browser list to its own loop and switched to browsers.append rather than +=. -- Added file: http://bugs.python.org/file39650/webbrowserfix6.patch ___ Python tracker rep...@bugs.python.org

[issue24403] Missing fixer for changed round() behavior

2015-06-07 Thread Mark Dickinson
Mark Dickinson added the comment: The old behaviour certainly can be emulated, but doing that correctly would require 4 or 5 lines of code. I don't know enough about 2to3 to know whether it can handle that sort of translation, but even if it can, I'd guess that in a good proportion of cases

[issue24400] Awaitable ABC incompatible with functools.singledispatch

2015-06-07 Thread Guido van Rossum
Guido van Rossum added the comment: I think it's actually good feedback and we should fix this during the beta. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24400 ___

[issue14373] C implementation of functools.lru_cache

2015-06-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: test_lru_cache_threaded is randomly failed on PPC64 PowerLinux buildbot: http://buildbot.python.org/all/builders/PPC64%20PowerLinux%203.x/builds/3573/steps/test/logs/stdio == FAIL:

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Tal Einat
Tal Einat added the comment: I tried running the pystone benchmark, but the results were inconclusive. I saw very large differences (up to 20%) between runs at different times, with no clear differences with or without the patch. However, a quick search shows that the operator module is

[issue18576] Document test.support.script_helper

2015-06-07 Thread Christie
Christie added the comment: If you diffed your patch from a public revision in the main repository, there should be a nice “Review” link. Ah, thanks @vadmium!!! I've been confused about why some patches get review links and others do not . I'll have a new patch up shortly which is diffed

[issue8232] webbrowser.open incomplete on Windows

2015-06-07 Thread Steve Dower
Steve Dower added the comment: That looks good to me, I'll get it merged in when I'm at my desk. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8232 ___

[issue24255] Replace debuglevel-related logic with logging

2015-06-07 Thread Eryn Wells
Eryn Wells added the comment: Here's a patch that replaces all the debuglevel stuff with logging. There's a single module-level logger that handles it all. I wasn't sure if it would be okay to break API compatibility, so I kept the debuglevel flag and the set_debuglevel() method even though

[issue18003] lzma module very slow with line-oriented reading.

2015-06-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: This looks good to me. -- stage: patch review - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18003 ___

[issue18003] lzma module very slow with line-oriented reading.

2015-06-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Perhaps this change is worth to mention in whatsnews. Could you add this Martin? It would be nice also add tests to ensure that next() after closing the file always raises ValueError. -- ___ Python tracker

[issue14003] __self__ on built-in functions is not as documented

2015-06-07 Thread eryksun
eryksun added the comment: In Python 2 [Py_InitModule4][1] optionally allows setting __self__ on module functions, but no module in the standard library actually uses this. It's always None. This is no longer optional with Python 3's [PyModule_Create][2]. Built-in module functions

[issue24397] Test asynchat makes wrong assumptions

2015-06-07 Thread Étienne Buira
Étienne Buira added the comment: The issue is that this buffer is also emptied at the end. Current version assumes that the server thread will not have enough opportunity to send the whole buffer before receiving a RST. But in reality, it's quite possible (happens reliably on a box) that: 1.

[issue24362] Simplify the fast nodes resize logic in C OrderedDict.

2015-06-07 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- stage: patch review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24362 ___

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Tal Einat
Tal Einat added the comment: Attached is a patch for all of _operator except for itemgetter, attrgetter and methodcaller. The entire test suite passes after applying this patch. Using AC has allowed the removal of all of the cryptic spam*() macros in the code, making it much more

[issue24403] Missing fixer for changed round() behavior

2015-06-07 Thread Mark Dickinson
Mark Dickinson added the comment: This is a bit tricky. The first expression you suggest doesn't work at all for negative numbers (e.g., producing `-3.0` for `round(-1.8)`). The second expression *mostly* works as you want, but not entirely. Some examples: def f(n): return

[issue24305] The new import system makes it impossible to correctly issue a deprecation warning for a module

2015-06-07 Thread Jakub Wilk
Changes by Jakub Wilk jw...@jwilk.net: -- nosy: +jwilk ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24305 ___ ___ Python-bugs-list mailing list

[issue24325] Speedup types.coroutine()

2015-06-07 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24325 ___

[issue22865] Document how to make pty.spawn not copy data

2015-06-07 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +twouters ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22865 ___ ___ Python-bugs-list

[issue14373] C implementation of functools.lru_cache

2015-06-07 Thread Tim Graham
Tim Graham added the comment: Thanks, that does resolve the issue. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14373 ___ ___ Python-bugs-list

[issue24264] imageop Unsafe Arithmetic

2015-06-07 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24264 ___

[issue24401] Windows 8.1 install gives DLL required to complete could not run

2015-06-07 Thread Laura Creighton
Laura Creighton added the comment: Definitely 3.3 and 3.4. I asked, got back '3.3 through the latest' so maybe 3.5 was not the latest where he was ... I will go ask again for 3.5 in particular. -- ___ Python tracker rep...@bugs.python.org

[issue24401] Windows 8.1 install gives DLL required to complete could not run

2015-06-07 Thread Steve Dower
Steve Dower added the comment: Did it fail for 3.3, 3.4 AND 3.5? Or was it not clear which version they were having trouble with? 3.5 is so different from earlier versions I'd be very surprised for this kind of failure to be the same. -- ___

[issue24402] input() uses sys.__stdout__ instead of sys.stdout for prompt

2015-06-07 Thread eryksun
eryksun added the comment: This looks like an oversight. In the implementation in [bltinmodule.c][1], if checking sys.stdout.fileno() fails, it clears the error without setting tty = 0. It's the [same in 3.5][2]. /* We should only use (GNU) readline if Python's sys.stdin and

[issue24391] Better repr for threading objects

2015-06-07 Thread Larry Hastings
Larry Hastings added the comment: The world of reprs already isn't particularly consistent. If you make your reprs consistent with module X, it'll be *inconsistent* with module Y, and vice versa. I say let's just worry about making it nice and readable for humans. That said, I like the

[issue24403] Missing fixer for changed round() behavior

2015-06-07 Thread priska
priska added the comment: Yes, those quick suggestions weren't thoroughly tested at all and turned out to be too short-sighted – thanks for checking, but are you saying the old behavior cannot be emulated or that it is not desirable to to so? --

[issue14003] __self__ on built-in functions is not as documented

2015-06-07 Thread Dmitry Kazakov
Changes by Dmitry Kazakov jsb...@gmail.com: -- nosy: +vlth ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14003 ___ ___ Python-bugs-list mailing

[issue18814] Add utilities to clean surrogate code points from strings

2015-06-07 Thread Steven D'Aprano
Changes by Steven D'Aprano steve+pyt...@pearwood.info: -- nosy: +steven.daprano ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18814 ___ ___

[issue24403] Missing fixer for changed round() behavior

2015-06-07 Thread priska
New submission from priska: The behavior of the round() function has changed between Python 2.x and Python3.x. From the release notes of Python 3.0: The round() function rounding strategy and return type have changed. Exact halfway cases are now rounded to the nearest even result instead of

[issue8232] webbrowser.open incomplete on Windows

2015-06-07 Thread Roundup Robot
Roundup Robot added the comment: New changeset b75c600e1614 by Steve Dower in branch '3.5': Issue #8232: webbrowser support incomplete on Windows. Patch by Brandon Milam https://hg.python.org/cpython/rev/b75c600e1614 New changeset 63b6e150b635 by Steve Dower in branch 'default': Issue #8232:

[issue24252] IDLE removes elements from tracebacks.

2015-06-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: Did you test my proposed patch? I am reluctant to make major changes in the absence of either documentation for why the code is as it is or test cases. So I do not know about trimming top versus bottom and the examples intended to show both are needed. I

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Tal Einat
Tal Einat added the comment: Attached a slightly revised patch thanks to Serhiy's review. In addition to Serhiy's remarks, I used _operator._compare_digest = _operator.eq to reduce a bit more boilerplate. -- Added file: http://bugs.python.org/file39654/issue20186._operator.v2.patch

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The operator module is rarely used in the stdlib, but if it is used in user code (mainly with map(), reduce() or like) the performance often is important. You can use microbenchmarks like following (operator.add is twice faster than lambda x, y: x + y).

[issue23377] HTTPResponse may drop buffer holding next response

2015-06-07 Thread Demian Brecht
Demian Brecht added the comment: Actually had a few free minutes so stuck a couple minor comments in Rietveld. Will have another go as soon as possible. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23377

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Tal Einat
Tal Einat added the comment: I just ran such microbenchmarks for operator.add and operator.not_, and saw no significant difference with or without the patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20186

[issue24402] input() uses sys.__stdout__ instead of sys.stdout for prompt

2015-06-07 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24402 ___ ___ Python-bugs-list mailing list

[issue24403] Missing fixer for changed round() behavior

2015-06-07 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- nosy: +benjamin.peterson ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24403 ___ ___ Python-bugs-list

[issue20186] Derby #18: Convert 31 sites to Argument Clinic across 23 files

2015-06-07 Thread Tal Einat
Tal Einat added the comment: Here's another complete conversion patch for _operator. As suggested by Serhiy, I changed the comparison operators to copy the signature from _operator.eq() instead of _operator.lt(), which is easier to understand. -- Added file:

[issue23891] Tutorial doesn't mention either pip or virtualenv

2015-06-07 Thread Tal Einat
Tal Einat added the comment: modules.patch and tutorial.patch LGTM. venv.patch is looking good; I posted two relatively minor comments on Rietveld. -- nosy: +taleinat ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23891

[issue24401] Windows 8.1 install gives DLL required to complete could not run

2015-06-07 Thread Laura Creighton
New submission from Laura Creighton: Another report from webmaster. (I still don't have a windows machine). Somebody tried to install 3.3, 3.4 or 3.5 and got this error. I asked them to try the Activestate installer. That worked. Thus Activestate knows to include something that users

[issue24402] input() uses sys.__stdout__ instead of sys.stdout for prompt

2015-06-07 Thread Keita Kita
New submission from Keita Kita: On Python 3.4, input() does not use wrapped sys.stdout. For example, the following script should print Wrapped stdout by print() and input() because sys.stdout is replaced with Writer object. import io import sys class Writer: def

[issue14102] argparse: add ability to create a man page

2015-06-07 Thread Mathieu Bridon
Changes by Mathieu Bridon boche...@daitauha.fr: -- nosy: +bochecha ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14102 ___ ___ Python-bugs-list

[issue14102] argparse: add ability to create a man page

2015-06-07 Thread Mathieu Bridon
Mathieu Bridon added the comment: Any news on this? The code posted by Oz Tiram (I took the latest from his github repo) works quite well, even with Python 3. (I just tested it) It would be great if argparse could include the formatter class, as well as the distutils command. --

[issue24384] difflib.SequenceMatcher faster quick_ratio with lower bound specification

2015-06-07 Thread Tal Einat
Tal Einat added the comment: Your second suggestion of adding a 'threshold' parameter to quick_ratio() is a bad idea in my opinion, since it would then be two significantly different functions crammed into one. The separate function would be possible. However, is there a compelling reason

[issue24400] Awaitable ABC incompatible with functools.singledispatch

2015-06-07 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- priority: normal - release blocker stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24400 ___

[issue24404] Python 2.7.0's BZ2File does not support with-statements

2015-06-07 Thread Ned Deily
Ned Deily added the comment: The misbehavior in Python 2.7 was due to a bug as documented in Issue9928, a bug that unfortunately was not discovered until just after 2.7 was initially released. The fix for Issue9928 was first included in 2.7.1 as you discovered. So the documentation has

[issue14373] C implementation of functools.lru_cache

2015-06-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch that adds __get__ for lru_cache object. -- Added file: http://bugs.python.org/file39646/clru_cache_descr_get.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14373

[issue23891] Tutorial doesn't mention either pip or virtualenv

2015-06-07 Thread A.M. Kuchling
A.M. Kuchling added the comment: One unrelated improvement: describe some of the recently-added modules, and mention the json module. -- keywords: +patch Added file: http://bugs.python.org/file39647/modules.patch ___ Python tracker

[issue23891] Tutorial doesn't mention either pip or virtualenv

2015-06-07 Thread A.M. Kuchling
A.M. Kuchling added the comment: Rewrite discussion of python-list a bit, and add pyvideo.org to the list of links. -- Added file: http://bugs.python.org/file39648/tutorial.patch ___ Python tracker rep...@bugs.python.org

[issue23891] Tutorial doesn't mention either pip or virtualenv

2015-06-07 Thread A.M. Kuchling
A.M. Kuchling added the comment: Finally, the major stuff: add a section on pyvenv and pip to the tutorial. -- Added file: http://bugs.python.org/file39649/venv.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23891

[issue23891] Tutorial doesn't mention either pip or virtualenv

2015-06-07 Thread A.M. Kuchling
Changes by A.M. Kuchling a...@amk.ca: -- stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23891 ___ ___ Python-bugs-list

[issue24397] Test asynchat makes wrong assumptions

2015-06-07 Thread R. David Murray
R. David Murray added the comment: The comments in the test indicate that this possibility was considered and dealt with. So that indicates it is a test bug in this particular test (test_close_when_done, for other readers), not in the fixture. It looks like the race condition still exists,

[issue24278] Docs on Parsing arguments should say something about mem mgmt for formatters returning C strings

2015-06-07 Thread Martin Blais
Martin Blais added the comment: LGTM! Thanks for making the change. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24278 ___ ___