[issue46056] Cannot use virtual environment on Windows 10 in corporate security settings

2021-12-13 Thread Steve Dower
Steve Dower added the comment: Also, if you see people discussing PEP 582, you might want to throw in a vote of support. It is intended to provide the benefits of a venv without needing to do tricks like we do for the current design, but it keeps being rejected for "not being sufficiently us

[issue14484] missing return in win32_kill?

2021-12-13 Thread Steve Dower
Steve Dower added the comment: > Windows should have its own specific function. Either that or mimic it properly. Having a single function that requires different parameters based on OS is a very user-hostile design. If someone wants to shepherd it through the process, I'd support either ma

[issue46068] Change use of warnings.warn to logging.warning in a few places

2021-12-13 Thread Andrei Kulakov
New submission from Andrei Kulakov : In discussion on https://github.com/python/cpython/pull/29910 related to whether to use warnings.warn or logging.warning, I found two places in the library where it might make sense to change to logging.warning. There's probably other instances where the s

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Vinay Sajip
Vinay Sajip added the comment: > This is the intended behaviour, and yes it's changed from previous versions > ... The previous value was incorrect, hence it was marked as an internal > field. But the value as it's calculated now seems to give a file that doesn't exist - how can that be cor

[issue14484] missing return in win32_kill?

2021-12-13 Thread Irit Katriel
Change by Irit Katriel : -- versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.7 ___ Python tracker ___ ___ Python-bugs-list

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Ned Batchelder
Ned Batchelder added the comment: This started because a set of tests in the coverage.py test suite fail with 3.11.0a3. They attempt to create a venv in the test, and the test is already running inside a virtualenv. The venv creation fails, with a reference to a non-existent file. I wrote

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Steve Dower
Steve Dower added the comment: Is sys._base_executable correct without a venv? It should be the same as sys.executable in that case. venv calculates 'home' here: Lib/venv/__init__.py#L117 executable = sys._base_executable dirname, exename = os.path.split(os.path.abspath(execu

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Steve Dower
Steve Dower added the comment: > But the value as it's calculated now seems to give a file that doesn't exist > - how can that be correct? Because we never actually use the executable referenced by the 'home' path in a pyvenv.cfg. It's only used as a starting point to locate a couple of entr

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Steve Dower
Steve Dower added the comment: > Because we never actually use the executable referenced by the 'home' path in > a pyvenv.cfg. This is actually not true on Windows or (I believe) some situations on macOS, where we need to use a redirecting launcher to actually launch the binary specified in

