Commit graph

113711 commits

Author SHA1 Message Date
Vinay Sajip
49aeda989d
[3.11] gh-92897: Ensure venv --copies respects source build property of the creating interpreter (GH-92899) (GH-94567)
(cherry picked from commit 067597522a)

Co-authored-by: Jeremy Kloth <jeremy.kloth@gmail.com>
2022-07-05 16:40:17 +01:00
Miss Islington (bot)
7a3dae06eb
Docs: Convert PEP 630 (Isolating Extension Modules) to a HOWTO (GH-94489) (GH-94566)
Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Petr Viktorin <encukou@gmail.com>

(cherry picked from commit e6ec6f5b50)
2022-07-05 17:20:03 +02:00
Miss Islington (bot)
d49159bd9f
[3.11] bpo-46755: Don't log stack info twice in QueueHandler (GH-31355) (GH-94564)
Co-authored-by: Erik Montnemery <erik@montnemery.com>
2022-07-05 15:49:05 +01:00
Łukasz Langa
1bfe83a114
[3.11] gh-94485: Set line number of module's RESUME instruction to 0 as specified by PEP 626 (GH-94552) (GH-94562)
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Co-authored-by: Mark Shannon <mark@hotpy.org>

(cherry picked from commit 324d01944d)
2022-07-05 16:01:24 +02:00
Miss Islington (bot)
0615e7f9bb
gh-84753: Clarify change made to inspect functions (GH-94554) (GH-94560)
(cherry picked from commit a2a3f2c541)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2022-07-05 14:35:09 +02:00
Miss Islington (bot)
e28446858f
gh-94538: Fix Argument Clinic output to custom file (GH-94539) (GH-94555)
(cherry picked from commit 2b8ed4d3d4)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
2022-07-05 14:33:59 +02:00
Miss Islington (bot)
77bf973930
Docs: remove redundant "adverb-adjective" hyphens from compound modifiers (GH-94551) (GH-94557)
Discussion: https://discuss.python.org/t/slight-grammar-fix-throughout-adverbs-dont-need-hyphen/17021
(cherry picked from commit 3440d197a5)

Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
2022-07-05 14:30:19 +02:00
Miss Islington (bot)
99a06685d4
gh-93626: Set the release for __future__.annotations to None (GH-93628) (GH-94553)
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>
(cherry picked from commit 4791a8a835)

