[issue40701] tempfile mixes str and bytes in an inconsistent manner

2021-04-10 Thread Łukasz Langa
Łukasz Langa added the comment: Sorry, I decided not to take this. We're four bugfix releases into 3.9 and there is non-zero chance somebody relies on existing behavior somehow. Marking this as changing with 3.10.0 is cleaner from an end user standpoint. -- priority: release blocker

[issue43475] Worst-case behaviour of hash collision with float NaN

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: Mark, is there any reason hash(float('NaN')) and hash(Decimal('NaN')) have to be a constant? Since NaNs don't compare equal, the hash homomorphism has no restrictions. Why not have hash() return the id() like we do for instances of object? I

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: "cannot assign to name" looks wrong. Usually we can assign to name, unless it is a keyword. And the problem is not that we cannot assign to name (we can), but that is is an invalid syntax, assignment is a statement, not an expression. Seems it handles

[issue43715] curses inch() and scrbkgd() documentation ommissions

2021-04-10 Thread Peter J. Farley III
Peter J. Farley III added the comment: Sorry, this was not meant as a patch. I have no experience with git or pulls and would not know where to start to do as you have asked. The text I provided was intended as model text for the python documentation maintainer to type into whatever piece of

[issue43784] starting a thread in __del__ hangs at interpreter shutdown

2021-04-10 Thread Eryk Sun
Eryk Sun added the comment: > my subrocess code doesn't seem to hang on Linux where the > thread example code does? Reader threads for stdout and stderr are only used in Windows, since there's no equivalent to select/poll for synchronous pipes in Windows. Without using threads, I/O with

[issue43716] curses.pair_number() function incorrect value under Windows

