summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* gh-100344: Add C implementation for `asyncio.current_task` (#100345)Itamar Ostricher2022-12-226-9/+123
| | | Co-authored-by: pranavtbhat
* gh-78997: fix bad rebase of moved test file (#100424)Eli Schwartz2022-12-222-188/+6
|
* GH-99770: Make the correct call specialization fail kind show up in the ↵penguin_wwy2022-12-222-64/+85
| | | | stats (GH-99771)
* gh-99761: Add `_PyLong_IsPositiveSingleDigit` function to check for single ↵Pieter Eendebak2022-12-223-10/+25
| | | | digit integers (#100064)
* Correct typo in typing.py (#100423)david-why2022-12-221-1/+1
| | | | In the docstring of `ParamSpec`, the name of `P = ParamSpec('P')` was mistakenly written as `'T'`.
* GH-99554: Pack location tables more effectively (GH-99556)Brandt Bucher2022-12-223-34/+53
|
* GH-69564: Clarify use of octal format of mode argument in help(os.chmod) ↵amaajemyfren2022-12-213-3/+23
| | | | | (#20621) Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
* gh-78878: Fix crash when creating an instance of `_ctypes.CField` (#14837)Hai Shi2022-12-214-10/+10
|
* Remove unused variable from `dis._find_imports` (#100396)Nikita Sobolev2022-12-211-1/+0
|
* gh-100129: Add tests for pickling all builtin types and functions (GH-100142)Serhiy Storchaka2022-12-211-0/+29
|
* gh-100374: Fixed a bug in socket.getfqdn() (gh-100375)Dominic Socular2022-12-213-2/+7
|
* GH-100133: fix `asyncio` subprocess losing `stderr` and `stdout` output ↵Kumar Aditya2022-12-213-3/+18
| | | | (#100154)
* GH-100363: Speed up `asyncio.get_running_loop` (#100364)Kumar Aditya2022-12-213-118/+14
|
* gh-85267: Improvements to inspect.signature __text_signature__ handling (#98796)Shantanu2022-12-213-6/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes a couple related changes to inspect.signature's behaviour when parsing a signature from `__text_signature__`. First, `inspect.signature` is documented as only raising ValueError or TypeError. However, in some cases, we could raise RuntimeError. This PR changes that, thereby fixing #83685. (Note that the new ValueErrors in RewriteSymbolics are caught and then reraised with a message) Second, `inspect.signature` could randomly drop parameters that it didn't understand (corresponding to `return None` in the `p` function). This is the core issue in #85267. I think this is very surprising behaviour and it seems better to fail outright. Third, adding this new failure broke a couple tests. To fix them (and to e.g. allow `inspect.signature(select.epoll.register)` as in #85267), I add constant folding of a couple binary operations to RewriteSymbolics. (There's some discussion of making signature expression evaluation arbitrary powerful in #68155. I think that's out of scope. The additional constant folding here is pretty straightforward, useful, and not much of a slippery slope) Fourth, while #85267 is incorrect about the cause of the issue, it turns out if you had consecutive newlines in __text_signature__, you'd get `tokenize.TokenError`. Finally, the `if name is invalid:` code path was dead, since `parse_name` never returned `invalid`.
* gh-91081: Add note on WeakKeyDictionary behavior when deleting a replaced ↵Stanley2022-12-211-0/+24
| | | | | | entry (#91499) Co-authored-by: Pieter Eendebak <P.T.eendebak@tudelft.nl> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-99991: improve docs on str.encode and bytes.decode (#100198)Bisola Olasehinde2022-12-211-27/+33
| | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* gh-100188: Reduce misses in BINARY_SUBSCR_(LIST/TUPLE)_INT (#100189)Dennis Sweeney2022-12-202-4/+15
| | | Don't specialize if the index is negative.
* gh-99576: Fix cookiejar file that was not truncated for some classes (GH-99616)Nikita Sobolev2022-12-203-2/+36
| | | Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* Clarify that every thread has its own default context in contextvars (#99246)Pablo Galindo Salgado2022-12-201-0/+5
|
* gh-99925: Fix inconsistency in `json.dumps()` error messages (GH-99926)František Nesveda2022-12-203-3/+9
|
* gh-100348: Fix ref cycle in `asyncio._SelectorSocketTransport` with ↵Richard Kojedzinszky2022-12-202-0/+6
| | | | `_read_ready_cb` (#100349)
* gh-88211: Change lower-case and upper-case to match recommendations in ↵Brad Wolfe2022-12-201-1/+1
| | | | imaplib docs (#99625)
* gh-89051: Add ssl.OP_LEGACY_SERVER_CONNECT (#93927)Thomas Grainger2022-12-204-0/+26
| | | | | | Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Christian Heimes <christian@python.org> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Fixes https://github.com/python/cpython/issues/89051
* gh-69929: re docs: Add more specific definition of \w (#92015)Stanley2022-12-201-4/+3
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-89727: Fix os.walk RecursionError on deep trees (#99803)Jon Burdo2022-12-194-83/+139
| | | | | Use a stack to implement os.walk iteratively instead of recursively to avoid hitting recursion limits on deeply nested trees.
* Docs: Don't upload CI artifacts (#100330)Hugo van Kemenade2022-12-191-10/+0
|
* gh-94912: Added marker for non-standard coroutine function detection (#99247)Carlton Gibson2022-12-185-4/+100
| | | | | This introduces a new decorator `@inspect.markcoroutinefunction`, which, applied to a sync function, makes it appear async to `inspect.iscoroutinefunction()`.
* Correct CVE-2020-10735 documentation (#100306)Jeremy Paige2022-12-183-7/+7
|
* gh-100272: Fix JSON serialization of OrderedDict (GH-100273)Serhiy Storchaka2022-12-173-4/+15
| | | | It now preserves the order of keys.
* gh-93649: Split tracemalloc tests from _testcapimodule.c (#99551)Erlend E. Aasland2022-12-174-229/+250
|
* Docs: Use `PY_VERSION_HEX` for version comparison (#100179)Hugo van Kemenade2022-12-172-1/+3
|
* gh-97909: Fix markup for `PyMethodDef` members (#100089)ram vikram singh2022-12-171-17/+18
|
* gh-99240: Reset pointer to NULL when the pointed memory is freed in argument ↵colorfulappl2022-12-170-0/+0
| | | | | | parsing (#99890) Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* gh-99240: Reset pointer to NULL when the pointed memory is freed in argument ↵colorfulappl2022-12-174-5/+30
| | | | | | parsing (#99890) Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* GH-98831: Add DECREF_INPUTS(), expanding to DECREF() each stack input (#100205)Guido van Rossum2022-12-172-19/+18
| | | | | | | | | | | | | | | | | | | The presence of this macro indicates that a particular instruction may be considered for conversion to a register-based format (see https://github.com/faster-cpython/ideas/issues/485). An invariant (currently unchecked) is that `DEOPT_IF()` may only occur *before* `DECREF_INPUTS()`, and `ERROR_IF()` may only occur *after* it. One reason not to check this is that there are a few places where we insert *two* `DECREF_INPUTS()` calls, in different branches of the code. The invariant checking would have to be able to do some flow control analysis to understand this. Note that many instructions, especially specialized ones, can't be converted to use this macro straightforwardly. This is because the generator currently only generates plain `Py_DECREF(variable)` statements, and cannot generate things like `_Py_DECREF_SPECIALIZED()` let alone deal with `_PyList_AppendTakeRef()`.
* gh-78707: deprecate passing >1 argument to `PurePath.[is_]relative_to()` ↵Barney Gale2022-12-174-14/+35
| | | | | | | (GH-94469) This brings `relative_to()` and `is_relative_to()` more in line with other pathlib methods like `rename()` and `symlink_to()`. Resolves #78707.
* gh-99540: Constant hash for _PyNone_Type to aid reproducibility (GH-99541)yonillasky2022-12-162-1/+7
| | | Needed for ASLR builds of Python.
* gh-100039: enhance __signature__ to work with str and callables (GH-100168)Ethan Furman2022-12-165-4/+73
| | | | | Callables should be either class- or static-methods. Enum now uses the classmethod version to greatly improve the help given for enums and flags.
* gh-99830: asyncio: Document returns of remove_{reader,writer} (#100302)Ben Darnell2022-12-161-2/+4
|
* "Compound statement" docs: Fix with-statement step indexing (#100286)Frank Dana2022-12-161-1/+1
| | | | | Back in commit 226e6e7d4326cf91ef37e13528eb1f62de1bb832 an item was added to the list, renumbering all the rest of the items, but the forward-reference wasn't updated to match.
* GH-90043: Handle NaNs in COMPARE_OP_FLOAT_JUMP (GH-100278)Brandt Bucher2022-12-164-24/+23
|
* Improve stats presentation for calls. (GH-100274)Mark Shannon2022-12-161-37/+22
|
* Better stats for `LOAD_ATTR` and `STORE_ATTR` (GH-100295)Mark Shannon2022-12-162-13/+36
| | | | | * Don't attempt to specialize for LOAD_ATTR on instance if class has attribute * Improvement to LOAD_ATTR and STORE_ATTR specialization stats.
* gh-81057: Move the Cached Parser Dummy Name to _PyRuntimeState (#100277)Eric Snow2022-12-164-25/+20
|
* Document that zipfile's pwd parameter is a `bytes` object (#100209)JustAnotherArchivist2022-12-161-7/+8
|
* gh-99767: mark `PyTypeObject.tp_watched` as internal use only in table (#100271)Carl Meyer2022-12-161-1/+1
|
* Fix typo in introduction.rst (#100266)Mikhail Berkov2022-12-161-1/+1
|
* gh-78997: AttributeError if loading fails in LibraryLoader.__getattr__Ateeq Sharfuddin2022-12-153-1/+195
| | | | | Co-authored-by: Zachary Ware <zachary.ware@gmail.com> Co-authored-by: Filipe Laíns <filipe.lains@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* GH-100234: Set a default value for random.expovariate() (GH-100235)Raymond Hettinger2022-12-154-2/+8
|
* Remove uninformative itertools recipe (GH-100253)Raymond Hettinger2022-12-151-7/+0
|