[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong

2021-12-13 Thread Ned Batchelder
Ned Batchelder added the comment: Demonstration of a problem with only stdlib, and no undocumented features. This is on a Mac: This works: $ python3.10 -V Python 3.10.0 $ python3.10 -m venv v310 $ v310/bin/python -m venv v310-nested $ v310-nested/bin/python -V Python 3.10.0 This does not

[issue23469] Delete Misc/*.wpr files

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: IMO it's ok to remove these files. If WING is maintained again, it will be trivial to add again these configuratin files. I suggest to only remove these files in Python 3.11. -- nosy: +vstinner ___ Python tracker

[issue34624] -W option and PYTHONWARNINGS env variable does not accept module regexes

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: Oh, I didn't know this issue. I closed my issue bpo-43862 as a duplicate. -- nosy: +vstinner ___ Python tracker ___ _

[issue43862] warnings: -W option and PYTHONWARNINGS now use the message as a regex

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: I mark this issue as a duplicate of bpo-34624. -- resolution: -> duplicate stage: patch review -> resolved status: open -> closed superseder: -> -W option and PYTHONWARNINGS env variable does not accept module regexes __

[issue34624] -W option and PYTHONWARNINGS env variable does not accept module regexes

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: > Adding regular expression support to -W and PYTHONWARNINGS env var turns the > options into potential attack vectors. Why would an attacker control these options? If an attacker controls how Python is run, they are more efficient way to take control of Py

[issue34624] -W option and PYTHONWARNINGS env variable does not accept module regexes

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: One option is to keep the current behavior by default, but support a new "/regex/" format. The /regex/ format is commonly used in Perl and sed. Example to ignore warnings containing "deprecated" string in their message: python3 -W "ignore:/deprecated/"

[issue12489] email.errors.HeaderParseError if base64url is used

2021-12-13 Thread Irit Katriel
Irit Katriel added the comment: Reproduced on 3.11: >>> from email.header import decode_header >>> decode_header('=?iso-8859-1?B?QW5tZWxkdW5nIE5ldHphbnNjaGx1c3MgU_xkcmluZzNwLmpwZw==?=') Traceback (most recent call last): File "/Users/iritkatriel/src/cpython-1/Lib/email/header.py", line 126,

[issue25948] Invalid MIME encoding generated by email.mime (line too long)

2021-12-13 Thread Irit Katriel
Change by Irit Katriel : -- versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.5 ___ Python tracker ___ ___ Python-bugs-list

[issue31370] Remove support for threads-less builds

2021-12-13 Thread Brett Cannon
Brett Cannon added the comment: > https://web.dev/webassembly-threads/ suggests otherwise. It actually doesn't as that post isn't for WASI, it's for WASM in the browser (I chose my acronyms carefully 😉). WASI is like POSIX for WebAssembly, so it's meant for desktop usage and thus no browser

[issue23148] Missing the charset parameter in as_encoded_word()

2021-12-13 Thread Irit Katriel
Irit Katriel added the comment: I can't find as_encoded_word anywhere. Even on 3.7 branch. -- nosy: +iritkatriel ___ Python tracker ___ ___

[issue40059] Provide a toml module in the standard library

2021-12-13 Thread Brett Cannon
Brett Cannon added the comment: > I just noticed that tomli has dropped support for Python 3.6. That's a road > block for general adoption of the package in the Python ecosystem. It's already in pip, so I think it's already generally adopted 😉. https://github.com/pypa/pip/tree/main/src/pip/_v

[issue26528] NameError for built in function open when re-raising stored exception from yielded function

2021-12-13 Thread Irit Katriel
Irit Katriel added the comment: Reproduced on 3.11. -- nosy: +iritkatriel versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.4, Python 3.5, Python 3.6, Python 3.7, Python 3.8 ___ Python tracker _

[issue40059] Provide a toml module in the standard library

2021-12-13 Thread Martin Reboredo
Martin Reboredo added the comment: > Not officially, no. But I'm personally not going to bring it forward right > now. If someone else wants to formulate a complete proposal for the SC on > this then they are definitely welcome to! You will need to address where the > code is coming from, wh

[issue46063] TimedRotatingFileHandler deletes wrong files

2021-12-13 Thread Vinay Sajip
Vinay Sajip added the comment: New changeset cb589d1b6bad4b75852c2e2a471a3800d5efdca7 by Vinay Sajip in branch 'main': bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) https://github.com/python/cpython/commit/cb589d1b6bad4b75852c2e2a471a3800d5efdca7

[issue46063] TimedRotatingFileHandler deletes wrong files

2021-12-13 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 2.0 -> 3.0 pull_requests: +28317 pull_request: https://github.com/python/cpython/pull/30094 ___ Python tracker _

[issue46063] TimedRotatingFileHandler deletes wrong files

2021-12-13 Thread miss-islington
Change by miss-islington : -- pull_requests: +28318 pull_request: https://github.com/python/cpython/pull/30095 ___ Python tracker ___ __

[issue45953] Statically allocate interpreter states as much as possible.

2021-12-13 Thread Eric Snow
Eric Snow added the comment: New changeset 121f1f893a39d0b58d3d2b5597505c154ecaac2a by Eric Snow in branch 'main': bpo-45953: Statically initialize the small ints. (gh-30092) https://github.com/python/cpython/commit/121f1f893a39d0b58d3d2b5597505c154ecaac2a -- __

[issue31370] Remove support for threads-less builds

2021-12-13 Thread STINNER Victor
STINNER Victor added the comment: > This has unfortunately turned out to be a blocker on getting WASI support as > there's not direct threading support in WebAssembly. This issue is now closed and unrelated to WASI support. Can you please open a new separated issue for it? -- _

[issue45953] Statically allocate interpreter states as much as possible.

2021-12-13 Thread Eric Snow
Change by Eric Snow : -- pull_requests: +28319 pull_request: https://github.com/python/cpython/pull/30096 ___ Python tracker ___ ___

[issue46063] TimedRotatingFileHandler deletes wrong files

2021-12-13 Thread Vinay Sajip
Vinay Sajip added the comment: New changeset f84e2f6c0aca97c59ec8ce21715ae9bd89893307 by Miss Islington (bot) in branch '3.10': [3.10] bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) (GH-30094) https://github.com/python/cpython/commit/f84e2f6c0aca97c59ec8ce21

[issue46063] TimedRotatingFileHandler deletes wrong files

2021-12-13 Thread Vinay Sajip
Vinay Sajip added the comment: New changeset 94234228abbb84945a48049a7515dea960bc9834 by Miss Islington (bot) in branch '3.9': [3.9] bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) (GH-30095) https://github.com/python/cpython/commit/94234228abbb84945a48049a75

[issue45919] Use WinAPI GetFileType() in is_valid_fd()

2021-12-13 Thread Dong-hee Na
Dong-hee Na added the comment: New changeset 9130a4d62032468e0d4949aaa49c29afb0d854ca by Dong-hee Na in branch 'main': bpo-45919: Remove out of date comment (GH-30090) https://github.com/python/cpython/commit/9130a4d62032468e0d4949aaa49c29afb0d854ca -- _

[issue46068] Change use of warnings.warn to logging.warning in a few places

2021-12-13 Thread Raymond Hettinger
Raymond Hettinger added the comment: > The downside of making this change is that it may break 3rd party unit tests. I don’t see any upside. The modules in question have been stable for a good while. There’s no benefit to changing them. Also, there is no strong agreement that the standard

[issue46068] Change use of warnings.warn to logging.warning in a few places

2021-12-13 Thread Raymond Hettinger
Change by Raymond Hettinger : -- Removed message: https://bugs.python.org/msg408512 ___ Python tracker ___ ___ Python-bugs-list mail

[issue46068] Change use of warnings.warn to logging.warning in a few places

2021-12-13 Thread Raymond Hettinger
Raymond Hettinger added the comment: > The downside of making this change is that it may break 3rd party unit tests. I don’t see any upside. The modules in question have been stable for a good while. There’s no benefit to changing them. Also, there is no strong agreement that the standard

[issue45915] Use fcntl(fd, F_GETFD) to check whether an fd is valid

2021-12-13 Thread Eryk Sun
Eryk Sun added the comment: PR 29821 adds __APPLE__ to the platforms that use fcntl(fd, F_GETFD). Is this okay on macOS, given bpo-30225? Apparently fstat() fails if the other end of a pipe is closed. -- ___ Python tracker

[issue46057] argparse: embedded groups may prevent options from being in help output

2021-12-13 Thread Irit Katriel
Irit Katriel added the comment: You’re right that the api should not be there. See issue22047. I don’t think it should be patches to call super/return self. That would just be confusing. -- resolution: -> duplicate superseder: -> argparse improperly prints mutually exclusive options

<    1   2