[issue37545] Argparse Tutorial - unreasonable operators

2019-07-11 Thread Aldwin Pollefeyt
Aldwin Pollefeyt added the comment: @Zachary, you are right ... the last one should be >= 1. Now i see the difference with the previous examples. It changed the output drastically from "the square of {} equals {}" vs "{}^2 == {}" to suddenly printing the filename at -vv. I was focused more o

[issue36044] PROFILE_TASK for PGO build is not a good workload

2019-07-11 Thread Neil Schemenauer
Change by Neil Schemenauer : -- keywords: +patch pull_requests: +14501 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14702 ___ Python tracker ___

[issue37544] Multiple test failures during build

2019-07-11 Thread Jarek Zgoda
Jarek Zgoda added the comment: test.pythoninfo output -- Added file: https://bugs.python.org/file48467/test.pythoninfo.txt ___ Python tracker ___ _

[issue37544] Multiple test failures during build

2019-07-11 Thread Jarek Zgoda
Jarek Zgoda added the comment: make test output from unoptimized build with --disable-shared --prefix=/opt/python-3.7.4 -- Added file: https://bugs.python.org/file48468/3.7.4-test_output.txt ___ Python tracker

[issue36044] PROFILE_TASK for PGO build is not a good workload

2019-07-11 Thread Neil Schemenauer
Neil Schemenauer added the comment: I tweaked the list of unit tests a little more, trying to incorporate some from your Docker build settings. Not sure what's going on with the pickle results. Below are new pyperformance runs, comparing my PR to the "master" version it is based on. I add

[issue36044] PROFILE_TASK for PGO build is not a good workload

2019-07-11 Thread Neil Schemenauer
Neil Schemenauer added the comment: +-+---+-+ | Benchmark | task-all2 | task-short7 | +=+===+=+ | 2to3| 304 ms| 305 ms: 1

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread Jakub Kulik
New submission from Jakub Kulik : Hi, with the addition of shared memory into Python 3.8, we now have three tests failing on Solaris, namely `test_multiprocessing_fork`, `test_multiprocessing_forkserver` and `test_multiprocessing_spawn`. All of them fail in the same way: ===

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread Jakub Kulik
Change by Jakub Kulik : -- keywords: +patch pull_requests: +14502 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14703 ___ Python tracker ___

[issue37547] Add _PyObject_CallMethodOneArg()

2019-07-11 Thread Inada Naoki
Inada Naoki added the comment: New changeset 59ad110d7a7784d53d0b502eebce0346597a6bef by Inada Naoki (Jeroen Demeyer) in branch 'master': bpo-37547: add _PyObject_CallMethodOneArg (GH-14685) https://github.com/python/cpython/commit/59ad110d7a7784d53d0b502eebce0346597a6bef -- __

[issue37547] Add _PyObject_CallMethodOneArg()

2019-07-11 Thread Jeroen Demeyer
Change by Jeroen Demeyer : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue29548] Recommend PyObject_Call* APIs over PyEval_Call*() APIs

2019-07-11 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: I understand the arguments for not removing these functions. However, I still think that we should deprecate them but without planning in advance when they should be removed. Victor said that we should document these functions as "please don't use them", and

[issue37524] IDLE error on closing 3.8+ debug build

2019-07-11 Thread Tal Einat
Tal Einat added the comment: Doesn't reproduce on Win10 with current master. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue37559] IDLE: Scrolling issues with code context shown

2019-07-11 Thread Tal Einat
New submission from Tal Einat : With code context shown, scrolling a window by dragging the scrollbar causes the scrollbar's tab to "jump around" and sometimes some "flashing" visual artifacts. The "flashing" appears to occur only before the screen is resized for the first time, in which cas

[issue37560] with cgi.FieldStorage(...) fails on cleanup with AttributeError, missing try/except in __exit__

2019-07-11 Thread Stefanik Gábor
New submission from Stefanik Gábor : cgi.FieldStorage has this for its __del__ method: def __del__(self): try: self.file.close() except AttributeError: pass By contrast, __exit__ is missing the exception handler: def __exit__(self, *args):

[issue37549] os.dup() fails for standard streams on Windows 7

2019-07-11 Thread STINNER Victor
STINNER Victor added the comment: Oh, os.dup() doc says: "On Windows, when duplicating a standard stream (0: stdin, 1: stdout, 2: stderr), the new file descriptor is inheritable." https://docs.python.org/dev/library/os.html Maybe we should add an inheritable paramater to os.dup() in Python 3.

