[issue23275] Can assign [] = (), but not () = []

2015-05-27 Thread Stefan Behnel
Changes by Stefan Behnel sco...@users.sourceforge.net: -- nosy: +scoder ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23275 ___ ___

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

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: I've made this depend on issue 23810, rather than duplicating it. That way, issue 23810 can cover fixing the stdlib deprecation warnings, while this can cover making it a public API. -- dependencies: +Suboptimal stacklevel of deprecation warnings for

[issue24306] Backport py.exe to 3.4

2015-05-27 Thread Steve Dower
Steve Dower added the comment: I didn't mention it initially, but the harm it can do is overriding newer versions. The 3.5 and later installers have proper versioning built in, but I don't think that's possible with the 3.4 installer as well (due to MSI limitations, not any deficiency of the

[issue24310] Idle documentation -- what to do if you do not see an underscore.

2015-05-27 Thread Ned Deily
Ned Deily added the comment: That may be a problem better fixed in Tk itself. I don't have a Retina display handy. Assuming you have a current ActiveTcl 8.5 (8.5.18) installed, could you try some of the Tk text widget demos in /usr/local/bin/wish8.5 and see if the problem shows up there,

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: I'm OK with the patch as is, but I'm definitely concerned about the maintainability of inspect.signature in general. I'm trying to decide if a block comment covering the order of calling protocols that we check, and where we potentially recurse, would be a help

