[issue33049] itertools.count() confusingly mentions zip() and sequence numbers

2018-03-11 Thread Raymond Hettinger
Raymond Hettinger added the comment: > This is a strange thing to note though because enumerate > would be a better use here. IIRC, the wording predates the addition of enumerate() and before enumerate() grew a *start* argument. That said, enumerate() just

[issue33038] GzipFile doesn't always ignore None as filename

2018-03-11 Thread Diego Argueta
Diego Argueta added the comment: Yeah that's fine. Thanks! -- ___ Python tracker ___

[issue32719] fatal error raised when Ctrl-C print loop

2018-03-11 Thread Xiang Zhang
Xiang Zhang added the comment: Looks to me it's because the KeyboardInterrupt breaks `_wait_for_thread_shutdown` and reproduces the situation in #23309. @Antonie, do you think anything worth to improve here? Otherwise I'll take this as design. -- nosy: +pitrou

[issue32993] urllib and webbrowser.open() can open w/ file: protocol

2018-03-11 Thread Ned Deily
Change by Ned Deily : -- stage: -> resolved status: pending -> closed type: security -> ___ Python tracker ___

[issue32985] subprocess.Popen: Confusing documentation for restore_signals

2018-03-11 Thread R. David Murray
R. David Murray added the comment: Well, I imagine the original author thought of "python" as python itself, not the user's python program. That's certainly how I understood it when I read it in your message. It would not be a bad thing to clarify that, though.

[issue32982] Parse out invisible Unicode characters?

2018-03-11 Thread R. David Murray
R. David Murray added the comment: I think it sounds like a good idea to put the printed representation as a repered string, followed by the code point representation in parenthesis, in that message after "invalid character". -- nosy: +r.david.murray

[issue32993] urllib and webbrowser.open() can open w/ file: protocol

2018-03-11 Thread Martin Panter
Martin Panter added the comment: Hi Yao, I tend to agree with Ned. The support for “file:” URLs is by design. I don’t see any security problems. I suggest to close this. In Issue 11662, it was decided that a web server redirecting to a “file:” URL was a security

[issue33021] Some fstat() calls do not release the GIL, possibly hanging all threads

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset 4484f9dca9149da135bbae035f10a50d20d1cbbb by Antoine Pitrou (Nir Soffer) in branch 'master': bpo-33021: Release the GIL during fstat() calls (GH-6019)

[issue18802] ipaddress documentation errors

2018-03-11 Thread Cheryl Sabella
Cheryl Sabella added the comment: I've made a PR for Berker's patch. -- ___ Python tracker ___

[issue18802] ipaddress documentation errors

2018-03-11 Thread Cheryl Sabella
Change by Cheryl Sabella : -- pull_requests: +5844 ___ Python tracker ___ ___

[issue29804] test_ctypes test_pass_by_value fails on arm64 (aarch64) architecture

2018-03-11 Thread Ned Deily
Ned Deily added the comment: OK, PR 1559 (in 3.7.0) for Issue30353 has been backported to 3.6 in PR 5954 for release in 3.6.5. So based on msg312200, I'm going to assume the problem is no longer reproducible in 3.6 and close this issue. If not, please reopen. --

[issue32337] Dict order is now guaranteed, so add tests and doc for it

2018-03-11 Thread Ned Deily
Ned Deily added the comment: Raymond, do you want to review the current state of the PR before 3.7.0b4? Otherwise, I'll probably ask that it be merged as is. -- priority: release blocker -> deferred blocker ___ Python tracker

[issue33052] Sporadic segmentation fault in test_datetime

2018-03-11 Thread Antoine Pitrou
New submission from Antoine Pitrou : Just spotted this in a Travis-CI job: https://travis-ci.org/python/cpython/jobs/351010039#L2002 I'm not sure there's anything to do but I figured it was worth reporting anyway. -- components: Library (Lib), Tests messages: 313623

[issue32996] Improve What's New in 3.7

2018-03-11 Thread Ned Deily
Ned Deily added the comment: Thanks for the comments here. As noted by Yury in PR 5983: "Looks good. Keep in mind that @elprans and I will edit what's new (as we did for 3.5 & 3.6) closer to 3.7 release." -- nosy: +Elvis.Pranskevichus, yselivanov