[issue37559] IDLE: Scrolling issues with code context shown

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- keywords: +patch pull_requests: +14503 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14030 ___ Python tracker ___ __

[issue37550] SSL Pip Error

2019-07-11 Thread Christian Heimes
Christian Heimes added the comment: Please provide more information. What is your operating system, how did you install Python, and which error message are you getting? -- ___ Python tracker ___

[issue37561] the _sysconfigdata name should not encode MACHDEP and PLATFORM_TRIPLET

2019-07-11 Thread Matthias Klose
New submission from Matthias Klose : so issue28046 decided to encode both MACHDEP and PLATFORM_TRIPLET/MULTIARCH in the _sysconfigdata name. Unfortunately on KFreeBSD MACHDEP includes the kernel version, so you end up with a changing MACHDEP. The _sysconfigdata name should only encode the M

[issue37549] os.dup() fails for standard streams on Windows 7

2019-07-11 Thread Eryk Sun
Eryk Sun added the comment: > os.dup() doc says: "On Windows, when duplicating a standard stream > (0: stdin, 1: stdout, 2: stderr), the new file descriptor is > inheritable." That's not necessarily correct. For example, if stdout is a pipe or disk file: C:\>python -V Python 3.7.3

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
New submission from Pablo Galindo Salgado : Many functions are significantly slower after commit aacc77fbd77640a8f03638216fa09372cc21673d was applied: aacc77fbd77640a8f03638216fa09372cc21673d is the first bad commit commit aacc77fbd77640a8f03638216fa09372cc21673d Author: Jeroen Demeyer Date:

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I have bisected again and I always get commit aacc77fbd77640a8f03638216fa09372cc21673d but it would be great if someone can confirm these results independently. -- ___ Python tracker

[issue24338] In argparse adding wrong arguments makes malformed namespace

2019-07-11 Thread tomas platz
Change by tomas platz : Added file: https://bugs.python.org/file48470/126.pdf ___ Python tracker ___ ___ Python-bugs-list mailing list Unsub

[issue24338] In argparse adding wrong arguments makes malformed namespace

2019-07-11 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : Removed file: https://bugs.python.org/file48470/126.pdf ___ Python tracker ___ ___ Python-bugs-list mai

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: This is the stack difference for my previous experiment: * frame #0: 0x0001001578ee python.exe`unicode_length(self=0x00010140d220) at unicodeobject.c:12231:9 frame #1: 0x0001b453 python.exe`PyObject_Size(o=0x00010140d220) at

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Updated stack for the tip of 3.8: * frame #0: 0x00010015854e python.exe`unicode_length(self=0x0001014a4040) at unicodeobject.c:12235:9 frame #1: 0x0001a913 python.exe`PyObject_Size(o=0x0001014a4040) at abstract.c:57:26 fr

[issue37559] IDLE: Scrolling issues with code context shown

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- pull_requests: -14503 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue37559] IDLE: Scrolling issues with code context shown

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- stage: patch review -> type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- versions: +Python 3.8, Python 3.9 -Python 3.6 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset 79042ac4348ccc09344014f20dd49401579f8795 by Tal Einat in branch 'master': bpo-34369: make kqueue.control() docs better reflect that timeout is positional-only (GH-9499) https://github.com/python/cpython/commit/79042ac4348ccc09344014f20dd49401579f879

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14505 pull_request: https://github.com/python/cpython/pull/14705 ___ Python tracker ___ __

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14504 pull_request: https://github.com/python/cpython/pull/14704 ___ Python tracker ___ __

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14506 pull_request: https://github.com/python/cpython/pull/14706 ___ Python tracker ___ __

[issue37563] Documentation - default for StreamHandler

2019-07-11 Thread Jonathan
New submission from Jonathan : https://docs.python.org/2/library/logging.handlers.html https://docs.python.org/3/library/logging.handlers.html Both say: """class logging.StreamHandler(stream=None) Returns a new instance of the StreamHandler class. If stream is specified, the instance will us

[issue37563] Documentation - default for StreamHandler

