[issue39670] 2to3 fix_apply tries to fix user-defined apply function calls

2020-02-18 Thread ilya
New submission from ilya : Consider the following code: def apply(a, b): print(a) print(b) apply(1, 1) 2to3 suggests to fix it as follows: --- a.py(original) +++ a.py(refactored) @@ -2,4 +2,4 @@ print(a) print(b) -apply(1, 1) +(1)(*1) -- component

[issue39668] segmentation fault on calling __reversed__()

2020-02-18 Thread Grzegorz Krasoń
Grzegorz Krasoń added the comment: Python 3.8.0 (default, Oct 23 2019, 18:51:26) [GCC 9.2.0] on linux Linux anarchy 4.19.91-1-lts #1 SMP Sat, 21 Dec 2019 16:34:46 + x86_64 GNU/Linux Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz -- ___ Python tracker

[issue21255] Attaching a PropertyMock records calls

2020-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue39668] segmentation fault on calling __reversed__()

2020-02-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: Can you please try and update to 3.8.1? It should be fixed there. -- ___ Python tracker ___ ___

[issue39671] Mention in docs that asyncio.FIRST_COMPLETED does not guarantee the completion of no more than one task

2020-02-18 Thread Tom Pohl
New submission from Tom Pohl : Currently, the documentation of asyncio.wait gives the impression that using FIRST_COMPLETED guarantees the completion of no more than one task. In reality, the number of completed task after asyncio.wait can be larger than one. While this behavior (exactly one

[issue39671] Mention in docs that asyncio.FIRST_COMPLETED does not guarantee the completion of no more than one task

2020-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- components: +asyncio nosy: +asvetlov, yselivanov ___ Python tracker ___ ___ Python-bugs-list

[issue39670] 2to3 fix_apply tries to fix user-defined apply function calls

2020-02-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: apply was a builtin in Python 2 and not sure 2to3 can differentiate between user defined functions that shadow builtins. https://docs.python.org/3.8/library/2to3.html#2to3fixer-apply . Removes usage of apply(). For example apply(function, *args, **

[issue26967] argparse: allow_abbrev=False stops -vv from working

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset 8edfc47baec7ff4cb1b9db83dd35c8ffc1d498a4 by Kyle Meyer in branch 'master': bpo-39546: argparse: Honor allow_abbrev=False for specified prefix_chars (GH-18337) https://github.com/python/cpython/commit/8edfc47baec7ff4cb1b9db83dd35c8ffc1d498a4 -

[issue26967] argparse: allow_abbrev=False stops -vv from working

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17921 pull_request: https://github.com/python/cpython/pull/18543 ___ Python tracker ___ __

[issue39546] argparse: allow_abbrev=False is ignored for alternative prefix characters

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset 8edfc47baec7ff4cb1b9db83dd35c8ffc1d498a4 by Kyle Meyer in branch 'master': bpo-39546: argparse: Honor allow_abbrev=False for specified prefix_chars (GH-18337) https://github.com/python/cpython/commit/8edfc47baec7ff4cb1b9db83dd35c8ffc1d498a4 -

[issue39546] argparse: allow_abbrev=False is ignored for alternative prefix characters

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17920 pull_request: https://github.com/python/cpython/pull/18543 ___ Python tracker ___ __

[issue39668] segmentation fault on calling __reversed__()

2020-02-18 Thread Grzegorz Krasoń
Grzegorz Krasoń added the comment: I confirm. 3.8.1 is fixed. Thank you and sorry for bothering. -- ___ Python tracker ___ ___ Pytho

[issue39672] SIGSEGV crash on shutdown with shelve & c pickle

2020-02-18 Thread zd nex
New submission from zd nex : Hello, so I was transferring some our old code from Python2.7 to new and find that new version seems to crash quite a lot. After some finding (good thing faulthandler) I think I tracked it down to to Shelve.__del__ method > going to C Pickle module (not python one

[issue39673] TimeoutError

2020-02-18 Thread YoSTEALTH
New submission from YoSTEALTH : import os try: no = -62 raise OSError(-no, os.strerror(-no)) except TimeoutError: print('Success') except OSError as e: print('Failed:', e) # Failed: [Errno 62] Timer expired Shouldn't `TimeoutError` catch this error? -- messages:

[issue39673] TimeoutError

2020-02-18 Thread Eric V. Smith
Eric V. Smith added the comment: I don't see why it would. You're raising OSError, which is not a subclass of TimeoutError, so the TimeoutError code is not executing. You don't say, but I assume this is what you think should happen. The exception handling machinery does not look inside a rai

[issue39668] segmentation fault on calling __reversed__()

2020-02-18 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: No problem, closing it as duplicate of issue38525. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Strange reversed dict behavior ___ Python tracker

[issue39673] TimeoutError

2020-02-18 Thread YoSTEALTH
YoSTEALTH added the comment: Since I provide `OSError` with appropriate `errono`, it raises that error for example: import os try: no = -11 raise OSError(-no, os.strerror(-no)) except BlockingIOError as e: print('Success:', e) # Success: [Errno 11] Resource temporarily unava

[issue39673] TimeoutError

2020-02-18 Thread Eric V. Smith
Eric V. Smith added the comment: In both examples, what's being printed? It's not clear from your messages. -- ___ Python tracker ___ _

[issue39673] TimeoutError

2020-02-18 Thread YoSTEALTH
YoSTEALTH added the comment: First example prints # Failed: [Errno 62] Timer expired Second example prints # Success: [Errno 11] Resource temporarily unavailable -- ___ Python tracker __

[issue39546] argparse: allow_abbrev=False is ignored for alternative prefix characters

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset e412cbba52e7cf6699720d99a4b88baef92db7b2 by Miss Islington (bot) in branch '3.8': [3.8] bpo-39546: argparse: Honor allow_abbrev=False for specified prefix_chars (GH-18337) (GH-18543) https://github.com/python/cpython/commit/e412cbba52e7cf669972

[issue26967] argparse: allow_abbrev=False stops -vv from working

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset e412cbba52e7cf6699720d99a4b88baef92db7b2 by Miss Islington (bot) in branch '3.8': [3.8] bpo-39546: argparse: Honor allow_abbrev=False for specified prefix_chars (GH-18337) (GH-18543) https://github.com/python/cpython/commit/e412cbba52e7cf669972

[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset 5d38517aa1836542a5417b724c093bcb245f0f47 by Hai Shi in branch 'master': bpo-1635741: Port _bz2 extension module to multiphase initialization(PEP 489) (GH-18050) https://github.com/python/cpython/commit/5d38517aa1836542a5417b724c093bcb245f0f47

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread STINNER Victor
New submission from STINNER Victor : Following discussion on python-dev, I propose to revert the removal of a few deprecated functions to keep them in Python 3.9, and only remove them in Python 3.10. Please see the following email for the longer rationale, and the discussion for further detai

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue25988] collections.abc.Indexable

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +17923 pull_request: https://github.com/python/cpython/pull/18545 ___ Python tracker ___ __

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +17922 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18545 ___ Python tracker ___ _

[issue39675] forked process in multiprocessing does not honour atexit

2020-02-18 Thread gaborbernat
New submission from gaborbernat : I've talked with Pablo about this in person, and as advised opening the issue here now. I've discovered that forked processes do not honour atexit registrations. See the following example code: from multiprocessing import Process, set_start_method import ti

[issue39245] Public API for Vectorcall (PEP 590)

2020-02-18 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue39432] Distutils generates the wrong export symbol for unicode module names

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17924 stage: backport needed -> patch review pull_request: https://github.com/python/cpython/pull/18546 ___ Python tracker ___ ___

[issue39611] PyVectorcall_NARGS(): change return type to Py_ssize_t

2020-02-18 Thread Petr Viktorin
Petr Viktorin added the comment: The current return type already is Py_ssize_t, exactly for the reason you mention – compatibility with all other "argument count" values in Python. (It would be more correct to use unsigned, but that ship has sailed.) The *argument* type is unsigned size_t, th

[issue39611] PyVectorcall_NARGS(): change return type to Py_ssize_t

2020-02-18 Thread Petr Viktorin
Petr Viktorin added the comment: Closing; please reopen if we're somehow misunderstanding each other :) -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker

[issue39673] TimeoutError

2020-02-18 Thread Eric V. Smith
Eric V. Smith added the comment: Ah, I see. What platform are you on, and what's the value of errno.ETIMEDOUT? On cygwin I get: >>> errno.ETIMEDOUT 116 On a native Windows build I get: >>> errno.ETIMEDOUT 10060 and on Fedora I get: >>> errno.ETIMEDOUT 110 If you use errno.ETIMEDOUT instead

[issue39675] forked process in multiprocessing does not honour atexit

2020-02-18 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- assignee: -> pablogsal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39675] forked process in multiprocessing does not honour atexit

