[issue40234] Disallow daemon threads in subinterpreters optionally.

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: Graham Dumpleton started a discussion about bpo-37266 on Twitter: https://twitter.com/GrahamDumpleton/status/1246374493267701760 https://twitter.com/GrahamDumpleton/status/1246373855532216320 I dislike discussion threads on Twitter. For an unknown reason, I

[issue40204] Docs build error with Sphinx 3.0 due to invalid C declaration

2020-04-09 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: I have filed an issue upstream and it's fixed. The release of 3.0.1 is planned in few days and could help for other branches. But it would be nice to see the version pinned to avoid these problems in future. Upstream report :

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: Er, to clarify: "PEP 442 had that effect" => "PEP 442 had the effect of making it resurrectable only once, but not more than that." -- ___ Python tracker

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: > [...] but I am not sure it makes sense to allow to mark an object as > finalized because that could mess with the GC algorithm. Actually, I would like the opposite, to mark it unfinalized to resurrect the object more than once. PEP 442 from a ways back

[issue40243] Unicode 3.2 numeric uses decimal_changed instead of numeric_changed

2020-04-09 Thread William Meehan
Change by William Meehan : -- components: Unicode nosy: ezio.melotti, vstinner, wmeehan priority: normal severity: normal status: open title: Unicode 3.2 numeric uses decimal_changed instead of numeric_changed type: behavior versions: Python 2.7, Python 3.5, Python 3.6, Python 3.7,

[issue40239] Add a function for merging sorted iterables

2020-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Tim, it is exactly what I need! I got this search result, but I rejected it because it looked obvious that the function from the heapq module cannot have any relation to this. :( I meant chain() instead of tee(), sorry. -- resolution:

[issue40234] Disallow daemon threads in subinterpreters optionally.

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: First of all, I know that mod_wsgi uses subinterpreters, but I didn't know that it uses daemon threads. When I hack Python to better isolate subinterpreters, I keep mod_wsgi in mind ;-) My commit 066e5b1a917ec2134e8997d2cadd815724314252 message says:

[issue40242] zmq mysql core dump

2020-04-09 Thread Eric V. Smith
Eric V. Smith added the comment: This looks like a problem in zmq, pyzmq, or mysql-connector-python, not in python itself. I'd suggest asking in a mysql-connector-python specific location for starters. You should also try to duplicate the problem without importing zmq, which doesn't seem

[issue40202] Misleading grammatically of ValueError Message?

2020-04-09 Thread Vedran Čačić
Vedran Čačić added the comment: > It says **too many** but I assign a few than the size of the list. am I the > one who wrong here? Yes. The same as here: > Should said something else because it received less values and expected > should say 3 and not 2, correct? You probably don't

[issue40232] PyOS_AfterFork_Child() should use _PyThread_at_fork_reinit()

2020-04-09 Thread Dong-hee Na
Change by Dong-hee Na : -- keywords: +patch pull_requests: +18805 stage: -> patch review pull_request: https://github.com/python/cpython/pull/19450 ___ Python tracker ___

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +Mark.Shannon, serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue40242] zmq mysql core dump

2020-04-09 Thread Rohit Gupta
New submission from Rohit Gupta : # pyzmq==19.0.0 # zmq==0.0.0 # mysql-connector-python==8.0.19 # Following code is resulting in # Segmentation fault (core dumped) ## import zmq import mysql.connector database = "dev" host = "192.168.56.1" port = 3306 user =

[issue40204] Docs build error with Sphinx 3.0 due to invalid C declaration

