[issue41818] Lib/pty.py major revision

2020-12-10 Thread Soumendra Ganguly
Change by Soumendra Ganguly : -- pull_requests: +22598 pull_request: https://github.com/python/cpython/pull/23740 ___ Python tracker ___

[issue39717] Fix exception causes in tarfile module

2020-12-10 Thread Ethan Furman
Change by Ethan Furman : -- versions: +Python 3.10 -Python 3.9 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue39717] Fix exception causes in tarfile module

2020-12-10 Thread Ethan Furman
Change by Ethan Furman : -- keywords: +patch pull_requests: +22597 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23739 ___ Python tracker ___

[issue41559] Add support for PEP 612 to typing.py

2020-12-10 Thread Guido van Rossum
Guido van Rossum added the comment: I started doing this in the original code (long ago when PEP 484 was brand new) but have since realized that this makes the typing module both slow and hard to maintain. We should not follow this example. I do think we should try to keep `__args__` hashable,

[issue42609] Eval with too high string multiplication crashes newer Python versions

2020-12-10 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +methane ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42609] Eval with too high string multiplication crashes newer Python versions

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

[issue40747] sysconfig.get_config_var("py_version_nodot") should return 3_10

2020-12-10 Thread Steve Dower
Steve Dower added the comment: This has been blocking it: https://discuss.python.org/t/pep-641-using-an-underscore-in-the-version-portion-of-python-3-10-compatibility-tags/5513 Pablo (PEP delegate) has just posted his rejection though, so it will be fixed when packaging changes back to

[issue41559] Add support for PEP 612 to typing.py

2020-12-10 Thread Ken Jin
Ken Jin added the comment: The pyre version in their __init__.py looks like they took your advice for letting the static checker do the work wholeheartedly. I'm not in favour of type checking either. Just that the pre-existing code does it for me. Not type checking when seeing ~P in

[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-10 Thread Karl Nelson
Karl Nelson added the comment: Oddly that was the only exception that I got. When I hit continue it proceeded without issue and the dll was loaded correctly. However, when I try without the debugger attached the error reappears. So this is one of those Schrodinger errors. I know the

[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-10 Thread Steve Dower
Steve Dower added the comment: Replicating also requires installing Java (I got as far as the build failing), which is going to have to wait until I have time to spin up a throwaway machine :) That exception is a normal part of the import process and should be being handled. It's not the

[issue42083] PyStructSequence_NewType broken in 3.8

2020-12-10 Thread Steve Stagg
Steve Stagg added the comment: It looks like the segfault was fixed in https://github.com/python/cpython/commit/88c2cfd9ffbcfc43fd1364f2984852a819547d43 as part of https://bugs.python.org/issue41832. The code in this area of typeobject.c looks a bit different, now, but the backport seems

[issue42618] Enhancement request for importing stacktraces from foreign sources

2020-12-10 Thread Karl Nelson
New submission from Karl Nelson : In JPype, I am transfer stack information from Java into Python for diagnostics and display purposed. Unfortunately, as the exception system is directly accessing traceback structure elements this cannot be replicated without creating traceback structures

[issue42059] TypedDict(...) as function does not respect "total" when setting __required_keys__ and __optional_keys__

2020-12-10 Thread Brandt Bucher
Brandt Bucher added the comment: New changeset 67b769f5157c9dad1c7dd6b24e067b9fdab5b35d by Alex Grönholm in branch 'master': bpo-42059: Fix required/optional keys for TypedDict(..., total=False) (GH-22736) https://github.com/python/cpython/commit/67b769f5157c9dad1c7dd6b24e067b9fdab5b35d

[issue42617] Enhancement request for PyType_FromSpecWIthBases add option for meta class

2020-12-10 Thread Karl Nelson
New submission from Karl Nelson : PyType_FromSpecWithBases is missing an argument for taking a meta class. As a result it is necessary to replicate a large portion of Python code when I need to create a new heap type with a specified meta class. This is a maintenance issue as replicating

[issue42609] Eval with too high string multiplication crashes newer Python versions

2020-12-10 Thread Steve Stagg
Steve Stagg added the comment: In python 3.7/8, It's a stack overflow in the constant folding code. On master, the overflow seems to come out of validate_expr.c. * thread #1, name = 'python3', stop reason = signal SIGSEGV: invalid address (fault address: 0x7f7feff8) frame #0:

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Antony Lee
Change by Antony Lee : -- nosy: -Antony.Lee ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Antony Lee
Antony Lee added the comment: Thanks for implementing! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34750] locals().update doesn't work in Enum body, even though direct assignment to locals() does