2021-04-10 Thread Peter J. Farley III
Peter J. Farley III added the comment: Thank you for responding. I will pursue the issue with the windows-curses and/or PDCurses team. Peter On Wed, Apr 7, 2021 at 12:57 PM Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > The curses module is not supported on Windows.

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I tried to add | a=NAME '=' { RAISE_SYNTAX_ERROR_KNOWN_LOCATION( a, "invalid syntax. Maybe you meant '==' or ':=' instead of '='?") } | a=bitwise_or '=' { RAISE_SYNTAX_ERROR_KNOWN_LOCATION( a, "invalid syntax.

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Shreyan Avigyan
Shreyan Avigyan added the comment: I've signed the PSF CLA (as it is required) now. Please have a review. -- ___ Python tracker ___

[issue43475] Worst-case behaviour of hash collision with float NaN

2021-04-10 Thread Mark Dickinson
Mark Dickinson added the comment: > Why not have hash() return the id() like we do for instances of object? I think that's fine, and IIUC that's what Cong Ma was proposing. It seems like the least invasive potential fix. In principle I find the idea of making NaN a singleton rather

[issue43799] OpenSSL 3.0.0: define OPENSSL_API_COMPAT 1.1.1

2021-04-10 Thread Christian Heimes
Change by Christian Heimes : -- keywords: +patch pull_requests: +24062 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25329 ___ Python tracker

[issue43800] os.fwalk is not exposed on macOS

2021-04-10 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +ned.deily, ronaldoussoren ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Bob Kline
Bob Kline added the comment: Sorry, it's still failing with the same error message. -- status: closed -> open ___ Python tracker ___

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Shreyan Avigyan
Shreyan Avigyan added the comment: I've managed to overcome the "HEAD Detached" problem I was facing when switching to the 3.9, 3.8, 3.7 and 3.6 branches. So I'm also submitting the PRs for those documentation versions. -- ___ Python tracker

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Shreyan Avigyan
Change by Shreyan Avigyan : -- pull_requests: +24063 pull_request: https://github.com/python/cpython/pull/25330 ___ Python tracker ___

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: Are there other cases where suppressing one thing affects others? -- ___ Python tracker ___

[issue43753] [C API] Add Py_Is(x, y) and Py_IsNone(x) functions

2021-04-10 Thread STINNER Victor
STINNER Victor added the comment: New changeset 09bbebea163fe7303264cf4069c51d4d2f22fde4 by Victor Stinner in branch 'master': bpo-43753: Add Py_Is() and Py_IsNone() functions (GH-25227) https://github.com/python/cpython/commit/09bbebea163fe7303264cf4069c51d4d2f22fde4 --

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: LGTM -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Change by Eric V. Smith : -- keywords: +patch pull_requests: +24072 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/25337 ___ Python tracker

[issue43801] Carriage Return problem in version v3.9.0:9cf6752

2021-04-10 Thread Steven D'Aprano
Steven D'Aprano added the comment: Hello Santosh, In future, please don't post images or screen shots of text, please copy and paste the text of your code. You have something similar to this: >>> text = "short line\rvery long line of text" >>> print(text) very long line of text but you

[issue40137] TODO list when PEP 573 "Module State Access from C Extension Methods" will be implemented

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Here are some benchmarks of using lru_cache in 3.9 and 3.10 (PGO/LTO/CPU isol): ❯ ./python -m pyperf timeit "from functools import lru_cache; f = lru_cache(lambda: 42)" "f()" --compare-to ../3.9/python /home/pablogsal/github/3.9/python:

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: New changeset 750f484752763fe9ac1d6455780aabcb67f25508 by Eric V. Smith in branch 'master': bpo-43764: Add match_args=False parameter to dataclass decorator and to make_dataclasses function. (GH-25337)

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Change by Eric V. Smith : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43770] Rework C types initialization

2021-04-10 Thread STINNER Victor
STINNER Victor added the comment: New changeset ecf14e6557c6e4f7af9c0d6460d31fe121c22553 by Victor Stinner in branch 'master': bpo-43770: Refactor type_new() function (GH-25325) https://github.com/python/cpython/commit/ecf14e6557c6e4f7af9c0d6460d31fe121c22553 --

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 6e468cb16bde483ad73c1eb13b20a08d74e30846 by Pablo Galindo in branch 'master': bpo-43478: Fix formatting of NEWS entry (GH-25335) https://github.com/python/cpython/commit/6e468cb16bde483ad73c1eb13b20a08d74e30846 --

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: Here's a question. If __init__ is not being generated, either because the user supplied one to this class, or if init=False is specified, should __match_args__ be generated? I think the answer should be no, since the code has no idea what the parameters to

[issue43770] Rework C types initialization

2021-04-10 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +24070 pull_request: https://github.com/python/cpython/pull/25336 ___ Python tracker ___

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: There may be other reasons why `__init__` is not desired, and there's no absolute requirement that `__match_args__` must match the constructor -- only a convention. I'd say don't tie them together. -- ___ Python

[issue43753] [C API] Add Py_Is(x, y) and Py_IsNone(x) functions

2021-04-10 Thread STINNER Victor
STINNER Victor added the comment: Carl: > Just chiming in to say that for PyPy this API would be extremely useful, > because PyPy's "is" is not implementable with a pointer comparison on the C > level (due to unboxing we need to compare integers, floats, etc by value). > Right now, C

[issue41974] Remove complex.__float__, complex.__floordiv__, etc

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset ac05f82ad4983e3d3653ae7494c1ff62c4a265fc by DevilXD in branch 'master': bpo-41974: Remove part of the note regarding complex.__float__ (GH-25197) https://github.com/python/cpython/commit/ac05f82ad4983e3d3653ae7494c1ff62c4a265fc --

[issue43802] Seg fault on macOS using multiprocessing.JoinableQueue

2021-04-10 Thread Ned Deily
Ned Deily added the comment: Thanks for providing a detailed and relatively simple-to-run test case for such a complicated failure. Not totally surprising for what appears to likely be a race condition, I have been unable to reproduce it under several macOS environments including in a

[issue43776] Popen with shell=True yield mangled repr output

2021-04-10 Thread mkocher
Change by mkocher : -- keywords: +patch pull_requests: +24073 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25338 ___ Python tracker ___

[issue43475] Worst-case behaviour of hash collision with float NaN

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

[issue40137] TODO list when PEP 573 "Module State Access from C Extension Methods" will be implemented

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: As a Release Manager, I am not very happy with a 6% reduction in speed, especially in these functions. Can someone take a look to see if we can get the performance closer to Python 3.9? -- ___ Python

[issue43803] ctypes string_at/wstring_at

2021-04-10 Thread Tal Hayon
New submission from Tal Hayon : string_at and wstring_at first argument in docs in address but actually in code is ptr. See https://github.com/python/cpython/blob/750f484752763fe9ac1d6455780aabcb67f25508/Lib/ctypes/__init__.py#L513

[issue43803] ctypes string_at/wstring_at bad argument name

2021-04-10 Thread Tal Hayon
Change by Tal Hayon : -- title: ctypes string_at/wstring_at -> ctypes string_at/wstring_at bad argument name ___ Python tracker ___

[issue43803] ctypes string_at/wstring_at bad argument name

2021-04-10 Thread Jelle Zijlstra
Jelle Zijlstra added the comment: It's a bit worse: the actual name is "ptr", the function docstrings say "addr", and the documentation (https://docs.python.org/3.9/library/ctypes.html#ctypes.string_at) has "address". I'd favor updating them all to say "ptr", because changing the name of

[issue43800] os.fwalk is not exposed on macOS

2021-04-10 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- nosy: +erlendaasland ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43798] Add position metadata to alias AST type