2019-07-11 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +vinay.sajip ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset dc0b6af42eca70e520b67d0bcf4dc5278a3f02dd by Miss Islington (bot) in branch '3.8': bpo-34369: make kqueue.control() docs better reflect that timeout is positional-only (GH-9499) https://github.com/python/cpython/commit/dc0b6af42eca70e520b67d0bcf

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset d3747fd8fa91b768b73b60f2e2a14044e5404afa by Tal Einat (Miss Islington (bot)) in branch '3.7': bpo-34369: make kqueue.control() docs better reflect that timeout is positional-only (GH-9499) https://github.com/python/cpython/commit/d3747fd8fa91b768b73

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset 46c2eff5adca7dc309f077ec65faf95b95c47b43 by Tal Einat (Miss Islington (bot)) in branch '2.7': bpo-34369: make kqueue.control() docs better reflect that timeout is positional-only (GH-9499) https://github.com/python/cpython/commit/46c2eff5adca7dc309f

[issue34369] kqueue.control() documentation and implementation mismatch

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___ Pyt

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset 9b5ce62cac27fec9dea473865d79c2c654312957 by Tal Einat in branch 'master': bpo-36390: simplify classifyws(), rename it and add unit tests (GH-14500) https://github.com/python/cpython/commit/9b5ce62cac27fec9dea473865d79c2c654312957 -- __

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14508 pull_request: https://github.com/python/cpython/pull/14708 ___ Python tracker ___ __

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14507 pull_request: https://github.com/python/cpython/pull/14707 ___ Python tracker ___ __

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Tal Einat
Tal Einat added the comment: > I propose to merge PR 12481 first, after review, with tests, and then include > name change with rewrite in PR 14500. I've gone ahead and merged PR GH-14500 into master, since it was ready to get and a clear improvement. I've already merged this into PR GH-124

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Tal Einat
Change by Tal Einat : -- versions: +Python 3.7, Python 3.9 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset 242ad1f375bf564c35cf99cd754b2c5819c4d056 by Tal Einat (Miss Islington (bot)) in branch '3.8': bpo-36390: simplify classifyws(), rename it and add unit tests (GH-14500) https://github.com/python/cpython/commit/242ad1f375bf564c35cf99cd754b2c5819c4d056

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Tal Einat
Tal Einat added the comment: New changeset a2cf88efc417f1991720856f6913d16660e48941 by Tal Einat (Miss Islington (bot)) in branch '3.7': bpo-36390: simplify classifyws(), rename it and add unit tests (GH-14500) https://github.com/python/cpython/commit/a2cf88efc417f1991720856f6913d16660e48941

[issue37563] Documentation - default for StreamHandler

2019-07-11 Thread Vinay Sajip
Vinay Sajip added the comment: If None is passed, that is interpreted to mean whatever the implementation default is, and that is sys.stderr. For backwards compatibility, that won't change: and I don't see any need to update the documentation, as it makes it perfectly clear that sys.stderr w

[issue37564] ArgumentParser should support bool type according to truth values

2019-07-11 Thread Zach Beniash
New submission from Zach Beniash : Today when using argparse.ArgumentParser it seems that the bool type is not supported in a logical way. Foe example: - import argparse parser = argparse.ArgumentParser() parser.add_argument("--mybool", type=bool) parsed_args

[issue37563] Documentation - default for StreamHandler

2019-07-11 Thread Jonathan
Change by Jonathan : -- status: -> open ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

[issue37565] test_faulthandler failure

2019-07-11 Thread Michelle Johnson
New submission from Michelle Johnson : CentOS 7.6, running Linux gl-build.arc-ts.umich.edu 3.10.0-957.10.1.el7.x86_64 #1 SMP Mon Mar 18 15:06:45 UTC 2019 x86_64 on Intel(R) Xeon(R) Gold 6140 CPU @ 2.30GHz. Using gcc 8.2.0 compiled from source to build python 3.7.4 from source, make test fail

[issue37564] ArgumentParser should support bool type according to truth values

2019-07-11 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +14509 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14709 ___ Python tracker ___ __

[issue37564] ArgumentParser should support bool type according to truth values

2019-07-11 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +paul.j3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:

[issue37565] test_faulthandler failure

2019-07-11 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https

[issue3753] bytearray incompatible with y#

2019-07-11 Thread Zackery Spytz
Change by Zackery Spytz : -- pull_requests: -14485 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue29548] Recommend PyObject_Call* APIs over PyEval_Call*() APIs

2019-07-11 Thread Inada Naoki
Inada Naoki added the comment: FYI, PyEval_CallFunction and PyEval_CallMethod doesn't respect Py_SSIZE_T_CLEAN. So runtime warning is raised when they are used with "#" format. -- ___ Python tracker