2020-12-10 Thread Antony Lee
Change by Antony Lee : -- nosy: -Antony.Lee ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34750] locals().update doesn't work in Enum body, even though direct assignment to locals() does

2020-12-10 Thread Antony Lee
Antony Lee added the comment: Thanks! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42529] CPython DLL initialization routine failed from PYC cache file

2020-12-10 Thread Karl Nelson
Karl Nelson added the comment: I managed to get the debugger attached (unfortunately I am not a windows programmer so I don't use these tools). It appears when loading from a pyc, it is attempting to open the directory as a Zip file which is throwing an exception resulting in a failure to

[issue34750] locals().update doesn't work in Enum body, even though direct assignment to locals() does

2020-12-10 Thread Ethan Furman
Change by Ethan Furman : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue34750] locals().update doesn't work in Enum body, even though direct assignment to locals() does

2020-12-10 Thread Ethan Furman
Ethan Furman added the comment: New changeset a65828717982e6a56382d7aff738478f5b5b25d0 by Ethan Furman in branch 'master': bpo-34750: [Enum] add `_EnumDict.update()` support (GH-23725) https://github.com/python/cpython/commit/a65828717982e6a56382d7aff738478f5b5b25d0 --

[issue42609] Eval with too high string multiplication crashes newer Python versions

2020-12-10 Thread Steve Stagg
Steve Stagg added the comment: Looks like it was introduced by https://github.com/python/cpython/commit/7ea143ae795a9fd57eaccf490d316bdc13ee9065: bpo-29469: Move constant folding to AST optimizer (GH-2858) -- nosy: +stestagg ___ Python tracker

[issue41559] Add support for PEP 612 to typing.py

2020-12-10 Thread Guido van Rossum
Guido van Rossum added the comment: For reference, here's what Pyre has (though it's an older version): https://github.com/facebook/pyre-check/tree/master/pyre_extensions -- ___ Python tracker

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Ethan Furman
Ethan Furman added the comment: Thank you for finding that, Antony. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue42616] C Extensions on Darwin that link against libpython are likely to crash

2020-12-10 Thread Tom Birch
New submission from Tom Birch : After https://github.com/python/cpython/pull/12946, there exists an issue on MacOS due to the two-level namespace for symbol resolution. If a C extension links against libpython.dylib, all symbols dependencies from the Python C API will be bound to libpython.

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Ethan Furman
Ethan Furman added the comment: New changeset efb13be72cbf49edf591936fafb120fe1b7d59f7 by Ethan Furman in branch 'master': bpo-42385: [Enum] add `_generate_next_value_` to StrEnum (GH-23735) https://github.com/python/cpython/commit/efb13be72cbf49edf591936fafb120fe1b7d59f7 --

[issue41877] Check against misspellings of assert etc. in mock

2020-12-10 Thread Václav Brožek
Václav Brožek added the comment: https://github.com/python/cpython/pull/23737 has the initial draft of the check against misspelled arguments. -- ___ Python tracker ___

[issue41877] Check against misspellings of assert etc. in mock

2020-12-10 Thread Václav Brožek
Change by Václav Brožek : -- pull_requests: +22596 pull_request: https://github.com/python/cpython/pull/23737 ___ Python tracker ___

[issue41928] ZipFile does not supports Unicode Path Extra Field (0x7075) zip header field

2020-12-10 Thread Andrea Giudiceandrea
Change by Andrea Giudiceandrea : -- keywords: +patch pull_requests: +22595 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23736 ___ Python tracker

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Ethan Furman
Change by Ethan Furman : -- pull_requests: +22594 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/23735 ___ Python tracker ___

[issue41877] Check against misspellings of assert etc. in mock

