[issue44859] Improve some sqlite3 errors

2021-08-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 0eec6276fdcdde5221370d92b50ea95851760c72 by Serhiy Storchaka in branch 'main': bpo-44859: Improve error handling in sqlite3 and and raise more accurate exceptions. (GH-27654)

[issue41645] Typo First Page of Documentation

2021-08-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: This is not worth much more energy. Let's either add 'uses' or 'it uses' or close as 'works for me'. Lukasz, do you have a vote either way? I don't care which of us does a PR if we go that way. -- nosy: +lukasz.langa versions: +Python 3.11

[issue41645] Typo First Page of Documentation

2021-08-07 Thread Andrei Kulakov
Andrei Kulakov added the comment: +1 for '... and uses a simple but effective approach ..' -- nosy: +andrei.avk ___ Python tracker ___

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread Senthil Kumaran
Senthil Kumaran added the comment: New changeset 6a6bcf16370beff2e0d1a034661654d5c335b5ee by Miss Islington (bot) in branch '3.9': bpo-44830 - Remove the broken Broken Mozilla devguide link. (GH-27664) (GH-27665)

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread Senthil Kumaran
Change by Senthil Kumaran : -- pull_requests: +26155 pull_request: https://github.com/python/cpython/pull/27666 ___ Python tracker ___

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +26154 pull_request: https://github.com/python/cpython/pull/27665 ___ Python tracker

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread Senthil Kumaran
Senthil Kumaran added the comment: New changeset ebecffdb6d5fffa4249f9a813f1fc1915926feb5 by Senthil Kumaran in branch 'main': bpo-44830 - Remove the broken Broken Mozilla devguide link. (GH-27664) https://github.com/python/cpython/commit/ebecffdb6d5fffa4249f9a813f1fc1915926feb5 --

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread Jack DeVries
Jack DeVries added the comment: I created a discourse thread for people to propose alternatives:: https://discuss.python.org/t/alternate-article-for-how-to-wite-good-bug-report/10040 It's be a good idea to merge @orsenthil's PR which just removes the broken link right away. Then, we can

[issue44830] Broken Mozilla devguide link in "Dealing with Bugs" doc section

2021-08-07 Thread Senthil Kumaran
Change by Senthil Kumaran : -- keywords: +patch nosy: +orsenthil nosy_count: 3.0 -> 4.0 pull_requests: +26153 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27664 ___ Python tracker

[issue40899] Document exceptions raised by importlib.import

2021-08-07 Thread Irit Katriel
Irit Katriel added the comment: ModuleNotFoundError is a subclass of ImportError, so it's probably enough to just document the functions as raising ImportError on failure, as in the case of https://docs.python.org/3/library/importlib.html#importlib.abc.Loader.load_module. --

[issue44861] csv.writer stopped to quote values with escapechar with csv.QUOTE_MINIMAL in Python 3.10

2021-08-07 Thread Sebastian Bank
Sebastian Bank added the comment: The 3.9 behaviour is write: "spam\eggs" The 3.10 behaviour is write: spam\\eggs I think at least the change in csv.QUOTE_MINIMAL behviour should be documented (maybe adding hint to avoid the `escapechar` option for consistent output). --

[issue43526] Programmatic management of BytesWarning doesn't work for native triggers.

2021-08-07 Thread Xavier Morel
Xavier Morel added the comment: > If working Python 3 program suddenly became emitting BytesWarning it will > confuse users. Oh yeah no I meant making it a normal warning, without needing the `-b` flag, not enabling it by default. Because controlling / configuring warnings can be done

[issue44854] Add .editorconfig to the root directory

2021-08-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: I presume 'root directory' mean the repository directory. I would have to think about supporting this in IDLE. It already, I believe (or will), enforces the two whitespace rules when saving and defaults to 4-space indents for first lines of statements.

[issue44863] Allow TypedDict to inherit from Generics

2021-08-07 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch nosy: +python-dev nosy_count: 1.0 -> 2.0 pull_requests: +26152 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27663 ___ Python tracker

[issue44863] Allow TypedDict to inherit from Generics

2021-08-07 Thread Samodya Abey
New submission from Samodya Abey : TypedDict PEP-589 says: A TypedDict cannot inherit from both a TypedDict type and a non-TypedDict base class. So the current implementation has: `if type(base) is not _TypedDictMeta: raise TypeError(...)` This restricts the user from defining generic