2020-02-18 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- components: +Library (Lib) type: -> behavior versions: +Python 3.9 ___ Python tracker ___ ___

[issue39479] [RFE] Add math.lcm() function: Least Common Multiple

2020-02-18 Thread Ananthakrishnan
Change by Ananthakrishnan : -- pull_requests: +17925 pull_request: https://github.com/python/cpython/pull/18547 ___ Python tracker ___ _

[issue39673] TimeoutError

2020-02-18 Thread YoSTEALTH
YoSTEALTH added the comment: I am on Linux 5.5.2-1-MANJARO >>> sorted(errno.errorcode.items()) [(1, 'EPERM'), (2, 'ENOENT'), (3, 'ESRCH'), (4, 'EINTR'), (5, 'EIO'), (6, 'ENXIO'), (7, 'E2BIG'), (8, 'ENOEXEC'), (9, 'EBADF'), (10, 'ECHILD'), (11, 'EAGAIN'), (12, 'ENOMEM'), (13, 'EACCES'), (14,

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread Jason Madden
Change by Jason Madden : -- nosy: +jmadden ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue38691] [easy] importlib: PYTHONCASEOK should be ignored when using python3 -E

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: Tests fail on macOS: https://buildbot.python.org/all/#/builders/275/builds/249 I reopen the issue. The issue should be fixed soon, or the change will be reverted to repair buildobts: https://pythondev.readthedocs.io/ci.html#revert-on-fail ===

[issue39676] test_shutil fails with OSError: [Errno 28] No space left on device on "PPC64LE Fedora Stable LTO + PGO 3.x" buildbot

2020-02-18 Thread STINNER Victor
New submission from STINNER Victor : PPC64LE Fedora Stable LTO + PGO 3.x: https://buildbot.python.org/all/#/builders/449/builds/31 Example: == ERROR: test_big_chunk (test.test_shutil.TestZeroCopySendfile) -

[issue39673] TimeoutError

2020-02-18 Thread Eric V. Smith
Eric V. Smith added the comment: > These are both timeout errors but only `ETIMEDOUT` is accounted for? Yes, only ETIMEDOUT is accounted for in Objects/exceptions.c. There's precedent for mapping multiple errnos to the same exception: ADD_ERRNO(BlockingIOError, EAGAIN); ADD_ERRNO(Blo

[issue39673] TimeoutError

2020-02-18 Thread YoSTEALTH
YoSTEALTH added the comment: If nothing else, it could be a feature of next Python release as its appropriate that `TimeoutError` catches both `ETIME` and `ETIMEDOUT`. -- versions: +Python 3.9 -Python 3.8 ___ Python tracker

[issue39432] Distutils generates the wrong export symbol for unicode module names

2020-02-18 Thread Stefan Behnel
Stefan Behnel added the comment: New changeset 5bf58cef151249f1cca92166d1b70693348da9d8 by Miss Islington (bot) in branch '3.8': bpo-39432: Implement PEP-489 algorithm for non-ascii "PyInit_*" symbol names in distutils (GH-18150) (GH-18546) https://github.com/python/cpython/commit/5bf58cef15

[issue36347] Renaming the constants for the .flags of PyMemberDef

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset 24bba8cf5b8db25c19bcd1d94e8e356874d1c723 by Jeroen Demeyer in branch 'master': bpo-36347: stop using RESTRICTED constants (GH-12684) https://github.com/python/cpython/commit/24bba8cf5b8db25c19bcd1d94e8e356874d1c723 -- nosy: +miss-islin

[issue39432] Distutils generates the wrong export symbol for unicode module names

2020-02-18 Thread Stefan Behnel
Change by Stefan Behnel : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue39677] 3.6+ documentation for MAKE_FUNCTION

