[issue43513] venv: recreate symlinks on --upgrade

2021-08-26 Thread Scott Macpherson
Change by Scott Macpherson : -- nosy: +macpherson.scott ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44972] Add workflow_dispatch trigger for GitHub Actions jobs

2021-08-26 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: Neat! Thanks :) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44972] Add workflow_dispatch trigger for GitHub Actions jobs

2021-08-26 Thread Ryan Mast (nightlark)
Ryan Mast (nightlark) added the comment: > How is manually dispatched workflows different from just opening a PR to your > own fork? I do that from time to time in order to run the CI before opening a > PR against the CPython repo. Here are a few thoughts on how it is different: - They can

[issue45026] More compact range iterator

2021-08-26 Thread Dennis Sweeney
Dennis Sweeney added the comment: Is it worth removing the len field as well and lazily using get_len_of_range() as needed? Then the hot function can look something like: static PyObject * rangeiter_next(rangeiterobject *r) { long result = r->start if (result < r->stop) {

[issue44974] Warning about "Unknown child process pid" in test_asyncio

2021-08-26 Thread Ryan Mast (nightlark)
Ryan Mast (nightlark) added the comment: I haven't gotten a chance to narrow it down much yet, it might be that it is occurs more often on systems with a low core count/higher load -- a bit hard to tell with it being intermittent though. -- ___

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Guido van Rossum
Guido van Rossum added the comment: > The big time consumer is turning marshal'ed code objects back > into Python objects, though. If that could be made faster by > e.g. using a more efficient storage format such as one which is > platform dependent, it'd be a much bigger win than the freezing

[issue41818] Lib/pty.py major revision

2021-08-26 Thread Gregory P. Smith
Gregory P. Smith added the comment: New changeset 245f1f260577a005fd631144b4377febef0b47ed by Gregory P. Smith in branch 'main': bpo-41818: ++ termios versionadded markers. (GH-27987) https://github.com/python/cpython/commit/245f1f260577a005fd631144b4377febef0b47ed --

[issue45026] More compact range iterator

2021-08-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Currently the range iterator contains four integers: index, start, step and len. On iteration index is increased until achieve len, the result is calculated as start+index*step. In the proposed PR the range iterator contains only three integers: index was

[issue45027] Allow basicConfig to configure any logger, not just root

2021-08-26 Thread Greg Werbin
New submission from Greg Werbin : Hello all! I am proposing to add a "logger=" kwarg to logging.basicConfig(), which would cause the configuration to be applied to the specified logger. The value of this parameter could be a string or a logging.Logger object. Omitting logger= or passing

[issue41818] Lib/pty.py major revision

2021-08-26 Thread Gregory P. Smith
Change by Gregory P. Smith : -- pull_requests: +26434 pull_request: https://github.com/python/cpython/pull/27987 ___ Python tracker ___

[issue45026] More compact range iterator

2021-08-26 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +26433 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27986 ___ Python tracker

[issue45026] More compact range iterator

2021-08-26 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : The proposed PR provides more compact implementation of the range iterator. It consumes less memory and produces smaller pickles. It is presumably faster because it performs simpler arithmetic operations on iteration (no multiplications). --

[issue41818] Lib/pty.py major revision

2021-08-26 Thread Gregory P. Smith
Gregory P. Smith added the comment: New changeset ae224bb566301d3602e9b090e37c1dcf5a48c914 by Soumendra Ganguly in branch 'main': bpo-41818: Add termios.tcgetwinsize(), termios.tcsetwinsize(). (GH-23686) https://github.com/python/cpython/commit/ae224bb566301d3602e9b090e37c1dcf5a48c914

[issue45025] Reliance on C bit fields in C API is undefined behavior

2021-08-26 Thread Gregory Szorc
Change by Gregory Szorc : -- title: Reliance on C bit fields is C API is undefined behavior -> Reliance on C bit fields in C API is undefined behavior ___ Python tracker ___

[issue44993] enum.auto() starts with one instead of zero

2021-08-26 Thread Eric V. Smith
Change by Eric V. Smith : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45025] Reliance on C bit fields is C API is undefined behavior

2021-08-26 Thread Gregory Szorc
New submission from Gregory Szorc : At least the PyASCIIObject struct in Include/cpython/unicodeobject.h uses bit fields. Various preprocessor macros like PyUnicode_IS_ASCII() and PyUnicode_KIND() access this struct's bit field. This is problematic because according to the C specification,

[issue45024] Cannot extend collections ABCs with protocol

2021-08-26 Thread Anup Parikh
New submission from Anup Parikh : Since the container ABCs are normal classes, and Protocol cannot subclass normal classes, there's no way to create a protocol that extends the ABCs without explicitly listing out all the methods needed for the collection. e.g., can't do this: from typing

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Guido van Rossum
Guido van Rossum added the comment: I noticed nedbat un-nosied himself. Probably he didn't realize you were calling him out because it's possible this would affect coverage.py? -- ___ Python tracker

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26432 pull_request: https://github.com/python/cpython/pull/27985 ___ Python tracker ___

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 7.0 -> 8.0 pull_requests: +26431 pull_request: https://github.com/python/cpython/pull/27984 ___ Python tracker

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread Steve Dower
Steve Dower added the comment: New changeset 969ae7f7356584e30667b4e490ffa2ffa1810429 by Steve Dower in branch 'main': bpo-45022: Pin current libffi build to fixed version in preparation for upcoming update (GH-27982)

[issue45023] Python doesn't exit with proper resultcode on SIGINT in multiprocessing.Process

2021-08-26 Thread Amber Wright
New submission from Amber Wright : The return code of python on linux/MacOS when the program is ended with a KeyboardInterrupt should be -2, when running with multiprocessing the exitcode is 1. I've attached a reproduced example. >From The Process.join() docs:

[issue44140] WeakKeyDictionary should support lookup by id instead of hash

2021-08-26 Thread Alessio Bogon
Change by Alessio Bogon : -- nosy: +youtux ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43468] functools.cached_property incorrectly locks the entire descriptor on class instead of per-instance locking