2021-04-10 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: > Are there other cases where suppressing one thing affects others? Only the complex interactions among the unsafe_hash, eq, and frozen parameters. It feels like if __init__ is not being generated, then the @dataclass code would have no idea what it should

[issue39125] Type signature of @property not shown in help()

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: > Currently there is no way to tell if the *attribute* > is read-only, read-write or write-only. Read-only is segregated in the help() output. >>> class A: @property def computed_field(self): 'An example property'

[issue40137] TODO list when PEP 573 "Module State Access from C Extension Methods" will be implemented

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: State lookups and indirections were added to most performance sensitive code part of the _functools_state *state; state = get_functools_state_by_type(Py_TYPE(self)); if (state == NULL) { return NULL; } key =

[issue43783] Make ParamSpec.args/kwargs more useful objects

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset 522433601a5c64603dab3d733f41a5db39d237eb by Jelle Zijlstra in branch 'master': bpo-43783: Add ParamSpecArgs/Kwargs (GH-25298) https://github.com/python/cpython/commit/522433601a5c64603dab3d733f41a5db39d237eb --

[issue43783] Make ParamSpec.args/kwargs more useful objects

2021-04-10 Thread Guido van Rossum
Change by Guido van Rossum : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43772] Minor repr error in typing.TypeVar.__ror__()

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: New changeset 9045919bfa820379a66ea67219f79ef6d9ecab49 by Jelle Zijlstra in branch 'master': bpo-43772: Fix TypeVar.__ror__ (GH-25339) https://github.com/python/cpython/commit/9045919bfa820379a66ea67219f79ef6d9ecab49 --

[issue43772] Minor repr error in typing.TypeVar.__ror__()

2021-04-10 Thread Guido van Rossum
Change by Guido van Rossum : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43795] Implement PEP 652 -- Maintaining the Stable ABI

2021-04-10 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- nosy: +erlendaasland ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43798] Add position metadata to alias AST type

2021-04-10 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: New changeset 75a06f067bd0a2687312e5f8e78f9075be76ad3a by Matthew Suozzo in branch 'master': bpo-43798: Add source location attributes to alias (GH-25324) https://github.com/python/cpython/commit/75a06f067bd0a2687312e5f8e78f9075be76ad3a --

[issue43800] os.fwalk is not exposed on macOS