[issue33023] Unable to copy ssl.SSLContext

2018-03-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- type: crash -> behavior ___ Python tracker ___ ___

[issue33023] Unable to copy ssl.SSLContext

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Each connection attempt will require a fresh unadulterated clone of the > ssl.SSLContext instance provided by user to avoid any side-effects from prior > connection attempts. What would those side-effects be? -- nosy: +pitrou

[issue32996] Improve What's New in 3.7

2018-03-11 Thread bbayles
bbayles added the comment: Two things I'm familiar with that should probably be mentioned in the Library updates: * bpo-32102: New argument capture_output for subprocess.run * bpo-21417: Added support for setting the compression level for zipfile.ZipFile. -- nosy:

[issue33051] IDLE: Create new tab for editor options in configdialog

2018-03-11 Thread Cheryl Sabella
Change by Cheryl Sabella : -- keywords: +patch pull_requests: +5843 stage: -> patch review ___ Python tracker ___

[issue32971] Docs on unittest.TestCase.assertRaises() should clarify context manager details

2018-03-11 Thread R. David Murray
R. David Murray added the comment: The implementation is literally that no non-keyword arguments other than the exception are given. If any keyword arguments other than msg are given, you get a warning. To say just "no callable" would be about as confusing as the 'and

[issue33051] IDLE: Create new tab for editor options in configdialog

2018-03-11 Thread Cheryl Sabella
New submission from Cheryl Sabella : Split out editor options from general tab in Config Dialog. -- assignee: terry.reedy components: IDLE messages: 313618 nosy: csabella, terry.reedy priority: normal severity: normal status: open title: IDLE: Create new tab for

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: This is all fixed in the Python 3 branches now. I won't bother with Python 2 as it has quite a different code structure and backporting would take too much of my time. Pox TheGreat, thanks for reporting and the initial patch! --

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset 069b8d20be8018fbd49ed5aaf64c4caba311e48f by Antoine Pitrou in branch '3.6': [3.6] bpo-31804: Fix multiprocessing.Process with broken standard streams (GH-6079) (GH-6081)

[issue33048] macOS job broken on Travis CI

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: I meant that the Travis macOS configuration could indeed be maintained by macOS experts, indeed. The alternative, IMHO, would be to declare that bugs in macOS can appear without the offending PR being reverted if it was submitted by a

[issue33048] macOS job broken on Travis CI

2018-03-11 Thread Ned Deily
Ned Deily added the comment: > This should be simple to fix, though I wonder whether this could be taken > over by our macOS maintainers? :-) I'm not sure what you mean by *this*. If it's the Travis configuration, I don't use Homebrew myself and I have little experience

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset ff5d21331ec6cefec6ba5b78d256d8dbcd67a069 by Antoine Pitrou (Miss Islington (bot)) in branch '3.7': bpo-31804: Fix multiprocessing.Process with broken standard streams (GH-6079) (GH-6080)

[issue33049] itertools.count() confusingly mentions zip() and sequence numbers

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: For example zip(my_sequence, count(1)). -- nosy: +rhettinger, serhiy.storchaka ___ Python tracker

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- versions: +Python 3.8 -Python 2.7 ___ Python tracker ___ ___

[issue32981] Catastrophic backtracking in poplib (CVE-2018-1060) and difflib (CVE-2018-1061)

2018-03-11 Thread Larry Hastings
Larry Hastings added the comment: Is this ready to close? -- ___ Python tracker ___ ___

[issue32981] Catastrophic backtracking in poplib (CVE-2018-1060) and difflib (CVE-2018-1061)