[issue33232] Segmentation fault in operator.attrgetter

2021-08-07 Thread Zachary Ware
Zachary Ware added the comment: 3.5 is now EOL, so this is definitely out of date :) -- stage: -> resolved status: pending -> closed ___ Python tracker ___

[issue44819] assertSequenceEqual does not use _getAssertEqualityFunc

2021-08-07 Thread Irit Katriel
Irit Katriel added the comment: Closing as duplicate of issue22452. -- stage: -> resolved status: open -> closed ___ Python tracker ___

[issue22452] addTypeEqualityFunc is not used in assertListEqual

2021-08-07 Thread Irit Katriel
Irit Katriel added the comment: I've closed issue44819 as a duplicate of this. -- nosy: +iritkatriel versions: +Python 3.11 -Python 3.5 ___ Python tracker ___

[issue44862] [docs] make "Deprecated since version {deprecated}, will be removed in version {removed}" translation available

2021-08-07 Thread Vinícius Gubiani Ferreira
New submission from Vinícius Gubiani Ferreira : If we access https://docs.python.org/3.8/library/asyncio-queue.html#asyncio.Queue we can see the text Make Deprecated since version 3.8, will be removed in version 3.10 is perfectly visible in english. However if we change the language to pt-br

[issue10835] sys.executable default and altinstall

2021-08-07 Thread Eryk Sun
Eryk Sun added the comment: In 3.2, the default program name on non-Windows systems was changed to "python3" (see bpo-15020). In 3.5, the code was moved into Python/pylifecycle.c (see bpo-22869). Between 3.7 and 3.8, the initialization code was rewritten (see PEP 587). Currently it's set in

[issue44861] csv.writer stopped to quote values with escapechar with csv.QUOTE_MINIMAL in Python 3.10

2021-08-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The 3.9 behavior is incorrect: write 'spam\\eggs', read 'spameggs'. The 3.10 behavior is correct: write 'spam\\eggs', read 'spam\\eggs'. What is your problem exactly? -- nosy: +serhiy.storchaka ___ Python

[issue43526] Programmatic management of BytesWarning doesn't work for native triggers.

2021-08-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > And though I did not check, I expect the `-b` flag exists mostly because of > the performance impact of the warning any time bytes are checked for > equality, but surely that impact would be limited and probably not very > relevant for the

[issue44851] Update bundled pip to 21.2.3 and setuptools to 57.4.0

2021-08-07 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +26151 pull_request: https://github.com/python/cpython/pull/27657 ___ Python tracker

[issue43526] Programmatic management of BytesWarning doesn't work for native triggers.

2021-08-07 Thread Xavier Morel
Xavier Morel added the comment: And though I did not check, I expect the `-b` flag exists mostly because of the performance impact of the warning any time bytes are checked for equality, but surely that impact would be limited and probably not very relevant for the stringification of bytes

[issue43526] Programmatic management of BytesWarning doesn't work for native triggers.

2021-08-07 Thread Xavier Morel
Xavier Morel added the comment: > I am not against documenting the behavior of -b and BytesWarning clearly. I > don't think that anyone would be against. Just somebody have to provide a PR. Right but what about the ability to enable warning on stringification without enabling the warning on

[issue44840] Nested if/else gets phantom else trace again (3.10)

2021-08-07 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +26150 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27656 ___ Python tracker ___

[issue44861] csv.writer stopped to quote values with escapechar with csv.QUOTE_MINIMAL in Python 3.10

2021-08-07 Thread Sebastian Bank
Sebastian Bank added the comment: IIUC there is no way to work around this from client/downstream code (to get the olf 3.6 to 3.9 behaviour), so this might break assertions on the output of `csv.writer` for users of `escapechar` whenever the data to be written contains the escapcechar (e.g.

[issue38671] pathlib.Path.resolve(strict=False) returns relative path on Windows if the entry does not exist

2021-08-07 Thread Tzu-ping Chung
Tzu-ping Chung added the comment: I think this can be closed now that the PRs are all merged? -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue40912] _PyOS_SigintEvent is never closed on Windows

2021-08-07 Thread Dong-hee Na
Dong-hee Na added the comment: @vstinner https://github.com/python/cpython/blob/ae0a2b756255629140efcbe57fc2e714f0267aa3/Modules/signalmodule.c#L1743 Since _PySignal_Fini close the handle, IMHO we can close this issue. Is there any corner case to handle this? --