2020-04-09 Thread Ned Deily
Ned Deily added the comment: Why are we pinning to 1.8.2 when the official docs builds for all releases are currently using 2.3.1? (see, for example, https://docs.python.org/3.8/ at bottom right corner) -- nosy: +ned.deily ___ Python tracker

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: The following macros rely on PyGC_Head: * _PyGCHead_FINALIZED() * _PyGCHead_NEXT() * _PyGCHead_PREV() * _PyGCHead_SET_FINALIZED() * _PyGCHead_SET_NEXT() * _PyGCHead_SET_PREV() * _PyGC_FINALIZED() * _PyGC_PREV_MASK * _PyGC_PREV_MASK_COLLECTING *

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: Aye. Using a workaround for now ("leak" the object by incrementing the refcount on first resurrection): https://github.com/RobotLocomotion/pybind11/pull/39 I may try Antoine's suggestion later on, but will definitely reformulate this to use the public API

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +18806 stage: -> patch review pull_request: https://github.com/python/cpython/pull/19452 ___ Python tracker ___

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: > The following macros rely on PyGC_Head: (...) I already moved them to the internal C API in commit 1a6be91e6fd65ce9cb88c193db7e92ec6076 of bpo-35081. But Stefan Behnel reported that it breaks Cython: "Making _PyGC_FINALIZED() internal broke Cython

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: _testcapi uses _PyObject_GC_IS_TRACKED(). This macro is exposed in Python as gc.is_tracked(). IMO the function should be available in the public C API. For example, PyObject_GC_IsTracked(obj). Cython uses _PyGC_FINALIZED(). This macro is exposed in Python

[issue39598] ERR_CACHE_MISS

2020-04-09 Thread Sahurkhan
Sahurkhan added the comment: Solved, check here https://pcheckup.com/ -- nosy: +Sahurkhan ___ Python tracker ___ ___

[issue40204] Docs build error with Sphinx 3.0 due to invalid C declaration

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: > Why are we pinning to 1.8.2 when the official docs builds for all releases > are currently using 2.3.1? (see, for example, https://docs.python.org/3.8/ > at bottom right corner) First of all, to repair the CI :-) Before my change, it was no longer

[issue40234] Disallow daemon threads in subinterpreters optionally.

2020-04-09 Thread Graham Dumpleton
Graham Dumpleton added the comment: Just to make few things clear. It isn't mod_wsgi itself that relies on daemon threads, it is going to be users WSGI applications (or the things they need) that do. As a concrete example of things that would stop working are monitoring systems such as New

[issue39943] Meta: Clean up various issues in C internals

2020-04-09 Thread Benjamin Peterson
Benjamin Peterson added the comment: New changeset 38ada3bac8205a7690d573d715b0e84e60297c4c by Andy Lester in branch 'master': bpo-39943: Keep constness of pointer objects. (19405) https://github.com/python/cpython/commit/38ada3bac8205a7690d573d715b0e84e60297c4c -- nosy:

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread zhanying
zhanying added the comment: My platform is this. #python Python 3.6.9 |Anaconda, Inc.| (default, Jul 30 2019, 19:07:31) [GCC 7.3.0] on linux Type "help", "copyright", "credits" or "license" for more information. At 2020-04-09 20:45:51, "Eric V. Smith" wrote: > >Eric V. Smith added the

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > Actually, I would like the opposite, to mark it unfinalized to resurrect the > object more than once. That is out of contract and goes against the guarantees on the GC and can (will) cause the finalizer of the object to be executed more than once.

[issue40204] Docs build error with Sphinx 3.0 due to invalid C declaration

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: New changeset 9e5f159d3279a6b476d588010d529cfdbb8c8803 by Victor Stinner in branch '3.7': bpo-40204: Pin Sphinx version to 1.8.2 in Doc/Makefile (GH-19442) (GH-19443) https://github.com/python/cpython/commit/9e5f159d3279a6b476d588010d529cfdbb8c8803

[issue39207] concurrent.futures.ProcessPoolExecutor does not properly reap jobs and spawns too many workers

2020-04-09 Thread Kyle Stanley
Change by Kyle Stanley : -- keywords: +patch pull_requests: +18807 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/19453 ___ Python tracker

[issue40230] Itertools.product() Out of Memory Errors

2020-04-09 Thread Raymond Hettinger
Change by Raymond Hettinger : -- assignee: -> rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40204] Docs build error with Sphinx 3.0 due to invalid C declaration

2020-04-09 Thread Ned Deily
Ned Deily added the comment: I agree that it should be easier to keep them all in sync. But my point is that the on-going official doc builds (some multi[ple times per day) for all of the active versions (2.7 and 3.6 through 3.9) are using 2.3.1 so we should be doing CI against that

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread zhanying
zhanying added the comment: i read the source code, in this part def _calc_julian_from_U_or_W(year, week_of_year, day_of_week, week_starts_Mon): """Calculate the Julian day based on the year, week of the year, and day of the week, with week_start_day representing whether the week of the

[issue40230] Itertools.product() Out of Memory Errors

2020-04-09 Thread Henry Carscadden
Henry Carscadden added the comment: Hey, Tim, I just wanted a note of clarification. I was working on an approximation algorithm for a network science tool that is being released soon. Initially, I relied on itertools.product(), but when I moved to testing on non-trivial graphs, I

[issue40241] [C API] Make PyGC_Head structure opaque, or even move it to the internal C API

2020-04-09 Thread ppperry
Change by ppperry : -- title: [C API] Make PyGC_Head structure opaque, or even more it to the internal C API -> [C API] Make PyGC_Head structure opaque, or even move it to the internal C API ___ Python tracker

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset e3ec44d692d9442e640cf5b2d8708157a65cec3e by Ethan Smith in branch 'master': bpo-39481: PEP 585 for difflib, filecmp, fileinput (#19422) https://github.com/python/cpython/commit/e3ec44d692d9442e640cf5b2d8708157a65cec3e --

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: How are ipaddress and mmap generic? -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Guido van Rossum
Guido van Rossum added the comment: Check typeshed -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Guido van Rossum
Guido van Rossum added the comment: At this speed I can merge about 3 PRs per hour. I'll be back tomorrow. -- ___ Python tracker ___

[issue40230] Itertools.product() Out of Memory Errors

2020-04-09 Thread Tim Peters
Tim Peters added the comment: Henry, I have to ask again: please give at least one specific, concrete example of the behavior you're objecting to. English isn't helping, and I still have no idea what your complaint is. What I'm looking for: for i in itertools.product(???):

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset 2fa67df605e4b0803e7e3aac0b85d851b4b4e09a by Batuhan Taşkaya in branch 'master': bpo-39481: PEP 585 for ipaddress.py (GH-19418) https://github.com/python/cpython/commit/2fa67df605e4b0803e7e3aac0b85d851b4b4e09a --

[issue39481] Implement PEP 585 (Type Hinting Generics In Standard Collections)

2020-04-09 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset 7c4185d62d4aec486d82c3ad02acd878db2d3537 by Ethan Smith in branch 'master': bpo-39481: PEP 585 for enumerate, AsyncGeneratorType, mmap (GH-19421) https://github.com/python/cpython/commit/7c4185d62d4aec486d82c3ad02acd878db2d3537 --

[issue40202] Misleading grammatically of ValueError Message?

2020-04-09 Thread Ammar Askar
Change by Ammar Askar : -- keywords: +patch pull_requests: +18801 stage: -> patch review pull_request: https://github.com/python/cpython/pull/19446 ___ Python tracker ___

[issue40202] Misleading grammatically of ValueError Message?

2020-04-09 Thread Ammar Askar
Ammar Askar added the comment: Jacob, let's skip the 2.7 part of the report since that is EOL now. For reference, the full error on the latest Python is: >>> a, b, c, d = [1, 2, 3] Traceback (most recent call last): File "", line 1, in ValueError: not enough values to unpack (expected 4,

[issue31904] Python should support VxWorks RTOS

2020-04-09 Thread Peixing Xin
Change by Peixing Xin : -- pull_requests: +18803 pull_request: https://github.com/python/cpython/pull/19448 ___ Python tracker ___

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread zhanying
New submission from zhanying : In [7]: datetime.datetime.strptime("2024-0-3 00:00:00", "%Y-%W-%w %H:%M:%S") Out[7]: datetime.datetime(2024, 1, 3, 0, 0) In [8]: datetime.datetime.strptime("2024-1-3 00:00:00", "%Y-%W-%w %H:%M:%S") Out[8]: datetime.datetime(2024, 1, 3, 0, 0) -- messages:

[issue40202] Misleading grammatically of ValueError Message?

2020-04-09 Thread Steven D'Aprano
Steven D'Aprano added the comment: > Since the original report was about 2.7 which is no longer maintained, > I propose to close this issue as outdated. For what it's worth, I'm okay with closing. -- ___ Python tracker

[issue40176] unterminated string literal tokenization error messages could be better

2020-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I afraid there may be confusion between triple, double and single quoted string literals. So I suggest to change error messages to just "unterminated triple-quoted string literal" and "unterminated string literal" (or "unterminated single-quoted string

[issue31904] Python should support VxWorks RTOS

2020-04-09 Thread Peixing Xin
Change by Peixing Xin : -- pull_requests: +18802 pull_request: https://github.com/python/cpython/pull/19447 ___ Python tracker ___

[issue40202] Misleading grammatically of ValueError Message?

2020-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It was discussed in issue39816. I do not think that calling len() and ignoring any exception is a good idea. 1. This may silence some exceptions (errors in the __len__ implementation, MemoryError, RecursionError, KeyboardInterrupt) which should not be

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
Change by brendon zhang : -- title: generator exhaustion for builtin functions in nested call is O(depth) -> recursive call within generator expression is O(depth) ___ Python tracker

[issue25780] Add support for CAN_RAW_JOIN_FILTERS

2020-04-09 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 97e0de04b8cd44474e452a028761e34407192041 by Zackery Spytz in branch 'master': bpo-25780: Expose CAN_RAW_JOIN_FILTERS in the socket module (GH-19190) https://github.com/python/cpython/commit/97e0de04b8cd44474e452a028761e34407192041

[issue40214] test_ctypes.test_load_dll_with_flags Windows failure

2020-04-09 Thread miss-islington
miss-islington added the comment: New changeset c83f003ee5398e9c27a0c634329420003d607d46 by Miss Islington (bot) in branch '3.8': bpo-40214: Temporarily disable a ctypes test (GH-19404) https://github.com/python/cpython/commit/c83f003ee5398e9c27a0c634329420003d607d46 --

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread Eric V. Smith
Eric V. Smith added the comment: Can you tell us what platform you're on? Also, please include the header that's printed out when you run python from the command line. For example, mine shows: $ python3 Python 3.7.6 (default, Jan 30 2020, 10:29:04) [GCC 9.2.1 20190827 (Red Hat 9.2.1-1)] on

[issue40237] Test code coverage (C) job of Travis CI fails on test_distutils which creates _configtest.gcno file

2020-04-09 Thread STINNER Victor
New submission from STINNER Victor : Example: https://travis-ci.org/github/python/cpython/jobs/672698615 Output: === 0:09:01 load avg: 3.96 [104/421/1] test_distutils failed -- running: test_multiprocessing_forkserver (1 min 13 sec), test_unparse (6 min

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: Okay, I attached a complete minimal example below. In your shell, run ulimit -S -s unlimited Then try executing with various python versions 3.6 and 3.7 python3.6 benchbug.py python3.7 benchbug.py You will notice that python 3.7 has a significant

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: update 2: This affects ALL functions which exhaust a generator expression. If that generator expression makes a recursive call, then the cost of evaluating it is O(depth), when it should be only O(1). You can see demonstrate that this doesn't just affect

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
Change by brendon zhang : -- nosy: +rhettinger, vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40214] test_ctypes.test_load_dll_with_flags Windows failure

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: Python 3.8 is also affected. Example: https://github.com/python/cpython/pull/19444#issuecomment-611499825 I backported the change to skip the test until it's fixed: PR 19449. -- nosy: +vstinner versions: +Python 3.8

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi brendon, can you write a complete minimal example that shows the issue, it seems that you are heving an issue when consuming recursive generators and that it's actually not related to max(). I'm confused about the details and have not been able to write an

[issue27054] Python installation problem: No module named 'encodings'

2020-04-09 Thread E
E added the comment: python3 gave the error but I could sudo python3. To solve: export PYTHONHOME= export PYTHONPATH= -- nosy: +ergun ___ Python tracker ___

[issue25780] Add support for CAN_RAW_JOIN_FILTERS

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

[issue40214] test_ctypes.test_load_dll_with_flags Windows failure

2020-04-09 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 7.0 -> 8.0 pull_requests: +18804 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/19449 ___ Python tracker

[issue31904] Python should support VxWorks RTOS

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: New changeset 5cd28030092eaa8eb9223afd733974fd2afc8e2c by pxinwr in branch 'master': bpo-31904: Fix test_c_locale_coercion encodings for VxWorks RTOS (GH-19448) https://github.com/python/cpython/commit/5cd28030092eaa8eb9223afd733974fd2afc8e2c --

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: There is a specific Python function in 3.9 for it: https://docs.python.org/3.9/library/gc.html#gc.is_finalized So it may sense to add a function to query if an object is finalized, but I am not sure it makes sense to allow to mark an object as

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I will make a PR for exposing function to query if an object is finalized as for sure there is value on having that in the public API. -- ___ Python tracker

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

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-40241: "[C API] Make PyGC_Head structure opaque, or even more it to the internal C API". -- ___ Python tracker ___

[issue39943] Meta: Clean up various issues in C internals

2020-04-09 Thread Brett Cannon
Change by Brett Cannon : -- nosy: -brett.cannon ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: > Is it at all possible to considering making some of this public API? In bpo-35081, I wanted to move PyGC macros to the internal C API because they are private functions, but also because they expose implementation details. Example: #define

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: did you remember to run `ulimit -S -s unlimited`? If you don't increase the soft stack limit, your OS will kill the program. -- ___ Python tracker

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: hmm, I can't edit my previous posts. I meant to say python3.6 consumerbug.py python3.7 consumerbug.py -- ___ Python tracker ___

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: I'm unable to run the example as it segfaults on my computer because of the linear recursion but do you notice the same behavior with: from time import time from sys import setrecursionlimit setrecursionlimit(1000) def recurse(i): if i < 0:

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: No, the example you provided does not trigger the same bug. It is explicitly to do with calling recursively from within the generator expression. -- ___ Python tracker

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread brendon zhang
brendon zhang added the comment: reduce the upper bound for the recursion depth until it does not segfault eg hi = 12 -- ___ Python tracker ___

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +belopolsky, p-ganssle ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue40238] os.stat() on Windows succeeds for nonexistent paths with trailing spaces

2020-04-09 Thread David Strobach
New submission from David Strobach : On Windows (Server 2012 R2 in my case) os.stat() seems to be striping significant trailing spaces off the path argument: >>> import os >>> os.stat("c:\\Program Files ") os.stat_result(st_mode=16749, st_ino=281474976710717, st_dev=173025906,

[issue40112] AIX: xlc - default path changed and no longer recognized

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: I backported the fix to 3.8 to fix AIX 3.8 buildbots. -- ___ Python tracker ___ ___

[issue40232] PyOS_AfterFork_Child() should use _PyThread_at_fork_reinit()

2020-04-09 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +corona10 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40112] AIX: xlc - default path changed and no longer recognized

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: New changeset cd8e1da3eaf1b39cc0897def3845da2d793a9e4c by Victor Stinner in branch '3.8': bpo-40112: distutils test_search_cpp: Fix logic to determine if C compiler is xlc on AIX (GH-19225) (GH-19444)

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread Eric V. Smith
Eric V. Smith added the comment: I thought that strptime is platform specific (which is why I asked for the platform info). But, looking at the existing docs https://docs.python.org/3.5/library/time.html#time.strptime "But strptime() is independent of any platform and thus does not

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
New submission from STINNER Victor : Similarly to bpo-39573 (PyObject) and bpo-40170 (PyTypeObject), I propose to make the PyGC_Head structure opaque in the C API. See https://bugs.python.org/issue39573#msg361513 for the rationale. In short, my plan is to hide all implementation details from

[issue32377] Difference in ressurrection behavior with __del__ in py2 vs. py3

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: See also bpo-40240: "Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?" -- ___ Python tracker ___

[issue40225] recursive call within generator expression is O(depth)

2020-04-09 Thread STINNER Victor
Change by STINNER Victor : -- nosy: -vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27054] Python installation problem: No module named 'encodings'

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: > I continually get the error > "Fatal Python error: Py_Initialize: unable to load the file system codec > ImportError: No module named 'encodings'" FYI I enhanced this error in Python 3.8 to "dump the Python path configuration". Example: $ PYTHONHOME=x

[issue40232] PyOS_AfterFork_Child() should use _PyThread_at_fork_reinit()

2020-04-09 Thread Dong-hee Na
Dong-hee Na added the comment: I am going to take a look at this issue. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: C functions sound great! I am certainly not wed to the macros (nor do I love them), as I do not have intense performance requirements where inlining (and spilling implementation guts) is necessary. -- ___ Python

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread Eric Cousineau
New submission from Eric Cousineau : Motivated by this downstream project issue that I am working on: https://github.com/RobotLocomotion/drake/issues/13026 In https://bugs.python.org/issue32377, I encountered PEP 442's updated resurrection behavior when moving from supporting Python 2 to

[issue40237] Test code coverage (C) job of Travis CI fails on test_distutils which creates _configtest.gcno file

2020-04-09 Thread hai shi
Change by hai shi : -- nosy: +shihai1991 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40241] [C API] Make PyGC_Head structure opaque, or even more it to the internal C API

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-40240: "Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?". -- ___ Python tracker ___

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread Paul Ganssle
Paul Ganssle added the comment: I can reproduce this on Linux with Python 3.8.2. I think this may be a bug, but it may also just be platform-specific weirdness. Either way it's very curious behavior: >>> datetime.strptime("2023-0-0", "%Y-%W-%w")

[issue40239] Add a function for merging sorted iterables

2020-04-09 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : It would be useful to have a function in itertools to merge sorted iterables. merge_sorted(*iterables, key=None, reverse=False): It should emit the same items as sorted(tee(*iterables), key=key, reverse=reverse) if iterables are sorted with key and

[issue40238] os.stat() on Windows succeeds for nonexistent paths with trailing spaces

2020-04-09 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +eryksun ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue32377] Difference in ressurrection behavior with __del__ in py2 vs. py3

2020-04-09 Thread Eric Cousineau
Eric Cousineau added the comment: Super late response, but for this part: > Well... perhaps you could create another PyObject (it's just a wrapper, > right?) since the old one doesn't have any outside references to it > remaining. In certain cases, yes, that would be the case. I do have

[issue40239] Add a function for merging sorted iterables

2020-04-09 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi Serhiy, do you plan on writing a PR for this feature? If not I would love to have a go at it. -- nosy: +remi.lapeyre ___ Python tracker ___

[issue40239] Add a function for merging sorted iterables

2020-04-09 Thread Tim Peters
Tim Peters added the comment: Serhiy, are you aware of heapq.merge()? If not, look it up. And then if you still think merge_sorted() would differ in some way, please spell out how it would differ. Based on what you wrote, you threw an invalid invocation of tee() into the mix for some

[issue40236] datetime.datetime.strptime get day error

2020-04-09 Thread Paul Ganssle
Paul Ganssle added the comment: Likely relevant is bpo-23136, where they dealt with similar issues in the past. I don't see any explicit test for this behavior, but it seems that the solution is to try to be consistent and to not raise a ValueError. Looking at this issue, I think it's a

[issue40077] Convert static types to PyType_FromSpec()

2020-04-09 Thread Dong-hee Na
Dong-hee Na added the comment: New changeset dcb04d9c6dd6f31449ade6765fa4d26a305e7381 by Hai Shi in branch 'master': bpo-40077: Remove redundant cast in json module (GH-19438) https://github.com/python/cpython/commit/dcb04d9c6dd6f31449ade6765fa4d26a305e7381 --

[issue40240] Expose public spelling of _PyGC_FINALIZED and _PyGC_SET_FINALIZED?

2020-04-09 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-40241: "[C API] Make PyGC_Head structure opaque, or even more it to the internal C API". -- nosy: +pablogsal, pitrou, vstinner ___ Python tracker

[issue40238] os.stat() on Windows succeeds for nonexistent paths with trailing spaces

2020-04-09 Thread Eryk Sun
Eryk Sun added the comment: > os.stat() seems to be striping significant trailing spaces off > the path argument The Windows file API normalizes paths to replace forward slashes with backslashes; resolve relative paths and "." and ".." components; strip trailing spaces and dots from the