[issue31756] subprocess.run should alias universal_newlines to text

2017-10-22 Thread Wolfgang Maier
Change by Wolfgang Maier : -- nosy: +wolma ___ Python tracker ___

[issue9842] Document ... used in recursive repr of containers

2017-10-22 Thread Raymond Hettinger
Raymond Hettinger added the comment: Since the appearance of reprs is not guaranteed. I don't think this should be documented (because doing so makes it a guaranteed behavior). In fact, the appearance has changed over time from ... to [...] in and may change at

[issue28292] Make Calendar.itermonthdates() behave consistently in edge cases

2017-10-22 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Let me look into this. It's been a while ... -- ___ Python tracker ___

[issue31803] time.clock() should emit a DeprecationWarning

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, it is time.process_time(). This was the cause of adding two new functions time.perf_counter() and time.process_time() and deprecating (in the documentation only) time.clock(). On Windows time.clock() does include time

[issue28224] Compilation warnings on Windows: export 'PyInit_xx' specified multiple times

2017-10-22 Thread Stefan Krah
Stefan Krah added the comment: I know I closed #20166 myself, but could we revisit this? I'm now in favor of telling people to fix their modules. -- nosy: +skrah status: closed -> open ___ Python tracker

[issue31835] _PyFunction_FastCallDict and _PyFunction_FastCallKeywords: fast path not used

2017-10-22 Thread Antoine Pitrou
Change by Antoine Pitrou : -- nosy: +haypo versions: +Python 3.7 ___ Python tracker ___ ___

[issue30744] Local variable assignment is broken when combined with threads + tracing + closures

2017-10-22 Thread Nick Coghlan
Nick Coghlan added the comment: No, as locals() never returns the write-through proxy in the latest version of the PEP - it only ever returns the dynamic snapshot namespace (retrieving it from the proxy if necessary). To get access to the write-through proxy in Python

[issue31841] Several methods of collections.UserString do not return instances of UserString or its subclasses

2017-10-22 Thread Dmitry Kazakov
New submission from Dmitry Kazakov : A few of the methods of collections.UserString return objects of type str when one would expect instances of UserString or a subclass. Here's an example for UserString.join: >>> s = UserString(', ').join(['a', 'b', 'c']);

[issue31831] EmailMessage.add_attachment(filename="long or spécial") crashes or produces invalid output

2017-10-22 Thread R. David Murray
R. David Murray added the comment: Great, thank you for that research. And yes, that's exactly why __str__ uses utf8=True, the "picture" of the message is much more readable. I will commit that PR soon. -- ___ Python

[issue31828] Support Py_tss_NEEDS_INIT outside of static initialisation

2017-10-22 Thread Masayuki Yamamoto
Masayuki Yamamoto added the comment: Or Py_tss_NEEDS_INIT is removed from the C API document to become a private feature; in other words, the Python interpreter will recommend that the static allocation for the TSS key shouldn't be used in the API client codes

[issue31836] test_code_module fails after test_idle

2017-10-22 Thread Terry J. Reedy
Terry J. Reedy added the comment: On the PR, Serhiy asks "Wouldn't be better to restore sys.ps1 in test_idle if it is changed here?" Aside from the fact that, as far as I know, it is not sanely possible to do so, I think it a bug for a test to be unnecessarily fragile.

[issue31838] Python 3.4 supported SSL version

2017-10-22 Thread Mauro Fontana
Change by Mauro Fontana : -- stage: -> resolved status: open -> closed ___ Python tracker ___

[issue31838] Python 3.4 supported SSL version

2017-10-22 Thread Mauro Fontana
Mauro Fontana added the comment: Hi Christian Great! Thanks for the information. I apologize if this was trivial, just wanted to make sure. Cheers, -- ___ Python tracker

[issue31752] Assertion failure in timedelta() in case of bad __divmod__

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Unpatched Python should crash in debug build and can raise SystemError in release build. I can't reproduce a crash on Windows after the patch. -- ___ Python tracker

[issue25612] nested try..excepts don't work correctly for generators

2017-10-22 Thread Mark Shannon
Mark Shannon added the comment: Thanks Serhiy for spotting that. 'raise' should raise the same exception as sys.exc_info() returns. I'll update the PR. -- nosy: +Mark.Shannon ___ Python tracker

[issue30744] Local variable assignment is broken when combined with threads + tracing + closures

2017-10-22 Thread Nick Coghlan
Nick Coghlan added the comment: When I rejected that approach previously, it hadn't occurred to me yet that the write-through proxy could write through to both the frame state *and* the regular dynamic snapshot returned by locals(). The current design came from asking

