[issue39776] Crash in decimal module in heavy-multithreaded scenario

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: New changeset 5a92f42d8723ee865be80f028d402204649da15d by Stefan Krah in branch '3.8': bpo-39776: Lock ++interp->tstate_next_unique_id. (GH-18746) (#18746) (#18752) https://github.com/python/cpython/commit/5a92f42d8723ee865be80f028d402204649da15d --

[issue39776] Crash in decimal module in heavy-multithreaded scenario

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: New changeset 852aee69f49c654a03ad1f64d90a78ba8848e2c6 by Stefan Krah in branch '3.7': bpo-39776: Lock ++interp->tstate_next_unique_id (GH-18746) https://github.com/python/cpython/commit/852aee69f49c654a03ad1f64d90a78ba8848e2c6 -- ___

[issue39834] + vs. % operator precedence not correct

2020-03-03 Thread E
New submission from E : + has operator precedence over % in python: https://docs.python.org/3/reference/expressions.html However: > i=5 > i+5 % 10 10 > 10 % 10 0 > (i+5) % 10 0 Thus, for + to take precedence over %, parentheses need to be used. -- components: Interpreter Core messages

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is not so easy for 3.7. -- resolution: fixed -> stage: resolved -> status: closed -> open ___ Python tracker ___ _

[issue39834] + vs. % operator precedence not correct

2020-03-03 Thread E
E added the comment: Actually, the operator precedence is read upside down: https://docs.python.org/3/reference/expressions.html Thus, % has operator precedence and this might be causing the incorrect values. -- ___ Python tracker

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +18119 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18764 ___ Python tracker ___

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +18120 pull_request: https://github.com/python/cpython/pull/18765 ___ Python tracker ___

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Change by Stefan Krah : -- title: Crash in decimal module in heavy-multithreaded scenario -> PyContextVar_Get(): crash due to race condition in updating tstate->id ___ Python tracker

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Change by Stefan Krah : -- assignee: -> skrah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue35912] _testembed.c fails to compile when using --with-cxx-main in the configure step

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Duplicate of bpo-39697. -- nosy: +vstinner resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Failed to build with --with-cxx-main=g++-9.2.0 ___ Python tracker

[issue39697] Failed to build with --with-cxx-main=g++-9.2.0

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: I marked bpo-35912 as a duplicate of this issue (which has a longer history). -- ___ Python tracker ___ _

[issue30988] Exception parsing invalid email address headers starting or ending with dot

2020-03-03 Thread Steven Hilton
Change by Steven Hilton : -- nosy: +Steven Hilton nosy_count: 5.0 -> 6.0 pull_requests: +18121 pull_request: https://github.com/python/cpython/pull/18687 ___ Python tracker ___

[issue39778] collections.OrderedDict and weakref.ref raises "refcount is too small" assertion

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: It seems like OrderedDict was the only type which visited weak references: $ scm.py grep 'VISIT.*weak' master: Grep 'VISIT.*weak' -- <4284 filenames> == Objects/odictobject.c:1457:Py_VISIT(od->od_weakreflist);

[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: > Thankfully we don't need universal newlines, but no matter if we need them, > old versions of Samba will fail to build without a fix-up patch. io.open() is available since Python 2.6 and handles different kinds of newlines transparently. Example: $ python

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: Since many duplicate tstate ids are generated in the test case before the crash happens, I guess a set of tstates with the same id silently uses the cached context of the "winner" tstate. This can lead to incorrect results without noticing. -- priority:

[issue28577] ipaddress.ip_network(...).hosts() returns nothing for an IPv4 /32

2020-03-03 Thread Pete Wicken
Pete Wicken added the comment: Ok it was bugging me that they were different, so I also added the same logic for IPv6Networks. -- ___ Python tracker ___ _

[issue39834] + vs. % operator precedence not correct

2020-03-03 Thread E
Change by E : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bugs-list ma

[issue39802] Ensure {get, set}_escdelay and {get, set}_tabsize only implemented when the extensions are activated

2020-03-03 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue12915] Add inspect.locate and inspect.resolve

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset e0acec15412203359d59db33e447698ee51e07fc by Michael Felt in branch 'master': bpo-12915: Skip test_pkgutil.test_name_resolution() non-encodable filenames (GH-18720) https://github.com/python/cpython/commit/e0acec15412203359d59db33e447698ee51e07f

