[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: New changeset dab8423d220243efabbbcafafc12d90145539b50 by Victor Stinner in branch 'master': bpo-39984: Add PyInterpreterState.ceval (GH-19047) https://github.com/python/cpython/commit/dab8423d220243efabbbcafafc12d90145539b50 -- ___

[issue31895] Native hijri calendar support

2020-03-17 Thread Terry J. Reedy
Change by Terry J. Reedy : -- title: How to implement api in python website -> Native hijri calendar support ___ Python tracker ___

[issue25024] Allow passing "delete=False" to TemporaryDirectory

2020-03-17 Thread Anthony Sottile
Anthony Sottile added the comment: oh! that's neat, yeah hadn't been following closely enough it seems, good to hear that the readonly thing is fixed! -- ___ Python tracker

[issue39511] [subinterpreters] Per-interpreter singletons (None, True, False, etc.)

2020-03-17 Thread Larry Hastings
Larry Hastings added the comment: > The problem with having a single immortal `None`, is that it will > cause data cache thrashing as two different CPUs modify the > refcount on the shared `None` object. That's a very reasonable theory. Personally, I find modern CPU architecture bewildering a

[issue39996] test_multiprocessing_fork hangs on AMD64 FreeBSD Shared 3.x

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: On FreeBSD CURRENT worker, I reproduced the issue: "test_enter (test.test_multiprocessing_fork.WithProcessesTestPool) ..." hangs. Sadly I unblocked a process when I did a mistake in gdb while getting Python tracebacks. Process 90127: 90127 4 S+ 0:00

[issue39511] [subinterpreters] Per-interpreter singletons (None, True, False, etc.)

2020-03-17 Thread Mark Shannon
Mark Shannon added the comment: Having two CPUs write to the same cache line is a well known performance problem. There's nothing special about CPython here. The proper name for it seems to be "cache line ping-pong", but a search for "false sharing" might be more informative. -- __

[issue39689] struct and memoryview tests rely on undefined behavior (as revealed by clang 9)

2020-03-17 Thread Ronald Oussoren
Ronald Oussoren added the comment: Note that the implementation of np_bool in _struct.c [1] is incorrect because this is supposed to access a boolean of a standard size, but uses _Bool. The size of _Bool is not prescribed, and IIRC sizeof(_Bool) was 4 with the compilers used for macOS/PPC.

[issue39717] Fix exception causes in tarfile module

2020-03-17 Thread Ethan Furman
Ethan Furman added the comment: Yes. Some of the changes are good, others should be `from None`. The `from None` raises should include the ones where the new exception includes the text of the caught exception. What is needed is text captured from the proposed changes to see if the previou

[issue39997] "is" operator doesn't work on method returned from method descriptor

2020-03-17 Thread Yurii
New submission from Yurii : I reproduced this in python 3.8 and python 3.6. The last line displays the bug itself, all other lines do the setup and pretty much explain WHY I think that is the bug. class Class: def method(self): ... instance = Class() # expected: ids match assert id(Clas

[issue39717] Fix exception causes in tarfile module

2020-03-17 Thread Ram Rachum
Ram Rachum added the comment: I understand. I've closed my PR and I'll let someone else implement this ticket-- I don't want to be the reason that someone didn't get the information they wanted in an error report. Thanks anyway for your time. -- _

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

2020-03-17 Thread Lahfa Samy
Lahfa Samy added the comment: Nishant Misra are you still working on this issue, if not could I take it from now on, as my first issue and contribution to Python? -- nosy: +AkechiShiro ___ Python tracker __

[issue39997] "is" operator doesn't work on method returned from method descriptor

2020-03-17 Thread Christian Heimes
Christian Heimes added the comment: This is not a bug. The "is" operator works as expected. A method descriptor returns a new wrapper object on each access. CPython uses free lists to "recycle" memory locations to increase performance. id(Class.method.__get__(None, Class)) == id(Class.method

[issue39997] "is" operator doesn't work on method returned from method descriptor

2020-03-17 Thread Yurii
Yurii added the comment: @christian.heimes thanks for the feedback -- resolution: not a bug -> status: closed -> open ___ Python tracker ___ _

[issue39997] "is" operator doesn't work on method returned from method descriptor

2020-03-17 Thread Yurii
Change by Yurii : -- resolution: -> not a bug status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsub

[issue39979] Cannot tune scrypt with large enough parameters

2020-03-17 Thread Christian Heimes
Christian Heimes added the comment: Your parameter selection requires about 64 MB of memory (n * 2 * r * 64). As documented maxmem=0 defaults to 32 MB of maximum memory in OpenSSL 1.1.x. OpenSSL needs a bit of internal memory for book keeping and other stuff, so you need maxmem=65*1024*1024 f

[issue39988] Remove AugLoad and AugStore expression context from AST

2020-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 6b97598fb66a08d0f36e4d73bffea5c1b17740d4 by Serhiy Storchaka in branch 'master': bpo-39988: Remove ast.AugLoad and ast.AugStore node classes. (GH-19038) https://github.com/python/cpython/commit/6b97598fb66a08d0f36e4d73bffea5c1b17740d4 --

[issue39959] (Possible) bug on multiprocessing.shared_memory

2020-03-17 Thread Diogo Flores
Diogo Flores added the comment: Follow up - tested on Linux (The first solution). The solution presented below will fix the problem with the caveat that the base process (the one that creates the shared-memory obj) must outlive any process that use the shared-memory. The rationale is that un

[issue39719] tempfile.SpooledTemporaryFile still has softspace property

2020-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset d469d666b874ae746ca9a17bbfc9dbbf6fb2d6bc by Shantanu in branch 'master': bpo-39719: Remove softspace from tempfile.SpooledTemporaryFile (GH-18599) https://github.com/python/cpython/commit/d469d666b874ae746ca9a17bbfc9dbbf6fb2d6bc -- n

[issue38373] List overallocation strategy

2020-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 2fe815edd6778fb9deef8f8044848647659c2eb8 by Serhiy Storchaka in branch 'master': bpo-38373: Change list overallocating strategy. (GH-18952) https://github.com/python/cpython/commit/2fe815edd6778fb9deef8f8044848647659c2eb8 -- ___

[issue38373] List overallocation strategy

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

[issue39719] tempfile.SpooledTemporaryFile still has softspace property

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

[issue39988] Remove AugLoad and AugStore expression context from AST

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

[issue39879] Update language reference to specify that dict is insertion-ordered.

2020-03-17 Thread Zachary Ware
Zachary Ware added the comment: Hi Furkan. Please note that Lahfa Samy had already submitted a PR for this issue after "claiming" it with a note here; proper "netiquette" suggests not jumping in with your own PR in such a situation. Fortuitously though, it looks like the both of you have ac

[issue39511] [subinterpreters] Per-interpreter singletons (None, True, False, etc.)

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: I expect that for objects which are not commonly modified by two interpreters "at the same time", it should be fine. But None, True, small integer singletons, latin-1 str single character singletons, etc. objects are likely to be frequently accessed and so c

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

2020-03-17 Thread Nishant Misra
Nishant Misra added the comment: Yes Lahfa Samy, you can take it up. I did not work on the issue. -- ___ Python tracker ___ ___ Pyt

[issue39998] [C API] Remove PyEval_AcquireLock() and PyEval_ReleaseLock() functions

2020-03-17 Thread STINNER Victor
New submission from STINNER Victor : The PyEval_AcquireLock() and PyEval_ReleaseLock() functions are misleading and deprecated since Python 3.2. bpo-10913 deprecated them: commit 5ace8e98da6401827f607292a066da05df3ec5c1 Author: Antoine Pitrou Date: Sat Jan 15 13:11:48 2011 + Issue

[issue39998] [C API] Remove PyEval_AcquireLock() and PyEval_ReleaseLock() functions

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

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

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

[issue39998] [C API] Remove PyEval_AcquireLock() and PyEval_ReleaseLock() functions

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: What's New In Python 3.2 says: "The misleading functions PyEval_AcquireLock() and PyEval_ReleaseLock() have been officially deprecated. The thread-state aware APIs (such as PyEval_SaveThread() and PyEval_RestoreThread()) should be used instead." https://docs.

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

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

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

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

[issue38576] CVE-2019-18348: CRLF injection via the host part of the url passed to urlopen()

2020-03-17 Thread Matej Cepl
Change by Matej Cepl : -- pull_requests: +18403 pull_request: https://github.com/python/cpython/pull/19052 ___ Python tracker ___ __

[issue37127] Handling pending calls during runtime finalization may cause problems.

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: In the master branch of Python, trip_signal() calls _PyEval_AddPendingCall(tstate) and tstate is get using _PyRuntimeState_GetThreadState(runtime). trip_signal() can be called while the GIL is not held: tstate is NULL in this case. For example, it's the cas

[issue37127] Handling pending calls during runtime finalization may cause problems.

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: > In bpo-33608 I moved the pending calls to per-interpreter state. We saw > failures (sometimes sporadic) on a few buildbots (e.g. FreeBSD) during > runtime finalization. However, nearly all of the buildbots were fine, so it > may be a question of architec

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: While trying to move pending to PyInterpreterState, I hit in issue in _PyEval_AddPendingCall(): signal.raise_signal() can call it with tstate=NULL. See https://bugs.python.org/issue37127#msg364489 -- ___ Python tr

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: New changeset d7fabc116269e4650a684eb04f9ecd84421aa247 by Victor Stinner in branch 'master': bpo-39984: Pass tstate to handle_signals() (GH-19050) https://github.com/python/cpython/commit/d7fabc116269e4650a684eb04f9ecd84421aa247 --

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: New changeset 23ef89db7ae46d160650263cc80479c2ed6693fb by Victor Stinner in branch 'master': bpo-39984: _PyThreadState_DeleteCurrent() takes tstate (GH-19051) https://github.com/python/cpython/commit/23ef89db7ae46d160650263cc80479c2ed6693fb --

[issue39879] Update language reference to specify that dict is insertion-ordered.

2020-03-17 Thread Lahfa Samy
Lahfa Samy added the comment: Hi Furkan, would you mind to combine your revised PR with mine so that we can do as suggested by Zachary? -- ___ Python tracker ___

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

2020-03-17 Thread Dong-hee Na
Change by Dong-hee Na : -- pull_requests: +18404 pull_request: https://github.com/python/cpython/pull/19053 ___ Python tracker ___ _

[issue39877] Daemon thread is crashing in PyEval_RestoreThread() while the main thread is exiting the process

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

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

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

[issue39984] Move some ceval fields from _PyRuntime.ceval to PyInterpreterState.ceval

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: New changeset 29356e03d4f8800b04f799efe7a10e3ce8b16f61 by Victor Stinner in branch 'master': bpo-39877: Fix take_gil() for daemon threads (GH-19054) https://github.com/python/cpython/commit/29356e03d4f8800b04f799efe7a10e3ce8b16f61 -- __

[issue39877] Daemon thread is crashing in PyEval_RestoreThread() while the main thread is exiting the process

2020-03-17 Thread STINNER Victor
STINNER Victor added the comment: New changeset 29356e03d4f8800b04f799efe7a10e3ce8b16f61 by Victor Stinner in branch 'master': bpo-39877: Fix take_gil() for daemon threads (GH-19054) https://github.com/python/cpython/commit/29356e03d4f8800b04f799efe7a10e3ce8b16f61 -- __

[issue39957] bpo39775 not fixed - inspect.Signature.parameters still dict/mappingproxy around dict

2020-03-17 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___ P

[issue39957] bpo39775 not fixed - inspect.Signature.parameters still dict/mappingproxy around dict

2020-03-17 Thread Inada Naoki
Inada Naoki added the comment: New changeset 611836a69a7a98bb106b4d315ed76a1e17266f4f by Jens Reidel in branch 'master': bpo-39957: Change Signature.parameters to OrderedDict (GH-18988) https://github.com/python/cpython/commit/611836a69a7a98bb106b4d315ed76a1e17266f4f -- ___

[issue39980] importlib.resources.path() may return incorrect path when using custom loader

2020-03-17 Thread Jason R. Coombs
Jason R. Coombs added the comment: I believe this issue was addressed in the latest importlib_resources. If so, that behavior is being ported to Python 3.9 in issue39791. Would you test with `importlib_resources` 1.1 or later and see if that suits your purposes? If so, please use `importlib_

[issue38576] CVE-2019-18348: CRLF injection via the host part of the url passed to urlopen()

2020-03-17 Thread Gregory P. Smith
Gregory P. Smith added the comment: marking as a 2.7 release blocker just to get benjamin's RM attention before the final 2.7. -- assignee: gregory.p.smith -> benjamin.peterson nosy: +benjamin.peterson priority: high -> release blocker stage: resolved -> patch review status: closed ->

[issue39974] A race condition with GIL releasing exists in stringlib_bytes_join

2020-03-17 Thread tzickel
tzickel added the comment: Regarding getting the buffer and releasing the GIL, if it's wrong, why not fix other places in the code that do it, like: https://github.com/python/cpython/blob/611836a69a7a98bb106b4d315ed76a1e17266f4f/Modules/posixmodule.c#L9619 The GIL is released, the syscall mi

[issue39689] struct and memoryview tests rely on undefined behavior (as revealed by clang 9)

2020-03-17 Thread Ronald Oussoren
Ronald Oussoren added the comment: Sigh... never mind, I misread the code. Please ignore msg364472 -- ___ Python tracker ___ ___ P

<    1   2