[issue29548] Recommend PyObject_Call* APIs over PyEval_Call*() APIs

2019-07-11 Thread Inada Naoki
Inada Naoki added the comment: New changeset 1dbd084f1f68d7293718b663df675cfbd0c65712 by Inada Naoki (Jeroen Demeyer) in branch 'master': bpo-29548: no longer use PyEval_Call* functions (GH-14683) https://github.com/python/cpython/commit/1dbd084f1f68d7293718b663df675cfbd0c65712 --

[issue27379] SocketType changed in Python 3

2019-07-11 Thread hai shi
Change by hai shi : -- keywords: +patch pull_requests: +14510 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14710 ___ Python tracker ___

[issue27379] SocketType changed in Python 3

2019-07-11 Thread hai shi
hai shi added the comment: In order to keep back compatible, I would prefer to update SocketType ;) -- nosy: +shihai1991 ___ Python tracker ___ ___

[issue37566] Remove redudant code in socket.py

2019-07-11 Thread hai shi
New submission from hai shi : Looks like the _realsocket in socket.py is redudnat. But I am not sure somebody would use it or not. REF: https://github.com/python/cpython/blob/master/Lib/socket.py#L107 -- components: Library (Lib) messages: 347692 nosy: shihai1991 priority: normal seve

[issue37566] Remove redudant code in socket.py

2019-07-11 Thread hai shi
Change by hai shi : -- keywords: +patch pull_requests: +14511 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14711 ___ Python tracker ___

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14512 pull_request: https://github.com/python/cpython/pull/14712 ___ Python tracker ___ __

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset 7cbef72902f32866a416ca6c4e732af4541951b8 by Miss Islington (bot) (Mariatta) in branch 'master': closes bpo-37554: Remove `q:q` in os.rst documentation (GH-14692) https://github.com/python/cpython/commit/7cbef72902f32866a416ca6c4e732af4541951b8

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14513 pull_request: https://github.com/python/cpython/pull/14713 ___ Python tracker ___ __

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14514 pull_request: https://github.com/python/cpython/pull/14714 ___ Python tracker ___ __

[issue37554] Typo in os.rename docs

2019-07-11 Thread Mariatta
Mariatta added the comment: Thanks for the report! -- nosy: +Mariatta ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset 107171500d7d6e60f463eeb4db492c0ae292a669 by Miss Islington (bot) in branch '3.8': closes bpo-37554: Remove `q:q` in os.rst documentation (GH-14692) https://github.com/python/cpython/commit/107171500d7d6e60f463eeb4db492c0ae292a669 -- _

[issue37545] Argparse Tutorial - unreasonable operators

2019-07-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I concur with Zachary. The current writing is more errorproof. -- nosy: +serhiy.storchaka resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue37554] Typo in os.rename docs

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset 71435f685c0423f878946e584f4b9eb01233d332 by Miss Islington (bot) in branch '3.7': closes bpo-37554: Remove `q:q` in os.rst documentation (GH-14692) https://github.com/python/cpython/commit/71435f685c0423f878946e584f4b9eb01233d332 -- _

[issue37555] _CallList.__contains__ doesn't always respect ANY.

2019-07-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Karthikeyan, I think there is a flaw in your example. The good __eq__ should return NotImplemented instead of False for other types. This wil allow the right operand's __eq__ to play. -- nosy: +serhiy.storchaka

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset 4737265622251756a9480ab84af2442b6b986850 by Miss Islington (bot) (Jakub Kulík) in branch 'master': bpo-37558: Shared memory tests are failing due to double slashes (GH-14703) https://github.com/python/cpython/commit/4737265622251756a9480ab84af244

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread miss-islington
Change by miss-islington : -- pull_requests: +14515 pull_request: https://github.com/python/cpython/pull/14715 ___ Python tracker ___ __

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread miss-islington
miss-islington added the comment: New changeset 3d58b78481e0238593f85cc182b798fe3b77648c by Miss Islington (bot) in branch '3.8': bpo-37558: Shared memory tests are failing due to double slashes (GH-14703) https://github.com/python/cpython/commit/3d58b78481e0238593f85cc182b798fe3b77648c ---

[issue37567] Python compiles empty bytecode files when out of virtual memory on windows

2019-07-11 Thread Mike Lovelace
New submission from Mike Lovelace : On a system under heavy load last night Windows ran out of virtual memory, and it appears that python interpreted that as the pyc files did not exist and attempted to recreate them. In recreating them, it created essentially empty files, which caused furthe