2021-04-10 Thread Ned Deily
Ned Deily added the comment: Thank you for the report. The issue is that the necessary operating system support for opening with a file descriptor, openat, was only first implemented in macOS 10.10 (see man 2 openat) and, up until recently, all python.org macOS binaries were built on 10.9

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- nosy: +pablogsal nosy_count: 8.0 -> 9.0 pull_requests: +24069 pull_request: https://github.com/python/cpython/pull/25335 ___ Python tracker

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: I can go either way. It's easy enough for the user to add their own __match_args__, so I won't link them. Here's what I have for the documentation, which is why the issue came up: - ``match_args``: If true (the default is ``True``), the

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +vstinner nosy_count: 9.0 -> 10.0 pull_requests: +24071 pull_request: https://github.com/python/cpython/pull/25227 ___ Python tracker ___

[issue43654] IDLE: Applying settings disables tab completion

2021-04-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: I presume '^' means 'hit Tab'. The underlying Python problem is that namespaces are conceptually mappings of names (identifiers), a subset of strings, to objects. Python specifies that the global namespace is a dict, which I believe could mean a dict

[issue43772] Minor repr error in typing.TypeVar.__ror__()

2021-04-10 Thread Jelle Zijlstra
Change by Jelle Zijlstra : -- keywords: +patch nosy: +Jelle Zijlstra nosy_count: 4.0 -> 5.0 pull_requests: +24074 stage: test needed -> patch review pull_request: https://github.com/python/cpython/pull/25339 ___ Python tracker

[issue43802] Seg fault on macOS using multiprocessing.JoinableQueue

2021-04-10 Thread Jacob Walls
Jacob Walls added the comment: Thanks for this detailed reply. I reproduced on Python 3.9.4 on the same iMac from my original report running macOS 10.13.6, but with much lesser frequency (I wouldn't use the word "consistently" anymore). I tried on a MacBook Pro with worn-out hardware

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Shreyan Avigyan
Change by Shreyan Avigyan : -- pull_requests: +24065 pull_request: https://github.com/python/cpython/pull/25331 ___ Python tracker ___

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Bob Kline
Bob Kline added the comment: Super, thanks! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43714] re.findall: '\Z' must consume end of string if it matched

2021-04-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I concur with Matthew. I tested several implementations in different programming languages. Perl, PHP and Java behave the same way as Python. Sed, awk and Go behave other way. We can argue that one or other way is "better", but it looks subjective, and in

[issue43682] Make static methods created by @staticmethod callable

2021-04-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > Do you see a way to make C functions and Python functions behave the same? Implement __get__ for C functions. Of course it is breaking change so we should first emit a warning. It will force all users to use staticmethod explicitly if they set a C

[issue43800] os.fwalk is not exposed on macOS

2021-04-10 Thread ntninja
New submission from ntninja : Is has come to my attention that the `os.fwalk` function has been missing from the standard library on Python for macOS since 3.6, even though macOS should support the necessary OS-interfaces (as specified in POSIX.1-2008) to support that function it just

[issue43799] OpenSSL 3.0.0: define OPENSSL_API_COMPAT 1.1.1

2021-04-10 Thread Christian Heimes
New submission from Christian Heimes : OpenSSL 1.1 introduced the macro OPENSSL_API_COMPAT to select which APIs are exposed and which deprecation warnings are shown. https://www.openssl.org/docs/manmaster/man7/OPENSSL_API_COMPAT.html "#define OPENSSL_API_COMPAT 0x10101000L" suppresses

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-10 Thread Adrian Freund
Adrian Freund added the comment: I think for namedtuple a short mention in the opening paragraph, where it also mentions the generation of a docstring and __repr__ method should be enough. -- ___ Python tracker

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread Shreyan Avigyan
Change by Shreyan Avigyan : -- nosy: +shreyanavigyan nosy_count: 8.0 -> 9.0 pull_requests: +24064 pull_request: https://github.com/python/cpython/pull/25207 ___ Python tracker

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Mariatta
Mariatta added the comment: Thanks for the report. I've identified the problem and fixed it. It should be working now. Further issues with it can be filed at https://github.com/Mariatta/check_python_cla/issues Thanks. -- assignee: -> Mariatta components: -Demos and Tools

[issue43801] Carriage Return problem in version v3.9.0:9cf6752