2020-12-10 Thread miss-islington
miss-islington added the comment: New changeset 9fc571359af9320fddbe4aa2710a767f168c1707 by vabr-g in branch 'master': bpo-41877: Improve docs for assert misspellings check in mock (GH-23729) https://github.com/python/cpython/commit/9fc571359af9320fddbe4aa2710a767f168c1707 -- nosy:

[issue42385] adjust enum.auto's behavior for StrEnum to return the enum name

2020-12-10 Thread Ethan Furman
Change by Ethan Furman : -- stage: patch review -> needs patch title: Should enum.auto's behavior be adjusted for StrEnum to return the enum name? -> adjust enum.auto's behavior for StrEnum to return the enum name ___ Python tracker

[issue41559] Add support for PEP 612 to typing.py

2020-12-10 Thread Guido van Rossum
Guido van Rossum added the comment: > class X(Generic[T, P]): ... > > 1. X[int, [int, bool]] raises TypeError because second arg isn't a type (this > is easy to fix). How would you fix it? By just allowing it? But then X.__args__ would be unhashable (see the other issue we're working on

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +22593 pull_request: https://github.com/python/cpython/pull/23734 ___ Python tracker ___

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread STINNER Victor
STINNER Victor added the comment: > a simple test with the tools/freeze/hello.py example was successfull with > your patch and the newest cpython from github. Oh great, thanks for your quick feedback! I applied your PR to master and I will backport it to 3.9. --

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread STINNER Victor
STINNER Victor added the comment: New changeset b5c7b38f5ebbc84b5b80192db1743d3e1cdcf4c5 by Victor Stinner in branch 'master': bpo-42591: Export missing Py_FrozenMain() symbol (GH-23730) https://github.com/python/cpython/commit/b5c7b38f5ebbc84b5b80192db1743d3e1cdcf4c5 --

[issue42615] Redundant jump instructions due to deleted unreachable bytecode blocks

2020-12-10 Thread Om G
Change by Om G : -- keywords: +patch pull_requests: +22591 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23733 ___ Python tracker ___

[issue42615] Redundant jump instructions due to deleted unreachable bytecode blocks

2020-12-10 Thread Om G
New submission from Om G : During optimization, the compiler deletes blocks that are marked as unreachable. In doing so, it can render jump instructions that used to jump over the now-deleted blocks redundant, since simply falling through to the next non-empty block is now equivalent. An

[issue41559] Add support for PEP 612 to typing.py

2020-12-10 Thread Ken Jin
Ken Jin added the comment: > and was surprised that C.__parameters__ was (T,) instead of (T, P). Alright, I just fixed that :). I'm now encountering many problems with how typing works which prevent what PEP 612 declare as valid from not throwing an error (these are all examples copied from

[issue30459] PyList_SET_ITEM could be safer

2020-12-10 Thread Petr Viktorin
Petr Viktorin added the comment: > The change respects the documentation which always documented the result type > as "void". Then, IMO, the documentation should be fixed. > My expectation is that apart py-qt4, no project abuse these 3 macros. That's not true; at least ALSA's python

[issue30459] PyList_SET_ITEM could be safer

2020-12-10 Thread STINNER Victor
STINNER Victor added the comment: I checked: commit 0ef96c2b2a291c9d2d9c0ba42bbc1900a21e65f3 is part of Python 3.10.0a3 (released 3 days ago). -- ___ Python tracker ___

[issue30459] PyList_SET_ITEM could be safer

2020-12-10 Thread STINNER Victor
STINNER Victor added the comment: > This change goes directly against PEP 387. The change respects the documentation which always documented the result type as "void". 3.10: https://docs.python.org/dev/c-api/tuple.html#c.PyTuple_SET_ITEM 3.5:

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread Christian Bachmaier
Christian Bachmaier added the comment: Dear Victor, a simple test with the tools/freeze/hello.py example was successfull with your patch and the newest cpython from github. 1. git clone https://github.com/python/cpython.git 2. Applied a patch of your pull request 3. configure, make, amke

[issue42614] Pathlib does not support a Cyrillic character 'й'

