[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-01 Thread Madhav Datt
New submission from Madhav Datt: The problem is described with an example in this StackOverflow question (https://stackoverflow.com/questions/26589805/python-enums-across-modules). Like in C and other languages, I would expect Enum equality to work across modules and not compare enum

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 1c92c0edca413c6f8ce8ec326a67451ae751ead9 by Mariatta in branch '3.6': bpo-30052: Link `bytes` & `bytearray` to stdtypes not functions (GH-1271) (GH-1915) https://github.com/python/cpython/commit/1c92c0edca413c6f8ce8ec326a67451ae751ead9

[issue30303] IDLE: Add _utest to textview and add textview tests

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +1996 ___ Python tracker ___ ___

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +1995 ___ Python tracker ___ ___

[issue29514] Add a test case that prevents magic number changes in minor releases

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- stage: patch review -> backport needed ___ Python tracker ___

[issue30392] default webbrowser fails on macOS Sierra 10.12.5

2017-06-01 Thread Kevin Ballard
Kevin Ballard added the comment: There is a potential workaround that could be used so that way macOS 10.12.5 works. It turns out that, with osascript, if you catch the error and try again, it works. $ osascript < try > open location "http://apple.com; > on error > open location

[issue21783] smtpd.py does not allow multiple helo/ehlo commands

2017-06-01 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: I don't have much interest in working on this for smtpd.py any more. We have an asyncio-based version that's much better, albeit Python 3 only. https://github.com/aio-libs/aiosmtpd This same issue is open over there; if you're still interested in this,

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset cca3d4aa25a7aea0cda90dd2aa012f58c85e7e24 by Mariatta (Matthias Bussonnier) in branch '3.5': bpo-29660: traceback: Document that etype is ignored in some places. (GH-344) (GH-1914)

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks :) -- resolution: -> fixed stage: backport needed -> resolved status: open -> closed ___ Python tracker ___

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset e417d12d728103445b8516a35f643536e401f120 by Mariatta (Matthias Bussonnier) in branch '3.6': bpo-29660: traceback: Document that etype is ignored in some places. (GH-344) (GH-1913)

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Matthias Bussonnier
Changes by Matthias Bussonnier : -- pull_requests: +1994 ___ Python tracker ___

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Matthias Bussonnier
Changes by Matthias Bussonnier : -- pull_requests: +1993 ___ Python tracker ___

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Matthias Bussonnier
Matthias Bussonnier added the comment: Thanks @Mariatta, I'll try to cherry-pick! -- ___ Python tracker ___

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-01 Thread Segev Finer
Changes by Segev Finer : -- pull_requests: +1992 ___ Python tracker ___ ___

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-01 Thread Segev Finer
New submission from Segev Finer: Found due to this: https://github.com/pytest-dev/py/issues/103 I'm going to submit a PR. -- components: IO, Windows messages: 294975 nosy: Segev Finer, paul.moore, steve.dower, tim.golden, zach.ware priority: normal severity: normal status: open title:

[issue25324] Importing tokenize modifies token

2017-06-01 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +1991 ___ Python tracker ___ ___

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks Matthias. I can backport this later today. Or do you want to do it? :) You can use cherry_picker.py https://github.com/python/core-workflow/tree/master/cherry_picker -- ___ Python tracker

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- stage: patch review -> backport needed ___ Python tracker ___

[issue29660] Document that print/format_exception ignore etype

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset cdb89cd72cbc66e4626914b4a71b9052ddb3a32a by Mariatta (Matthias Bussonnier) in branch 'master': bpo-29660: traceback: Document that etype is ignored in some places. (GH-344)

[issue30541] Add restricted mocks to the python unittest mocking framework

2017-06-01 Thread Eric N. Vander Weele
Changes by Eric N. Vander Weele : -- nosy: +ericvw ___ Python tracker ___ ___

[issue30543] test_timeout fails on AMD64 FreeBSD CURRENT Debug 3.x: ConnectionResetError: [Errno 54] Connection reset by peer

2017-06-01 Thread STINNER Victor
Changes by STINNER Victor : -- keywords: +buildbot ___ Python tracker ___ ___

[issue30543] test_timeout fails on AMD64 FreeBSD CURRENT Debug 3.x: ConnectionResetError: [Errno 54] Connection reset by peer