2021-04-10 Thread Santosh Kumbhar
New submission from Santosh Kumbhar : Carriage return \r provide incorrect result -- components: Interpreter Core files: CarriageReturn_Issue.JPG messages: 390714 nosy: skumbhar priority: normal severity: normal status: open title: Carriage Return problem in version v3.9.0:9cf6752

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Bob Kline
Bob Kline added the comment: I can, if you prefer, close this ticket and create a new one on GitHub (even though this is the same issue, not a different "further" issue). -- ___ Python tracker

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread Shreyan Avigyan
Change by Shreyan Avigyan : -- pull_requests: -24064 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43478] Disallow Mock spec arguments from being Mocks

2021-04-10 Thread Shreyan Avigyan
Change by Shreyan Avigyan : -- nosy: -shreyanavigyan ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Bob Kline
Bob Kline added the comment: To reproduce, enter "bkline" in the GitHub username field and press Check. -- ___ Python tracker ___

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Shreyan Avigyan
Shreyan Avigyan added the comment: Thanks Mariatta. It works now. I'm able to check if I've signed the CLA now. Thanks a lot. -- ___ Python tracker ___

[issue43790] CLA check fails with a 500 error

2021-04-10 Thread Bob Kline
Bob Kline added the comment: And now it's working for me as well. Thanks, @Mariatta. -- resolution: third party -> fixed status: open -> closed ___ Python tracker ___

[issue37251] Mocking a MagicMock with a function spec results in an AsyncMock

2021-04-10 Thread Gregory P. Smith
Change by Gregory P. Smith : -- resolution: fixed -> stage: resolved -> needs patch status: closed -> open ___ Python tracker ___

[issue40701] tempfile mixes str and bytes in an inconsistent manner

2021-04-10 Thread Gregory P. Smith
Change by Gregory P. Smith : -- pull_requests: +24068 pull_request: https://github.com/python/cpython/pull/25334 ___ Python tracker ___

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > in invalid_named_expression, but it does not have any effect. That is because the rule for named_expressions are: named_expression[expr_ty]: | a=NAME ':=' ~ b=expression | expression !':=' | invalid_named_expression and the second

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: > Do you need anything from me here? No, I don't think so. Thanks. -- ___ Python tracker ___ ___

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: I don't think we need control at the field level here. Omitting one field is just going to cause confusion. -- ___ Python tracker ___

[issue42737] PEP 563: drop annotations for complex assign targets

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: Hm, reading the thread it's not 100% clear to me what you are proposing to do in your patch, since different people seem to have proposed different things. I think I'd be okay if `foo[bar]: baz` and `foo.bar: baz` (etc.) didn't generate any bytecode at

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Shreyan Avigyan
Shreyan Avigyan added the comment: Documentation versions older than 3.8 describes a different approach to import the module. Therefore those documentation versions are not to be messed with. I've attached the PRs for documentation versions 3.10, 3.9 and 3.8. Please anyone have a review of