2020-12-10 Thread Mihail Kirilov
Mihail Kirilov added the comment: I am uploading an Archive with 1 - mac.png Using a mac I cannot generate the other 'й', but I can load the file, it exists, but .name is wrong. 2 - linux.png Using a linux the exact same thing generates the file not existing. 3 - The file itself. It is

[issue42614] Pathlib does not support a Cyrillic character 'й'

2020-12-10 Thread Steven D'Aprano
Steven D'Aprano added the comment: In addition, you are probably hitting normalization issues. There are two ways to get the Cyrillic character 'й' in your string, one of them is a single code point, the other is two code points: >>> a = 'й' >>> b = 'й' >>> len(a), unicodedata.name(a) (1,

[issue42614] Pathlib does not support a Cyrillic character 'й'

2020-12-10 Thread Steven D'Aprano
Steven D'Aprano added the comment: You are comparing the name with the file extension against the name without the file extension: >>> "Файл на български.ldr" == "Файл на български" False -- nosy: +steven.daprano ___ Python tracker

[issue30459] PyList_SET_ITEM could be safer

2020-12-10 Thread Petr Viktorin
Petr Viktorin added the comment: This change goes directly against PEP 387. -- nosy: +petr.viktorin ___ Python tracker ___ ___

[issue42614] Pathlib does not support a Cyrillic character 'й'

2020-12-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: What platform are you using? -- nosy: +ronaldoussoren ___ Python tracker ___ ___

[issue42614] Pathlib does not support a Cyrillic character 'й'

2020-12-10 Thread Mihail Kirilov
New submission from Mihail Kirilov : I have a file with a Cirilyc name - "Файл на български", which when I load with path.Path and call name on it behaves differently ``` (Pdb) pathlib.Path("/tmp/pytest-of-root/pytest-15/test_bulgarian_name0/data/encoding/Файл на български.ldr").name 'Файл

[issue42612] Software Designer

2020-12-10 Thread hai shi
hai shi added the comment: Hi, Thanks for your report, Deepanshu. Can you upload your code in here? Adding victor in this bpo, MAYBE he can give some suggestions about it. -- nosy: +shihai1991, vstinner ___ Python tracker

[issue42611] PEP 594

2020-12-10 Thread Batuhan Taskaya
Change by Batuhan Taskaya : -- nosy: +BTaskaya ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42613] freeze.py doesn't support sys.platlibdir different than lib nor multiarch

2020-12-10 Thread STINNER Victor
New submission from STINNER Victor : Tools/freeze/freeze.py doesn't support config directory using multiarch nor directory using a sys.platlibdir different than "lib". In short, it doesn't work on Fedora 33 which uses: /usr/lib64/python3.10/config-3.10-x86_64-linux-gnu/ It might be possible

[issue41877] Check against misspellings of assert etc. in mock

2020-12-10 Thread Václav Brožek
Václav Brožek added the comment: https://github.com/python/cpython/pull/23729 is now a follow-up to improve docs and error message about the assert misspellings. I'm now looking at the misspelled arguments: autospec and spec_set. These are accepted by patch, patch.object and patch.multiple,

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread STINNER Victor
STINNER Victor added the comment: I wrote PR 23730 to fix the issue. Would it be possible for you to test it? Since Python 3.9, symbols which are not explicitly exported are no longer exported. Python now uses -fvisibility=hidden. -- ___ Python

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch nosy: +vstinner nosy_count: 1.0 -> 2.0 pull_requests: +22590 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23730 ___ Python tracker

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread Christian Bachmaier
Christian Bachmaier added the comment: The file containing the source code is Python/frozenmain.c . -- ___ Python tracker ___ ___

[issue42591] Method Py_FrozenMain missing in libpython3.9

2020-12-10 Thread Christian Bachmaier
Christian Bachmaier added the comment: The same under Python 3.9.1 (Package from Debian bullseye/testing). As the method Py_FrozenMain is contained in the source code, maybe ist has something to do with the build process, a change in makefile? As far as I can see, the builder of the

[issue41877] Check against misspellings of assert etc. in mock

2020-12-10 Thread Václav Brožek
Change by Václav Brožek : -- pull_requests: +22589 pull_request: https://github.com/python/cpython/pull/23729 ___ Python tracker ___