2017-06-01 Thread STINNER Victor
New submission from STINNER Victor: http://buildbot.python.org/all/builders/AMD64%20FreeBSD%20CURRENT%20Debug%203.x/builds/350/steps/test/logs/stdio testAcceptTimeout (test.test_timeout.TCPTimeoutTestCase) ... ok testConnectTimeout (test.test_timeout.TCPTimeoutTestCase) ... skipped "Resource

[issue30177] pathlib.resolve(strict=False) only includes first child

2017-06-01 Thread Antoine Pietri
Antoine Pietri added the comment: So, I asked a friend to check again with a more recent Python version on Windows and he can't reproduce the documented behavior, so the bug seems to also be present on Windows. My patch doesn't address that for now, which explains why the build fails (and why

[issue25324] Importing tokenize modifies token

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Albert-Jan Nijburg added the comment: > Aah! Oops I can fix later today. Don't worry. Our test suite and all reviewers also missed it ;-) -- ___ Python tracker

[issue30541] Add restricted mocks to the python unittest mocking framework

2017-06-01 Thread Mario Corchero
Mario Corchero added the comment: Sample implementation using the new class: https://github.com/mariocj89/cpython/commit/2f13963159e239de041cd68273b9fc4a2aa778cd Sample implementation using the new function to seal existing mocks:

[issue22393] multiprocessing.Pool shouldn't hang forever if a worker process dies unexpectedly

2017-06-01 Thread Francis Bolduc
Francis Bolduc added the comment: This problem also happens simply by calling sys.exit from one of the child processes. The following script exhibits the problem: import multiprocessing import sys def test(value): if value: sys.exit(123) if __name__ == '__main__': pool =

[issue30535] Warn that meta_path is not empty

2017-06-01 Thread Brett Cannon
Brett Cannon added the comment: I'm fine with adding a note to the Python 2 docs, but putting it in Python 3 seems to be going in the wrong direction as having sys.meta_path not be empty is how Python will be going forward. -- ___ Python tracker

[issue25324] Importing tokenize modifies token

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset c9ccacea3ff441b1ff519c7399602b7db16f9783 by Mariatta (Albert-Jan Nijburg) in branch 'master': bpo-25324: add missing comma in Parser/tokenizer.c (GH-1910) https://github.com/python/cpython/commit/c9ccacea3ff441b1ff519c7399602b7db16f9783

[issue29512] regrtest refleak: implement bisection feature

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: The next step is to add a command to regrtest implementing all steps. Or maybe this script is enough? At least, it's enough for my needs ;-) -- ___ Python tracker

[issue29512] regrtest refleak: implement bisection feature

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "I don't understand how issue30523 and issue30540 can help to resolve this issue." - issue30523 produces a list of all test methods - issue30540 allows to pass a file to filter tests - attached bisect_test.py takes an input file produced by

[issue30542] test_files() of test_tools.test_unparse.DirectoryTestCase leaks references

2017-06-01 Thread STINNER Victor
New submission from STINNER Victor: haypo@selma$ ./python -m test -R 3:3 test_tools -m test_files Run tests sequentially 0:00:00 load avg: 0.57 [1/1] test_tools beginning 6 repetitions 123456 .. test_tools leaked [0, 4, 0] references, sum=4 test_tools leaked [0, 3, 0] memory blocks, sum=3

[issue29512] regrtest refleak: implement bisection feature

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I don't understand how issue30523 and issue30540 can help to resolve this issue. -- nosy: +serhiy.storchaka ___ Python tracker

[issue30541] Add restricted mocks to the python unittest mocking framework

2017-06-01 Thread Mario Corchero
New submission from Mario Corchero: Define a way to disable the automatic generation of submocks when accessing an attribute of a mock which is not set. Rationale: Inspired by GMock RestrictedMock, it aims to allow the developer to declare a narrow interface to the mock that defines what the

[issue25324] Importing tokenize modifies token

2017-06-01 Thread Albert-Jan Nijburg
Changes by Albert-Jan Nijburg : -- pull_requests: +1990 ___ Python tracker ___ ___

[issue17852] Built-in module _io can loose data from buffered files at exit

2017-06-01 Thread Xavier G. Domingo
Changes by Xavier G. Domingo : -- nosy: +xgdomingo ___ Python tracker ___ ___

[issue30540] regrtest: add --matchfile option

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: This issue is the last part to implement the issue #29512: "regrtest refleak: implement bisection feature". See also the second part, bpo-30523: unittest: add --list-tests option to only display the list of test names, don't run tests. --

[issue30540] regrtest: add --matchfile option

2017-06-01 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +1989 ___ Python tracker ___ ___

[issue30537] Using PyNumber_AsSsize_t in itertools.islice

2017-06-01 Thread Mark Dickinson
Changes by Mark Dickinson : -- nosy: +mark.dickinson ___ Python tracker ___ ___

[issue30540] regrtest: add --matchfile option

2017-06-01 Thread STINNER Victor
New submission from STINNER Victor: Attached pull request adds the --matchfile option to regrtest. * Add a new option taking a filename to get a list of test names to filter tests. * support.match_tests becomes a list. * Modify run_unittest() to accept to match the whole test identifier,

[issue30475] Docs for PyDict_GetItemWithError() should say it returns a borrowed reference.

2017-06-01 Thread Eric Snow
Changes by Eric Snow : -- resolution: -> fixed stage: needs patch -> resolved status: open -> closed ___ Python tracker ___

[issue17852] Built-in module _io can loose data from buffered files at exit

2017-06-01 Thread Neil Schemenauer
Changes by Neil Schemenauer : -- pull_requests: +1987 ___ Python tracker ___ ___

[issue25324] Importing tokenize modifies token

2017-06-01 Thread Albert-Jan Nijburg
Albert-Jan Nijburg added the comment: Aah! Oops I can fix later today. On Thu, 1 Jun 2017 at 18:08, STINNER Victor wrote: > > STINNER Victor added the comment: > > We got a bug report from Coverity: > > *** CID 1411801: Incorrect expression (MISSING_COMMA) >

[issue25324] Importing tokenize modifies token

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: We got a bug report from Coverity: *** CID 1411801: Incorrect expression (MISSING_COMMA) /Parser/tokenizer.c: 111 in () 105 "OP", 106 "AWAIT", 107 "ASYNC", 108 "", 109 "COMMENT", 110 "NL", >>> CID 1411801:

[issue17852] Built-in module _io can loose data from buffered files at exit

2017-06-01 Thread Neil Schemenauer
Neil Schemenauer added the comment: "Did you get any ResourceWarning?" I already knew that explicitly closing the file would fix the issue. However, think of the millions of lines of Python 2 that hopefully will be converted to Python 3. There will be many ResourceWarning errors. It is not

[issue30462] urllib does not support NO_PROXY environment variable containing domain with asterisk

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: Hi Jiri, thanks for your PR. But at least we need a corresponding test and an entry in Misc/NEWS to complete the patch. Also, if your name is not in Misc/ACKS, please add it. :-) -- nosy: +xiang.zhang ___ Python