2021-08-26 Thread Alessio Bogon
Change by Alessio Bogon : -- nosy: +youtux ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread Steve Dower
Steve Dower added the comment: This first PR is just to avoid accidentally upgrading old builds. Otherwise, as soon as I push the new build into the cpython-bin-deps repository, it'll take precedence. This one needs backporting into 3.10 and 3.9, but should be a no-op. --

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread Steve Dower
Change by Steve Dower : -- keywords: +patch pull_requests: +26430 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/27982 ___ Python tracker

[issue45022] Update libffi to 3.4.2

2021-08-26 Thread Steve Dower
New submission from Steve Dower : libffi is doing releases again! We're a few versions behind, so should pull in the latest. https://github.com/libffi/libffi/ Adding RMs for opinions on backporting, and Ned in case this impacts the macOS build. -- components: Build, Windows, ctypes

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Eric Snow
Eric Snow added the comment: > For the latter, the obvious solution is to introduce a startup hook I'm not sure why I said "obvious". Sorry about that. -- ___ Python tracker

[issue45021] Race condition in thread.py

2021-08-26 Thread nullptr
nullptr added the comment: A more direct way to reproduce from concurrent.futures import ProcessPoolExecutor, ThreadPoolExecutor from time import sleep def worker(): with ProcessPoolExecutor() as pool: r = list(pool.map(sleep, [0.01] * 8)) def submit(pool):

[issue45021] Race condition in thread.py

2021-08-26 Thread nullptr
Change by nullptr : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34804] Repetition of 'for example' in documentation

2021-08-26 Thread Diana
Diana added the comment: I will handle it. I will send a pull request within 3 days. -- nosy: +DonnaDia ___ Python tracker ___ ___

[issue45021] Race condition in thread.py

2021-08-26 Thread nullptr
New submission from nullptr : The following code can sometimes hang up import random from concurrent.futures import ProcessPoolExecutor, ThreadPoolExecutor from time import sleep def worker():

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread Łukasz Langa
Change by Łukasz Langa : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.6 ___ Python tracker

[issue45007] OpenSSL 1.1.1l is released