[issue12915] Add inspect.locate and inspect.resolve

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: I understand that all known issues are now fixed, so I close the issue. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker __

[issue39599] ABI breakage between Python 3.7.4 and 3.7.5: change in PyGC_Head structure

2020-03-03 Thread Julien Danjou
Julien Danjou added the comment: The problem is that AFAIK the wheel system does not allow you to specify and provide a wheel for each minor Python version. For references, the code that segfaults is: https://github.com/DataDog/dd-trace-py/blob/master/ddtrace/profile/collector/stack.pyx ---

[issue39599] ABI breakage between Python 3.7.4 and 3.7.5: change in PyGC_Head structure

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: > The problem is that AFAIK the wheel system does not allow you to specify and > provide a wheel for each minor Python version. The alternative is to identify which part of your code depends on PyGC_Head size, and handle the different sizes there. -

[issue39809] argparse: add max_text_width parameter to ArgumentParser

2020-03-03 Thread Luca
Luca added the comment: Of course I still think there should be an easier way to do this though. -- ___ Python tracker ___ ___ Pyth

[issue39599] ABI breakage between Python 3.7.4 and 3.7.5: change in PyGC_Head structure

2020-03-03 Thread Julien Danjou
Julien Danjou added the comment: Right, though if you read the code I linked, the PyGC_Head size is never used. AFAICS the Cython code does not access it either (at least not directly). The code segfaults at import time. I'm not even sure it's possible and the problem isn't in something in CP

[issue39467] Allow to deprecate CLI arguments in argparse

2020-03-03 Thread hervé
hervé added the comment: hello, First thanks everyone to took time to discute about this proposal. This topic is now opened since ~1 months so I don't think we will more feedback about this, then I will address all your comments in my changes soon to match an implementation more consensually

[issue26460] datetime.strptime without a year fails on Feb 29

2020-03-03 Thread Gerard C Weatherby
Gerard C Weatherby added the comment: Yes, code that has been working for my organization the past two years just broke this weekend. Meaning depends on context. The straightforward solution is that if no year is specified, the return value should default to the current year. -- nos

[issue39820] Bracketed paste mode for REPL

2020-03-03 Thread Mark Dickinson
Mark Dickinson added the comment: See also the discussion in #38747 (also opened by Marco), which was closed as rejected. This issue is close to a duplicate of that one. -- ___ Python tracker __

