summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* gh-96265: Formatting changes for faq/programming (#98242)Stanley2022-11-021-39/+48
| | | | | | | | | | | | | | | | | * Formatting changes for faq/programming * Add missing method formatting, use non-literal formatting * Fix sphinx warnings * Some extra formatting missed earlier * More formatting suggestions from review Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> * Add missing colon, avoid referening external module Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* gh-92679: Clarify asyncio.loop.start_tls parameters (#92682)Oleg Iarygin2022-11-021-3/+8
|
* gh-92871: Postpone the removal of typing.{io,re} to 3.13 (#98958)Sebastian Rittau2022-11-021-3/+3
|
* [doc] Update cookbook example for socket-based logging in a production ↵Vinay Sajip2022-11-011-7/+65
| | | | | sett… (GH-98922) Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* gh-98925: Lower marshal recursion depth for WASI (GH-98938)Brett Cannon2022-11-014-0/+7
| | | | | For wasmtime 2.0, the stack depth cost is 6% higher. This causes the default max `marshal` recursion depth to blow the stack. As the default marshal depth is 2000 and Windows is set to 1000, split the difference and choose 1500 for WASI to be safe.
* gh-98689: Update Windows builds to zlib v1.2.13 (GH-98968)Zachary Ware2022-11-013-2/+4
|
* Doc: use "unnumbered" footnotes (#98954)Manuel Kaufmann2022-11-011-2/+2
| | | | | Use unnumbered footnote in this file to avoid reseting the footnotes numbering. Example: when building the tutorial into a PDF and using `latex_show_urls = "footnotes"`; this footnote become the number 8. However, without this change, the footnote shows the number 1.
* gh-98931: Improve error message when the user types 'import x from y' ↵Pablo Galindo Salgado2022-11-015-392/+503
| | | | instead of 'from y import x' (#98932)
* gh-98852: Fix subscription of type aliases (GH-98920)Serhiy Storchaka2022-11-014-0/+43
| | | | | Fix subscription of type aliases containing bare generic types or types like TypeVar: for example tuple[A, T][int] and tuple[TypeVar, T][int], where A is a generic type, and T is a type variable.
* GH-98766: Modest speed-up from ChainMap.__iter__ (GH-98946)Raymond Hettinger2022-11-011-2/+2
|
* gh-98658: Add __class_getitem__ to array.array (#98661)Jelle Zijlstra2022-11-014-2/+12
| | | Closes #98658
* Rename JUMP_TO_INSTRUCTION to GO_TO_INSTRUCTION (#98934)Guido van Rossum2022-11-011-14/+14
| | | | | | This reduces confusion between jumps at the bytecode level (e.g. JUMPTO(), JUMPBY(), and various JUMP_*() opcodes) and jumps in the C code (which are 'goto' statements).
* Fix wording in Functional Programming HOWTO (GH-98939)partev2022-11-011-1/+1
|
* Missing PS1 prompt in tutorial example (GH-98921)Manuel Kaufmann2022-11-011-2/+3
|
* GH-98897: fix memory leak if `math.dist` raises exception (GH-98898)Kumar Aditya2022-11-013-3/+9
|
* gh-98692: Enable treating shebang lines as executables in py.exe launcher ↵Steve Dower2022-10-314-4/+124
| | | | (GH-98732)
* gh-98610: Adjust the Optional Restrictions on Subinterpreters (GH-98618)Eric Snow2022-10-3115-47/+220
| | | | | | | Previously, the optional restrictions on subinterpreters were: disallow fork, subprocess, and threads. By default, we were disallowing all three for "isolated" interpreters. We always allowed all three for the main interpreter and those created through the legacy `Py_NewInterpreter()` API. Those settings were a bit conservative, so here we've adjusted the optional restrictions to: fork, exec, threads, and daemon threads. The default for "isolated" interpreters disables fork, exec, and daemon threads. Regular threads are allowed by default. We continue always allowing everything For the main interpreter and the legacy API. In the code, we add `_PyInterpreterConfig.allow_exec` and `_PyInterpreterConfig.allow_daemon_threads`. We also add `Py_RTFLAGS_DAEMON_THREADS` and `Py_RTFLAGS_EXEC`.
* Fix typo in sorting HOWTO (#98888)partev2022-10-311-1/+1
|
* Doc: Fix sphinx-lint issues (GH-98911)Julien Palard2022-10-311-1/+1
| | | They were introduced right between GH-98441 and GH-98408.
* gh-98576: Fix types in dataclass.InitVar example (gh-98577)Shantanu2022-10-311-2/+2
|
* gh-98410: move getbufferproc and releasebufferproc to buffer.h (#31158)David Hewitt2022-10-315-4/+10
| | | This adds them to the Limited API.
* gh-98878: Use builtins from the bound frame when offering a suggestion (#98880)Batuhan Taskaya2022-10-313-1/+12
|
* gh-98811: use full source location to simplify __future__ imports error ↵Irit Katriel2022-10-315-69/+71
| | | | checking. This also fixes an incorrect error offset. (GH-98812)
* gh-96151: Use a private name for passing builtins to dataclass. This now ↵Shantanu2022-10-313-5/+13
| | | | allows for a field named BUILTIN (gh-98143)
* gh-98879: Remove unreachable error case from COMPARE_OP_STR_JUMP (GH-98882)Dennis Sweeney2022-10-301-3/+0
| | | Thanks to PEP 623 changes, the comparison cannot fail.
* gh-97966: Update uname docs to clarify the special nature of the platform ↵Jason R. Coombs2022-10-302-4/+10
| | | | attribute and to indicate when it became late-bound. (#97972)
* gh-96853: Restore test coverage for Py_Initialize(Ex) (GH-98212)Nick Coghlan2022-10-305-19/+57
| | | | | | | | | | | * As most of `test_embed` now uses `Py_InitializeFromConfig`, add a specific test case to cover `Py_Initialize` (and `Py_InitializeEx`) * Rename `_testembed` init helper to clarify the API used * Add a `PyConfig_Clear` call in `Py_InitializeEx` to make the code more obviously correct (it already didn't leak as none of the dynamically allocated config fields were being populated, but it's clearer if the wrappers follow the documented API usage guidelines)
* gh-98783: Fix crashes when `str` subclasses are used in `_PyUnicode_Equal` ↵Nikita Sobolev2022-10-305-3/+36
| | | | (#98806)
* gh-98793: Fix typecheck in `overlapped.c` (#98835)Charlie Zhao2022-10-304-5/+25
| | | | Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
* glossary.rst: Fix typo in package definition (GH-98865)ab2022-10-291-1/+1
| | | | | | This is a tiny typo fix of package definition in glossary. According to https://devguide.python.org/documentation/help-documenting/ simple typos don’t require issues of their own, but, instead, a pull request can by submitted directly. Automerge-Triggered-By: GH:AlexWaygood
* Fix typo in docs (GH-98863)Yuvi Panda2022-10-291-1/+1
|
* gh-93358: Fix python-config docs for how to embed Python (#98649)Erlend E. Aasland2022-10-291-6/+6
|
* Fix comment typos in `_operator.c` (#98853)David Buchanan2022-10-291-2/+2
|
* dataclasses docs: consistent indentation (4 spaces) in examples (#98855)FC Stegerman2022-10-291-16/+16
|
* GH-90352: fix _SelectorDatagramTransport to inherit from DatagramTransport ↵Kumar Aditya2022-10-293-1/+6
| | | | (#98844)
* gh-98744: Prevent column-level decoding crashes on traceback module (#98824)Batuhan Taskaya2022-10-293-14/+63
|
* gh-98286: handle empty filename in ZipFile/ZipInfo properly (#98346)FC Stegerman2022-10-291-2/+5
| | | effectively code modernization and a meaningful exception.
* gh-98240: Updated Path.rename docs, when it is atomic (GH-98245)Mateusz2022-10-281-0/+2
|
* gh-84538: add strict argument to pathlib.PurePath.relative_to (GH-19813)domragusa2022-10-286-21/+150
| | | | | | | | | | | | | | | | | | | | | | | By default, :meth:`pathlib.PurePath.relative_to` doesn't deal with paths that are not a direct prefix of the other, raising an exception in that instance. This change adds a *walk_up* parameter that can be set to allow for using ``..`` to calculate the relative path. example: ``` >>> p = PurePosixPath('/etc/passwd') >>> p.relative_to('/etc') PurePosixPath('passwd') >>> p.relative_to('/usr') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "pathlib.py", line 940, in relative_to raise ValueError(error_message.format(str(self), str(formatted))) ValueError: '/etc/passwd' does not start with '/usr' >>> p.relative_to('/usr', strict=False) PurePosixPath('../etc/passwd') ``` https://bugs.python.org/issue40358 Automerge-Triggered-By: GH:brettcannon
* Fix typo in contextvars docs (#98823)cburroughs2022-10-281-1/+1
|
* gh-92452: Avoid race in initialization of sysconfig._CONFIG_VARSGareth Rees2022-10-282-60/+82
| | | Co-authored-by: Filipe Laíns <lains@riseup.net>
* `argparse` docs: normalize constant references (#98765)Skip Montanaro2022-10-281-5/+6
|
* gh-98776: Fix make regen-test-levenshtein for out-of-tree builds (GH-98779)Miro Hrončok2022-10-282-1/+2
| | | | | Fixes https://github.com/python/cpython/issues/98776 Automerge-Triggered-By: GH:erlend-aasland
* gh-98657: [docs] `array.typecodes` is a module-level attribute (#98729)Nikita Sobolev2022-10-281-3/+8
| | | | | * gh-98657: [docs] `array.typecodes` is a module-level attribute * Update array.rst
* gh-65002: Make note that null bytes are used to pad bytes (#98635)Stanley2022-10-281-1/+4
|
* gh-98745: Allow py.exe launcher to install 3.11 by default and 3.12 on ↵Steve Dower2022-10-282-1/+5
| | | | request (GH-98780)
* gh-98624 Add mutex to unittest.mock.NonCallableMock (#98688)noah-weingarden2022-10-282-28/+40
| | | | | | | | | | | * Added lock to NonCallableMock in unittest.mock * Add blurb * Nitpick blurb * Edit comment based on @Jason-Y-Z's review * Add link to GH issue
* gh-98789: Fix FOR_ITER assert on big-endian (GH-98792)Dennis Sweeney2022-10-281-1/+1
| | | Fix FOR_ITER assertion syntax
* gh-98739: Update libexpat from 2.4.9 to 2.5.0 (#98742)Shaun Walbridge2022-10-274-18/+36
| | | | | * Update libexpat from 2.4.9 to 2.5.0 to address CVE-2022-43680. Co-authored-by: Shaun Walbridge <shaun.walbridge@gmail.com>
* obmalloc: Remove unused variable. (GH-98770)Benjamin Peterson2022-10-271-3/+1
|