[issue31803] time.clock() should emit a DeprecationWarning

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: On non-Windows platforms clock() returns the processor time, perf_counter() does include time elapsed during sleep. >>> import time >>> start = time.clock(); time.sleep(1); print(time.clock() - start) 9.7001374e-05 >>>

[issue31803] time.clock() should emit a DeprecationWarning

2017-10-22 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 22.10.2017 15:14, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > On non-Windows platforms clock() returns the processor time, perf_counter() > does include time elapsed during sleep.

[issue31626] Writing in freed memory in _PyMem_DebugRawRealloc() after shrinking a memory block

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ping. -- ___ Python tracker ___ ___

[issue31572] Avoid suppressing all exceptions in PyObject_HasAttr()

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 04e36af9b88cd5e80fc818e51d46f07252a2ff3f by Serhiy Storchaka in branch 'master': bpo-31572: Get rid of using _PyObject_HasAttrId() in pickle. (#3729)

[issue30744] Local variable assignment is broken when combined with threads + tracing + closures

2017-10-22 Thread Nick Coghlan
Nick Coghlan added the comment: I rewrote the PEP based on the latest iteration of the design concept: https://github.com/python/peps/commit/9a8e590a523bdeed0598084a0782fb07fc15dfc0 (That initial commit has some minor errors in it that I've already fixed, so check the

[issue31840] `ImportError` is` raised` only when `python -m unittest discover` is given

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Run python -m unittest discover --start-directory pkg --top-level-directory . By default the top level directory is the same as the start directory (i.e. pkg). -- nosy: +serhiy.storchaka resolution: -> not a bug

[issue26765] Factor out common bytes and bytearray implementation

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue16700] Document that bytes OS API can returns unusable results on Windows

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- versions: -Python 3.5 ___ Python tracker ___

[issue16700] Document that bytes OS API can returns unusable results on Windows

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is now 2.7 only issue. -- ___ Python tracker ___

[issue28197] range.index mismatch with documentation

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- stage: -> needs patch ___ Python tracker ___

[issue31840] `ImportError` is` raised` only when `python -m unittest discover` is given

2017-10-22 Thread Hiroki “h2” Horiuchi
New submission from Hiroki “h2” Horiuchi : Create a package `pkg`. Put `test.py` there. Write `none = None` in `pkg/__init__.py`. In the directory containing `pkg/`, `python [23] -m unittest pkg.test` will terminate normally, but `python [23] -m unittest discover pkg` will

[issue28022] SSL releated deprecation for 3.6

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Shouldn't this issue be closed? Since SSL context arguments are not supported in 2.7, the deprecated arguments can't be removed until EOL of 2.7. -- ___ Python tracker

[issue24567] random.choice IndexError due to double-rounding

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you mind to create a pull request Raymond? -- components: +Library (Lib) versions: -Python 3.5 ___ Python tracker

[issue28292] Make Calendar.itermonthdates() behave consistently in edge cases

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you mind to create a pull request Alexander? -- components: +Library (Lib) stage: test needed -> needs patch ___ Python tracker

[issue28326] multiprocessing.Process depends on sys.stdout being open

2017-10-22 Thread Antoine Pitrou
Change by Antoine Pitrou : -- pull_requests: +4043 ___ Python tracker ___ ___

[issue31815] Make itertools iterators interruptible

2017-10-22 Thread Koos Zevenhoven
Koos Zevenhoven added the comment: For the interactive user who uses an interactive environment such as the repl or a Jupyter notebook, the situation is a little different from "CPython as programming language runtime". The docs say a KeyboardInterrupt is "Raised when the