Co-authored-by: KotlinIsland <65446343+KotlinIsland@users.noreply.github.com>
2022-07-05 11:16:32 +02:00
Miss Islington (bot)
68f5fa6683
[3.11] GH-94262: Don't create frame objects for frames that aren't yet complete. (GH-94371) (#94482)
Co-authored-by: Mark Shannon <mark@hotpy.org>
2022-07-04 19:43:12 +01:00
Vinay Sajip
8fe0b1d8fa
[3.11] Update logging documentation: change cross-reference and add webapp r… (GH-94541) 2022-07-04 09:09:40 +01:00
Miss Islington (bot)
1e7efbc449
IDLE doc: Tweek RESTART and Windows console start (GH-94530)
(cherry picked from commit 39c29f753e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-07-03 10:20:48 -07:00
Miss Islington (bot)
abf5f5c5d7
gh-81054: Document that SimpleHTTPRequestHandler follows symbolic links (GH-94416) (GH-94492)
(cherry picked from commit 80aaeabb8b)

Co-authored-by: Sam Ezeh <sam.z.ezeh@gmail.com>
2022-07-01 18:41:24 +02:00
Miss Islington (bot)
227e0d69ed
gh-75372: Specify major version in README for installation (GH-92759) (GH-94487)
(cherry picked from commit 3abda7a38a)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2022-07-01 18:22:02 +02:00
Miss Islington (bot)
1b46df1e3d
Update code sample when importing modules in queue doc (GH-94244) (GH-94490)
In the queue documentation, the code snippet shows the import to be not PEP 8 compliant.

Since people typically copy-paste from such code samples, I think it's important to show best-practices here.
(cherry picked from commit ad55147c1d)

Co-authored-by: Mariatta Wijaya <Mariatta@users.noreply.github.com>
2022-07-01 18:14:39 +02:00
Jason R. Coombs
c4f82ea0de
[3.11] gh-93975: Provide nicer error reporting from subprocesses in test_venv.EnsurePipTest.test_with_pip (GH-93959) (GH-94003)
This change does three things:

1. Extract a function for trapping output in subprocesses.
2. Emit both stdout and stderr when encountering an error.
3. Apply the change to `ensurepip._uninstall` check.
(cherry picked from commit 6066f450b9)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
2022-07-01 17:32:56 +02:00
Mark Shannon
02b30a8ef8
[3.11] GH-94438: Backport GH-94444 (#94486)
* Account for NULLs on evaluation stack when jumping lines.
2022-07-01 15:44:30 +01:00
Miss Islington (bot)
9fa966136f
gh-84461: Tool/wasm/python.html: Add subresource integrity hashes (GH-93953)
(cherry picked from commit 1df9449db2)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2022-07-01 03:17:38 -07:00
Miss Islington (bot)
ca58ca8641
gh-84461: Improve WebAssembly in-browser demo (GH-91879)
* Buffer standard input line-by-line

* Add non-root .editorconfig for JS & HTML indent

* Add support for clearing REPL with CTRL+L

* Support unicode in stdout and stderr

* Remove \r\n normalization

* Note that local .editorconfig file extends root

* Only normalize lone \r characters (convert to \n)

* Skip non-printable characters in buffered input

* Fix Safari bug (regex lookbehind not supported)

Co-authored-by: Christian Heimes <christian@python.org>
(cherry picked from commit a8e333d79a)

Co-authored-by: Trey Hunner <trey@treyhunner.com>
2022-07-01 03:16:25 -07:00
Mark Shannon
113b309f18
[3.11] GH-93354: Use exponential backoff to avoid excessive specialization attempts (GH-93355) (GH-93379)
Co-authored-by: Mark Shannon <mark@hotpy.org>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2022-06-30 23:03:37 +02:00
Miss Islington (bot)
6c40538191
multiprocessing.spawn doc: Capitalize the p in "Python" (gh-94462)
(cherry picked from commit 62bb7a3b50)

Co-authored-by: Mariatta Wijaya <Mariatta@users.noreply.github.com>
2022-06-30 11:23:14 -07:00
Miss Islington (bot)
9ebec7d46c
gh-84753: Make inspect.iscoroutinefunction() work with AsyncMock (GH-94050) (GH-94460)
The inspect version was not working with unittest.mock.AsyncMock.

The fix introduces special-casing of AsyncMock in
`inspect.iscoroutinefunction` equivalent to the one
performed in `asyncio.iscoroutinefunction`.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 4261b6bffc)

Co-authored-by: Mehdi ABAAKOUK <sileht@sileht.net>
2022-06-30 20:04:42 +02:00
Miss Islington (bot)
7fe949e5ea
GH-94398: TaskGroup: Fail create_task() during shutdown (GH-94400) (GH-94463)
Once the task group is shutting down, it should not be possible to create a new task.
Here "shutting down" means `self._aborting` is set, indicating that at least one task
has failed and we have cancelled all others.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 594c369949)

Co-authored-by: Guido van Rossum <guido@python.org>
2022-06-30 20:02:42 +02:00
Miss Islington (bot)
aed28b7feb
xml.dom.minidom docs: fix typo (GH-93437)
(cherry picked from commit 639e35108b)

Co-authored-by: Jean-Christophe Helary <jean.christophe.helary@traduction-libre.org>
2022-06-30 10:15:00 -07:00
Miss Islington (bot)
8ee4e12caf
gh-93491: Fix PEP 11 tier detection for FreeBSD (GH-94441)
(cherry picked from commit 67d208fbee)

Co-authored-by: Christian Heimes <christian@python.org>
2022-06-30 09:29:46 -07:00
Miss Islington (bot)
b3d69ffeb3
GH-90908: Document asyncio.TaskGroup (GH-94359) (GH-94456)
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
(cherry picked from commit b6ec6d4041)

Co-authored-by: Guido van Rossum <guido@python.org>
2022-06-30 18:27:15 +02:00
Miss Islington (bot)
fdc008138e
gh-91719: Reload opcode on unknown error so that C can optimize the dispatching in ceval.c (GH-94364) (#94453)
(cherry picked from commit ea39b77de9)

Co-authored-by: neonene <53406459+neonene@users.noreply.github.com>
2022-06-30 09:11:05 -07:00
Irit Katriel
ecc8e77cc1
[3.11] gh-89038: [doc] update dis.findlinestarts documentation for changes related to PEP-626 (GH-94247) (GH-94450)
(cherry picked from commit d68f2d27bb)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2022-06-30 16:18:30 +01:00
Miss Islington (bot)
f58c366a73
GH-94329: Don't raise on excessive stack consumption (GH-94421) (GH-94446)
(cherry picked from commit b152bf448b)
2022-06-30 15:53:20 +01:00
Irit Katriel
48a739ec10
gh-94332: make it safe to call assemble_free when assemble_init has not been called (GH-94389) (GH-94442)
(cherry picked from commit be82d26570)
2022-06-30 15:30:12 +01:00
Miss Islington (bot)
20b8c9eee0
gh-92336: linecache.getline should not raise exceptions on decoding errors (GH-94410)
(cherry picked from commit 21cbdae90f)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2022-06-30 02:59:33 -07:00
Miss Islington (bot)
c5ecfa0a1e
[3.11] GH-77403: Fix tests which fail when PYTHONUSERBASE is not normalized (GH-93917) (GH-93969)
(cherry picked from commit b1ae4af5e8)


Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>

Automerge-Triggered-By: GH:iritkatriel
2022-06-30 02:47:16 -07:00
Miss Islington (bot)
5084a64d38
bpo-92336: [doc] clarify that the dfile is read by the traceback display code (GH-94409)
(cherry picked from commit 68fb03249f)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2022-06-29 13:53:42 -07:00
Miss Islington (bot)
cbd562ff4e
Docs: Update SyntaxError message in REPL example for list comprehension (GH-93901) (GH-94425)
(cherry picked from commit 22b783aba0)

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2022-06-29 19:22:11 +02:00
Christian Heimes
a548a45633
[3.11] gh-94404: Use module CFLAGS before PY_STDMODULE_CFLAGS (GH-94413) (GH-94415)
``PY_STDMODULE_CFLAGS`` may contain include directories with system
headers. This can break compiling with built-in libmpdec.
Co-authored-by: Christian Heimes <christian@python.org>
2022-06-29 16:22:41 +02:00
Christian Heimes
9140c413d0
[3.11] GH-93516: Drop broken assert, fixes GH-93769 (GH-94411) 2022-06-29 13:53:56 +01:00
Christian Heimes
0122ab235b
[3.11] gh-94026: Buffer regrtest worker stdout in temporary file (GH-94253) (GH-94408)
Co-authored-by: Victor Stinner <vstinner@python.org>.
Co-authored-by: Christian Heimes <christian@python.org>
2022-06-29 13:51:25 +02:00
Miss Islington (bot)
aaa85b55d9
gh-94404: makesetup: use correct CFLAGS and macOS workaround (GH-94405)
``makesetup`` now works around an issue with sed on macOS and uses correct
CFLAGS for object files that end up in a shared extension.
(cherry picked from commit 5150cbcd68)

Co-authored-by: Christian Heimes <christian@python.org>
2022-06-29 01:10:58 -07:00
Mark Shannon
3b4f5ed168
[3.11] GH-93516: Backport GH-93769 (GH-94231)
* Store offset of first traceable instruction to avoid having to recompute it all the time when tracing.
2022-06-28 16:30:22 +01:00
Miss Islington (bot)
50a2e36ce9
gh-88116: Avoid undefined behavior when decoding varints in code objects (GH-94375)
(cherry picked from commit c485ec014c)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
2022-06-28 06:54:30 -07:00
Pablo Galindo Salgado
648469299d
[3.11] Backport ABI regeneration script (#94376) 2022-06-28 14:33:08 +01:00
Miss Islington (bot)
3937dbfaf8
gh-61585: Clarify import scope in modules tutorial (GH-93455) (GH-94373)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
(cherry picked from commit 4b854b7466)
2022-06-28 12:29:38 +02:00
Miss Islington (bot)
926bf235da
[3.11] gh-86404: [doc] Fix missing space in idle documentation. (GH-94366) (GH-94369)
This should have been spotted by sphinx-lint, tracked here:

https://github.com/sphinx-contrib/sphinx-lint/issues/39
(cherry picked from commit bc7f6fcdf1)


Co-authored-by: Julien Palard <julien@palard.fr>

Automerge-Triggered-By: GH:JulienPalard
2022-06-28 03:11:36 -07:00
Miss Islington (bot)
64365d0df9
gh-91860: Add docs for typing.dataclass_transform field specifier params (GH-94354) (GH-94372)
(cherry picked from commit 81ac9ac492)

Co-authored-by: Erik De Bonte <erikd@microsoft.com>
2022-06-28 12:10:42 +02:00
Miss Islington (bot)
cf64db6d6d
gh-94208: Add more TLS version/protocol checks for FreeBSD (GH-94347)
Three test cases were failing on FreeBSD with latest OpenSSL.
(cherry picked from commit 1bc86c2625)

Co-authored-by: Christian Heimes <christian@python.org>
2022-06-28 00:59:57 -07:00
Miss Islington (bot)
1d2c8ff38f
gh-82006: IDLE doc improvements (GH-94349)
0. Update text start and stop conditions.
1. Title-case sections but not subsections.
2. Edit Shell Window sections: title, execute, restart.
(cherry picked from commit e6391e08bf)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2022-06-27 16:24:08 -07:00
Miss Islington (bot)
5751530f51
gh-94315: Check for DAC override capability (GH-94316)
``os.geteuid() == 0`` is not a reliable check whether the current user
has the capability to bypass permission checks. Tests now probe for DAC
override.
(cherry picked from commit 7e0d98ecb3)

Co-authored-by: Christian Heimes <christian@python.org>
2022-06-27 11:51:45 -07:00
Christian Heimes
56f5f90496
[3.11] gh-90473: Reduce recursion limit on WASI even further (GH-94333) (GH-94334)
Co-authored-by: Christian Heimes <christian@python.org>
2022-06-27 18:33:01 +02:00
Christian Heimes
4ec146cefd
[3.11] gh-90005: Rename MODULE_EGG variable to MODULE_EGG_STATE (GH-94301) (GH-94317)
Co-authored-by: Christian Heimes <christian@python.org>
2022-06-27 09:23:04 +02:00
Terry Jan Reedy
bc8d81a8fe
[3.11] gh-84623: Remove unused imports in stdlib (#94313)
#93773

Backport only for 2 idlelib files.
Cherrypicked from  259dd71c32
2022-06-26 23:54:10 -04:00
Irit Katriel
575997af62
[3.11] gh-85023: [doc] clarify parameters vs arguments explanation in FAQ (GH-94282) (GH-94311)
(cherry picked from commit d71f5adc41)

Co-authored-by: Arun Mani J <49952138+arun-mani-j@users.noreply.github.com>

Co-authored-by: Arun Mani J <49952138+arun-mani-j@users.noreply.github.com>
2022-06-26 23:00:52 +01:00