[issue17535] IDLE: Add an option to show line numbers along the left side of the editor window, and have it enabled by default.

2019-07-11 Thread Tal Einat
Tal Einat added the comment: To those following this issue, PR GH-14030 is now in a very good state, and would benefit from more feedback. -- ___ Python tracker ___ _

[issue37553] SendfileUsingSendTest tests timeout too short for Windows ARM32

2019-07-11 Thread Paul Monson
Change by Paul Monson : -- keywords: +patch pull_requests: +14516 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14716 ___ Python tracker ___

[issue37568] Misleading UnBoundLocalError on assignment to closure variable

2019-07-11 Thread kolia
New submission from kolia : def outer(a): def inner(): print(a) a = 43 return inner t = outer(42) print(t()) Outputs: ~/Documents/repro.py in inner() 1 def outer(a):

[issue37564] ArgumentParser should support bool type according to truth values

2019-07-11 Thread paul j3
paul j3 added the comment: This is an old topic, though it may be easier to find a relevant StackOverflow thread. https://stackoverflow.com/a/19233287/901925 (a 2013 thread) I and others have explained that the `type` parameter is supposed to be a callable. The default Python `bool` funct

[issue30755] locale.normalize() and getdefaultlocale() convert C.UTF-8 to en_US.UTF-8

2019-07-11 Thread Jeffrey Kintscher
Change by Jeffrey Kintscher : -- nosy: +Jeffrey.Kintscher ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue21478] mock calls don't propagate to parent (autospec)

2019-07-11 Thread Jack Wong
Jack Wong added the comment: Thanks, Karthikeyan! I applied your change to Lib/unittest/mock.py, and it fixed the bug for me. I confirmed that calls to the child mock now appear in the parent's mock_calls in my test suite. Your PR looks good to me. -- ___

[issue37568] Misleading UnBoundLocalError on assignment to closure variable

2019-07-11 Thread Steven D'Aprano
Steven D'Aprano added the comment: The behaviour and error message is correct, and your interpretation is incorrect. You are not assigning to a closure variable on line 4; you are printing an unbound local variable on line 3, precisely as the error message says. That may not match your *inte

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: Could you please specify: - which commits are you comparing exactly? From your explanation, I guess aacc77fbd and its parent, but that's not completely fair since PEP 590 consists of many commits (see #36974). A better comparison would be master against 3.8a4

[issue37569] Complete your registration to Python tracker

2019-07-11 Thread David
New submission from David : Here is the link to register. From: report=bugs.python@roundup.psfhosted.org on behalf of Python tracker Sent: Thursday, July 11, 2019 8:59 PM To: davedro...@hotmail.com Subject: Complete your registration to Python tracker To

[issue37568] Misleading UnBoundLocalError on assignment to closure variable

2019-07-11 Thread Steven D'Aprano
Steven D'Aprano added the comment: To clarify further, unlike (say) Lua, Python doesn't allow variables to change scope part-way through a function. (At least not without hacking the byte-code.) In any function, a name refers to precisely one of (1) a local, (2) a nonlocal, and (3) a global,

[issue37569] Complete your registration to Python tracker

2019-07-11 Thread Steven D'Aprano
Steven D'Aprano added the comment: Seems to have been created in error. -- nosy: +steven.daprano resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker __

[issue37558] Shared memory tests are failing due to double slashes

2019-07-11 Thread Antoine Pitrou
Change by Antoine Pitrou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue37568] Misleading UnBoundLocalError on assignment to closure variable

2019-07-11 Thread Josh Rosenberg
Josh Rosenberg added the comment: I'm inclined to close as Not a Bug as well. I'm worried the expanded error message would confuse people when they simply failed to assign a variable, and make them try bad workarounds like adding global/nonlocal when it's not the problem, e.g.: def foo(bar)

[issue30550] Document order-preserving dictionary output in json

2019-07-11 Thread Josh Rosenberg
Josh Rosenberg added the comment: Is there a reason to document object_pairs_hook=OrderedDict rather than just making the decoder populate a regular dict in an order-preserving way? (No idea if it does this already) -- nosy: +josh.r ___ Python tra

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: I believe I meant the opposite of what I said, which fortunately is what Tal did. PR 14500 is the one I looked at and commented on and the name change in PR 14500 is what needed to be included in PR 12481 (done). I would like to retitle this issue 'IDLE: Mo

[issue36390] IDLE: Refactor formatting methods from editor