[issue30095] HTMLCalendar allow custom classes

2017-06-01 Thread Oz Tiram
Oz Tiram added the comment: @Walter, I fixed the issues your raised, and also solved the merge conflict in What's New. -- ___ Python tracker ___

[issue30351] regrtest hangs on x86 Windows XP 2.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: New failure on AMD64 Windows7 SP1 2.7: http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%202.7/builds/107/steps/test/logs/stdio ... 0:04:31 [402/403] test_ssl passed (32 sec) -- running: test_weakref (33 sec) Resource 'sha256.tbs-internet.com' is

[issue30095] HTMLCalendar allow custom classes

2017-06-01 Thread Walter Dörwald
Walter Dörwald added the comment: See comments on the pull request. Also it seems that currently the pull request can't be merged because of merge conflicts. -- ___ Python tracker

[issue30351] regrtest hangs on x86 Windows XP 2.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Similar issue on AMD64 OpenIndiana 2.7: http://buildbot.python.org/all/builders/AMD64%20OpenIndiana%202.7/builds/156/steps/test/logs/stdio ... 0:10:05 [400/403] test_old_mailbox passed -- running: test_bsddb3 (590 sec) 0:10:07 [401/403] test_imaplib passed --

[issue30339] test_multiprocessing_main_handling: "RuntimeError: Timed out waiting for results" on x86 Windows7 3.x

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: New failure: http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.5/builds/161/steps/test/logs/stdio == FAIL: test_directory