[issue43737] Documentation of modulo operator should document behaviour clearly when second operator is negative

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: I just checked with another Python expert who reported: """ I have never once in my whole life seen or used a negative modulo. And that says a lot given that 6 years of it was spent studying math. Including a few years in a math PhD program. Perhaps my

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread miss-islington
Change by miss-islington : -- pull_requests: +24067 pull_request: https://github.com/python/cpython/pull/25333 ___ Python tracker ___

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset ea9b2d631902238acf69e51af6e3d308567b5dfd by Shreyan Avigyan in branch 'master': bpo-43739: Add type declaration Doc/extending/extending.rst example https://github.com/python/cpython/commit/ea9b2d631902238acf69e51af6e3d308567b5dfd

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +24066 pull_request: https://github.com/python/cpython/pull/25332 ___ Python tracker

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: So, should we reopen this ad add the flag to suppress __match_args__ generation after all? -- ___ Python tracker ___

[issue40701] tempfile mixes str and bytes in an inconsistent manner

2021-04-10 Thread Gregory P. Smith
Gregory P. Smith added the comment: New changeset e05a703848473b0365886dcc593cbddc46609f29 by Gregory P. Smith in branch 'master': bpo-40701: doc typo historcal -> historical (GH-25334) https://github.com/python/cpython/commit/e05a703848473b0365886dcc593cbddc46609f29 --

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: These are good points, let me investigate a bit -- ___ Python tracker ___ ___

[issue43654] IDLE: Applying settings disables tab completion

2021-04-10 Thread Mikhail
Mikhail added the comment: I did a little experiment, and it turned out that the problem is not in the IDLE, but inside Python itself. With this case, the same behavior remains inside the terminal version of Python, and IPython also produces a similar error. --

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: Okay, I'll re-open this to just add @dataclass(match_args=False). -- resolution: rejected -> stage: resolved -> needs patch status: closed -> open ___ Python tracker

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Raymond Hettinger
Change by Raymond Hettinger : -- nosy: +scoder ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-10 Thread Eric V. Smith
Eric V. Smith added the comment: > So, should we reopen this ad add the flag to suppress __match_args__ > generation after all? I think so, although I'm still contemplating it. I can't decide if we should also add match_arg=False to field(). Or is it good enough to just tell the user to

[issue43682] Make static methods created by @staticmethod callable

2021-04-10 Thread STINNER Victor
STINNER Victor added the comment: > Implement __get__ for C functions. Of course it is breaking change so we > should first emit a warning. It will force all users to use staticmethod > explicitly if they set a C function as a class attribute. We can also start > emitting warnings for all

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset 3a3c0464bd719a8cac6e52b02a3479b2834b88a4 by Miss Islington (bot) in branch '3.8': bpo-43739: Add type declaration Doc/extending/extending.rst example (GH-25332)

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset 28fb2d1c4dbf16b05acfb20d457b08e049a7c83f by Miss Islington (bot) in branch '3.9': bpo-43739: Add type declaration Doc/extending/extending.rst example (GH-25333)

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-10 Thread Guido van Rossum
Guido van Rossum added the comment: Do you need anything from me here? -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- nosy: +lys.nikolaou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43792] Cython is not compatible with Python 3.10 yet: "SystemError: bad argument to internal function"

2021-04-10 Thread STINNER Victor
STINNER Victor added the comment: This issue is a bug in Cython, not in Python. I close it. -- resolution: -> third party stage: -> resolved status: open -> closed ___ Python tracker

[issue43802] Seg fault on macOS using multiprocessing.JoinableQueue

2021-04-10 Thread Jacob Walls
New submission from Jacob Walls : macOS 10.13.6 Python 3.9.2 I can consistently reproduce a seg fault while using multiprocessing.JoinableQueue in Python 3.9.2. My use case is the sheet music processing library music21. My fork includes a folder of 209 files I use to reproduce, running 3

[issue43739] Fixing the example code in Doc/extending/extending.rst to declare and initialize the pmodule variable to be of the right type.

2021-04-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: Thanks for the PR -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43797] Improve syntax error for invalid comparisons

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I have updated the PR with: * Works for while statements (we can make it work for other kinds of statements but is a bit tricky because those have different grammar paths. We could do this in other PRs. * I changed the error message for when the LHS

[issue43654] IDLE: Applying settings disables tab completion

2021-04-10 Thread Mikhail
Mikhail added the comment: Hello again! I found another kind of bug, where the autosupplement window doesn't show up. In order for the bug to occur, you need to put a non-string value into `locals()`. Example: ``` locals()['arg'] = 123 # or locals().setdefault('arg', 123) # ^ it's okay

[issue43751] await anext() returns None when default is given

2021-04-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset dfb45323ce8a543ca844c311e32c994ec9554c1b by Dennis Sweeney in branch 'master': bpo-43751: Fix anext() bug where it erroneously returned None (GH-25238) https://github.com/python/cpython/commit/dfb45323ce8a543ca844c311e32c994ec9554c1b

[issue43751] await anext() returns None when default is given

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

  1   2   >