[issue39704] Disable code coverage

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Ernest updated the organization configuration to: --- comment: off coverage: status: changes: off project: off patch: off --- which gives: { "comment": false, "coverage": { "status": { "changes": false,

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

2020-03-03 Thread Barney Gale
Barney Gale added the comment: Can I ask what sort of backwards-compatibility guarantees Python provides for these cases? In the case of using a Path object as a context manager, I think we can say: - It's easy to do - there's no need to call any underscore-prefixed methods for example - It

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

2020-03-03 Thread Barney Gale
Barney Gale added the comment: Also, thank you Antoine for your explanation :-) -- ___ Python tracker ___ ___ Python-bugs-list mail

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-03-03 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +18122 pull_request: https://github.com/python/cpython/pull/18766 ___ Python tracker ___ ___

[issue38960] DTrace FreeBSD build fix

2020-03-03 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +18123 pull_request: https://github.com/python/cpython/pull/18766 ___ Python tracker ___ ___

[issue38960] DTrace FreeBSD build fix

2020-03-03 Thread Petr Viktorin
Petr Viktorin added the comment: The fix introduced a regression, see bpo-39761 -- ___ Python tracker ___ ___ Python-bugs-list mail

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

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Another candidate is to revert the ignored "U" mode in open(): commit e471e72977c83664f13d041c78549140c86c92de of bpo-37330. Removing "U" mode of open() broke 11 packages in Fedora: * aubio * openvswitch * python-SALib * python-altgraph * python-apsw * pytho

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Change by Stefan Krah : Added file: https://bugs.python.org/file48945/pydecimal_cases.zip ___ Python tracker ___ ___ Python-bugs-list mailin

[issue39835] Implement PyObject_CopyToObject

2020-03-03 Thread Joannah Nanjekye
New submission from Joannah Nanjekye : I suggest implementing a C-API for copying data into a buffer exported by an obj. i.e int PyObject_CopyToObject(PyObject *obj, void *buf, Py_ssize_t len, char fortran) as was intended in PEP 3118. The documentation there says

[issue39836] Implement PyObject_GetMemoryView

2020-03-03 Thread Joannah Nanjekye
New submission from Joannah Nanjekye : We have a memory-view object represented with the following structure: typedef struct { PyObject_VAR_HEAD _PyManagedBufferObject *mbuf; /* managed buffer */ Py_hash_t hash; /* hash value for read-only views */ int flags;

[issue39836] Implement PyObject_GetMemoryView

2020-03-03 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +skrah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

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

2020-03-03 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +18124 pull_request: https://github.com/python/cpython/pull/18767 ___ Python tracker ___ __

[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-03-03 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +18125 pull_request: https://github.com/python/cpython/pull/18767 ___ Python tracker ___ __

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: Also _pydecimal was affected. This is a modified version of Evgeny's test case: from _pydecimal import * from time import sleep from random import randint import sys sys.setswitchinterval(0.001) def usleep(x): sleep(x/100.0) class Test: def

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: Setting to release blocker, but please move to deferred again if a release is almost finished. -- nosy: +lukasz.langa, ned.deily priority: deferred blocker -> release blocker ___ Python tracker

[issue39794] Add --without-decimal-contextvar option to use just threads in decimal

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: #39776 is fixed, but _pydecimal was also affected, see msg363266. -- ___ Python tracker ___ ___ Pyth

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Change by Stefan Krah : -- stage: patch review -> resolved ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Change by Stefan Krah : -- resolution: -> fixed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue38870] Expose ast.unparse in the ast module

2020-03-03 Thread Batuhan Taskaya
Change by Batuhan Taskaya : -- pull_requests: +18126 pull_request: https://github.com/python/cpython/pull/18768 ___ Python tracker ___ _

[issue38826] Regular Expression Denial of Service in urllib.request.AbstractBasicAuthHandler

2020-03-03 Thread Matthew Barnett
Matthew Barnett added the comment: A smaller change to the regex would be to replace the "(?:.*,)*" with "(?:[^,]*,)*". I'd also suggest using a raw string instead: rx = re.compile(r'''(?:[^,]*,)*[ \t]*([^ \t]+)[ \t]+realm=(["']?)([^"']*)\2''', re.I) -- nosy: +mrabarnett _

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Ned Deily
Ned Deily added the comment: Thanks for the heads-up and the fix, Stefan. The fix for 3.7.x was merged before the 3.7.7rc1 cutoff (by a few hours!) and the next 3.8.x release cutoff is planned for April and 3.9.0a5 is later in March, so, if you are not planning to merge any other changes for

[issue39773] Export symbols for vectorcall

2020-03-03 Thread Petr Viktorin
Petr Viktorin added the comment: Yes. Can you use PyObject_Call instead (or one of the non-Vectorcall variants listed in https://docs.python.org/3.9/c-api/call.html#object-calling-api ) Vectorcall is mainly a speed optimization over PyObject_Call. We want to allow the C compiler to inline Py

[issue39389] gzip metadata fails to reflect compresslevel

2020-03-03 Thread Ned Deily
Ned Deily added the comment: Ping. The 3.7.x backport (PR 18101) for this issue is still open and neither needs to be fixed or closed. -- nosy: +ned.deily resolution: fixed -> stage: resolved -> backport needed status: closed -> open ___ Python tr

[issue39389] gzip metadata fails to reflect compresslevel

2020-03-03 Thread Ned Deily
Ned Deily added the comment: "either" -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue39530] Documentation about comparisons between numeric types is misleading

2020-03-03 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +18127 pull_request: https://github.com/python/cpython/pull/18737 ___ Python tracker _

[issue39776] PyContextVar_Get(): crash due to race condition in updating tstate->id

2020-03-03 Thread Stefan Krah
Stefan Krah added the comment: Thanks Ned, closing then. Evgeny, please reopen if you see it again (I ran the tests for about 20 min, way above the usual reproduction time of 1 min). Thanks for the very instructive test case! -- status: open -> closed __

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread Petr Viktorin
Petr Viktorin added the comment: IMO: - The "native" format should use native _Bool, and we should only test unpacking 0 and 1 - The "standard" format should use portable char semantics: continue to treat any non-zero value as true - The docs should grow a warning that for the native format

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

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 2aa694dd55202eb6d062fdf49c07cf95f8520f2d by Victor Stinner in branch '3.8': bpo-39674: Update collections ABC deprecation doc (GH-18748) https://github.com/python/cpython/commit/2aa694dd55202eb6d062fdf49c07cf95f8520f2d --

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

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

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

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 91fe4142642286b65c166f7b6e27de16f42b1286 by Victor Stinner in branch 'master': bpo-39674: Update collections ABC deprecation doc (GH-18747) https://github.com/python/cpython/commit/91fe4142642286b65c166f7b6e27de16f42b1286 -- _

[issue35293] make doctest (Sphinx) emits a lot of warnings

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: > Relevant docutils upstream issue : > https://sourceforge.net/p/docutils/bugs/373/ . Also the SyntaxWarning was > changed to DeprecationWarning with msg349335. SyntaxWarning warnings have been fixed in docutils 0.16. -- ___

[issue39837] Remove Azure Pipelines from GitHub PRs

2020-03-03 Thread STINNER Victor
New submission from STINNER Victor : The Azure Pipelines jobs have been reimplemented as GitHub actions which are better integrated with GitHub: * Docs / Docs (pull_request) * Tests / Windows (x64) (pull_request) * Tests / macOS (pull_request) * Tests / Ubuntu (pull_request) * etc. Azure Pipe

[issue39837] Remove Azure Pipelines from GitHub PRs

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

[issue26460] datetime.strptime without a year fails on Feb 29

2020-03-03 Thread Nick Moore
Nick Moore added the comment: It's kind of funny that there's already consideration of this in _strptime._strptime(), which returns a tuple used by datetime.datetime.strptime() to construct the new datetime. Search for `leap_year_fix`. I think the concern though is if we changed the default

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset ae75a294352e9b9487f5dc8e88f068e7e6974dc2 by Serhiy Storchaka in branch 'master': bpo-39831: Remove outdated comment. (GH-18764) https://github.com/python/cpython/commit/ae75a294352e9b9487f5dc8e88f068e7e6974dc2 -- ___

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 2.0 -> 3.0 pull_requests: +18129 pull_request: https://github.com/python/cpython/pull/18770 ___ Python tracker _

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread miss-islington
miss-islington added the comment: New changeset 57fb29219f09ee705065e39ad488334a9c7e3d71 by Miss Islington (bot) in branch '3.8': bpo-39831: Remove outdated comment. (GH-18764) https://github.com/python/cpython/commit/57fb29219f09ee705065e39ad488334a9c7e3d71 --

[issue39837] Remove Azure Pipelines from GitHub PRs

2020-03-03 Thread Brett Cannon
Change by Brett Cannon : -- nosy: +steve.dower ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue39831] Reference leak in PyErr_WarnEx()

2020-03-03 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > It is not so easy for 3.7. Apologies Serhiy, I thought it was more straightforward and just wanted to stop the mail storm that the refleak buildbots were causing :( -- ___ Python tracker

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Charalampos Stratakis also reported this issue to python-dev: "Unpacking native bools in the struct module: Is Python relying on undefined behavior?" https://mail.python.org/archives/list/python-...@python.org/thread/O742VLCYX2AE3RWQK5RBQ3BGUOHESLF5/

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

2020-03-03 Thread Brett Cannon
Brett Cannon added the comment: > Can I ask what sort of backwards-compatibility guarantees Python provides for > these cases? A deprecation warning for two releases (i.e. two years). Then it can be removed. So if people want to move forward with removing this then a DeprecationWarning woul

[issue39838] Possible unnecessary redifinition of _POSIX_C_SOURCE

2020-03-03 Thread Joannah Nanjekye
New submission from Joannah Nanjekye : Please note the compile warning: ./pyconfig.h:1590: warning: "_POSIX_C_SOURCE" redefined #define _POSIX_C_SOURCE 200809L In file included from /usr/include/x86_64-linux-gnu/bits/libc-header-start.h:33, from /usr/include/string.h:26,

[issue39839] Non-working error handler when creating a task with assigning a variable

2020-03-03 Thread Рустам Шах
New submission from Рустам Шах : #This example does not work due to assigning the task to a variable import asyncio import logging def handle_exception(loop, context): msg = context.get("exception", context["message"]) logging.error("Caught exception: %s", msg) async def test(): a

[issue1294959] Problems with /usr/lib64 builds.

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: > Why "sys.python_libdir"? Isn't that too public? A lot of similar > path-related info is in sysconfig; why shouldn't it be there? I replied in a previous comment: "Matthias Klose asked to not add another sys attribute, but Jan Matějek explained that the op

[issue39837] Remove Azure Pipelines from GitHub PRs

2020-03-03 Thread Steve Dower
Steve Dower added the comment: Deleting the files is not the right first step. First, it needs to be changed to a non-required check. Then, I can use the web UI to disable it starting. *Then*, we can remove *some* of the files in the directory. Others are used for the official release, and

[issue39839] Non-working error handler when creating a task with assigning a variable

2020-03-03 Thread Rustam Shakh
Rustam Shakh added the comment: # This line doesn`t work task = loop.create_task(test()) # This line works loop.create_task(test()) -- ___ Python tracker ___

[issue39837] Remove Azure Pipelines from GitHub PRs

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: > PR 18769 should *not* be merged. Ok, I closed it. > First, it needs to be changed to a non-required check. Who is allowed to do that? -- ___ Python tracker

[issue39837] Remove Azure Pipelines from GitHub PRs

2020-03-03 Thread Steve Dower
Steve Dower added the comment: > Who is allowed to do that? Brett did it the first time. I'm having too much trouble with GitHub right now to find the current admins. -- nosy: +brett.cannon ___ Python tracker

[issue35712] Make NotImplemented unusable in boolean context

2020-03-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 469325c30e147680543b2f5118b83fd95055a499 by MojoVampire in branch 'master': bpo-35712: Make using NotImplemented in a boolean context issue a deprecation warning (GH-13195) https://github.com/python/cpython/commit/469325c30e147680543b2f5118b8

[issue35712] Make NotImplemented unusable in boolean context

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

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread Gregory P. Smith
Gregory P. Smith added the comment: fwiw oss-fuzz also finds this on struct (via ubsan) https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=20949 struct.unpack('?', ' ') -- ___ Python tracker ___

[issue39820] Bracketed paste mode for REPL

2020-03-03 Thread Marco Sulla
Marco Sulla added the comment: Please read the message of Terry J. Reed: https://bugs.python.org/issue38747#msg356345 I quote the relevant part below > Skipping the rest of your post, I will just restate why I closed this > issue. > > 1. It introduces too many features not directly related

[issue31122] SSLContext.wrap_socket() throws OSError with errno == 0

2020-03-03 Thread Shevis Johnson
Change by Shevis Johnson : -- nosy: +shevis ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyth

[issue39697] Failed to build with --with-cxx-main=g++-9.2.0

2020-03-03 Thread Marco Sulla
Marco Sulla added the comment: I agree with Pablo Galindo Salgado: https://bugs.python.org/issue35912#msg334942 The "quick and dirty" solution is to change MAINCC to CC, for _testembed.c AND python.c (g++ fails with both). After that, _testembed.c and python.c should be changed so they can b

[issue39840] FileNotFoundError et al show b-prefix on filepaths if passed as bytes

2020-03-03 Thread Augie Fackler
New submission from Augie Fackler : I'm not really sure if this is a bug per se, so please feel encouraged to close as WAI if you like, but: >>> open(b'foo', 'rb') Traceback (most recent call last): File "", line 1, in FileNotFoundError: [Errno 2] No such file or directory: b'foo' Seems a

[issue33433] ipaddress is_private misleading for IPv4 mapped IPv6 addresses

2020-03-03 Thread Pete Wicken
Change by Pete Wicken : -- nosy: +Wicken ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

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

2020-03-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: Note you could simply remove the "closed" flag and the context manager live. That way, you don't have to deprecate anything. -- ___ Python tracker _

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread Petr Viktorin
Petr Viktorin added the comment: Viewing the oss-fuzz bug requires login. Is there any interesting public info in it? -- ___ Python tracker ___ __

[issue39841] "as" variable in except block deletes local variables with same name

2020-03-03 Thread Alan Robertson
New submission from Alan Robertson : When an exception "as" variable occurs, it deletes local variables with the same name. This is certainly surprising, and doesn't appear to be a documented behavior (but maybe I don't know where to look). The word "bug" comes to mind. The following few lin

[issue39820] Bracketed paste mode for REPL

2020-03-03 Thread Eric V. Smith
Eric V. Smith added the comment: I suggest closing this issue. If the REPL is going to be improved, it won't be done one-feature-at-a-time on the bug tracker. It will need to have a holistic design that takes into account desired features and the architecture of the systems that it needs to

[issue39841] "as" variable in except block deletes local variables with same name

2020-03-03 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi Alan, this is documented at https://docs.python.org/3/reference/compound_stmts.html#the-try-statement: > When an exception has been assigned using as target, it is cleared at the end > of the except clause. This is as if > > except E as N: >foo > > was

[issue39841] "as" variable in except block deletes local variables with same name

2020-03-03 Thread Eric V. Smith
Eric V. Smith added the comment: Yes, this is a known issue. See https://docs.python.org/3/reference/compound_stmts.html#the-try-statement, in particular the sentence "When an exception has been assigned using as target, it is cleared at the end of the except clause" and the following text.

[issue39639] Remove Suite node from AST

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Jeff Allen: thanks for the useful feedback on how it's used in Jython! -- nosy: +vstinner ___ Python tracker ___

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread Ammar Askar
Ammar Askar added the comment: Nothing too interesting, here's the stack trace: /src/cpython3/Modules/_struct.c:487:28: runtime error: load of value 32, which is not a valid value for type '_Bool' #0 0x7f50371a7670 in nu_bool cpython3/Modules/_struct.c:487:28 #1 0x7f503719ea3d in s_un

[issue39020] [AIX] module _curses fails to build since ESCDELAY has been added

2020-03-03 Thread Michael Felt
Michael Felt added the comment: This issue was resolved by issue39802. Marking as fixed, and closed. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue39840] FileNotFoundError et al show b-prefix on filepaths if passed as bytes

2020-03-03 Thread Eric V. Smith
Eric V. Smith added the comment: That behavior is consistent with other exceptions. It's a helpful piece of information if you were to see it in a traceback, without any other context. So this is by design. -- nosy: +eric.smith resolution: -> not a bug stage: -> resolved status: op

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

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: New changeset 116fd4af7370706d0d99ac7c70541ef965672d4e by Victor Stinner in branch 'master': bpo-39674: Suggest to test with DeprecationWarning (GH-18552) https://github.com/python/cpython/commit/116fd4af7370706d0d99ac7c70541ef965672d4e --

[issue39841] "as" variable in except block deletes local variables with same name

2020-03-03 Thread Alan Robertson
Alan Robertson added the comment: Thanks for your kind explanation. I may even vaguely remember seeing this sometime in the past. Thanks much for your time! -- ___ Python tracker ___

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-03-03 Thread STINNER Victor
STINNER Victor added the comment: Using memcpy() to write a value different than 0 or 1 into a _Bool is clearly an undefined behavior. Example with clang UBSan. bool.c: --- #include #include int main() { char ch = 42; _Bool x; memcpy(&x, &ch, 1); return x == true; } --- $

[issue39702] PEP 614: Relaxing Grammar Restrictions On Decorators

2020-03-03 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset be501ca2419a91546dea85ef4f36945545458589 by Brandt Bucher in branch 'master': bpo-39702: Relax grammar restrictions on decorators (PEP 614) (GH-18570) https://github.com/python/cpython/commit/be501ca2419a91546dea85ef4f36945545458589

[issue39702] PEP 614: Relaxing Grammar Restrictions On Decorators

2020-03-03 Thread Guido van Rossum
Guido van Rossum added the comment: I'm guessing there's some doc update that needs to happen now the code has landed. -- ___ Python tracker ___ _

[issue37953] Fix ForwardRef equality checks

2020-03-03 Thread Ned Deily
Ned Deily added the comment: New changeset 3eff46fc7d2e3c80c4dedba4177782f1fc8ad89b by Ryan Rowe in branch '3.7': bpo-37953: Fix ForwardRef hash and equality checks (GH-15400) (GH-18751) https://github.com/python/cpython/commit/3eff46fc7d2e3c80c4dedba4177782f1fc8ad89b -- nosy: +ned.

[issue37953] Fix ForwardRef equality checks

2020-03-03 Thread Ned Deily
Change by Ned Deily : -- versions: +Python 3.7, Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

  1   2   >