[issue44858] sysconfig's posix_user scheme has different platlib value to distutils'

2021-08-07 Thread Tzu-ping Chung
Change by Tzu-ping Chung : -- stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue44861] csv.writer stopped to quote values with escapechar with csv.QUOTE_MINIMAL in Python 3.10

2021-08-07 Thread Sebastian Bank
New submission from Sebastian Bank : AFAICT there was an undocumented change in behaviour related to the fix of https://bugs.python.org/issue12178 (also reported in https://bugs.python.org/issue12178#msg397440): Python 3.9 quotes values with escapechar: ``` import csv import io kwargs =

[issue44860] sysconfig's posix_user scheme has different platlib value to distutils's unix_user

2021-08-07 Thread Tzu-ping Chung
Change by Tzu-ping Chung : -- keywords: +patch pull_requests: +26149 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27655 ___ Python tracker ___

[issue44859] Improve some sqlite3 errors

2021-08-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Entries 3 and 4 are about Cursor.executescript(), not Cursor.execute(). -- ___ Python tracker ___

[issue44859] Improve some sqlite3 errors

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

[issue44860] sysconfig's posix_user scheme has different platlib value to distutils's unix_user

2021-08-07 Thread Tzu-ping Chung
New submission from Tzu-ping Chung : On POSIX, the user scheme has a different 'platlib' location between distutils and sysconfig, dispite the comment claiming they should be the same. This can be reproduced on Fedora 34's stock Python 3.9: $ docker run -it --rm -h=p fedora:34 bash

[issue44859] Improve some sqlite3 errors