[issue29920] Document cgitb.text and cgitb.html

2017-06-01 Thread Berker Peksag
Berker Peksag added the comment: Please don't close it yet. I agree with Serhiy's comments in msg293394, but I couldn't find time to address his comments yet (plus we still need to backport the documentation update to 3.5 and 3.6 branches) -- ___

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: Thanks calcheng for your report and Vinay for the review. -- resolution: -> fixed stage: -> resolved status: open -> closed versions: +Python 2.7, Python 3.6, Python 3.7 ___ Python tracker

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: New changeset 3ef3bcbe38e1913119c3022ca470d06908eeda3c by Xiang Zhang in branch '2.7': bpo-30378: Fix the problem that SysLogHandler can't handle IPv6 addresses (#1904) (#1676) https://github.com/python/cpython/commit/3ef3bcbe38e1913119c3022ca470d06908eeda3c

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: New changeset 95b4da2be4aeb74ee46ddece71f2075b32915c60 by Xiang Zhang in branch '3.6': bpo-30378: Fix the problem that SysLogHandler can't handle IPv6 addresses (#1676) (#1903) https://github.com/python/cpython/commit/95b4da2be4aeb74ee46ddece71f2075b32915c60

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: New changeset e20d22671996712eac416dd7bda79b5344d81164 by Xiang Zhang in branch '3.5': bpo-30378: Fix the problem that SysLogHandler can't handle IPv6 addresses (#1676) (#1902) https://github.com/python/cpython/commit/e20d22671996712eac416dd7bda79b5344d81164

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks Julien and Raymond. PR has been merged and backported to 2.7, 3.5 and 3.6. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 662d856cd7d21dbdbd4043c1735d93b32568c9e5 by Mariatta in branch '2.7': bpo-30499: Remove a deprecated note about sets. (GH-1848) (GH-1907) https://github.com/python/cpython/commit/662d856cd7d21dbdbd4043c1735d93b32568c9e5 --

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 9d752aa5e695d682f3cfc40655580900b132e52a by Mariatta in branch '3.6': bpo-30499: Remove a deprecated note about sets. (GH-1848) (GH-1905) https://github.com/python/cpython/commit/9d752aa5e695d682f3cfc40655580900b132e52a --

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 3419fc2bf1e81d42ef4578e59d3c10f9c239e80f by Mariatta in branch '3.5': bpo-30499: Remove a deprecated note about sets. (GH-1848) (GH-1906) https://github.com/python/cpython/commit/3419fc2bf1e81d42ef4578e59d3c10f9c239e80f --

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +1984 ___ Python tracker ___ ___

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +1985 ___ Python tracker ___ ___

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +1986 ___ Python tracker ___ ___

[issue30499] Deprecated note in set documentation

2017-06-01 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 0737ee20671d60802a7ef40f653fe449f1921de0 by Mariatta (Julien) in branch 'master': bpo-30499: Remove a deprecated note about sets. (GH-1848) https://github.com/python/cpython/commit/0737ee20671d60802a7ef40f653fe449f1921de0 --

[issue30539] Make Proactor public in asyncio.ProactorEventLoop

