[issue29798] Handle "git worktree" in "make patchcheck"

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 6a6d090612dd7deaac2bc0399fad743e5e2db606 by Nick Coghlan in branch 'master': bpo-29798: Handle git worktree in `make patchcheck` (#629) https://github.com/python/cpython/commit/6a6d090612dd7deaac2bc0399fad74

[issue29656] Change "make patchcheck" to be branch aware

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset be31a837304f81842b13dbabdaaa14bb9bbe64af by Nick Coghlan in branch '3.5': bpo-29656: Handle PR branches in 'make patchcheck' (#302) (#627) https://github.com/python/cpython/commit/be31a837304f81842b13

[issue29656] Change "make patchcheck" to be branch aware

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 2f386254e2cf054cc7ee5103b54c1cf16d9fa979 by Nick Coghlan in branch '3.6': bpo-29656: Handle PR branches in 'make patchcheck' (#302) (#626) https://github.com/python/cpython/commit/2f386254e2cf054cc7ee

[issue29656] Change "make patchcheck" to be branch aware

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 482f7a274fa52b7ba34ff308cd9acdcac9f41ba5 by Nick Coghlan in branch 'master': bpo-29656: Handle PR branches in 'make patchcheck' (#302) https://github.com/python/cpython/commit/482f7a274fa52b7ba34f

[issue29537] Alternative fix for BUILD_MAP_UNPACK_WITH_CALL opcode in 3.5

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 0410bee6e6c87f37e91f6cae3627d8e3704075f1 by Nick Coghlan in branch '3.5': bpo-29537: Also cover 3.5.2 in NEWS entry https://github.com/python/cpython/commit/0410bee6e6c87f37e91f6cae3627d8

[issue27286] str object got multiple values for keyword argument

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 93602e3af70d3b9f98ae2da654b16b3382b68d50 by Nick Coghlan in branch '3.5': [3.5] bpo-29537: Tolerate legacy invalid bytecode (#169) https://github.com/python/cpython/commit/93602e3af70d3b9f98ae2da654b16b3382b68d50 -- nosy:

[issue29537] Alternative fix for BUILD_MAP_UNPACK_WITH_CALL opcode in 3.5

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 93602e3af70d3b9f98ae2da654b16b3382b68d50 by Nick Coghlan in branch '3.5': [3.5] bpo-29537: Tolerate legacy invalid bytecode (#169) https://github.com/python/cpython/commit/93602e3af70d3b9f98ae2da654b16b

[issue24241] webbrowser default browser detection and/or public API for _trylist.

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 56a8eccc43c66ae51c5a6bfc89635b1998fd419e by Nick Coghlan in branch 'master': bpo-24241: Add dedicated webbrowser.register test case (#288) https://github.com/python/cpython/commit/56a8eccc43c66ae51c5a6bfc89635b

[issue29644] Importing webbrowser outputs a message on stderr

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 140792bd514ee4ba739fda899785bea3ce746f05 by Nick Coghlan in branch 'master': bpo-29644: suppress subprocess output from webbrowser (#289) https://github.com/python/cpython/commit/140792bd514ee4ba739fda899785be

[issue26128] Let the subprocess.STARTUPINFO constructor take arguments

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset ae160bba2030a7b6c86f6c7aeaf2f9d3fdb627b7 by Nick Coghlan (Subhendu Ghosh) in branch 'master': bpo-26128: Added __init__to subprocess.STARTUPINFO (#171) https://github.com/python/cpython/commit/ae160bba2030a7b6c86f6c7aeaf2f9

[issue16285] Update urllib quoting to RFC 3986

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 21024f06622c4c55b666adb130797a4ee205d005 by Nick Coghlan (Ratnadeep Debnath) in branch 'master': bpo-16285: Update urllib quoting to RFC 3986 (#173) https://github.com/python/cpython/commit/21024f06622c4c55b666adb130797a

[issue24241] webbrowser default browser detection and/or public API for _trylist.

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset e3ce69522ffd7c0354d6e70d18f42bce325ed97e by Nick Coghlan (David Steele) in branch 'master': bpo-24241: Improve preferred webbrowser handling (#85) https://github.com/python/cpython/commit/e3ce69522ffd7c0354d6e70d18f42b

[issue20438] inspect: Deprecate getfullargspec?

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 2197eac6104311472f200645bc844adb46444b10 by Nick Coghlan (Berker Peksag) in branch '3.6': bpo-28814: Undeprecate inadvertently deprecated inspect functions. (#122) (#243) https://github.com/python/cpyt

[issue28814] Deprecation notice on inspect.getargvalues() is incorrect

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 2197eac6104311472f200645bc844adb46444b10 by Nick Coghlan (Berker Peksag) in branch '3.6': bpo-28814: Undeprecate inadvertently deprecated inspect functions. (#122) (#243) https://github.com/python/cpyt

[issue20438] inspect: Deprecate getfullargspec?

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 0246422b974b1a0c50dd30b0e1a1138674ef87a5 by Nick Coghlan (Berker Peksag) in branch '3.5': bpo-28814: Undeprecate inadvertently deprecated inspect functions. (#122) (#244) https://github.com/python/cpyt

[issue28814] Deprecation notice on inspect.getargvalues() is incorrect

2017-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 0246422b974b1a0c50dd30b0e1a1138674ef87a5 by Nick Coghlan (Berker Peksag) in branch '3.5': bpo-28814: Undeprecate inadvertently deprecated inspect functions. (#122) (#244) https://github.com/python/cpyt

[issue29913] ipadress compare_networks does not work according to documentation

2017-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: Looking into it, this appears to be a holdover from the original ipaddr design where rather than being modelled as separate objects, host interfaces are modelled as denormalised network objects (i.e. a host address with a netmask). So the stdlib equivalent of

[issue29913] ipadress compare_networks does not work according to documentation

2017-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: Right, I agree compare_networks() is behaving correctly according to its original design. However: - it was designed for Python 2, where cmp() style idioms were still more common. Those idioms have largely been removed in Python 3 (no cmp() builtin, no __cmp__

[issue29929] Idea: Make __main__ an implied package

2017-03-28 Thread Nick Coghlan
New submission from Nick Coghlan: In just the last 24 hours, I've run across two cases where the default "the script directory is on sys.path" behaviour confused even experienced programmers: 1. a GitHub engineer thought the Python version in their Git-for-Windows bundle was

[issue29929] Idea: Make __main__ an implied package

2017-03-28 Thread Nick Coghlan
Nick Coghlan added the comment: A key enabler for actually pursuing this idea would be coming up with a feasible way of emitting a deprecation warning for code that relied on the old implicit relative imports. A reasonable fast check for that would be to: 1. Start populating a private sys

[issue29929] Eliminate implicit __main__ relative imports

2017-03-28 Thread Nick Coghlan
Nick Coghlan added the comment: In formulating a post to import-sig about this, I realised it made more sense to describe it in terms of the goal (eliminating implicit __main__ relative imports) rather than one possible technique for achieving that goal. -- title: Idea: Make __main__

[issue29798] Handle "git worktree" in "make patchcheck"

2017-03-28 Thread Nick Coghlan
Nick Coghlan added the comment: No, that's the bug that prompted me to reopen the issue. I just got distracted and never submitted the follow-up PR :( -- ___ Python tracker <http://bugs.python.org/is

[issue29944] Argumentless super() calls do not work in classes constructed with type()

2017-03-30 Thread Nick Coghlan
Nick Coghlan added the comment: Interestingly, even `types.new_class` misbehaves in this case: ``` >>> def mydec(cls): ... return types.new_class(cls.__name__, cls.__bases__, exec_body=lambda ns: ns.update(cls.__dict__)) ... >>> @mydec ... class MyList(list): ... de

[issue29944] Argumentless super() calls do not work in classes constructed with type()

2017-03-30 Thread Nick Coghlan
Nick Coghlan added the comment: Right, there's a very similar instance-method-reuse related problem described in http://bugs.python.org/issue29270, where ctypes re-uses a class namespace is define a swapped-endianness version of the originally defined class. The easiest place to de

[issue29881] Add a new private API clear private variables, which are initialized once, at Python shutdown

2017-03-30 Thread Nick Coghlan
Nick Coghlan added the comment: I'm +1 for _Py_SET_FINALIZED with the semantics Serhiy suggests, and +0 for _Py_SET_ONCE. My rationale for that preference is that _Py_SET_ONCE is a misnomer in the presence of * multiple Py_Initialize/Py_Finalize cycles; and/or * _Py_SETREF calls that re

[issue29881] Add a new private API clear private variables, which are initialized once, at Python shutdown

2017-03-30 Thread Nick Coghlan
Nick Coghlan added the comment: _PY_SET_FINALIZED is only one letter longer than _PY_ONCEVAR_INIT and the same length as the originally proposed _PY_STATICVAR_INIT. Since it shouldn't be anywhere near as common as _Py_SETREF, I'm also okay in general with trading a bit of brevity fo

[issue27100] Attempting to use class with both __enter__ & __exit__ undefined yields __exit__ attribute error

2017-04-04 Thread Nick Coghlan
Nick Coghlan added the comment: Reviewing the discussion, I assume this was left open to cover reordering the __aenter__ and __aexit__ checks for async with, but that can just as easily be handled as a separate issue (which would also be clearer at the NEWS level). -- stage: patch

[issue29988] (async) with blocks and try/finally are not as KeyboardInterrupt-safe as one might like

2017-04-04 Thread Nick Coghlan
Nick Coghlan added the comment: My first thought would be to inject a wordcode instruction that's essentially an eval loop directive: "ATOMIC_UNTIL " ATOMIC_UNTIL would have at least the following properties: - checks for signals are skipped until the given offset is reac

[issue11978] Report correct coverage.py data for tests that invoke subprocesses

2017-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: As a starting point, I'd suggest looking at what can be achieved without making any changes to CPython or its test suite: 1. Set COVERAGE_PROCESS_START in the environment where the tests are being run 2. Inject a sitecustomize.py file into Lib (and add

[issue11978] Report correct coverage.py data for tests that invoke subprocesses

2017-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: To be more specific regarding `sitecustomize.py`: $ echo "print('Hello from sitecustomize.py')" > Lib/sitecustomize.py $ ./python -c "print('Hello from command line')" Hello from sitecustomize.py Hello

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1204 ___ Python tracker <http://bugs.python.org/issue29798> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1205 ___ Python tracker <http://bugs.python.org/issue29798> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Oops, the new PRs and merges haven't shown up automatically because I didn't fix the spelling of the issue number. 3.7 (master): https://github.com/python/cpython/pull/1058 3.6: https://github.com/python/cpython/pull/1060 3.5: https://github.com/pyth

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1206 ___ Python tracker <http://bugs.python.org/issue29798> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1207 ___ Python tracker <http://bugs.python.org/issue29798> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 4c116cb3b3ee38cae229f7e0df0cd2045fe73c27 by Nick Coghlan in branch '3.6': bpo-29798: Handle git worktree in patchcheck (#1058) (#1060) https://github.com/python/cpython/commit/4c116cb3b3ee38cae229f7e0df0cd2

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset c82d39479a88154bd72a3a304be5f473c118da95 by Nick Coghlan in branch '3.5': bpo-29798: Handle git worktree in patchcheck https://github.com/python/cpython/commit/c82d39479a88154bd72a3a304be5f4

[issue29798] Handle "git worktree" in "make patchcheck"

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: OK, this should really be working now (and I checked it on my 2.7 checkout before submitting that PR). Any further problems found should go in a new issue. -- resolution: -> fixed stage: needs patch -> resolved status: open -&g

[issue13691] pydoc help (or help('help')) should show the doc for help

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: After reviewing Sanyam's PR at https://github.com/python/cpython/pull/172 I ended up rejecting it as an approach to resolving this issue. The core problem with the approach is that accessing `_sitebuiltins._Helper` is an implementation detail twice

[issue22702] to improve documentation for join() (str method)

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Raymond, in the review comments on https://github.com/python/cpython/pull/156 Xiang noted that the current apparently duplicated iterable isn't entirely redundant: - the first reference is to the term "iterable" - the second reference is to the

[issue22702] to improve documentation for join() (str method)

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Noting for the record: Marco Buttu proposed my suggested approach on the PR back in early March. -- ___ Python tracker <http://bugs.python.org/issue22

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Assigning to myself since Sanyam submitted the related PR at the PyCon Pune sprints. -- assignee: docs@python -> ncoghlan ___ Python tracker <http://bugs.python.org/issu

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: I'm going to merge Sanyam's PR as-is, as while David's reformulation shorten the overall sentence, it complicates the core description of the problem (copying things that you didn't want copied) by merging it with the stereotypical example

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 19e04942562a980ad2519f6ff79c455a7472783b by Nick Coghlan (Sanyam Khurana) in branch 'master': bpo-29506: Clarify deep copy note in copy module https://github.com/python/cpython/commit/19e04942562a980ad2519f6ff79c45

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1208 ___ Python tracker <http://bugs.python.org/issue29506> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1209 ___ Python tracker <http://bugs.python.org/issue29506> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1210 ___ Python tracker <http://bugs.python.org/issue29506> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13691] pydoc help (or help('help')) should show the doc for help

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Aye, it's definitely a tricky problem. While I didn't take them into account in my review, I now realise those issues also impacted the attempted workaround - I'd be surprised if it worked as intended in those other contexts (even the "pyd

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset a524d6307273e3920d410452ace89610c843f051 by Nick Coghlan in branch '3.6': bpo-29506: Clarify deep copy note in copy module https://github.com/python/cpython/commit/a524d6307273e3920d410452ace896

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset ab16dc180e362e4cdb9eb163fae0a75664dcea3e by Nick Coghlan in branch '2.7': bpo-29506: Clarify deep copy note in copy module https://github.com/python/cpython/commit/ab16dc180e362e4cdb9eb163fae0a7

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Changes by Nick Coghlan : -- resolution: -> fixed stage: needs patch -> resolved status: open -> closed type: -> enhancement ___ Python tracker <http://bugs.python

[issue29506] Incorrect documentation for the copy module

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset bd18351c31573ab9a8580677004370a774a4eaae by Nick Coghlan in branch '3.5': bpo-29506: Clarify deep copy note in copy module https://github.com/python/cpython/commit/bd18351c31573ab9a8580677004370

[issue30024] Treat `import a.b.c as m` as `m = sys.modules['a.b.c']`

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: The background here is the change in http://bugs.python.org/issue17636 that allows IMPORT_FROM to fall back to sys.modules when written as "from a.b import c as m", while the plain LOAD_ATTR generated for "import a.b.c as m" fails. One pot

[issue30024] Treat `import a.b.c as m` as `m = sys.modules['a.b.c']`

2017-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: Right, this problem only arises with import cycles, and that's why we resisted making eager submodule resolution work *at all* for so long (issue 992389 was filed way back in 2004). We only conceded the point (with issue 17636 being implemented fo

[issue29692] contextlib.contextmanager may incorrectly unchain RuntimeError

2017-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 00c75e9a45ff0366c185e9e8a2e23af5a35481b0 by Nick Coghlan (svelankar) in branch 'master': bpo-29692: contextlib.contextmanager may incorrectly unchain RuntimeError (GH-949) https://github.com/python/cpyt

[issue29692] contextlib.contextmanager may incorrectly unchain RuntimeError

2017-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: This has been merged for 3.7, but cherry-picks to the other branches are still needed. I also inadvertently missed adding svelankar's name (Siddharth Velankar) to Misc/ACKS, so that oversight will need to be tidied up as well. -- resolution: -&g

[issue29692] contextlib.contextmanager may incorrectly unchain RuntimeError

2017-04-11 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan ___ Python tracker <http://bugs.python.org/issue29692> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue29692] contextlib.contextmanager may incorrectly unchain RuntimeError

2017-04-11 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1222 ___ Python tracker <http://bugs.python.org/issue29692> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29692] contextlib.contextmanager may incorrectly unchain RuntimeError

2017-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset e8a6bb4f3936123f3eca0b6cea05e2875a2722bc by Nick Coghlan in branch 'master': bpo-29692: Add missing ACKS entry (#1079) https://github.com/python/cpython/commit/e8a6bb4f3936123f3eca0b6cea05e2

[issue30024] Treat `import a.b.c as m` as `m = sys.modules['a.b.c']`

2017-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: Huh, interesting - I'd missed that the only part of the "from a.b import c" that IMPORT_FROM implements is the LOAD_ATTR variant that falls back to sys.modules. The prior adjustment to get IMPORT_NAME to return "a.b" instead of "

[issue11822] Improve disassembly to show embedded code objects

2017-04-15 Thread Nick Coghlan
Nick Coghlan added the comment: +1 for listing the nested code objects after the original one. In reviewing Serhiy's patch, the core technical implementation looks OK to me, but I think we may want to go with a "depth" argument rather than a simple "recursive" fla

[issue11822] Improve disassembly to show embedded code objects

2017-04-15 Thread Nick Coghlan
Nick Coghlan added the comment: The problem I see is that we have conflicting requirements for the default behaviour: - if we modify dis() instead of adding a new function, then the default behaviour needs to be non-recursive for backwards compatibility reasons - if we allow the depth to be

[issue30076] Opcode names BUILD_MAP_UNPACK_WITH_CALL and BUILD_TUPLE_UNPACK_WITH_CALL are too long

2017-04-16 Thread Nick Coghlan
Nick Coghlan added the comment: If we used the names from inspect.Parameter.kind (https://docs.python.org/3/library/inspect.html#inspect.Parameter.kind) these would become: * BUILD_VAR_POSITIONAL * BUILD_VAR_KEYWORD which would be 20 and 17 letters long, respectively. I think that would

[issue11822] Improve disassembly to show embedded code objects

2017-04-16 Thread Nick Coghlan
Nick Coghlan added the comment: Yeah, I was mixing this up with getargspec (et al), which get used by IDEs and similar tools. While third party tools do use the disassembler, they typically won't use its display logic directly unless they're just dumping the output to a terminal

[issue30076] Opcode names BUILD_MAP_UNPACK_WITH_CALL and BUILD_TUPLE_UNPACK_WITH_CALL are too long

2017-04-18 Thread Nick Coghlan
Nick Coghlan added the comment: I think it should be sufficient connection to describe the link in the documentation as: * BUILD_VAR_POSITIONAL: a variant of BUILD_TUPLE_UNPACK tailored specifically for use in function calls * BUILD_VAR_KEYWORD: a variant of BUILD_MAP_UNPACK tailored

[issue30113] Allow helper functions to wrap sys.setprofile

2017-04-21 Thread Nick Coghlan
Nick Coghlan added the comment: Thanks Louie. I've adjusted the issue title, as I think the core RFE is that we'd like the following helper function to work exactly the same way as calling sys.setprofile directly: def setprofile_helper(f): sys.setprofile(f) The followi

[issue30024] Treat `import a.b.c as m` as `m = sys.modules['a.b.c']`

2017-04-22 Thread Nick Coghlan
Nick Coghlan added the comment: Expanding on Serhiy's answer: the ModuleNotFoundError for "import sys.path" comes from IMPORT_NAME, not from any of the subsequent attribute lookups. That difference is visible in the bytecode: >>> dis("import sys.path as path

[issue23404] 'make touch' does not work with git clones of the source repository

2017-04-23 Thread Nick Coghlan
Nick Coghlan added the comment: As Martin notes, my concern is that I can go for years without having to touch the low level files (since syntax changes are rare), so it's important to me to make it easy to remember and/or relearn how to regenerate them. However, suitable make commands

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

2017-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset c6db4811f9ea3aeff0e1fafe1c60a22835ef359e by Nick Coghlan (csabella) in branch 'master': bpo-30052: Link `bytes` & `bytearray` to stdtypes not functions (GH-1271) https://github.com/python/cpython/commit/c6db4811f9ea3aeff0e1fafe1c

[issue27172] Undeprecate inspect.getfullargspec()

2017-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: No, there are no plans to ever deprecate getfullargspec() again - it isn't hard to maintain indefinitely as a wrapper around inspect.Signature(), and it doesn't have the significant limitations that affected getargspec(). -- priority: deferr

[issue27172] Undeprecate inspect.getfullargspec()

2017-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: Also, note that the programmatic deprecation warning change in the patch is to the warning for `getargspec()`, so that it recommends `getfullargspec()` rather than `Signature()`. There's no runtime deprecation warning for `getfullargspec()` in any versi

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

2017-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: Indeed, checking the dev build at https://docs.python.org/dev/library/urllib.parse.html#url-quoting shows it still linking to the old location. Perhaps the `autobuild-dev-html` target in the Makefile should be adding `-E` and `-a` so it always regenerates

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

2017-04-28 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1450 ___ Python tracker <http://bugs.python.org/issue30052> ___ ___ Python-bugs-list mailing list Unsubscribe:

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

2017-04-28 Thread Nick Coghlan
Nick Coghlan added the comment: New PR disabling the output caching and adding a corresponding NEWS entry: https://github.com/python/cpython/pull/1339 On my local machine, it takes a "nothing changed" build from less than 2 seconds to just under 2 minutes, but I think that's f

[issue22385] Define a binary output formatting mini-language for *.hex()

2017-05-01 Thread Nick Coghlan
Nick Coghlan added the comment: Copying the amended proposal from that python-ideas thread into here: Start with a leading base format character (chosen to be orthogonal to the default format characters): "h": lowercase hex "H": uppercase hex "A": AS

[issue22385] Define a binary output formatting mini-language for *.hex()

2017-05-01 Thread Nick Coghlan
Nick Coghlan added the comment: Minimalist proposal: def hex(self, *, bytes_per_group=None, delimiter=" "): """B.hex() -> string of hex digits B.hex(bytes_per_group=N) -> hex digits in groups separated by *delimeter* Create a str

[issue30223] Add Lib/test/__main__.py in 2.7

2017-05-02 Thread Nick Coghlan
Nick Coghlan added the comment: +1 from me. We hadn't done this (or the test.support backport) previously due to the "no new features" guideline, but I think simplifying cross-branch maintenance overrides that concerns. -- ___ Python

[issue25658] PyThread assumes pthread_key_t is an integer, which is against POSIX

2017-05-02 Thread Nick Coghlan
Nick Coghlan added the comment: Noting a design consideration that I only picked up in the latest PR review: when exposed as part of a non-opaque struct, the type used for TSS keys becomes part of Python's ABI, which means the API design in the PEP is going to have to handle making the s

[issue23404] 'make touch' does not work with git clones of the source repository

2017-05-03 Thread Nick Coghlan
Nick Coghlan added the comment: Could we use "regen-*" as the pattern for the file regeneration targets? I'd expect "make rebuild-all" to be akin to "make clean && make", since in the context of a C project, "buil

[issue22385] Define a binary output formatting mini-language for *.hex()

2017-05-03 Thread Nick Coghlan
Nick Coghlan added the comment: Re-using an existing minilanguage to mean something completely different wouldn't be a good idea. Whether or not we should add any bytes specific features for this at all is also still an open question, as one of the points raised in the latest python-

[issue30247] Make importlib.machinery class handle os.PathLike path

2017-05-04 Thread Nick Coghlan
Nick Coghlan added the comment: FileFinder only handles a single directory, and FileLoader only handles a single file, so their "path" attributes are paths in the "fspath" sense, rather than the "sys.path" or "PathFinder" sense. Perhaps it would be wort

[issue23404] 'make touch' does not work with git clones of the source repository

2017-05-05 Thread Nick Coghlan
Nick Coghlan added the comment: As noted on python-dev, it would be helpful if this change was mentioned in the 2.7, 3.5, and 3.6 What's New documents under a "Notable changes in maintenance releases" section. For 2.7, that would be a retitling of the existing section "Ne

[issue30306] release arguments of contextmanager

2017-05-08 Thread Nick Coghlan
Nick Coghlan added the comment: Nice catch. This behaviour is an artifact of the ContextDecorator support in _GeneratorContextManager, where context managers created with `@contextmanager` can be used as function decorators (implicitly wrapping them in a with statement) as well as directly in

[issue24932] Use proper command line parsing in _testembed

2017-05-08 Thread Nick Coghlan
Nick Coghlan added the comment: Based on the latest round of PEP 538 review, the related test case that currently relies on _testembed is going to be able to be simplified to just setting LC_ALL=C when calling the subprocess (the amount of code it's letting me delete from the draft pat

[issue504219] locale.resetlocale is broken

2017-05-09 Thread Nick Coghlan
Nick Coghlan added the comment: Trying to come up with a short LC_MONETARY example for PEP 538, I just ran into what seems to be a related problem with locale.resetlocale(), which is that it doesn't work properly for categories other than LC_CTYPE: locale.getdefaultlocale() doesn'

[issue30306] release arguments of contextmanager

2017-05-09 Thread Nick Coghlan
Nick Coghlan added the comment: You're right, there's no actual requirement that _recreate_cm() call self.__class__, so it can use a different type internally. -- ___ Python tracker <http://bugs.python.o

[issue30306] release arguments of contextmanager

2017-05-10 Thread Nick Coghlan
Nick Coghlan added the comment: Noting something I picked up in the PR review that apparently isn't covered by the test suite: the whole _recreate_cm() dance is necessary to make recursive and concurrent invocation of decorated functions work correctly. Otherwise the original CM instance

[issue30359] A standard convention for annotating a function as returning an (async) context manager?

2017-05-12 Thread Nick Coghlan
Nick Coghlan added the comment: Given that we have contextlib.AbstractContextManager now, perhaps it should just set "f.__annotations__['return'] = AbstractContextManager"? (assuming no other return annotation is already set) -- __

[issue30354] Change data model documentation to zero-argument super()

2017-05-14 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 12b1c180986fc744331b8f30d3d2f49a0fdb43dd by Nick Coghlan (csabella) in branch 'master': bpo-30354: Update data model documentation for super() (GH-1561) https://github.com/python/cpython/commit/12b1c180986fc744331b8f30d3d2f4

[issue29710] Incorrect representation caveat on bitwise operation docs

2017-05-16 Thread Nick Coghlan
Nick Coghlan added the comment: I think the simplest fix to make the docs "not wrong" would be to just delete the part in parentheses. Beyond that, I'm not quite sure how to concisely describe the actual behaviour, but I think the mention of "2's complement" i

[issue30306] release arguments of contextmanager

2017-05-17 Thread Nick Coghlan
Nick Coghlan added the comment: Re-reading my previous comment, I now realise it wasn't particularly clear. To be more explicit, I agree with Serhiy that since the internals of how @contextmanager works are a private API, it makes sense to switch to a two-class design that doesn't r

[issue30403] Running extension modules using -m switch

2017-05-20 Thread Nick Coghlan
Nick Coghlan added the comment: As a high level overview of the general idea: we'd like it to be almost entirely transparent to the end user as to whether a particular module is implemented as normal Python source code, a precompiled bytecode/wordcode file, or a precompiled Cython exte

[issue30403] Running extension modules using -m switch

2017-05-20 Thread Nick Coghlan
Nick Coghlan added the comment: Yep, that's the kind of thing we'd like to make possible. -- ___ Python tracker <http://bugs.python.org/issue30403> ___ ___

[issue30420] Clarify kwarg handing for subprocess convenience APIs

2017-05-20 Thread Nick Coghlan
New submission from Nick Coghlan: As per the discussion in https://github.com/python/cpython/pull/1685, the current nominal signatures of the convenience APIs in subprocess is confusing, as they don't make it clear that all Popen keyword arguments are supported, with only the most common

[issue25532] infinite loop when running inspect.unwrap over unittest.mock.call

2017-05-22 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset f9169ce6b48c7cc7cc62d9eb5e4ee1ac7066d14b by Nick Coghlan (Thomas Kluyver) in branch 'master': bpo-25532: Protect against infinite loops in inspect.unwrap() (#1717) https://github.com/python/cpython/commit/f9169ce6b48c7cc7cc62d9eb5e4ee1

[issue25532] infinite loop when running inspect.unwrap over unittest.mock.call

2017-05-22 Thread Nick Coghlan
Changes by Nick Coghlan : -- stage: needs patch -> backport needed versions: +Python 3.7 ___ Python tracker <http://bugs.python.org/issue25532> ___ ___ Python-

[issue25532] infinite loop when running inspect.unwrap over unittest.mock.call

2017-05-23 Thread Nick Coghlan
Nick Coghlan added the comment: Ah, sorry - I merged the PR before seeing the discussion about the limit over here. I'd be fine with replacing the sys.getrecursionlimit() call with a module level constant like "_UNWRAP_LIMIT = 500". If someone desperately needed a higher

[issue30403] Running extension modules using -m switch

2017-05-24 Thread Nick Coghlan
Nick Coghlan added the comment: I just marked the associated PR as "[PEP required]", as while I'm in favour of merging this, I think we should go through the PEP process first: 1. We've been burned before by not properly advertising changes to Python's command

[issue12857] Expose called function on frame object

2017-05-25 Thread Nick Coghlan
Nick Coghlan added the comment: Regarding Mark's point about the anonymous scopes created for things like list comprehensions, at least in CPython, those are actually full functions with generated names like "" (at module level) or "f.." (at function level). >Fr

[issue30420] Clarify kwarg handing for subprocess convenience APIs

2017-05-25 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 368cf1d20630498ca7939069a05d744fabb570aa by Nick Coghlan (Alex Gaynor) in branch 'master': bpo-30420: List cwd parameter in subprocess convenience APIs (GH-1685) https://github.com/python/cpython/commit/368cf1d20630498ca7939069a05d74

<    16   17   18   19   20   21   22   23   24   25   >