2021-08-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There is also a problem with the sqlite3.InterfaceError raised when bind parameters with message "Error binding parameter XXX - probably unsupported type." It is raised not only for unsupported types, but: * For too large integers (outside of the range of

[issue44850] Could operator.methodcaller be optimized using LOAD_METHOD?

2021-08-07 Thread Dennis Sweeney
Dennis Sweeney added the comment: For what it's worth, in my benchmarks on 3.11, methodcaller was already a bit faster than lambda: Builtin calls PS > .\python.bat -m pyperf timeit -s "from operator import methodcaller as mc" -s "reverse_it =

[issue44859] Improve some sqlite3 errors

2021-08-07 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : * MemoryError is now raised instead of sqlite3.Warning when memory is not enough for encoding statement to UTF-8 in Connection.__call__() and Cursor.execute(). * UnicodEncodeError is now raised instead of sqlite3.Warning when statement contains

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread Łukasz Langa
Łukasz Langa added the comment: Confirmed this fixed refleaks in test_typing. Backported to all branches listed on the issue. Thanks for super-effective debugging and the fix, Pablo! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed

[issue44858] sysconfig's posix_user scheme has different platlib value to distutils'

2021-08-07 Thread Tzu-ping Chung
New submission from Tzu-ping Chung : Submitted by accident; please ignore this, sorry for the noise. (I am going to submit this issue properly.) -- resolution: -> duplicate ___ Python tracker

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread miss-islington
miss-islington added the comment: New changeset ac8f72cd3ffa24f53c558911947c42316865683c by Miss Islington (bot) in branch '3.10': bpo-44856: Possible reference leak in error paths of update_bases() and __build_class__ (GH-27647)

[issue44858] sysconfig's posix_user scheme has different platlib value to distutils'

2021-08-07 Thread Tzu-ping Chung
Change by Tzu-ping Chung : -- nosy: uranusjr priority: normal severity: normal status: open title: sysconfig's posix_user scheme has different platlib value to distutils' ___ Python tracker

[issue28973] [doc] The fact that multiprocess.Queue uses serialization should be documented.

2021-08-07 Thread R. David Murray
R. David Murray added the comment: Mentioning ids would be pretty much redundant with mentioning pickle. If it is pickled its id is going to change. I think Davin was suggesting that while the use of serialization is documented, it is not documented *consistently*. Everywhere

[issue44850] Could operator.methodcaller be optimized using LOAD_METHOD?

2021-08-07 Thread Dennis Sweeney
Dennis Sweeney added the comment: Using _PyObject_GetMethod similarly to the way that LOAD_METHOD/CALL_METHOD does seems like a reasonable idea to me -- do you want to make a pull request? It would also be nice to see some microbenchmarks for the change once it's ready. -- nosy:

[issue44524] __name__ attribute in typing module

2021-08-07 Thread Łukasz Langa
Change by Łukasz Langa : -- assignee: -> lukasz.langa status: pending -> open ___ Python tracker ___ ___ Python-bugs-list mailing

[issue44524] __name__ attribute in typing module

2021-08-07 Thread Łukasz Langa
Change by Łukasz Langa : -- priority: release blocker -> normal status: open -> pending ___ Python tracker ___ ___ Python-bugs-list

[issue10835] sys.executable default and altinstall

2021-08-07 Thread Irit Katriel
Irit Katriel added the comment: I can't reproduce this on 3.11, and I don't see a "progname" variable in Python/pythonrun.c. I will close this unless someone will indicate it is still relevant. -- nosy: +iritkatriel resolution: -> out of date status: open -> pending

[issue44524] __name__ attribute in typing module

2021-08-07 Thread Łukasz Langa
Łukasz Langa added the comment: Curiously, while the root cause for the refleaks is in BPO-44856, while hunting down how test_typing.py triggered them, I found that for a while now this exception has been kind of broken: >>> class C(Union[int, str]): ... ... Traceback (most recent call

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset 0a423096e8d8bbe22c0fb0904f7520387a8d4247 by Miss Islington (bot) in branch '3.8': bpo-44856: Possible reference leak in error paths of update_bases() and __build_class__ (GH-27647) (GH-27652)

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset ed718e9b07df06ea1abbe7b34c649e9d610adf86 by Miss Islington (bot) in branch '3.9': bpo-44856: Possible reference leak in error paths of update_bases() and __build_class__ (GH-27647) (GH-27651)

[issue21111] Add a new PyLong_AsUnsignedLongAndOverflow function

2021-08-07 Thread Irit Katriel
Change by Irit Katriel : -- versions: +Python 3.11 -Python 3.5 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue19582] Tkinter is not working with Py_SetPath

2021-08-07 Thread Irit Katriel
Irit Katriel added the comment: This is an old issue and I don't know if it's still relevant. The main problem with this issue is that there isn't enough information to understand what happened. What did you set the path to with Py_SetPath? The error message says it could not find in

[issue6820] Redefinition of HAVE_STRFTIME can cause compiler errors.

2021-08-07 Thread Irit Katriel
Change by Irit Katriel : -- versions: +Python 3.11 -Python 3.4, Python 3.5 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread miss-islington
Change by miss-islington : -- pull_requests: +26147 pull_request: https://github.com/python/cpython/pull/27653 ___ Python tracker ___

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset a40675c659cd8c0699f85ee9ac31660f93f8c2f5 by Pablo Galindo Salgado in branch 'main': bpo-44856: Possible reference leak in error paths of update_bases() and __build_class__ (GH-27647)

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread miss-islington
Change by miss-islington : -- pull_requests: +26146 pull_request: https://github.com/python/cpython/pull/27652 ___ Python tracker ___

[issue44856] Possible reference leak in error paths of update_bases() and __build_class__

2021-08-07 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 1.0 -> 2.0 pull_requests: +26145 pull_request: https://github.com/python/cpython/pull/27651 ___ Python tracker

[issue43838] There is a way to access an underlying mapping in MappingProxyType

2021-08-07 Thread Nick Coghlan
Nick Coghlan added the comment: That resolution makes sense to me as well. Should we make a note in the documentation for https://docs.python.org/3/library/types.html#types.MappingProxyType that the "read-only" protection is to guard against *accidental* modification, not against active

[issue43838] There is a way to access an underlying mapping in MappingProxyType

2021-08-07 Thread Guido van Rossum
Change by Guido van Rossum : -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker ___ ___

[issue44522] [doc] open() function errors='surrogateescape' has inaccurate information

2021-08-07 Thread meowmeowcat
Change by meowmeowcat : -- keywords: +patch pull_requests: +26144 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27650 ___ Python tracker ___

[issue44522] [doc] open() function errors='surrogateescape' has inaccurate information

2021-08-07 Thread meowmeowcat
meowmeowcat added the comment: Thanks! Confirmed by: https://docs.python.org/3/library/codecs.html#error-handlers I'll open a PR for this. -- nosy: +meowmeowmeowcat ___ Python tracker