2017-06-01 Thread jabdoa
New submission from jabdoa: pyserial-asyncio cannot use IOCP for serial sockets on windows because _proactor is private on the ProactorEventLoop. Can it be made public? Currently, pyserial-asyncio has to rely on polling for windows which is suboptimal. Some forks use Proactor (e.g.

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Changes by Xiang Zhang : -- pull_requests: +1983 ___ Python tracker ___ ___

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-01 Thread Christian Heimes
Christian Heimes added the comment: http://www.unicode.org/reports/tr46/#IDNA2008-Section Additions. Some IDNs are invalid in IDNA2003, but valid in IDNA2008. Subtractions. Some IDNs are valid in IDNA2003, but invalid in IDNA2008. Deviations. Some IDNs are valid in both, but resolve

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Changes by Xiang Zhang : -- pull_requests: +1982 ___ Python tracker ___ ___

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Changes by Xiang Zhang : -- pull_requests: +1981 ___ Python tracker ___ ___

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-01 Thread Christian Heimes
Christian Heimes added the comment: zvyn, thanks for your patch. However I'm sorry to say that Python stdlib's IDNA support is fundamentally broken by design. Therefore I'm against any IDNA related patches until we have addresses multiple issues with internationalized domain names. Our naive

[issue30378] SysLogHandler does not support IPv6 destinations

2017-06-01 Thread Xiang Zhang
Xiang Zhang added the comment: New changeset 0b4b57df964f1ba427684556b8e5f05852454e0d by Xiang Zhang in branch 'master': bpo-30378: Fix the problem that SysLogHandler can't handle IPv6 addresses (#1676) https://github.com/python/cpython/commit/0b4b57df964f1ba427684556b8e5f05852454e0d

[issue30538] Functional Programming HOWTO describes one argument itertools.count()

2017-06-01 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- type: -> enhancement ___ Python tracker ___ ___

[issue30538] Functional Programming HOWTO describes one argument itertools.count()

2017-06-01 Thread Cheryl Sabella
New submission from Cheryl Sabella: The Functional Programming HOWTO describes single variable itertools.count instead of the two variable version that is linked to. -- assignee: docs@python components: Documentation messages: 294935 nosy: csabella, docs@python priority: normal

[issue30537] Using PyNumber_AsSsize_t in itertools.islice

2017-06-01 Thread Michael Seifert
New submission from Michael Seifert: In a question on StackOverflow (https://stackoverflow.com/questions/44302946/itertools-does-not-recognize-numpy-ints-as-valid-inputs-on-python-3-6) it was mentioned that numpys scalars cannot be used as index for `itertools.islice`. The reason for this

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 01/06/2017 à 12:41, Serhiy Storchaka a écrit : > > First at all, I'm not sure that allowing to modify TextIOWrapper settings > after creation is a good idea. I would be feeling uncomfortable if the > third-party library changed the buffering or encoding

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: First at all, I'm not sure that allowing to modify TextIOWrapper settings after creation is a good idea. I would be feeling uncomfortable if the third-party library changed the buffering or encoding settings of passed text stream for its own needs, and this

[issue30536] SubinterpThreadingTests.test_threads_join_2() of test_threading leaks references

2017-06-01 Thread STINNER Victor
New submission from STINNER Victor: Ah! I succeeded to hack a tool to bisect -m test -R 3:3 failure (issue #29512, I will publish it later, right now it's too hackish), so I found a first guilty of failure on the Gentoo Refleak failure. Maybe it's related to recent Eric Snow's work. Maybe

[issue30520] loggers can't be pickled

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > The fact that it creates a new logger if it doesn't exist is > pretty much by design. May be. I don't have a strong opinion. -- ___ Python tracker

[issue29920] Document cgitb.text and cgitb.html

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I suggest to move the descriptions of text() and html() after handle(). And I don't know what to do with the discrepancy in the parameter name. -- versions: -Python 2.7, Python 3.5, Python 3.6 ___ Python tracker

[issue30535] Warn that meta_path is not empty

2017-06-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: A warning is probably too strong. Also, it's easy to check sys.meta_path at the interpreter prompt, so I'm not sure it's worth mentioning at all. -- nosy: +brett.cannon, eric.snow, ncoghlan, pitrou ___ Python

[issue29920] Document cgitb.text and cgitb.html

2017-06-01 Thread Xavier Morel
Xavier Morel added the comment: Should I close this since the PR was merged? -- ___ Python tracker ___ ___

[issue30535] Warn that meta_path is not empty

2017-06-01 Thread Xavier Morel
Xavier Morel added the comment: And it turns out the change was noted in the Python 3.3 release notes[0] though not all the consequences were spelled out (and the meta_path and path_hooks documentations were not changed) [0] https://docs.python.org/3/whatsnew/3.3.html#visible-changes

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-01 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review ___ Python tracker ___ ___

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: I don't think those two issues need to be merged. Setting line_buffering and write_through is almost trivial, while setting the encoding seems to take a significant amount of effort. That said, I agree that a unified interface may be nice. Perhaps a

[issue30535] Warn that meta_path is not empty

2017-06-01 Thread Xavier Morel
Xavier Morel added the comment: Addendum: the warning was present (in the documentation) until Python 3.5, even though Python 3.3 is apparently where the "default finders" were moved to meta_path: > python3.2 -c 'import sys;print(sys.meta_path)' [] > python3.3 -c 'import

[issue30520] loggers can't be pickled

2017-06-01 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 01/06/2017 à 11:28, Serhiy Storchaka a écrit : > > The idea LGTM. But we should first check that the logger is accessible by the > name: getLogger(self.name) is self. The same is done when pickling classes, > functions, etc. It shouldn't be a surprise on

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This looks similar to issue15216 and may be merged with it. At least setting line_buffering and encoding should have unified interface. I see two possibilities of making this Pythonic: * Make attributes writeable. * Add a method (configure(), reopen(), or

[issue30520] loggers can't be pickled

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The idea LGTM. But we should first check that the logger is accessible by the name: getLogger(self.name) is self. The same is done when pickling classes, functions, etc. It shouldn't be a surprise on unpickler side. And maybe use not getLogger(), but

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The details can be different. For example: >>> 1 .__add__(x=2) Traceback (most recent call last): File "", line 1, in TypeError: wrapper __add__ doesn't take keyword arguments The message contains the word "wrapper" and doesn't contains parenthesis. I

[issue30535] Warn that meta_path is not empty

2017-06-01 Thread Xavier Morel
New submission from Xavier Morel: Encountered this issue porting Python 2 code manipulating meta_path to Python 3. In Python 2, meta_path is empty by default and its documentation specifically notes that: > sys.meta_path is searched before any implicit default finders or sys.path. As a

[issue30397] Expose regular expression and match objects types in the re module

2017-06-01 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +levkivskyi ___ Python tracker ___ ___

[issue30397] Expose regular expression and match objects types in the re module

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Added GvR and Ivan because this is related to the typing module. This change allows re.Patter and re.Match be just imported from the re module. -- nosy: +gvanrossum ___ Python tracker

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: > Note that some error messages are "takes no keyword arguments", but others > are "does not take keyword arguments" or "doesn't take keyword arguments". We already have a _PyArg_NoKeywords() function. Maybe we could add a new _PyErr_NoKeywords() function

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Note that some error messages are "takes no keyword arguments", but others are "does not take keyword arguments" or "doesn't take keyword arguments". They should be unified. What wording is better? -- stage: -> patch review

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: See also "[Python-ideas] Positional-only parameters" discussion of last March: https://mail.python.org/pipermail/python-ideas/2017-March/044956.html Brett Cannon: "It seems all the core devs who have commented on this are in the positive (Victor, Yury, Ethan,

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: I introduced the regression with the commit 7fc252adfbedece75f2330bcfdadbf84dee7836f: "Optimize _PyCFunction_FastCallKeywords(): Issue #29259: Write fast path in _PyCFunction_FastCallKeywords() for METH_FASTCALL, (...) Cleanup also

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +1980 ___ Python tracker ___ ___

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Ah, Python 3.6 is not affected: haypo@selma$ ./python Python 3.6.1+ (heads/unpack_dict:ba4fb35, May 31 2017, 16:31:51) >>> abs(x=5) TypeError: abs() takes no keyword arguments -- ___ Python tracker

[issue30534] error message for incorrect call degraded in 3.7

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Example with a builtin function, abs(), which uses METH_O. Before: haypo@selma$ python3 Python 3.5.3 (default, Apr 24 2017, 13:32:13) >>> abs(x=5) TypeError: abs() takes no keyword arguments After: haypo@selma$ ./python Python 3.7.0a0 (heads/master:85aba23,

[issue22898] segfault during shutdown attempting to log ResourceWarning

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: The issue #17852 is still alive and has a reference to this issue. It would be nice to rebase the latest patch on master and create a PR ;-) -- ___ Python tracker

[issue17852] Built-in module _io can loose data from buffered files at exit

2017-06-01 Thread STINNER Victor
STINNER Victor added the comment: Neil Schemenauer: "Well, I just spent a couple of hours debugging a problem caused by this issue." Did you get any ResourceWarning? You need to run python3 with -Wd to see them. By the way, I enhanced ResourceWarning in Python 3.6: if you enable tracemalloc,

  1   2   >