summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* GH-96569: Add two NULL checks to avoid undefined behavior. (GH-96585)Mark Shannon2022-09-063-10/+13
|
* GH-93911: Fix `LOAD_ATTR_PROPERTY` caches (GH-96519)Brandt Bucher2022-09-062-5/+7
|
* gh-96478: Test `@overload` on C functions (#96479)Nikita Sobolev2022-09-051-0/+14
| | | Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* argparse: Remove unused name variable when handling ArgumentTypeError (#96549)Jonathon Reinhart2022-09-051-1/+0
| | | | | | | | This removes the unused `name` variable in the block where `ArgumentTypeError` is handled. `ArgumentTypeError` errors are handled by showing just the string of the exception; unlike `ValueError`, the name (`__name__`) of the function is not included in the error message. Fixes #96548
* [doc] Update example in traceback doc (GH-96600)Irit Katriel2022-09-051-15/+11
| | | | | This Monty Python reference is of-its-time. It could seem inappropriate in the context of today's sensibilities around mental health. Automerge-Triggered-By: GH:iritkatriel
* gh-93963: Remove ResourceReaderDefaultsTests (GH-96598)Jason R. Coombs2022-09-051-28/+0
| | | Automerge-Triggered-By: GH:jaraco
* gh-96559: Fixes Windows launcher handling of defaults using old-style tags, ↵Steve Dower2022-09-054-22/+51
| | | | and adds What's New section (GH-96595)
* Add upstream openssl 1.1.1q patch for trivial build error on macOS (GH-96594)Ned Deily2022-09-052-0/+18
|
* gh-92986: Fix ast.unparse when ImportFrom.level is None (#92992)Shantanu2022-09-053-1/+8
| | | | | This doesn't happen naturally, but is allowed by the ASDL and compiler. We don't want to change ASDL for backward compatibility reasons (#57645, #92987)
* gh-96587: Raise `SyntaxError` for PEP654 on older `feature_version` (#96588)Nikita Sobolev2022-09-054-2/+15
|
* gh-84095: Fill documentation gap regarding user-defined objects. (GH-96574)Vinay Sajip2022-09-051-0/+19
|
* gh-96538: Move some type-checking out of bisect.bisect() loops (GH-96539)Dennis Sweeney2022-09-052-16/+143
|
* gh-93973: Add all_errors to asyncio.create_connection (#93974)Pamela Fox2022-09-054-2/+54
| | | | Co-authored-by: Oleg Iarygin <dralife@yandex.ru>
* ceval.c's GETITEM should have asserts, not set exceptions (GH-96518)Dennis Sweeney2022-09-041-2/+8
|
* Docs: alphabetically order sqlite3.Cursor attrs (#96565)Erlend E. Aasland2022-09-041-30/+31
|
* gh-95778: Correctly pre-check for int-to-str conversion (#96537)Mark Dickinson2022-09-044-7/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | Converting a large enough `int` to a decimal string raises `ValueError` as expected. However, the raise comes _after_ the quadratic-time base-conversion algorithm has run to completion. For effective DOS prevention, we need some kind of check before entering the quadratic-time loop. Oops! =) The quick fix: essentially we catch _most_ values that exceed the threshold up front. Those that slip through will still be on the small side (read: sufficiently fast), and will get caught by the existing check so that the limit remains exact. The justification for the current check. The C code check is: ```c max_str_digits / (3 * PyLong_SHIFT) <= (size_a - 11) / 10 ``` In GitHub markdown math-speak, writing $M$ for `max_str_digits`, $L$ for `PyLong_SHIFT` and $s$ for `size_a`, that check is: $$\left\lfloor\frac{M}{3L}\right\rfloor \le \left\lfloor\frac{s - 11}{10}\right\rfloor$$ From this it follows that $$\frac{M}{3L} < \frac{s-1}{10}$$ hence that $$\frac{L(s-1)}{M} > \frac{10}{3} > \log_2(10).$$ So $$2^{L(s-1)} > 10^M.$$ But our input integer $a$ satisfies $|a| \ge 2^{L(s-1)}$, so $|a|$ is larger than $10^M$. This shows that we don't accidentally capture anything _below_ the intended limit in the check. <!-- gh-issue-number: gh-95778 --> * Issue: gh-95778 <!-- /gh-issue-number --> Co-authored-by: Gregory P. Smith [Google LLC] <greg@krypto.org>
* no-issue: Fix typo in 3.11.0a7.rst (gh-96547)Ikko Ashimine2022-09-041-1/+1
| | | accross -> across
* gh-68163: Correct conversion of Rational instances to float (GH-25619)Sergey B Kirpichev2022-09-044-4/+36
| | | | | | | * gh-68163: Correct conversion of Rational instances to float Also document that numerator/denominator properties are instances of Integral. Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
* gh-93884: Improve test coverage of `PyNumber_ToBase` (GH-93932)Charlie Zhao2022-09-042-8/+25
| | | | | | | Link to #93884 * Test with some large negative and positive values(out of range of a longlong,i.e.[-2\*\*63, 2\*\*63-1]) * Test with objects of non-int type Automerge-Triggered-By: GH:mdickinson
* gh-95778: remove unneeded doc note on float.as_integer_ratio (#96553)Gregory P. Smith2022-09-041-7/+0
| | | Per mdickinson@'s comment on the main branch PR.
* doc typo: spell limitation (#96542)Mehrdad Moradizadeh2022-09-041-1/+1
|
* gh-90195: Unset logger disabled flag when configuring it. (GH-96530)Vinay Sajip2022-09-032-0/+30
|
* gh-89087: Update logging.QueueHandler documentation to clarify record… ↵Vinay Sajip2022-09-031-0/+14
| | | | (GH-96527)
* gh-75500: Update idlelib/help.html (#96523)Terry Jan Reedy2022-09-031-7/+8
|
* GH-96458: Statically initialize utf8 representation of static strings (#96481)Kumar Aditya2022-09-036-165/+139
|
* gh-45108: Improve docstring and testing of ZipFile.testfile() (GH-96233)Serhiy Storchaka2022-09-033-12/+13
|
* [Enum] bump version tag on HTTP status category indicators (GH-96508)Alexandru Mărășteanu2022-09-021-1/+1
|
* bpo-30419: DOC: Update missing information in bdb docs (#1687)Cheryl Sabella2022-09-022-65/+133
| | | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Martin Panter <vadmium@users.noreply.github.com> Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* gh-95180: Add `TaskGroup` and `Runner` to AsyncIO API Index (#95189)siph2022-09-021-9/+20
| | | | | Also rearrange some items in the list. Co-authored-by: Thomas Grainger <tagrain@gmail.com>
* gh-95778: CVE-2020-10735: Prevent DoS by very large int() (#96499)Gregory P. Smith2022-09-0228-20/+803
| | | | | | | | | | | | | | | | Integer to and from text conversions via CPython's bignum `int` type is not safe against denial of service attacks due to malicious input. Very large input strings with hundred thousands of digits can consume several CPU seconds. This PR comes fresh from a pile of work done in our private PSRT security response team repo. Signed-off-by: Christian Heimes [Red Hat] <christian@python.org> Tons-of-polishing-up-by: Gregory P. Smith [Google] <greg@krypto.org> Reviews via the private PSRT repo via many others (see the NEWS entry in the PR). <!-- gh-issue-number: gh-95778 --> * Issue: gh-95778 <!-- /gh-issue-number --> I wrote up [a one pager for the release managers](https://docs.google.com/document/d/1KjuF_aXlzPUxTK4BMgezGJ2Pn7uevfX7g0_mvgHlL7Y/edit#). Much of that text wound up in the Issue. Backports PRs already exist. See the issue for links.
* Allow whitespace around a slash in fraction string inputs (GH-96496)Raymond Hettinger2022-09-024-4/+7
|
* gh-96168: Improve sqlite3 dict_factory example (#96457)Erlend E. Aasland2022-09-011-18/+9
| | | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
* gh-93554: Conditional jump opcodes only jump forward (GH-96318)Irit Katriel2022-09-0113-448/+298
|
* gh-96455: update example in exception_handling_notes.txt to the 3.11RC ↵Irit Katriel2022-09-011-25/+28
| | | | bytecode (GH-96456)
* gh-93678: apply remove_redundant_jumps in optimize_cfg (GH-96274)Irit Katriel2022-09-012-14/+36
|
* gh-96143: subprocess API %s/universal_newlines=/text=/g. (GH-96468)Gregory P. Smith2022-09-011-4/+4
| | | | | minor missed test cleanup to use the modern API from the big review. Automerge-Triggered-By: GH:gpshead
* GH-96079 Fix missing field name for _AnnotatedAlias (#96080)Anh71me2022-08-313-1/+6
|
* gh-96408: Document difference between set-like view and sets. (GH-96439)Piotr Kaznowski2022-08-311-1/+5
|
* gh-89258: Add a getChildren() method to logging.Logger. (GH-96444)Vinay Sajip2022-08-314-0/+47
| | | Co-authored-by: Éric <merwok@netwok.org>
* gh-96414: Inline code examples in sqlite3 docs (#96442)Erlend E. Aasland2022-08-3115-349/+380
|
* gh-95865: Speed up urllib.parse.quote_from_bytes() (GH-95872)Dennis Sweeney2022-08-312-1/+2
|
* Remove the binary_subscr_dict_error label (GH-96443)Brandt Bucher2022-08-301-11/+4
|
* gh-96408: Test set operation on items dict view. (GH-96438)Filip Łajszczak2022-08-301-0/+18
|
* Docs: normalise sqlite3 placeholder how-to heading (#96413)Erlend E. Aasland2022-08-301-2/+2
|
* gh-96143: Add some comments and minor fixes missed in the original PR (#96433)Pablo Galindo Salgado2022-08-304-1/+17
| | | | | | | | | * gh-96132: Add some comments and minor fixes missed in the original PR * Update Doc/using/cmdline.rst Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
* Automatically update more GitHub projects. (#94921)Ezio Melotti2022-08-301-4/+12
| | | | | | | | | | | * Automatically update the `asyncio` GitHub project. * Use a matrix to add issues to projects. * Remove trailing whitespace. Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* gh-95149: Enhance `http.HTTPStatus` with properties that indicate the HTTP ↵Alexandru Mărășteanu2022-08-305-1/+93
| | | | status category (GH-95453)
* Fix regeneration of global objects through the Windows build files (GH-96394)Kumar Aditya2022-08-301-1/+8
|
* gh-95987: Fix `repr` of `Any` type subclasses (#96412)Nikita Sobolev2022-08-303-1/+10
|
* gh-96143: Allow Linux perf profiler to see Python calls (GH-96123)Pablo Galindo Salgado2022-08-3024-2/+1412
| | | | | | | :warning: :warning: Note for reviewers, hackers and fellow systems/low-level/compiler engineers :warning: :warning: If you have a lot of experience with this kind of shenanigans and want to improve the **first** version, **please make a PR against my branch** or **reach out by email** or **suggest code changes directly on GitHub**. If you have any **refinements or optimizations** please, wait until the first version is merged before starting hacking or proposing those so we can keep this PR productive.