2021-08-26 Thread Steve Dower
Steve Dower added the comment: The new build and tags for Windows are up. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread miss-islington
miss-islington added the comment: New changeset f1e3fc4631da5e6ca1ea047c82bd9b42db9dd9ae by Miss Islington (bot) in branch '3.9': bpo-40635: Fix getfqdn() docstring and docs (GH-27971) https://github.com/python/cpython/commit/f1e3fc4631da5e6ca1ea047c82bd9b42db9dd9ae --

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread miss-islington
miss-islington added the comment: New changeset 719af92e108ea3b31729cb09077673b8f13905d2 by Miss Islington (bot) in branch '3.10': bpo-40635: Fix getfqdn() docstring and docs (GH-27971) https://github.com/python/cpython/commit/719af92e108ea3b31729cb09077673b8f13905d2 --

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Ned Batchelder
Change by Ned Batchelder : -- nosy: -nedbat ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue30274] Rename 'name' to 'fullname' argument to ExtensionFileLoader

2021-08-26 Thread Roundup Robot
Change by Roundup Robot : -- nosy: +python-dev nosy_count: 6.0 -> 7.0 pull_requests: +26429 pull_request: https://github.com/python/cpython/pull/27981 ___ Python tracker ___

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Eric Snow
Eric Snow added the comment: > The big time consumer is turning marshal'ed code objects back > into Python objects, though. If that could be made faster by > e.g. using a more efficient storage format such as one which is > platform dependent, it'd be a much bigger win than the freezing >

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Ronald Oussoren
Change by Ronald Oussoren : -- nosy: +ronaldoussoren ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Not sure whether you are aware, but the PyRun project I'm maintaining does that and goes beyond this by freezing almost the complete stdlib and statically linking most C extensions into a single binary: https://www.egenix.com/products/python/PyRun/

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Eric Snow
Eric Snow added the comment: I'm aware of two potentially problematic consequences to this change: * making changes to those source files for the modules will not be reflected during execution until after "make" is run * tricks to inject hooks ASAP (e.g. coverage.py swaps the encodings

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Eric Snow
Eric Snow added the comment: FYI, with my branch I'm getting a 15% improvement to startup for "./python -c pass". -- ___ Python tracker ___

[issue45020] Freeze all modules imported during startup.

2021-08-26 Thread Eric Snow
New submission from Eric Snow : Currently we freeze the 3 main import-related modules into the python binary (along with one test module). This allows us to bootstrap the import machinery from Python modules. It also means we get better performance importing those modules. If we freeze

[issue45019] Freezing modules has manual steps but could be automated.

2021-08-26 Thread Eric Snow
Change by Eric Snow : -- keywords: +patch pull_requests: +26428 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/27980 ___ Python tracker

[issue45019] Freezing modules has manual steps but could be automated.

2021-08-26 Thread Eric Snow
New submission from Eric Snow : Currently we freeze the 3 main import-related modules, as well as one module for testing. Adding more modules or otherwise making any adjustments requires manually editing several files (frozen.c, Makefile.pre.in, ...). Those files aren't particularly

[issue44997] [sqlite3] build fails on macOS 11.5.1

2021-08-26 Thread Erlend E. Aasland
Change by Erlend E. Aasland : -- keywords: +patch pull_requests: +26427 stage: resolved -> patch review pull_request: https://github.com/python/cpython/pull/27979 ___ Python tracker

[issue44933] python3.9-intel64 hardened runtime not enabled

2021-08-26 Thread Ronald Oussoren
Ronald Oussoren added the comment: @ned: the "reliable way to run under rosetta" is using "arch -x86_64 python3". I don't particularly like having another executable to accomplish the same goal. -- ___ Python tracker

[issue44997] [sqlite3] build fails on macOS 11.5.1

2021-08-26 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: Thanks, Ronald, that's a nice improvement. I'll create a PR for it. -- ___ Python tracker ___

[issue44997] [sqlite3] build fails on macOS 11.5.1

2021-08-26 Thread Erlend E. Aasland
Change by Erlend E. Aasland : -- resolution: fixed -> status: closed -> open ___ Python tracker ___ ___ Python-bugs-list mailing

[issue44997] [sqlite3] build fails on macOS 11.5.1

2021-08-26 Thread Ronald Oussoren
Ronald Oussoren added the comment: Note that sqlite3_enable_load_extension was unavailable way before macOS 11.5.1, the symbol is not present on 10.15 (I used 'nm /usr/lib/libsqlite3.dylib' to check for symbol availability). Just checking for MACOS and a system include directory should do

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26426 pull_request: https://github.com/python/cpython/pull/27978 ___ Python tracker ___

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset fdcb675eed47b1f6054fae381af4388b16a6fff4 by andrei kulakov in branch 'main': bpo-40635: Fix getfqdn() docstring and docs (GH-27971) https://github.com/python/cpython/commit/fdcb675eed47b1f6054fae381af4388b16a6fff4 -- nosy: +lukasz.langa

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 5.0 -> 6.0 pull_requests: +26425 pull_request: https://github.com/python/cpython/pull/27977 ___ Python tracker