2020-02-18 Thread thautwarm
New submission from thautwarm : LINK: https://docs.python.org/3.6/library/dis.html?highlight=bytecode#opcode-MAKE_FUNCTION To avoid being confusing, MAKE_FUNCTION(argc) shall be MAKE_FUNCTION(flag), since 3.6 the operand of MAKE_FUNCTION never means `argcount`. -- assignee: docs@pyth

[issue39677] 3.6+ documentation for MAKE_FUNCTION

2020-02-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Agree. Do you want to provide a PR? Although it may be too later for 3.6 which only takes security fixes. -- keywords: +easy nosy: +serhiy.storchaka stage: -> needs patch versions: +Python 3.7, Python 3.8, Python 3.9 __

[issue39555] test_distutils fails for Windows debug build

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17926 pull_request: https://github.com/python/cpython/pull/18548 ___ Python tracker ___ __

[issue39673] Map errno==ETIME to TimeoutError

2020-02-18 Thread Eric V. Smith
Change by Eric V. Smith : -- stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue39673] Map errno==ETIME to TimeoutError

2020-02-18 Thread Eric V. Smith
Change by Eric V. Smith : -- title: TimeoutError -> Map errno==ETIME to TimeoutError type: behavior -> enhancement ___ Python tracker ___ __