[issue24294] DeprecationWarnings should be visible by default in the interactive REPL

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: +1 for showing DeprecationWarning by default (as these features may be going away in the next X.Y release of Python) -0 for showing PendingDeprecationWarning by default (as these won't be going away until X.Y+1 at the earliest) -- nosy: +ncoghlan

[issue24307] pip error on windows whose current user name contains non-ascii characters

2015-05-27 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- nosy: +Marcus.Smith, dstufft, ncoghlan, paul.moore ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24307 ___

[issue24308] Test failure: test_with_pip (test.test_venv.EnsurePipTest in 3.x

2015-05-27 Thread koobs
koobs added the comment: My mistake, revision 1ca30423b0c99c9599d5d4654323eeeae4a03804 or revision 29b95625a07cc5bb22e260c983500ed9efed67bf -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24308

[issue18032] Optimization for set/frozenset.issubset()

2015-05-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: Personally I don't sure that this optimization is worth to apply. I concur. Closing as not worth it :-) -- resolution: - rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue24306] Backport py.exe to 3.4

2015-05-27 Thread Mark Lawrence
Mark Lawrence added the comment: Can it actually do any harm? It certainly appears to remove the potential for a lot of bug reports from a lot of frustrated users, myself included. -- nosy: +BreamoreBoy ___ Python tracker rep...@bugs.python.org

[issue23810] Suboptimal stacklevel of deprecation warnings for formatter and imp modules

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: Issue 24305 covers either making this a public API for general use, or else just making module level deprecation warnings skip the import machinery automatically. I also wonder whether Eric's _boostrap_external changes might have broken any of the frame hiding

[issue24310] Idle documentation -- what to do if you do not see an underscore.

2015-05-27 Thread Laura Creighton
New submission from Laura Creighton: On some operating systems, for instance a Macbook Pro with Retina, the bottoms of hanging letters such as 'g' or 'y', as well as underscorces, cannot be seen in IDLE. The fix is to go to Options - Configure IDLE, and change the size of the default font to

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: Thanks for highlighting these Stefan - you guessed correctly that I'd missed them on the review. For your first question, I agree getawaitablefunc / aiternextfunc / getaiterfunc should all be dropped and replaced with the existing unaryfunc. For your second

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: Given that tp_call is just ternaryfunc, my guess would be because when the iterator protocol was added, someone went with function-pointer-type-per-slot rather than function-pointer-type-per-call-signature. We *are* a little inconsistent here (e.g. reprfunc

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

2015-05-27 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- nosy: +brett.cannon, eric.snow, ncoghlan ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24305 ___ ___

[issue4753] Faster opcode dispatch on gcc

2015-05-27 Thread Robert Collins
Robert Collins added the comment: FWIW I'm interested and willing to poke at this if more testers/reviewers are needed. -- nosy: +rbcollins ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4753

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-05-27 Thread Ethan Furman
Ethan Furman added the comment: On the SO question [1] the OP stated that he tried errorlevel of both 1 and 2 with no effect... however, he was using Python2.6. Martin, can you run that same test with 2.6 to verify that errorlevel did not work there, but does now? [1]

[issue24310] Idle documentation -- what to do if you do not see an underscore.

2015-05-27 Thread Ned Deily
Ned Deily added the comment: Yes, that's probably a good thing to do in any case. I can add it to the Tcl/Tk info page for OS X as at least an interim measure: https://www.python.org/download/mac/tcltk/ -- assignee: docs@python - ned.deily components: +IDLE versions: -Python 3.2,

[issue24310] Idle documentation -- what to do if you do not see an underscore.

2015-05-27 Thread Laura Creighton
Laura Creighton added the comment: Thank you. I don't think that this problem is unique to Retina Macbooks -- I had it on an ancient Toshiba laptop I was using about 15 years ago. It's not something that I have thought of very much recently. :) --

[issue24308] Test failure: test_with_pip (test.test_venv.EnsurePipTest in 3.x

2015-05-27 Thread koobs
New submission from koobs: test_with_pip fails since revision 0d0989359bbbff9aa502158e362eb298e1a8ba7c with the following output: == FAIL: test_with_pip (test.test_venv.EnsurePipTest)

[issue4753] Faster opcode dispatch on gcc

2015-05-27 Thread Ned Deily
Ned Deily added the comment: @Vamsi, could you please open a new issue and attach your patch there so it can be properly tracked for 2.7? This issue has been closed for five years and the code has been out in the field for a long time in Python 3. Thanks! -- nosy: +ned.deily

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

2015-05-27 Thread Nathaniel Smith
New submission from Nathaniel Smith: (Noticed while fixing the IPython equivalent of issue 24294) The obvious way to deprecate a module is to issue a DeprecationWarning inside the main body of the module, i.e. # thirdpartymodule.py import warnings warnings.warn({} is

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: It occurs to me we're also bypassing the check that the unwrapped obj is a callable, so it probably makes sense to just recurse unconditionally after unwrapping the object, rather than only recursing for methods. That's also a little more future-proof, in case

[issue4753] Faster opcode dispatch on gcc

2015-05-27 Thread Srinivas Vamsi Parasa
Srinivas Vamsi Parasa added the comment: Hi All, This is Vamsi from Server Scripting Languages Optimization team at Intel Corporation. Would like to submit a request to enable the computed goto based dispatch in Python 2.x (which happens to be enabled by default in Python 3 given its

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

2015-05-27 Thread Barry A. Warsaw
Changes by Barry A. Warsaw ba...@python.org: -- nosy: +barry ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24305 ___ ___ Python-bugs-list mailing

[issue18032] Optimization for set/frozenset.issubset()

2015-05-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Personally I don't sure that this optimization is worth to apply. Its cost is high and optimized case is not common. This is rather an experiment, how large can be maximal effect of the optimization. -- ___

[issue24175] Sporadic test_utime() failures on FreeBSD

2015-05-27 Thread koobs
koobs added the comment: See also: Issue 16287 (Solaris) Issue 15745 (Related to FreeBSD/ZFS, has patch) 3.4 and 3.x are still failing -- title: Test failure in test_utime on FreeBSD - Sporadic test_utime() failures on FreeBSD ___ Python tracker

[issue24309] string.Template should be using str.format and/or deprecated

2015-05-27 Thread Dmitry Kazakov
New submission from Dmitry Kazakov: I came across this piece of code in Lib/string.py:146: # We use this idiom instead of str() because the latter will # fail if val is a Unicode containing non-ASCII characters. return '%s' % (mapping[named],) This seems vestigial. I think it'd be

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Yury Selivanov
Yury Selivanov added the comment: It *is* correct, see PEP 492. Awaitable is either a coroutine *or* an object with an __await__ method. coroutine, yes. But Coroutine? Shouldn't the Coroutine ABC then require __await__ to be implemented? Maybe even by inheriting from Awaitable? This

[issue24309] string.Template should be using str.format and/or deprecated

2015-05-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I'm strongly -1 for deprecating string.Template. It provides simple, widely used syntax, and is used in a lot of third-party code. I don't think that it needs to be extended. However I have an idea about implementing general string composing engine than

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Yury Selivanov
Yury Selivanov added the comment: For your first question, I agree getawaitablefunc / aiternextfunc / getaiterfunc should all be dropped and replaced with the existing unaryfunc. I have no problem with that. But why do we have iternextfunc getiterfunc (no a prefix)? --

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-05-27 Thread Martin Panter
Martin Panter added the comment: Actually, looking closer at the module, perhaps you just need to set the errorlevel=1 option: with tarfile.open(truncated.tar, errorlevel=1) as tar:... tar.extractall(test-dir) ... Traceback (most recent call last): File stdin, line 2, in module

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-05-27 Thread Martin Panter
Martin Panter added the comment: I guess it depends on the particular tar file and where it gets truncated. Just now I tested with a tar file created from Python’s Tools directory: $ tar c Tools/ good.tar $ ls -gG good.tar -rw-r--r-- 1 17397760 May 28 02:43 good.tar $ head -c 13 good.tar

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

2015-05-27 Thread Berker Peksag
Berker Peksag added the comment: This looks like a duplicate of issue 23810 (there is a patch for stdlib usages, but it probably can be changed to a more general solution). -- nosy: +berker.peksag ___ Python tracker rep...@bugs.python.org

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Stefan Behnel
Stefan Behnel added the comment: I added a couple of review comments to patch 6, but since no-one has responded so far, I guess they simply haven't been noticed. So I'll just repeat them here. 1) getawaitablefunc / aiternextfunc / getaiterfunc Is there a reason why these need to have their

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Yury Selivanov
Yury Selivanov added the comment: 2) Awaitable.register(Coroutine) I think this is incorrect. A Coroutine is not Awaitable unless it also implements __await__. How else should it be awaited? It *is* correct, see PEP 492. Awaitable is either a coroutine *or* an object with an __await__

[issue24309] string.Template should be using str.format and/or deprecated

2015-05-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: I came across this piece of code in Lib/string.py:146: That may be artifact from the days of ASCII strings and may or may not have analog with the bytes data type. But I'm not exactly sure string.Template should be in Python 3 at all. It still has

[issue24301] gzip module failing to decompress valid compressed file

2015-05-27 Thread Martin Panter
Martin Panter added the comment: I suspect Eric’s file has non-zero, non-gzip garbage bytes appended to the end of it. Assuming I am right, here is way to reproduce that scenario: from gzip import GzipFile from io import BytesIO file = BytesIO() with GzipFile(fileobj=file, mode=wb) as z:

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Yury Selivanov
Yury Selivanov added the comment: That's also a little more future-proof, in case any further checks happen to be inserted ahead of the check for __wrapped__. Well, we unwrap until we see a __signature__ attribute (or we can't unwrap anymore). And right after unwrapping we try to return

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-05-27 Thread Ethan Furman
Ethan Furman added the comment: Actually, the OP was using 2.7.6. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24259 ___ ___ Python-bugs-list

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Yury Selivanov
Yury Selivanov added the comment: I'm OK with the patch as is, but I'm definitely concerned about the maintainability of inspect.signature in general. I agree, _signature_from_callable is getting quite complex. The good news is that we have a very good test coverage for signatures. As for

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset 42819b176d63 by Yury Selivanov in branch '3.4': Issue 24298: Fix signature() to properly unwrap wrappers around bound methods https://hg.python.org/cpython/rev/42819b176d63 New changeset d7e392c5c53a by Yury Selivanov in branch '3.5': Issue 24298:

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Yury Selivanov
Changes by Yury Selivanov yseliva...@gmail.com: -- resolution: - fixed stage: patch review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24298 ___

[issue24307] pip error on windows whose current user name contains non-ascii characters

2015-05-27 Thread tanbro-liu
New submission from tanbro-liu: On windows8.1 x64, current user name contains non-ascii characters. When executing ``pip`` in the command-line, such an error happens:: C:\Users\雪彦pip Traceback (most recent call last): File C:\Python27\lib\runpy.py, line 162, in

[issue24309] string.Template should be using str.format and/or deprecated

2015-05-27 Thread Dmitry Kazakov
Dmitry Kazakov added the comment: Ugh, I guess I was too quick to propose deprecation, sorry :( But is it a strict No to the proposed use of str.format as well? This would be a (relatively) minor but useful change which, again, won't break anything. I can write the patch. --

[issue23275] Can assign [] = (), but not () = []

2015-05-27 Thread Nick Coghlan
Nick Coghlan added the comment: +1 for Martin's suggestion of removing the inconsistency the other way (i.e. allowing () = iterable to mean the same thing as [] = iterable, effectively asserting that an iterable is empty) I also agree with Raymond that it doesn't need to be mentioned in the

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-05-27 Thread Ethan Furman
Ethan Furman added the comment: I took an existing tar file and chopped it in half with `head -c`. I was able to extract half the files, but I didn't check the viability of the last file as I was looking for tar or python error feedback. -- ___

[issue24017] Implemenation of the PEP 492 - Coroutines with async and await syntax

2015-05-27 Thread Stefan Behnel
Stefan Behnel added the comment: Another question: is it ok if Cython implements and uses the tp_as_async slot in all Py3.x versions (3.2+)? It shouldn't hurt, but it would speed up async/await in Cython at least under Py3.x. Only Py2.6/7 would then have to resort to calling __await__() etc.

[issue24310] Idle documentation -- what to do if you do not see an underscore.

2015-05-27 Thread Laura Creighton
Laura Creighton added the comment: I don't have one, alas. It was a question sent to webmaster. I just happened to know that reconfiguring your font size fixes the 'no underscore' problem, so it occured to me that mentioning this in the idle documentation might save some grief. --

[issue24304] Documentation broken link to license

2015-05-27 Thread Ned Deily
Ned Deily added the comment: Thanks for the report! -- nosy: +ned.deily resolution: - fixed stage: - resolved status: open - closed versions: +Python 2.7, Python 3.4, Python 3.5 ___ Python tracker rep...@bugs.python.org

[issue1243678] httplib gzip support

2015-05-27 Thread Martin Panter
Changes by Martin Panter vadmium...@gmail.com: -- superseder: Performance for small reads and fix seek problem - transparent gzip compression in urllib ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1243678

[issue24290] c_uint32 bitfields break structures

2015-05-27 Thread Rony Batista
Rony Batista added the comment: Well, looks like the issue is with 64 bit mode then. For the first 5 cases the right answer is 69.95930480957031, and for the last 2 its -69.95930480957031. The results for the 32 bit mode are all correct. -- ___

[issue24293] Windows installer unreadable with std/custom themes

2015-05-27 Thread Mike Miller
Mike Miller added the comment: Thanks. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24293 ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue24298] inspect.signature includes bound argument for wrappers around bound methods

2015-05-27 Thread Yury Selivanov
Changes by Yury Selivanov yseliva...@gmail.com: Added file: http://bugs.python.org/file39526/signature2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24298 ___

[issue24304] Documentation broken link to license

2015-05-27 Thread Roundup Robot
Roundup Robot added the comment: New changeset d4080f3c0894 by Ned Deily in branch '2.7': Issue 24304: Fix broken license link in FAQ. https://hg.python.org/cpython/rev/d4080f3c0894 New changeset 8631d61f6577 by Ned Deily in branch '3.4': Issue 24304: Fix broken license link in FAQ.

[issue24294] DeprecationWarnings should be visible by default in the interactive REPL

2015-05-27 Thread Nathaniel Smith
New submission from Nathaniel Smith: DeprecationWarning and PendingDeprecationWarning are invisible by default. The rationale for this is that they are only useful to people who are writing code, so they should not be shown to end-users who are merely running code. If someone is typing stuff

[issue24294] DeprecationWarnings should be visible by default in the interactive REPL

2015-05-27 Thread Nathaniel Smith
Nathaniel Smith added the comment: I also filed a similar bug with ipython: https://github.com/ipython/ipython/issues/8478 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24294 ___

<    1   2