[issue45010] Remove support of special method __div__ in unittest.mock

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: Agreed, let's get rid of it. Thanks! I grepped for this and there's still one left-over here: https://github.com/python/cpython/blob/f9cd40f5e242d3c64cc20a5064500f5fe864f91f/Lib/importlib/metadata/_meta.py#L40-L41 Fortunately, this was already fixed upstream:

[issue30274] Rename 'name' to 'fullname' argument to ExtensionFileLoader

2021-08-26 Thread Diana Van Straaten
Diana Van Straaten added the comment: I want to work on it. -- nosy: +zemlya3018 ___ Python tracker ___ ___ Python-bugs-list

[issue45010] Remove support of special method __div__ in unittest.mock

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset f9cd40f5e242d3c64cc20a5064500f5fe864f91f by Serhiy Storchaka in branch 'main': bpo-45010: Remove support of special method __div__ in unittest.mock (GH-27965) https://github.com/python/cpython/commit/f9cd40f5e242d3c64cc20a5064500f5fe864f91f

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread Łukasz Langa
Change by Łukasz Langa : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 970533e65c1a1129dfc1cc1867f6ad075f7f5bf6 by Miss Islington (bot) in branch '3.9': [3.9] bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968) (GH-27970) https://github.com/python/cpython/commit/970533e65c1a1129dfc1cc1867f6ad075f7f5bf6

[issue45018] Pickling a range iterator with an index of over sizeof(int) stores an invalid index

2021-08-26 Thread Jordan Limor
Change by Jordan Limor : -- keywords: +patch nosy: +chilaxan nosy_count: 1.0 -> 2.0 pull_requests: +26424 pull_request: https://github.com/python/cpython/pull/27938 ___ Python tracker

[issue45018] Pickling a range iterator with an index of over sizeof(int) stores an invalid index

2021-08-26 Thread Łukasz Langa
New submission from Łukasz Langa : Consider the following: >>> it = iter(range(2**32 + 2)) >>> for _ in range(2**32): ... _ = next(it) >>> it2 = pickle.loads( ... pickle.dumps(it) ... ) >>> assert next(it) == next(it2) This assert currently fails because the reduce method for range

[issue39218] Assertion failure when calling statistics.variance() on a float32 Numpy array

2021-08-26 Thread Raymond Hettinger
Raymond Hettinger added the comment: > what it's correcting for is an inaccurate value of "c" [...] I'll leave the logic as-is and just add a note about what is being corrected. > Numerically, it's probably not helpful. To make a difference, the mean would have to have huge magnitude

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread Łukasz Langa
Change by Łukasz Langa : -- versions: +Python 3.6, Python 3.7, Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 81148c6f91092c3aa207a53b657b2548a20b230c by Miss Islington (bot) in branch '3.8': bpo-45001: Make email date parsing more robust against malformed input (GH-27946) (GH-27974)

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 2cdbd3b8b2bb4fa0dbcc04ce305fbafaeedd9e67 by Miss Islington (bot) in branch '3.9': bpo-45001: Make email date parsing more robust against malformed input (GH-27946) (GH-27973)

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
miss-islington added the comment: New changeset 9a79242567d79f42ad1a953cce2b1c4a94df23ea by Miss Islington (bot) in branch '3.10': bpo-45001: Make email date parsing more robust against malformed input (GH-27946)

[issue45017] move opcode-related logic from modulefinder to dis

2021-08-26 Thread Guido van Rossum
Change by Guido van Rossum : -- nosy: +gvanrossum ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45017] move opcode-related logic from modulefinder to dis

2021-08-26 Thread Irit Katriel
New submission from Irit Katriel : The modulefinder library module has logic that understands particular opcodes (such as the scan_opcodes method). This should be encapsulated in the dis module, and modulefinder should not process opcodes directly. -- components: Library (Lib)

[issue45016] Multiprocessing freeze support unclear