[issue39555] test_distutils fails for Windows debug build

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17927 pull_request: https://github.com/python/cpython/pull/18546 ___ Python tracker ___ __

[issue38860] GenericPyCData_new does not invoke new or init

2020-02-18 Thread Rebecca Morgan
Rebecca Morgan added the comment: I would still be interested in this, with some clarity on the testing/expected behavior. -- ___ Python tracker ___ _

[issue39677] 3.6+ documentation for MAKE_FUNCTION

2020-02-18 Thread thautwarm
thautwarm added the comment: Okay, I'll make a PR. It's okay because users will always check docs of version 3 instead of a specific version like 3.6. -- ___ Python tracker _

[issue39669] macOS test failures

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: It's bpo-38691. Let's discuss it there. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> [easy] importlib: PYTHONCASEOK should be ignored when using python3 -E ___ Python trac

[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: > If we can keep functions that don't modify the object to accept const > PyObject* it will help make things safer in the long run. In my experience, trying to add "const" is quite painful, since the "const" has to be propagated to all functions called by th

[issue39555] test_distutils fails for Windows debug build

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: This issue is related to bpo-39432. commit 9538bc9185e934bee2bd5ae2cda2b2e92a61906d Author: Stefan Behnel Date: Tue Feb 4 16:24:30 2020 +0100 bpo-39432: Implement PEP-489 algorithm for non-ascii "PyInit_*" symbol names in distutils (GH-18150)

[issue39676] test_shutil fails with OSError: [Errno 28] No space left on device on "PPC64LE Fedora Stable LTO + PGO 3.x" buildbot

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +cstratak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.py

[issue39432] Distutils generates the wrong export symbol for unicode module names

2020-02-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +17928 pull_request: https://github.com/python/cpython/pull/18548 ___ Python tracker ___ __

[issue37373] Configuration of windows event loop for libraries

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- nosy: -vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue39611] PyVectorcall_NARGS(): change return type to Py_ssize_t

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: Alright, I was confused by how PyVectorcall_NARGS() is supposed to be used. -- ___ Python tracker ___ ___