[issue28326] multiprocessing.Process depends on sys.stdout being open

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset daeefd2e049b74340307481112a39f77de0f4769 by Antoine Pitrou in branch 'master': bpo-28326: Fix multiprocessing.Process when stdout and/or stderr is closed or None. (#4073)

[issue28326] multiprocessing.Process depends on sys.stdout being open

2017-10-22 Thread Antoine Pitrou
Change by Antoine Pitrou : -- pull_requests: +4045 ___ Python tracker ___ ___

[issue28416] defining persistent_id in _pickle.Pickler subclass causes reference cycle

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- assignee: -> serhiy.storchaka versions: -Python 3.5 ___ Python tracker ___

[issue28326] multiprocessing.Process depends on sys.stdout being open

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: This is now fixed in 3.6 and 3.7. Closing! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue28326] multiprocessing.Process depends on sys.stdout being open

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset 34ef6da8f5fb03b83268bd35b77fb2183c748b70 by Antoine Pitrou in branch '3.6': [3.6] bpo-28326: Fix multiprocessing.Process when stdout and/or stderr is closed or None. (GH-4073). (#4075)

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +4044 ___ Python tracker ___ ___

[issue31838] Python 3.4 supported SSL version

2017-10-22 Thread Christian Heimes
Christian Heimes added the comment: You are correct, Python 3.4 does not support OpenSSL 1.1 and will never support it. The last bug fix release of Python 3.4 was 3.4.4 in 2015-12-20. 3.4.5 and newer are security fix releases that only contain critical security updates.

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset bcbdd2f8db396c3f0ec9186162b39b5a34effa0e by Serhiy Storchaka in branch 'master': bpo-28286: Add tests for the mode argument of GzipFile. (#4074)

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +4046 ___ Python tracker ___

[issue31653] Don't release the GIL if we can acquire a multiprocessing semaphore immediately

2017-10-22 Thread Antoine Pitrou
Change by Antoine Pitrou : -- keywords: +patch pull_requests: +4048 stage: needs patch -> patch review ___ Python tracker ___

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +4047 ___ Python tracker ___ ___

[issue31653] Don't release the GIL if we can acquire a multiprocessing semaphore immediately

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset c872d39d324cd6f1a71b73e10406bbaed192d35f by Antoine Pitrou in branch 'master': bpo-31653: Don't release the GIL if we can acquire a multiprocessing semaphore immediately (#4078)

[issue31653] Don't release the GIL if we can acquire a multiprocessing semaphore immediately

2017-10-22 Thread Antoine Pitrou
Change by Antoine Pitrou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 251de30935490a702b0a365f1e9bea696b39c016 by Serhiy Storchaka (Miss Islington (bot)) in branch '3.6': bpo-28286: Add tests for the mode argument of GzipFile. (GH-4074) (#4076)

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset f7d19b0464cb89ec696affbad9fd7e7c94456eaf by Serhiy Storchaka in branch '2.7': [2.7] bpo-28286: Add tests for the mode argument of GzipFile. (GH-4074). (#4077)

[issue30744] Local variable assignment is broken when combined with threads + tracing + closures

2017-10-22 Thread Xavier de Gaye
Xavier de Gaye added the comment: Nick, in msg304388 you wrote "[allow] immediate write-through from trace functions". The latest iteration of PEP 558 says instead: "tracing mode: the way the interpreter behaves when a trace hook has been registered..." and also says:

[issue31839] datetime: add method to parse isoformat() output

2017-10-22 Thread SilentGhost
Change by SilentGhost : -- nosy: +belopolsky versions: +Python 3.7 ___ Python tracker ___

[issue31803] time.clock() should emit a DeprecationWarning

2017-10-22 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 20.10.2017 19:46, Serhiy Storchaka wrote: > > This will break a code that depends on the current behavior on non-Windows > platforms. And this will contradict the expectation of non-Windows > programmers. If change the behavior of

[issue14465] xml.etree.ElementTree: add feature to prettify XML output

2017-10-22 Thread Wolfgang Maier
Change by Wolfgang Maier : -- nosy: +wolma ___ Python tracker ___

[issue31843] sqlite3.connect() should accept PathLike objects

2017-10-22 Thread Allen Li
New submission from Allen Li : sqlite3.connect() should accept PathLike objects (objects that implement __fspath__) -- messages: 304773 nosy: Allen Li priority: normal severity: normal status: open title: sqlite3.connect() should accept PathLike objects

[issue31843] sqlite3.connect() should accept PathLike objects

2017-10-22 Thread Allen Li
Change by Allen Li : -- type: -> enhancement ___ Python tracker ___ ___

[issue31828] Support Py_tss_NEEDS_INIT outside of static initialisation

2017-10-22 Thread Nick Coghlan
Nick Coghlan added the comment: For the wording fix, since it's just a trivial docs update, we can go ahead and fix it without an issue reference from the PRs. As far as the API goes, I do want to support "static Py_tss_t my_tss_key = Py_tss_NEEDS_INIT;" in third party

[issue31826] Misleading __version__ attribute of modules in standard library

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: +1 for removing __version__ on all stdlib modules which are not externally maintained. -- nosy: +pitrou versions: -Python 2.7, Python 3.6 ___ Python tracker

[issue31572] Avoid suppressing all exceptions in PyObject_HasAttr()

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: > The only solution of this problem is getting rid of PyObject_HasAttr() if > favor of PyObject_GetAttr(). I don't understand why. Why not fix PyObject_HasAttr() like hasattr() was? -- nosy: +pitrou

[issue31826] Misleading __version__ attribute of modules in standard library

2017-10-22 Thread Raymond Hettinger
Raymond Hettinger added the comment: I would support just removing the version attributes for csv and re. -- nosy: +ncoghlan, rhettinger ___ Python tracker

[issue31822] Document that urllib.parse.{Defrag, Split, Parse}Result are namedtuples

2017-10-22 Thread Raymond Hettinger
Change by Raymond Hettinger : -- assignee: docs@python -> lisroach nosy: +lisroach ___ Python tracker ___

[issue25612] nested try..excepts don't work correctly for generators

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset ae3087c6382011c47db82fea4d05f8bbf514265d by Antoine Pitrou (Mark Shannon) in branch 'master': Move exc state to generator. Fixes bpo-25612 (#1773) https://github.com/python/cpython/commit/ae3087c6382011c47db82fea4d05f8bbf514265d

[issue28292] Make Calendar.itermonthdates() behave consistently in edge cases

2017-10-22 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: > 1. Raise OverflowError at both ends (revert issue15421patch). The method > becomes unusable for two extreme months. The issue 15421 patch was committed in 85710a40e7e9eab86060bedc3762ccf9ca8d26ca. --

[issue31756] subprocess.run should alias universal_newlines to text

2017-10-22 Thread Wolfgang Maier
Change by Wolfgang Maier : -- nosy: -wolma ___ Python tracker ___

[issue31842] pathlib: "Incorrect function" during resolve()

2017-10-22 Thread Erik Aronesty
Change by Erik Aronesty : -- components: +Windows nosy: +paul.moore, steve.dower, tim.golden, zach.ware ___ Python tracker ___

[issue31842] pathlib: "Incorrect function" during resolve()

2017-10-22 Thread Erik Aronesty
New submission from Erik Aronesty : When strict is "false", pathlib should not fail if the network share is inaccessible. It should, as documented, catch the exception and continue with as much of the path as it has. >>> pathlib.Path("v:").resolve() Traceback (most

[issue31756] subprocess.run should alias universal_newlines to text

2017-10-22 Thread Gregory P. Smith
Gregory P. Smith added the comment: New changeset 7fed7bd8bb628f0f09c6011871a4ce68afb41b18 by Gregory P. Smith (andyclegg) in branch 'master': bpo-31756: subprocess.run should alias universal_newlines to text (#4049)

[issue28286] gzip guessing of mode is ambiguous

2017-10-22 Thread Wolfgang Maier
Change by Wolfgang Maier : -- nosy: +wolma ___ Python tracker ___

[issue25612] nested try..excepts don't work correctly for generators

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thank you Mark for the fix! -- versions: -Python 2.7, Python 3.6 ___ Python tracker ___

[issue31756] subprocess.run should alias universal_newlines to text

2017-10-22 Thread Gregory P. Smith
Change by Gregory P. Smith : -- resolution: -> fixed stage: patch review -> commit review status: open -> closed ___ Python tracker

[issue28292] Make Calendar.itermonthdates() behave consistently in edge cases

2017-10-22 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I submitted PR 4079. Serhiy, please review the logic and if this matches what we discussed a year ago, I will add the docs and NEWS entries. -- ___ Python tracker

[issue31739] socket.close recommended but not demonstrated in same-page example code

2017-10-22 Thread Raymond Hettinger
Raymond Hettinger added the comment: Lisa, would you care to wrap this one up? -- assignee: docs@python -> lisroach nosy: +lisroach, rhettinger ___ Python tracker

[issue20825] containment test for "ip_network in ip_network"

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: This is now in 3.7. Thanks to everyone who contributed! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.7 -Python 3.8 ___ Python tracker

[issue20825] containment test for "ip_network in ip_network"

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset 91dc64ba3f51100540b2ab6c6cd72c3bb18a6d49 by Antoine Pitrou (Cheryl Sabella) in branch 'master': bpo-20825: Containment test for ip_network in ip_network.

[issue31826] Misleading __version__ attribute of modules in standard library

2017-10-22 Thread Nick Coghlan
Nick Coghlan added the comment: +1 from me for dropping these, and noting which modules were affected in the Porting section of the 3.7 What's New (I'd be surprised if anyone was depending on them existing, but it doesn't hurt to mention it, and may help if someone is

[issue31833] Compile fail on gentoo for MIPS CPU of loongson 2f

2017-10-22 Thread Antoine Pitrou
Antoine Pitrou added the comment: You should try running with strace to see which system call failed: $ strace ./python -c "import _multiprocessing" -- nosy: +pitrou ___ Python tracker

[issue28292] Make Calendar.itermonthdates() behave consistently in edge cases

2017-10-22 Thread Alexander Belopolsky
Change by Alexander Belopolsky : -- keywords: +patch pull_requests: +4049 stage: needs patch -> patch review ___ Python tracker