2021-08-26 Thread Ronald Oussoren
New submission from Ronald Oussoren : The requirements on a freezing tool to work with the freeze support in the multiprocessing library are unclear. In particular, I'm trying to support multiprocessing in py2app and cannot rely on the documentation to implement that support. The particular

[issue44946] Integer operations are inefficient for "medium" integers.

2021-08-26 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue44990] Change layout of frames back to specials-locals-stack (from locals-specials-stack)

2021-08-26 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue45013] os.path.isfile fails on path exactly 260 Chars long in Windows

2021-08-26 Thread Eryk Sun
Eryk Sun added the comment: The legacy maximum buffer size is 260 characters, but remember that strings in C are terminated by a null character (i.e. "\0"). So the maximum path length is actually 259 characters when opening files. In Windows 10 with Python 3.6+, you can enable the

[issue40772] module 'resource' has no attribute 'RLIMIT_VMEM'

2021-08-26 Thread Ronald Oussoren
Ronald Oussoren added the comment: According to https://man7.org/linux/man-pages/man2/getrlimit.2.html there is no RLIMIT_VMEM on linux, RLIMIT_AS is the closest equivalent. -- nosy: +ronaldoussoren resolution: -> not a bug stage: -> resolved status: open -> closed

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26423 pull_request: https://github.com/python/cpython/pull/27976 ___ Python tracker ___

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26422 pull_request: https://github.com/python/cpython/pull/27975 ___ Python tracker ___

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26421 pull_request: https://github.com/python/cpython/pull/27974 ___ Python tracker ___

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 989f6a3800f06b2bd31cfef7c3269a443ad94fac by wouter bolsterlee in branch 'main': bpo-45001: Make email date parsing more robust against malformed input (GH-27946) https://github.com/python/cpython/commit/989f6a3800f06b2bd31cfef7c3269a443ad94fac

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 3.0 -> 4.0 pull_requests: +26419 pull_request: https://github.com/python/cpython/pull/27972 ___ Python tracker

[issue45001] Date parsing helpers in email module incorrectly raise IndexError for some malformed inputs

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26420 pull_request: https://github.com/python/cpython/pull/27973 ___ Python tracker ___

[issue45009] Get last modified date of Folders and Files using os.path module

2021-08-26 Thread Gopesh Singh
Gopesh Singh added the comment: Thanks Vedram for the response. Changed the title. But I get the same issue with Path.stat(). When I put a sleep time for each iteration, it works fine. Else, it gives current date as modified date. -- ___ Python

[issue45009] Get last modified date of Folders and Files using os.path module

2021-08-26 Thread Gopesh Singh
Gopesh Singh added the comment: Updated title. As I used getmtime of os.path module. -- title: Get last modified date of Folders and Files using pathlib module -> Get last modified date of Folders and Files using os.path module ___ Python tracker

[issue33092] The bytecode for f-string formatting is inefficient.

2021-08-26 Thread Mark Shannon
Mark Shannon added the comment: No significant change in performance https://gist.github.com/markshannon/34a780d65e69b5a573a83f3fdb0139aa I think this merely indicates that there are little to no f-strings in the pyperformance benchmark suite. --

[issue45009] Get last modified date of Folders and Files using pathlib module

2021-08-26 Thread Vedran Čačić
Vedran Čačić added the comment: It probably has nothing to do with your bug, but your title is wrong. You are _not_ getting mtime using pathlib (but using os.path instead). That is done like using this approach: https://docs.python.org/3/library/pathlib.html#pathlib.Path.stat Just to

[issue45015] Language Reference failing to describe the treatment of starred expressions

2021-08-26 Thread Takuo Matsuoka
New submission from Takuo Matsuoka : The issue is described as Issue (1) here: https://mail.python.org/archives/list/python-id...@python.org/message/BEGGQEU6MG7RYIY7HB4I6VQ23L6TXB6H/ Please look at "Note" just before "Issues treated" there as well. What's mentioned in this note is also filed

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread miss-islington
miss-islington added the comment: New changeset 9f814beadb3ee2c7b37e949a2acf72117a449ffd by Miss Islington (bot) in branch '3.10': bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968) https://github.com/python/cpython/commit/9f814beadb3ee2c7b37e949a2acf72117a449ffd --

[issue45014] SyntaxError describing the error using a wrong term

