summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-102541: Hide traceback in help prompt (gh-102614) (gh-105778)Miss Islington (bot)2023-06-152-8/+14
| | | | | | gh-102541: Hide traceback in help prompt (gh-102614) (cherry picked from commit ba516e70c6d156dc59dede35b6fc3db0151780a5) Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
* [3.12] gh-105821: Use a raw f-string in test_httpservers.py (GH-105822) ↵Miss Islington (bot)2023-06-151-2/+2
| | | | | | | | | | (#105824) gh-105821: Use a raw f-string in test_httpservers.py (GH-105822) Use a raw f-string in test_httpservers.py (cherry picked from commit 09ce8c3b48f940eb8865330f029b8069854c3106) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* [3.12] More reorganisation of the typing docs (GH-105787) (#105810)Miss Islington (bot)2023-06-151-101/+117
| | | | | | More reorganisation of the typing docs (GH-105787) (cherry picked from commit da911a6b226ca47cc15088d800b575e19a731f1c) Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] Improve docs for `typing.dataclass_transform` (GH-105792) (#105809)Miss Islington (bot)2023-06-151-37/+69
| | | | | | Improve docs for `typing.dataclass_transform` (GH-105792) (cherry picked from commit 006a4532058f1fadba93283c0f45b0d82735b364) Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] gh-105196: Fix indentations of section headings in C API docs ↵Miss Islington (bot)2023-06-153-6/+6
| | | | | | | | (GH-105672) (#105782) gh-105196: Fix indentations of section headings in C API docs (GH-105672) (cherry picked from commit d32e8d6070057eb7ad0eb2f9d9f1efab38b2cff4) Co-authored-by: TATHAGATA ROY <royzen9495@gmail.com>
* [3.12] gh-105800: Issue SyntaxWarning in f-strings for invalid escape ↵Miss Islington (bot)2023-06-153-3/+8
| | | | | | sequences (GH-105801) (#105806) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* [3.12] Typing docs: move the deprecated stuff below the non-deprecated stuff ↵Alex Waygood2023-06-141-496/+496
| | | | (#105781) (#105783)
* [3.12] gh-105745: Fix open method of webbrowser.Konqueror (GH-105746) (#105777)Miss Islington (bot)2023-06-142-9/+1
| | | | | | gh-105745: Fix open method of webbrowser.Konqueror (GH-105746) (cherry picked from commit e5d45b7444733861153d6e8959c34323fd361322) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* [3.12] gh-105587: Remove assertion from `_PyStaticObject_CheckRefcnt` ↵Miss Islington (bot)2023-06-142-3/+5
| | | | | | | | (GH-105638) (#105769) gh-105587: Remove assertion from `_PyStaticObject_CheckRefcnt` (GH-105638) (cherry picked from commit 6199fe3b3236748033a7ce2559aeddb5a91bbbd9) Co-authored-by: Eddie Elizondo <eduardo.elizondorueda@gmail.com>
* [3.12] gh-105699: Use a Thread-Local Variable for PKGCONTEXT (gh-105740) ↵Miss Islington (bot)2023-06-144-1/+24
| | | | | | | | (gh-105765) This fixes a race during import. The existing _PyRuntimeState.imports.pkgcontext is shared between interpreters, and occasionally this would cause a crash when multiple interpreters were importing extensions modules at the same time. To solve this we add a thread-local variable for the value. We also leave the existing state (and infrequent race) in place for platforms that do not support thread-local variables. (cherry picked from commit b87d2882754a7c273e2695c33384383eba380d7d) Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* [3.12] gh-105387: Limited C API implements Py_INCREF() as func (GH-105388) ↵Miss Islington (bot)2023-06-143-8/+18
| | | | | | | | | | | | (#105763) gh-105387: Limited C API implements Py_INCREF() as func (GH-105388) In the limited C API version 3.12, Py_INCREF() and Py_DECREF() functions are now implemented as opaque function calls to hide implementation details. (cherry picked from commit b542972dc133973a7f0517aa1b61779271789111) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-104812: Run Pending Calls in any Thread (gh-104813) (gh-105752)Eric Snow2023-06-1417-658/+1311
| | | | For a while now, pending calls only run in the main thread (in the main interpreter). This PR changes things to allow any thread run a pending call, unless the pending call was explicitly added for the main thread to run. (cherry picked from commit 757b402)
* [3.12] gh-105436: Ignore unrelated errors when checking empty env ↵Miss Islington (bot)2023-06-131-3/+4
| | | | | | | | (GH-105742) (#105756) gh-105436: Ignore unrelated errors when checking empty env (GH-105742) (cherry picked from commit 4cefe3cf10f498c0927ae4fdba4880d5a64826e4) Co-authored-by: Steve Dower <steve.dower@python.org>
* [3.12] gh-98040: Fix importbench: use types.ModuleType() (GH-105743) (#105754)Miss Islington (bot)2023-06-132-1/+4
| | | | | | | | gh-98040: Fix importbench: use types.ModuleType() (GH-105743) Replace removed imp.new_module(name) with types.ModuleType(name). (cherry picked from commit 457a459c7804950d4c27a243b176eb933ec87a06) Co-authored-by: Victor Stinner <vstinner@python.org>
* [3.12] gh-102613: Bump recursion limit to fix running test_pathlib under ↵Miss Islington (bot)2023-06-131-1/+1
| | | | | | | | Coverage (GH-105744) (#105749) gh-102613: Bump recursion limit to fix running test_pathlib under Coverage (GH-105744) (cherry picked from commit 4e80082723b768df124f77d2b73b3ba6b584a735) Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* [3.12] gh-105603: Change the PyInterpreterConfig.own gil Field (gh-105620) ↵Miss Islington (bot)2023-06-136-16/+40
| | | | | | | | (gh-105731) We are changing it to be more flexible that a strict bool can be for possible future expanded used cases. (cherry picked from commit b97e14a806477af4225777d215ac38c0d9b845f0) Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* [3.12] gh-105718: Fix buffer allocation in tokenizer with readline ↵Miss Islington (bot)2023-06-133-5/+11
| | | | | | (GH-105728) (#105729) Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
* [3.12] gh-105084: Tests: Use setuptools+wheel from ↵Miro Hrončok2023-06-133-33/+67
| | | | | | | | | | sysconfig.get_config_var('WHEEL_PKG_DIR') if set (#105056) (#105424) Includes part of the changes from afa759fb800be416f69e3e9c9b3efe68006316f5, to make this apply. Co-Authored-By: Lysandros Nikolaou <lisandrosnik@gmail.com> (cherry picked from commit bd98b65e974b7a1e086a51e7b55131582f7a0491)
* [3.12] gh-105713: Document that tokenize raises when mixing tabs/spaces ↵Miss Islington (bot)2023-06-131-0/+3
| | | | | | | | | | | (GH-105723) (#105725) * gh-105713: Document that tokenize raises when mixing tabs/spaces * Update Doc/whatsnew/3.12.rst (cherry picked from commit ed8217b493e19cea0f3f539e55b592c09ceb9323) Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] gh-105375: Improve error handling in _Unpickler_SetInputStream() ↵Erlend E. Aasland2023-06-132-13/+20
| | | | | | | | (#105667) (#105720) Prevent exceptions from possibly being overwritten in case of multiple failures. (cherry picked from commit 217589d4f3246d67c6ef0eb0be2b1c33987cf260)
* [3.12] gh-105375: Explicitly initialise all {Pickler,Unpickler}Object fields ↵Miss Islington (bot)2023-06-121-37/+53
| | | | | | | | | | | | (GH-105686) (#105710) All fields must be explicitly initialised to prevent manipulation of uninitialised fields in dealloc. Align initialisation order with the layout of the object structs. (cherry picked from commit ca3cc4b95d66f7527ebe0ba4cdb1907082d9bfc8) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105436: The environment block should end with two null wchar_t ↵Miss Islington (bot)2023-06-123-1/+22
| | | | | | | | values (GH-105495) (#105700) gh-105436: The environment block should end with two null wchar_t values (GH-105495) (cherry picked from commit 4f7d3b602d47d61137e82145f601dccfe6f6cd3c) Co-authored-by: Dora203 <66343334+sku2000@users.noreply.github.com>
* [3.12] gh-103968: PyType_FromMetaclass: Allow metaclasses with tp_new=NULL ↵Miss Islington (bot)2023-06-125-9/+53
| | | | | | | | (GH-105386) (GH-105697) gh-103968: PyType_FromMetaclass: Allow metaclasses with tp_new=NULL (GH-105386) (cherry picked from commit 2b90796be6959d5ef46b38c434a514fce25be971) Co-authored-by: Petr Viktorin <encukou@gmail.com>
* [3.12] ARM64 clamping bug also exists in MSVC 14.35 (GH-105679) (#105695)Miss Islington (bot)2023-06-121-1/+1
| | | | | | ARM64 clamping bug also exists in MSVC 14.35 (GH-105679) (cherry picked from commit 58f0bda34126ed790000451874b96140737f40ed) Co-authored-by: Steve Dower <steve.dower@python.org>
* [3.12] gh-105673: Fix uninitialized warning in sysmodule.c (GH-105674) (#105675)Miss Islington (bot)2023-06-121-1/+1
| | | | | | In sys_add_xoption(), 'value' may be uninitialized for some error paths. (cherry picked from commit a8d69fe92c65d636fc454cfb1825c357eb2e6325) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* [3.12] gh-105375: Harden pyexpat initialisation (#105606) (#105669)Erlend E. Aasland2023-06-112-7/+14
| | | | | | (cherry picked from commit 20a56d8becba1a5a958b167fdb43b1a1b9228095) Add proper error handling to add_errors_module() to prevent exceptions from possibly being overwritten.
* [3.12] gh-105375: Improve error handling in the sys extension module ↵Miss Islington (bot)2023-06-112-6/+20
| | | | | | | | | | (GH-105611) (#105665) In _PySys_AddXOptionWithError() and sys_add_xoption(), bail on first error to prevent exceptions from possibly being overwritten. (cherry picked from commit 41cddc2e93a285b81fa30ac542b088bd9d0112e9) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve error handling in _ctypes (GH-105593) (#105663)Miss Islington (bot)2023-06-112-4/+15
| | | | | | | Prevent repeated PyLong_FromVoidPtr() from possibly overwriting the current exception. (cherry picked from commit e8998e46a7ce8ad336e0941a6da6e50cb88d1e47) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve error handling in PyUnicode_BuildEncodingMap() ↵Miss Islington (bot)2023-06-112-12/+19
| | | | | | | | (GH-105491) (#105661) Bail on first error to prevent exceptions from possibly being overwritten. (cherry picked from commit 555be81026fe1205d16c02f6321221381174cd07) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve PyErr_WarnExplicit() error handling (GH-105610) ↵Miss Islington (bot)2023-06-112-12/+18
| | | | | | | | | (#105659) Bail on first error to prevent exceptions from possibly being overwritten. (cherry picked from commit 567d6ae8e77579173510fc948ac06b2ababf3d40) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve posix error handling (GH-105592) (#105598)Miss Islington (bot)2023-06-112-4/+10
| | | | | | Fix a bug where an IndexError could end up being overwritten. (cherry picked from commit f668f73bc88cce0112b304d87aa998fb28013c71) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] Fix typo in configparser module docstring (GH-105652) (#105653)Miss Islington (bot)2023-06-111-1/+1
| | | | | | | | Fix typo in configparser module docstring (GH-105652) "zc.buildbot" -> "zc.buildout" (cherry picked from commit 845e593c4ec97dd9f73b50536c1e1e7ed10ceecd) Co-authored-by: litlighilit <97860435+litlighilit@users.noreply.github.com>
* [3.12] gh-105375: Improve error handling in the builtins extension module ↵Miss Islington (bot)2023-06-112-8/+34
| | | | | | | (GH-105585) (#105649) (cherry picked from commit d4fa52934a282df51cff800eee5caeb94a229547) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve _decimal error handling (GH-105605) (#105647)Miss Islington (bot)2023-06-112-1/+6
| | | | | | Fix a bug where an exception could end up being overwritten. (cherry picked from commit c932f7284977ebf813313157c52d716ba225a7ac) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Harden _datetime initialisation (GH-105604) (#105645)Miss Islington (bot)2023-06-112-5/+32
| | | | | | Improve error handling so init bails on the first exception. (cherry picked from commit 16d49680b56e00c53c00683b949138e584669fd3) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Harden _ssl initialisation (GH-105599) (#105642)Miss Islington (bot)2023-06-112-5/+13
| | | | | | | Add proper error handling to prevent reference leaks and overwritten exceptions. (cherry picked from commit 01f4230460454d4a849a5ba93320142c1a0c93a8) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve array.array exception handling (GH-105594) (#105644)Miss Islington (bot)2023-06-112-3/+7
| | | | | | Fix a bug where 'tp_richcompare' could end up overwriting an exception. (cherry picked from commit 35cff545db7c7912046c0ce5627db2e4d2b60f57) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-99108: Mention HACL\* in the hashlib docs. (GH-105634) (#105635)Miss Islington (bot)2023-06-101-5/+6
| | | | | | gh-99108: Mention HACL\* in the hashlib docs. (GH-105634) (cherry picked from commit 3a314f7c3df0dd7c37da7d12b827f169ee60e1ea) Co-authored-by: Gregory P. Smith <greg@krypto.org>
* [3.12] Cleanup and clarify our hashlib docs. (GH-105624) (#105632)Miss Islington (bot)2023-06-101-47/+90
| | | | | | | | Cleanup and clarify our hashlib docs. (GH-105624) Clarify and improve our hashlib docs. Now with 50% less mess! (cherry picked from commit 0d1d6ab966ff4e4d651d0dee0ec9a2f868ef42da) Co-authored-by: Gregory P. Smith <greg@krypto.org>
* [3.12] gh-105375: Improve error handling in `zoneinfo` module (GH-105586) ↵Miss Islington (bot)2023-06-092-6/+12
| | | | | | | | | | | (#105612) Fix bugs where exceptions could end up being overwritten because of deferred error handling. (cherry picked from commit 33c92c4f15539806c8aff8574ff30a8b307e3e4d) Co-authored-by: Nikita Sobolev <mail@sobolevn.me> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Harden error handling in `_testcapi/heaptype.c` ↵Miss Islington (bot)2023-06-091-1/+4
| | | | | | | | (GH-105608) (#105615) Bail on first error in heapctypesubclasswithfinalizer_finalize() (cherry picked from commit d636d7dfe714e7168b342c7ea5f9f9d3b3569ed0) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] Docs: fix formatting in 2023-06-09-12-59-18 NEWS item (GH-105607) ↵Miss Islington (bot)2023-06-091-2/+2
| | | | | | | (#105614) (cherry picked from commit 91441bf7cbaefbd328ee7efa59a06e661f61542e) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105549: Tokenize separately NUMBER and NAME tokens and allow ↵Miss Islington (bot)2023-06-093-3/+45
| | | | | | 0-prefixed literals (GH-105555) (#105602) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* [3.12] gh-105375: Improve error handling in _elementtree (GH-105591) (#105600)Miss Islington (bot)2023-06-092-3/+8
| | | | | | Fix bugs where exceptions could end up being overwritten. (cherry picked from commit 00b599ab5a76023fa0083d7cc5d3c569342a5191) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105375: Improve errnomodule error handling (#105590) (#105596)Erlend E. Aasland2023-06-092-2/+6
| | | | | | (cherry picked from commit eede1d2f48b4fe7f7918952d9ebeb744b58668c1) Bail immediately if an exception is set, to prevent exceptions from being overwritten.
* [3.12] gh-105375: Improve _pickle error handling (#105475) (#105584)Erlend E. Aasland2023-06-092-12/+28
| | | | | | (cherry picked from commit 89aac6f6b7b3af046ec137121c90732289e79efc) Error handling was deferred in some cases, which could potentially lead to exceptions being overwritten.
* [3.12] gh-105375: Improve error handling in compiler_enter_scope() ↵Miss Islington (bot)2023-06-092-1/+6
| | | | | | | (GH-105494) (#105581) (cherry picked from commit 6c832ddcf28187f86100c790afb16a0223d945d0) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105557: Remove duplicate sqlite3 test method (GH-105558) (#105561)Miss Islington (bot)2023-06-091-7/+2
| | | | | | | test_func_return_too_large_int() was defined twice. Keep only the redefined method, as that also checks the tracebacks. (cherry picked from commit b8fa7bda4f286503447dc12327b789bbfc836458) Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-105564: Don't include artificial newlines in the line attribute of ↵Miss Islington (bot)2023-06-093-8/+13
| | | | | | tokens (GH-105565) (#105579) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* [3.12] Clarify the supported cases in the tokenize module (GH-105569) (#105573)Miss Islington (bot)2023-06-091-0/+9
| | | | Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>