2019-07-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: When this is merged, I will open a format menu master issue listing todos. Dependencies will include 4 issues, #24817, #5150 (two items), #18583 (with patch), and #23367 (with patch), other than #36219, follow-up code revisions, and revising README.txt. ---

[issue37562] PEP 590 implementation introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: >which commits are you comparing exactly? From your explanation, I guess >aacc77fbd and its parent, but that's not completely fair since PEP 590 >consists of many commits (see #36974). A better comparison would be master >against 3.8a4. I am comparin

[issue37562] PEP 590 implementation may have introduced a performance regression

2019-07-11 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- title: PEP 590 implementation introduced a performance regression -> PEP 590 implementation may have introduced a performance regression ___ Python tracker __

[issue37566] Remove redudant code in socket.py

2019-07-11 Thread Aldwin Pollefeyt
Aldwin Pollefeyt added the comment: seems it is/was used in socket._socketobject in 2.7 -- nosy: +aldwinaldwin ___ Python tracker ___ _

[issue37566] Remove redudant code in socket.py

2019-07-11 Thread Benjamin Peterson
Benjamin Peterson added the comment: New changeset c8e7146de257930ea8d0d4aa74b3a64fcaa79d4b by Benjamin Peterson (Hai Shi) in branch 'master': closes bpo-37566: Remove _realsocket from socket.py. (GH-14711) https://github.com/python/cpython/commit/c8e7146de257930ea8d0d4aa74b3a64fcaa79d4b --

[issue37570] `distutils.util.byte_compile` fails indirect byte compiling with non-ASCII full-path.

2019-07-11 Thread Suzumizaki
New submission from Suzumizaki : `distutils.util.byte_compile` fails _indirect_ byte compiling when the full-path of the .py file contains non-ASCII characters. Because there is the project (cx_Freeze) which directly uses `distutils.util.byte_compile`, the problem would happen while installing

[issue37570] `distutils.util.byte_compile` fails indirect byte compiling with non-ASCII full-path.

2019-07-11 Thread Suzumizaki
Suzumizaki added the comment: Here's test code. Note: I marked just Python 3.8 and 3.7 I tested, but maybe all versions. -- Added file: https://bugs.python.org/file48473/my_test_case.py ___ Python tracker _

[issue37548] Document range of atan, acos and asin

2019-07-11 Thread Giovanni Cappellotto
Change by Giovanni Cappellotto : -- keywords: +patch pull_requests: +14517 stage: -> patch review pull_request: https://github.com/python/cpython/pull/14717 ___ Python tracker ___

[issue37548] Document range of atan, acos and asin

2019-07-11 Thread Giovanni Cappellotto
Giovanni Cappellotto added the comment: I created a small diff to update the documentation of `math.atan`, `math.asin` and `math.acos`. -- nosy: +potomak ___ Python tracker _

[issue37570] `distutils.util.byte_compile` fails indirect byte compiling with non-ASCII full-path.

2019-07-11 Thread Aldwin Pollefeyt
Aldwin Pollefeyt added the comment: All 'The byte compiling test seems succeeded.' when i tested your script on ubuntu 18.04 on latest 3.7.4rc2+, 3.8.0b1+ and 3.9.0a0. What are the exact python versions and the OS version you see the issue? -- nosy: +aldwinaldwin ___

[issue37555] _CallList.__contains__ doesn't always respect ANY.

2019-07-11 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: > Karthikeyan, I think there is a flaw in your example. The good __eq__ should > return NotImplemented instead of False for other types. This wil allow the > right operand's __eq__ to play. Serhiy, my example was to try reproducing the original rep

[issue37570] `distutils.util.byte_compile` fails indirect byte compiling with non-ASCII full-path.

2019-07-11 Thread Suzumizaki
Suzumizaki added the comment: Terribly Sorry! I forgot to write this is only Windows Issue! Thanks! -- components: +Unicode, Windows nosy: +ezio.melotti, paul.moore, steve.dower, tim.golden, vstinner, zach.ware ___ Python tracker

[issue37570] `distutils.util.byte_compile` fails indirect byte compiling with non-ASCII full-path.

2019-07-11 Thread Suzumizaki
Suzumizaki added the comment: ... and please check "batch.diff" (Oops, that's typo of 'patch'). I just added "encoding" parameter to calling open() function, and added the temp file to 'utf-8' code declaration. This bug could happen where the default encoding of open() function is not utf-8(

  1   2   >