2021-08-26 Thread Takuo Matsuoka
New submission from Takuo Matsuoka : The error is this: >>> *() File "", line 1 SyntaxError: can't use starred expression here I think it's right SyntaxError is raised here, but the message is incorrect. Indeed, many starred expressions are actually allowed there. E.g., >>> *(), () I

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 3.0 -> 4.0 pull_requests: +26418 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27971 ___ Python tracker

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 6.0 -> 7.0 pull_requests: +26416 pull_request: https://github.com/python/cpython/pull/27969 ___ Python tracker

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 7dc505b8655b3e48b93a4274dfd26e5856d9c64f by Serhiy Storchaka in branch 'main': bpo-45011: Fix test_asyncio without C module _asyncio (GH-27968) https://github.com/python/cpython/commit/7dc505b8655b3e48b93a4274dfd26e5856d9c64f --

[issue45011] tests fail when using pure-python instead of _asyncio

2021-08-26 Thread miss-islington
Change by miss-islington : -- pull_requests: +26417 pull_request: https://github.com/python/cpython/pull/27970 ___ Python tracker ___

[issue45013] os.path.isfile fails on path exactly 260 Chars long in Windows

2021-08-26 Thread Luke Rossi
Luke Rossi added the comment: I saw 33105, but believe this to be a different issue as path length 260 is valid. I did testing by crafting a path that is exactly 260 by hand - A path 259 in length reports .isfile() as True. The Stack Error: [WinError 3] The system cannot find the path

[issue45013] os.path.isfile fails on path exactly 260 Chars long in Windows

2021-08-26 Thread Luke Rossi
New submission from Luke Rossi : I saw 33105, but believe this to be a different issue as path length 260 is valid. I did testing by crafting a path that is exactly 260 by hand - A path 259 in length reports .isfile() as True. -- components: Library (Lib) messages: 400341 nosy:

[issue44967] pydoc should return non-zero exit code when a query is not found

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: Thanks for the report and fix, Gregory! ✨  ✨ -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.11 ___ Python tracker

[issue44967] pydoc should return non-zero exit code when a query is not found

2021-08-26 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 8868d48712aee2b490efaf60bed8dfe9fb14d6b7 by Gregory Anders in branch 'main': bpo-44967: pydoc: return non-zero exit code when query is not found (GH-27868) https://github.com/python/cpython/commit/8868d48712aee2b490efaf60bed8dfe9fb14d6b7

[issue25867] os.stat raises exception when using unicode and no locale is set

2021-08-26 Thread Eryk Sun
Eryk Sun added the comment: > It's doing this now, so seems like it has been fixed Yes. In POSIX systems since Python 3.7, if the LC_CTYPE locale is the legacy "C" or "POSIX" locale, by default it tries to coerce LC_CTYPE to "C.UTF-8", "C.utf8", or "UTF-8". If coercion fails or is disabled

[issue45012] DirEntry.stat method should release GIL

2021-08-26 Thread Uosiu
New submission from Stanisław Skonieczny (Uosiu) : We have an application that crawls filesystem using `os.scandir`. It uses multiple threads for various things. Application is used on variety of filesystems, some of them might be slow or occasionally unresponsive. We have found out that

[issue36073] sqlite crashes with converters mutating cursor

2021-08-26 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: Er, a little bit too fast there. There is still a crash, but it is of course postponed bco. bpo-44976. New reproducer: import sqlite3 as sqlite con = sqlite.connect(':memory:', detect_types=sqlite.PARSE_COLNAMES) cur = con.cursor()

[issue36073] sqlite crashes with converters mutating cursor

2021-08-26 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: After GH-27884 (bpo-44976) there is no longer a segfault. I suggest to expand the test suite with the reproducer Sergey provided. -- ___ Python tracker

[issue36073] sqlite crashes with converters mutating cursor

2021-08-26 Thread Erlend E. Aasland
Change by Erlend E. Aasland : -- status: pending -> open Removed message: https://bugs.python.org/msg400334 ___ Python tracker ___

[issue36073] sqlite crashes with converters mutating cursor

2021-08-26 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: This issue was fixed by GH-27884 (bpo-44976). I suggest to expand the test suite with the reproducer Sergey provided before closing the issue. -- status: open -> pending ___ Python tracker

  1   2   >