2018-03-11 Thread Larry Hastings
Larry Hastings added the comment: New changeset 937ac1fe069a4dc8471dff205f553d82e724015b by larryhastings (Ned Deily) in branch '3.5': [3.5] bpo-32981: Fix catastrophic backtracking vulns (GH-5955) (#6034)

[issue32981] Catastrophic backtracking in poplib (CVE-2018-1060) and difflib (CVE-2018-1061)

2018-03-11 Thread Larry Hastings
Larry Hastings added the comment: New changeset 942cc04ae44825ea120e3a19a80c9b348b8194d0 by larryhastings (Ned Deily) in branch '3.4': [3.4] bpo-32981: Fix catastrophic backtracking vulns (GH-5955) (#6035)

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- pull_requests: +5842 ___ Python tracker ___ ___

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +5841 ___ Python tracker ___

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset e756f66c83786ee82f5f7d45931ae50a6931dd7f by Antoine Pitrou in branch 'master': bpo-31804: Fix multiprocessing.Process with broken standard streams (#6079)

[issue33050] Centralized documentation of assumptions made by C code

2018-03-11 Thread Timothy VanSlyke
New submission from Timothy VanSlyke : It would be nice for those who write C extensions to have a resource that explicitly states what assumptions are made by the CPython implementation that are otherwise implementation-defined in standard C. For example, Python

[issue33049] itertools.count() confusingly mentions zip() and sequence numbers

2018-03-11 Thread Trey Hunner
New submission from Trey Hunner : >From the itertools documentation: >https://docs.python.org/3/library/itertools.html?highlight=itertools#itertools.count > Also, used with zip() to add sequence numbers. I'm not certain what the goal of the original sentence was, but

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- superseder: multiprocessing.Process depends on sys.stdout being open -> ___ Python tracker ___

[issue33048] macOS job broken on Travis CI

2018-03-11 Thread Antoine Pitrou
New submission from Antoine Pitrou : Well, it didn't take long. The macOS job broke on Travis CI. Apparently "brew" thinks Python 2 and Python 3 are the same thing, so "brew install python3" now fails with an error message telling to use "brew upgrade" instead. But it did

[issue31804] multiprocessing calls flush on sys.stdout at exit even if it is None (pythonw)

2018-03-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- pull_requests: +5840 ___ Python tracker ___ ___

[issue33047] "RuntimeError: dictionary changed size during iteration" using trace.py module

2018-03-11 Thread Adrien
New submission from Adrien : Hello. I am strangely encountering an error whil trying to run "python -m trace -c script.py" on this simple code: > import multiprocessing > queue = multiprocessing.Queue() > queue.put("a") Which raises on Windows 10 using Python 3.6.3: >

[issue32996] Improve What's New in 3.7

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The most breaking change in 3.7 (according to the statistics of GitHub issues) is making async a keyword. But this change is even not mentioned in What's New. -- ___ Python tracker

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Berker Peksag
Change by Berker Peksag : -- resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Matej Cepl
Matej Cepl added the comment: OK, Serhiy you have the point: it was just a good exercise for me, but the benefit is doubtful. Could somebody close this ticket then? -- ___ Python tracker

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Berker Peksag
Berker Peksag added the comment: I agree with Serhiy and Terry. Also, PR 5999 does not accept pathlib.Path() objects at the moment. This and Serhiy's following comment are good examples of why it shouldn't be added to the standard library in my opinion: > If combine

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Terry J. Reedy
Change by Terry J. Reedy : -- nosy: +berker.peksag ___ Python tracker ___ ___

[issue33034] urllib.parse.urlparse and urlsplit not raising ValueError for bad port

2018-03-11 Thread Matt Eaton
Matt Eaton added the comment: I agree. I think an explicit exception message would be appropriate when the cast fails to cast from string to int in int(post, 10). Putting in a PR to fix this now. https://github.com/python/cpython/pull/6078 -- nosy:

[issue33034] urllib.parse.urlparse and urlsplit not raising ValueError for bad port

2018-03-11 Thread Matt Eaton
Change by Matt Eaton : -- pull_requests: +5838 ___ Python tracker ___ ___

[issue33034] urllib.parse.urlparse and urlsplit not raising ValueError for bad port

2018-03-11 Thread Matt Eaton
Change by Matt Eaton : -- keywords: +patch pull_requests: +5837 stage: -> patch review ___ Python tracker ___

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: George, your third sentence is missing a closing ')' somewhere. In the first part, I believe you meant that the user is able to create a bad file by directly writing other content or calling cf.write more than once. I don't get the part

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is a problem with writing two lines of code? with open(...) as f: config.write(f) If combine ConfigParser.write() with builtin open() you will need to add support of encoding, errors, buffering, newline, and

[issue28788] ConfigParser should be able to write config to a given filename, not only into file object

2018-03-11 Thread Terry J. Reedy
Change by Terry J. Reedy : -- nosy: +lukasz.langa ___ Python tracker ___ ___

[issue32174] nonASCII punctuation characters can not display in python363.chm.

2018-03-11 Thread Ma Lin
Change by Ma Lin : Added file: https://bugs.python.org/file47476/screenshot.PNG ___ Python tracker ___

[issue32174] nonASCII punctuation characters can not display in python363.chm.

2018-03-11 Thread Ma Lin
Ma Lin added the comment: Here is a solution: 1, open a page(whatever) with Internet Explorer. 2, right click the page -> Encoding -> check "Auto-Select" Then the wrong characters (�/抯) will disappear forever. > Does anyone else see this problem? Probably a lot of people have

[issue32576] concurrent.futures.thread deadlock due to Queue in weakref callback

2018-03-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: Perhaps the gemato issue has nothing to do with multiprocessing indeed. I would suggest add some progress logging to your program to see whether/where it actually hangs. -- ___ Python tracker

[issue22087] asyncio: support multiprocessing (support fork)

2018-03-11 Thread Zac Medico
Change by Zac Medico : -- nosy: +zmedico ___ Python tracker ___ ___ Python-bugs-list

[issue17288] cannot jump from a 'return' or 'exception' trace event

2018-03-11 Thread Xavier de Gaye
Xavier de Gaye added the comment: Serhiy, I have updated the tests for using the jump_test() decorator and replied to your comment about RETURN_VALUE. -- ___ Python tracker

[issue33016] nt._getfinalpathname may use uninitialized memory

2018-03-11 Thread Eryk Sun
Eryk Sun added the comment: > pathlib currently expects DOS paths only: it will strip '\\?\' > prefix in resolve() pathlib's unqualified conversion from the extended form to classic DOS form is a bug. The resolved path may be invalid as a classic DOS path. It may be too

[issue32576] concurrent.futures.thread deadlock due to Queue in weakref callback

2018-03-11 Thread Michał Górny
Michał Górny added the comment: Well, according to the reporters disabling GC doesn't help at all. Maybe it's another issue. -- ___ Python tracker

[issue12486] tokenize module should have a unicode API

2018-03-11 Thread Thomas Kluyver
Thomas Kluyver added the comment: > Why not just bless the existing generate_tokens() function as a public API We're actually using generate_tokens() from IPython - we wanted a way to tokenize unicode strings, and although it's undocumented, it's been there for a number

[issue32970] Improve disassembly of the MAKE_FUNCTION instruction

2018-03-11 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32970] Improve disassembly of the MAKE_FUNCTION instruction

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset e2732d3e66eba9ec13f9d55c499f2437ead552db by Serhiy Storchaka in branch 'master': bpo-32970: Improve disassembly of the MAKE_FUNCTION instruction. (GH-5937)

[issue32946] Speed up import from non-packages

2018-03-11 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32925] AST optimizer: Change a list into tuple in iterations and containment tests

2018-03-11 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33026] Fix jumping out of "with" block

2018-03-11 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33026] Fix jumping out of "with" block

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 3854f5885edc8dc67b1aba82fbb525604fbc625b by Serhiy Storchaka (Miss Islington (bot)) in branch '2.7': [2.7] bpo-33026: Fix jumping out of "with" block by setting f_lineno. (GH-6026). (GH-6074) (GH-6076)

[issue32925] AST optimizer: Change a list into tuple in iterations and containment tests

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 3f7e9aa2ef215917b9f1521441f67f4ecd33a1bc by Serhiy Storchaka in branch 'master': bpo-32925: Optimized iterating and containing test for literal lists (GH-5842)

[issue32946] Speed up import from non-packages

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 4e2442505c5e9eec396dcef4d2e6bdd2b6f92fc9 by Serhiy Storchaka in branch 'master': bpo-32946: Speed up "from ... import ..." from non-packages. (GH-5873)

[issue33026] Fix jumping out of "with" block

2018-03-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 20ac11a9fb027f183914bbaaaed091b57c882e54 by Serhiy Storchaka (Miss Islington (bot)) in branch '3.6': [3.6] bpo-33026: Fix jumping out of "with" block by setting f_lineno. (GH-6026). (GH-6074) (GH-6075)