[issue39677] 3.6+ documentation for MAKE_FUNCTION

2020-02-18 Thread thautwarm
Change by thautwarm : -- keywords: +patch pull_requests: +17929 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/18549 ___ Python tracker ___

[issue39677] 3.6+ documentation for MAKE_FUNCTION

2020-02-18 Thread thautwarm
Change by thautwarm : -- pull_requests: +17930 pull_request: https://github.com/python/cpython/pull/18550 ___ Python tracker ___ ___

[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-18 Thread Andy Lester
Andy Lester added the comment: All I'm saying is that I think Py_IS_TYPE is a great idea, and that Py_IS_TYPE should take const arguments, since its arguments are not modified. If you think that should go in a different ticket, then I can make that happen. -- __

[issue32352] `inspect.getfullargspec` doesn't work fine for some builtin callable objects

2020-02-18 Thread thautwarm
Change by thautwarm : -- stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue37921] Improve zipfile: add support for symlinks

2020-02-18 Thread Henning von Bargen
Henning von Bargen added the comment: If I understand correctly, this bug is about supporting symlinks on *creating* ZIP files. Please see also https://bugs.python.org/issue27318 for a proposal to support symlinks while *unpacking* ZIP files. Maybe a preserve_symlinks optional argument shou

[issue39678] RFC improve readability of _queue_management_worker for ProcessPoolExecutor

2020-02-18 Thread Thomas Moreau
New submission from Thomas Moreau : As discussed in GH#17670, the the `_queue_management_worker` function has grown quite long and complicated. It could be turned into an object with a bunch of short and readable helper methods. -- components: Library (Lib) messages: 362218 nosy: pitr

[issue37207] Use PEP 590 vectorcall to speed up calls to range(), list() and dict()

2020-02-18 Thread miss-islington
miss-islington added the comment: New changeset 6e35da976370e7c2e028165c65d7d7d42772a71f by Petr Viktorin in branch 'master': bpo-37207: Use vectorcall for range() (GH-18464) https://github.com/python/cpython/commit/6e35da976370e7c2e028165c65d7d7d42772a71f -- __

[issue39678] RFC improve readability of _queue_management_worker for ProcessPoolExecutor

2020-02-18 Thread Thomas Moreau
Change by Thomas Moreau : -- keywords: +patch pull_requests: +17931 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18551 ___ Python tracker ___ __

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread Guido van Rossum
Guido van Rossum added the comment: Yes please. I have one exception. I f we manage to get the new parser (pegen) in, we have to remove the old parser module. -- nosy: +gvanrossum ___ Python tracker __

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset af5ee3ff610377ef446c2d88bbfcbb3dffaaf0c9 by Victor Stinner in branch 'master': bpo-39674: Revert "bpo-25988: Do not expose abstract collection classes in the collections module. (GH-10596)" (GH-18545) https://github.com/python/cpython/commit/af

[issue25988] collections.abc.Indexable

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: New changeset af5ee3ff610377ef446c2d88bbfcbb3dffaaf0c9 by Victor Stinner in branch 'master': bpo-39674: Revert "bpo-25988: Do not expose abstract collection classes in the collections module. (GH-10596)" (GH-18545) https://github.com/python/cpython/commit/af

[issue39648] Update math.gcd() to accept "n" arguments.

2020-02-18 Thread Ananthakrishnan
Ananthakrishnan added the comment: Can I put together a PR for this issue? -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue39635] One paragraph of the doc is not translated in French

2020-02-18 Thread Ananthakrishnan
Change by Ananthakrishnan : -- keywords: +patch pull_requests: +17932 stage: -> patch review pull_request: https://github.com/python/cpython/pull/1153 ___ Python tracker ___ _

[issue34822] Simplify AST for slices

2020-02-18 Thread Vedran Čačić
Vedran Čačić added the comment: I wrote some AST analyzers, and this would have simplified my code. So I welcome it. :-) However, it means people might be tempted to write a[b:c, d]asa[(b:c, d)] (or at least expect it to work -- same as `a[b, c]` can now be written as `a[(b, c)

[issue39635] One paragraph of the doc is not translated in French

2020-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- pull_requests: -17932 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +17933 pull_request: https://github.com/python/cpython/pull/18552 ___ Python tracker ___ __

[issue39674] Keep deprecated features in Python 3.9 to ease migration from Python 2.7, but remove in Python 3.10

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: PR 18552 adds a section to What's New In Python 3.9 to strongly advice to check for DeprecationWarning in your Python projects. -- ___ Python tracker __

[issue38691] [easy] importlib: PYTHONCASEOK should be ignored when using python3 -E

2020-02-18 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +17934 stage: resolved -> patch review pull_request: https://github.com/python/cpython/pull/18553 ___ Python tracker ___ __

[issue38691] importlib: PYTHONCASEOK should be ignored when using python3 -E

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: I'm unable to debug the issue on macOS. I prepared PR 18553 to revert the change, just to give more time to fix the issue. It's to repair the CI, so we can notice other regressions. -- keywords: -newcomer friendly title: [easy] importlib: PYTHONCASE

[issue38691] importlib: PYTHONCASEOK should be ignored when using python3 -E

2020-02-18 Thread STINNER Victor
STINNER Victor added the comment: > Tests fail on macOS: https://buildbot.python.org/all/#/builders/275/builds/249 Tests are run with "./python.exe ./Tools/scripts/run_tests.py -j 1 -u all -W --slowest --fail-env-changed --timeout=900 -j2 --junit-xml test-results.xml" which runs tests with

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Ananthakrishnan
Ananthakrishnan added the comment: https://stackoverflow.com/questions/58427394/what-is-the-meaning-of-total-dunder-attribute-in-python-3 questions about this. -- nosy: +Ananthakrishnan ___ Python tracker _

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Guido van Rossum
Change by Guido van Rossum : -- keywords: +easy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Ananthakrishnan
Ananthakrishnan added the comment: It will be usefull if we document _total_ argument also. -- ___ Python tracker ___ ___ Python-bu

[issue39635] One paragraph of the doc is not translated in French

2020-02-18 Thread Julien Palard
Julien Palard added the comment: This has been resolved in https://github.com/python/python-docs-fr/pull/1153 I bet Frédéric is the author so thank you for the PR. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ P

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Guido van Rossum
Guido van Rossum added the comment: There's no __total__ argument, but there is a __total__ attribute. There are also (new in 3.9) __required_keys__ and __total_keys__ attributes. Are you interested in submitting a PR with the needed doc changes? -- _

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Ananthakrishnan
Ananthakrishnan added the comment: yes,I'm interested. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue39572] [typing] TypedDict's 'total' argument is undocumented

2020-02-18 Thread Ananthakrishnan
Change by Ananthakrishnan : -- keywords: +patch pull_requests: +17935 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/18554 ___ Python tracker _

[issue39679] functools: singledispatchmethod doesn't work with classmethod

2020-02-18 Thread Viktor Roytman
New submission from Viktor Roytman : I couldn't get the example given for the interaction between @singledispatchmethod and @classmethod to work https://docs.python.org/3/library/functools.html?highlight=singledispatch#functools.singledispatchmethod from functools import singledispatchmet

[issue34822] Simplify AST for slices

2020-02-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: No, this PR does not change the Python syntax. It only changes the AST representation. -- ___ Python tracker ___ _

[issue39662] Characters are garbled when displaying Byte data

2020-02-18 Thread Eric V. Smith
Eric V. Smith added the comment: I'm going to close this. But if you have additional information that points to this being a bug in python, we can re-open it. -- resolution: -> not a bug stage: -> resolved status: pending -> closed ___ Python tra

[issue39555] test_distutils fails for Windows debug build

2020-02-18 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset d77e77116fa7a9fc85be1d9f417c7e9e33fe1296 by Miss Islington (bot) in branch '3.8': bpo-39555: Fix distutils test to handle _d suffix on Windows debug build (GH-18357) (GH-18548) https://github.com/python/cpython/commit/d77e77116fa7a9fc85be1d9f417

[issue9056] Adding additional level of bookmarks and section numbers in python pdf documents.

2020-02-18 Thread Julien Palard
Julien Palard added the comment: Merged Cheryl's patch (thanks Cheryl!). pengyu.ut if you want to test it you'll be able to see generated PDF in a maximum of 24h from now on [1]. Don't hesitate to ask if you need them for 3.8 we can backport it. [1]: https://docs.python.org/dev/ --

[issue28859] os.path.ismount sometimes raises FileNotFoundError on Windows

2020-02-18 Thread Steve Dower
Steve Dower added the comment: > I am going to think maybe it was the "os.path.ismount" command that is > causing the issue. Does the file exist? If the file does not exist, it is definitely not a mount point. So the function should return False instead of raising an error. --

[issue39603] [security] http.client: HTTP Header Injection in the HTTP method

2020-02-18 Thread Maor Kleinberger
Maor Kleinberger added the comment: Hey, it's been a week since the last activity here... Amir, if you are not working on it I'd be glad to work on it as well :) -- nosy: +kmaork ___ Python tracker _

[issue38691] importlib: PYTHONCASEOK should be ignored when using python3 -E

2020-02-18 Thread Ido Michael
Ido Michael added the comment: Yes I saw those in the morning, thanks for patching it up. I will debug this over the weekend and will update. -- ___ Python tracker ___ __

[issue39680] datetime.astimezone() method does not handle invalid local times as required by PEP 495

2020-02-18 Thread Alexander Belopolsky
New submission from Alexander Belopolsky : Let g be a an invalid time in New York spring-forward gap: >>> g = datetime(2020, 3, 8, 2, 30) According to PEP 495, conversion of such instance to UTC should return a value that corresponds to a valid local time greater than g, but >>> print(g.asti

[issue39681] pickle.load expects an object that implements readinto

2020-02-18 Thread Nathan Goldbaum
New submission from Nathan Goldbaum : As of https://github.com/python/cpython/pull/7076, it looks like at least the C implementation of pickle.load expects the file argument to implement readinto: https://github.com/python/cpython/blob/ffd9753a944916ced659b2c77aebe66a6c9fbab5/Modules/_pickle.c

[issue39681] pickle.load expects an object that implements readinto

2020-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue39670] 2to3 fix_apply tries to fix user-defined apply function calls

2020-02-18 Thread ilya
ilya added the comment: > apply was a builtin in Python 2 and not sure 2to3 can differentiate between > user defined functions that shadow builtins. > https://docs.python.org/3.8/library/2to3.html#2to3fixer-apply . > Removes usage of apply(). For example apply(function, *args, **kwargs) is

[issue39682] pathlib.Path objects can be used as context managers

2020-02-18 Thread Barney Gale
New submission from Barney Gale : `pathlib.Path` objects can be used as context managers, but this functionality is undocumented and makes little sense. Example: >>> import pathlib >>> root = pathlib.Path("/") >>> with root: ... print(1) ... 1 >>> with root: ... print(2) ... Tracebac

[issue39683] 2to3 fix_exitfunc suggests duplicated import of atexit module

2020-02-18 Thread ilya
New submission from ilya : Consider the following code: import sys def foo(): print(1) def bar(): print(2) if input("case: ") == 1: sys.exitfunc = foo else: sys.exitfunc = bar 2to3 -f exitfunc suggests to fix it as follows: --- a.py(original) +++ a.py(refact

  1   2   >