]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
3 years agogh-95324: Emit a warning if an object doesn't call PyObject_GC_UnTrack during dealloc...
Pablo Galindo Salgado [Wed, 27 Jul 2022 15:03:38 +0000 (16:03 +0100)] 
gh-95324: Emit a warning if an object doesn't call PyObject_GC_UnTrack during deallocation in debug mode (#95325)

3 years agogh-95174: Move WASIX logic into wasi-env (GH-95320)
Christian Heimes [Wed, 27 Jul 2022 13:30:36 +0000 (15:30 +0200)] 
gh-95174: Move WASIX logic into wasi-env (GH-95320)

wasi-env now sets WASIX flags. This allows us to control all build
parameter for wasm32-wasi buildbot from CPython repository.

Also export and improve SYSROOT parameter.

3 years agogh-95273: Normalise sqlite3 reference wording (#95274)
Erlend Egeberg Aasland [Wed, 27 Jul 2022 13:24:13 +0000 (15:24 +0200)] 
gh-95273: Normalise sqlite3 reference wording (#95274)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
3 years agoGH-93899: fix checks for eventfd flags (GH-95170)
Kumar Aditya [Wed, 27 Jul 2022 13:05:29 +0000 (18:35 +0530)] 
GH-93899: fix checks for eventfd flags  (GH-95170)

3 years agogh-94630: Fixup sqlite3 argument spec docs for connection execute* methods (#95319)
Erlend Egeberg Aasland [Wed, 27 Jul 2022 12:46:21 +0000 (14:46 +0200)] 
gh-94630: Fixup sqlite3 argument spec docs for connection execute* methods (#95319)

3 years agoGH-95045: gc untrack _lsprof.Profiler before deallocating it (GH-95315)
Kumar Aditya [Wed, 27 Jul 2022 12:03:50 +0000 (17:33 +0530)] 
GH-95045: gc untrack _lsprof.Profiler before deallocating it (GH-95315)

Automerge-Triggered-By: GH:pablogsal
3 years agogh-93963: Remove usage of deprecated interface from importlib.abc. (#95217)
Jason R. Coombs [Wed, 27 Jul 2022 08:54:31 +0000 (04:54 -0400)] 
gh-93963: Remove usage of deprecated interface from importlib.abc. (#95217)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
3 years agogh-95005: Replace PyAccu with PyUnicodeWriter (gh-95006)
Aivars Kalvāns [Wed, 27 Jul 2022 08:43:34 +0000 (11:43 +0300)] 
gh-95005: Replace PyAccu with PyUnicodeWriter (gh-95006)

3 years agogh-95280: Fix test_get_ciphers on systems without RSA key exchange (GH-95282)
Christian Heimes [Wed, 27 Jul 2022 07:19:49 +0000 (09:19 +0200)] 
gh-95280: Fix test_get_ciphers on systems without RSA key exchange (GH-95282)

3 years agogh-95174: WASI: skip missing sockets functions (GH-95179)
Christian Heimes [Wed, 27 Jul 2022 06:19:23 +0000 (08:19 +0200)] 
gh-95174: WASI: skip missing sockets functions (GH-95179)

3 years agogh-95085: Promote Emscripten and WASI to PEP 11 tier 3 (GH-95086)
Christian Heimes [Wed, 27 Jul 2022 06:18:34 +0000 (08:18 +0200)] 
gh-95085: Promote Emscripten and WASI to PEP 11 tier 3 (GH-95086)

3 years agogh-94635: Add sqlite3 'Introduction' and 'Tutorial' doc headings (#95269)
Erlend Egeberg Aasland [Wed, 27 Jul 2022 05:43:24 +0000 (07:43 +0200)] 
gh-94635: Add sqlite3 'Introduction' and 'Tutorial' doc headings (#95269)

3 years agogh-94673: Add Per-Interpreter Storage for Static Builtin Types (#95255)
Eric Snow [Tue, 26 Jul 2022 23:26:43 +0000 (17:26 -0600)] 
gh-94673: Add Per-Interpreter Storage for Static Builtin Types (#95255)

This is the last precursor to storing tp_subclasses (and tp_weaklist) on the interpreter state for static builtin types.

Here we add per-type storage on PyInterpreterState, but only for the static builtin types.  This involves the following:

* add PyInterpreterState.types
   * move PyInterpreterState.type_cache to it
   * add a "num_builtins_initialized" field
   * add a "builtins" field (a static array big enough for all the static builtin types)
* add _PyStaticType_GetState() to look up a static builtin type's state
* (temporarily) add PyTypeObject.tp_static_builtin_index (to hold the type's index into PyInterpreterState.types.builtins)

We will be eliminating tp_static_builtin_index in a later change.

3 years agogh-95285: py.exe launcher fails with short argv0 (GH-95295)
Steve Dower [Tue, 26 Jul 2022 20:24:44 +0000 (21:24 +0100)] 
gh-95285: py.exe launcher fails with short argv0 (GH-95295)

3 years agogh-93678: Address stack exhaustion on WASI (GH-95296)
Christian Heimes [Tue, 26 Jul 2022 20:14:35 +0000 (22:14 +0200)] 
gh-93678: Address stack exhaustion on WASI (GH-95296)

3 years agogh-94801: Fix regression in configure's CPPFLAGS handling (GH-95288)
Christian Heimes [Tue, 26 Jul 2022 19:39:04 +0000 (21:39 +0200)] 
gh-94801: Fix regression in configure's CPPFLAGS handling (GH-95288)

3 years agogh-95291: Use import helper to improve sqlite3 audit tests (#95292)
Erlend Egeberg Aasland [Tue, 26 Jul 2022 19:18:16 +0000 (21:18 +0200)] 
gh-95291: Use import helper to improve sqlite3 audit tests (#95292)

Now the tests are correctly reported as skipped if sqlite3 is not available.

3 years agoFix minor docstring issues in `dataclasses.py`. (gh-93024)
Roman Novak [Tue, 26 Jul 2022 14:48:58 +0000 (07:48 -0700)] 
Fix minor docstring issues in `dataclasses.py`. (gh-93024)

Previously, when using `functools.wrap` around them (and inherit their docstrings), sphinx renders the docstrings badly and raises warnings about wrong indent.

3 years agogh-93678: extract 'struct cfg_builder' from the compiler so that the CFG can be manip...
Irit Katriel [Tue, 26 Jul 2022 13:36:30 +0000 (14:36 +0100)] 
gh-93678: extract 'struct cfg_builder' from the compiler so that the CFG can be manipulated directly (GH-95107)

3 years agogh-95259: add test for traceback with angle-bracketed filename (GH-95260)
Irit Katriel [Tue, 26 Jul 2022 13:34:46 +0000 (14:34 +0100)] 
gh-95259: add test for traceback with angle-bracketed filename (GH-95260)

3 years agogh-95041: Fail syslog.syslog in case inner call to syslog.openlog fails (GH-95264)
Noam Cohen [Tue, 26 Jul 2022 11:34:15 +0000 (14:34 +0300)] 
gh-95041: Fail syslog.syslog in case inner call to syslog.openlog fails (GH-95264)

3 years agogh-95066: ast: Replace assert with ValueError (GH-95072)
Shantanu [Tue, 26 Jul 2022 09:43:09 +0000 (02:43 -0700)] 
gh-95066: ast: Replace assert with ValueError (GH-95072)

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
3 years agogh-95174: Handle missing dup() and constants in WASI (GH-95229)
Christian Heimes [Tue, 26 Jul 2022 09:16:51 +0000 (11:16 +0200)] 
gh-95174: Handle missing dup() and constants in WASI (GH-95229)

- check for ``dup()`` libc function
- handle missing ``F_DUPFD`` in ``dup2()`` replacement function
- add workaround for WASI libc bug in MSG_TRUNC
- ESHUTDOWN is missing, use EPIPE instead
- POLLPRI is missing, define as 0 (no-op)

3 years agogh-95205: Improve WASM README.md (GH-95267)
Christian Heimes [Tue, 26 Jul 2022 09:12:42 +0000 (11:12 +0200)] 
gh-95205: Improve WASM README.md (GH-95267)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@protonmail.com>
3 years agoStatistics inv_cdf sync with corresponding random module normal distributions (#95265)
Raymond Hettinger [Tue, 26 Jul 2022 07:23:33 +0000 (02:23 -0500)] 
Statistics inv_cdf sync with corresponding random module normal distributions (#95265)

3 years agoClarifying the documentation on library/syslog (GH-92587)
Nicolas Haller [Tue, 26 Jul 2022 07:06:06 +0000 (03:06 -0400)] 
Clarifying the documentation on library/syslog (GH-92587)

3 years agogh-95235: Add explicit parameter list to some sqlite3 methods (#95240)
Erlend Egeberg Aasland [Tue, 26 Jul 2022 06:29:18 +0000 (08:29 +0200)] 
gh-95235: Add explicit parameter list to some sqlite3 methods (#95240)

Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
3 years agogh-95041: Fix several minor issues in syslog.openlog() (GH-95058)
Serhiy Storchaka [Tue, 26 Jul 2022 06:12:10 +0000 (09:12 +0300)] 
gh-95041: Fix several minor issues in syslog.openlog() (GH-95058)

* syslog_get_argv() swallows exceptions, but not in all cases.
* if ident is non UTF-8 encodable, syslog.openlog() fails after setting the
  global reference to ident. Now the C string saved internally in the previous
  call to openlog() points to the freed memory.
* PySys_Audit() can crash if ident is NULL.
* There may be a race condition with syslog.syslog(), because the global
  reference to ident is decrefed before setting the new value.
* Possible use of freed memory if syslog.openlog() is called while
  the GIL is released in syslog.syslog().

3 years agogh-91247: Use memcpy for list and tuple repeat (#91482)
Pieter Eendebak [Tue, 26 Jul 2022 02:10:23 +0000 (04:10 +0200)] 
gh-91247: Use memcpy for list and tuple repeat (#91482)

* Add _Py_memory_repeat function to pycore_list

* Add _Py_RefcntAdd function to pycore_object

* Use the new functions in tuplerepeat, list_repeat, and list_inplace_repeat

3 years agoGH-92678: Expose managed dict clear and visit functions (#95246)
Mark Shannon [Mon, 25 Jul 2022 21:30:53 +0000 (22:30 +0100)] 
GH-92678: Expose managed dict clear and visit functions (#95246)

3 years agogh-94673: Always Finalize Static Builtin Types (#95153)
Eric Snow [Mon, 25 Jul 2022 20:23:41 +0000 (14:23 -0600)] 
gh-94673: Always Finalize Static Builtin Types (#95153)

Static builtin types are finalized by calling _PyStaticType_Dealloc().  Before this change, we were skipping finalizing such a type if it still had subtypes (i.e. its tp_subclasses hadn't been cleared yet).  The problem is that types hold several heap objects, which leak if we skip the type's finalization.  This change addresses that.

For context, there's an old comment (from e9e3eab0b86) that says the following:

   // If a type still has subtypes, it cannot be deallocated.
   // A subtype can inherit attributes and methods of its parent type,
   // and a type must no longer be used once it's deallocated.

However, it isn't clear that is actually still true.  Clearing tp_dict should mean it isn't a problem.

Furthermore, the only subtypes that might still be around come from extension modules that didn't clean them up when unloaded (i.e. extensions that do not implement multi-phase initialization, AKA PEP 489).  Those objects are already leaking, so this change doesn't change anything in that regard.  Instead, this change means more objects gets cleaned up that before.

3 years agogh-85454: Remove distutils.ccompiler from Tools/c-analyzer (GH-95171)
Dong-hee Na [Mon, 25 Jul 2022 19:10:30 +0000 (04:10 +0900)] 
gh-85454: Remove distutils.ccompiler from Tools/c-analyzer (GH-95171)

3 years agogh-94673: Add _PyStaticType_InitBuiltin() (#95152)
Eric Snow [Mon, 25 Jul 2022 18:47:31 +0000 (12:47 -0600)] 
gh-94673: Add _PyStaticType_InitBuiltin() (#95152)

This is the first of several precursors to storing tp_subclasses (and tp_weaklist) on the interpreter state for static builtin types.

We do the following:

* add `_PyStaticType_InitBuiltin()`
* add `_Py_TPFLAGS_STATIC_BUILTIN`
* set it on all static builtin types in `_PyStaticType_InitBuiltin()`
* shuffle some code around to be able to use _PyStaticType_InitBuiltin()
    * rename `_PyStructSequence_InitType()` to `_PyStructSequence_InitBuiltinWithFlags()`
    * add `_PyStructSequence_InitBuiltin()`.

3 years agogh-92546: Move pprint benchmark into pyperformance (GH-94613)
Oleg Iarygin [Mon, 25 Jul 2022 18:30:13 +0000 (21:30 +0300)] 
gh-92546: Move pprint benchmark into pyperformance (GH-94613)

This PR couples with https://github.com/python/pyperformance/pull/222 and supersedes https://github.com/python/cpython/pull/92560. Inspired by https://github.com/python/cpython/issues/93096#issuecomment-1134576471.

Automerge-Triggered-By: GH:ericsnowcurrently
3 years agogh-95077: [Enum] add code-based deprecation warnings for member.member access (GH...
Ethan Furman [Mon, 25 Jul 2022 18:05:10 +0000 (11:05 -0700)] 
gh-95077: [Enum] add code-based deprecation warnings for member.member access (GH-95083)

* issue deprecation warning for member.member access
* always store member property in current class
* remove __getattr__

3 years agoGH-94851: check refcnt of immortal objects after finalization (GH-95001)
Kumar Aditya [Mon, 25 Jul 2022 17:43:59 +0000 (23:13 +0530)] 
GH-94851: check refcnt of immortal objects after finalization (GH-95001)

3 years agogh-95235: Document undocumented parameters in sqlite3 functions and methods (#95236)
Erlend Egeberg Aasland [Mon, 25 Jul 2022 16:46:55 +0000 (18:46 +0200)] 
gh-95235: Document undocumented parameters in sqlite3 functions and methods (#95236)

Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
3 years agogh-93963: Document importlib.abc deprecations (#94546)
Hugo van Kemenade [Mon, 25 Jul 2022 16:24:42 +0000 (19:24 +0300)] 
gh-93963: Document importlib.abc deprecations (#94546)

3 years agogh-93610: Improve docs for importlib.resources (#93611)
Petr Viktorin [Mon, 25 Jul 2022 16:16:17 +0000 (18:16 +0200)] 
gh-93610: Improve docs for importlib.resources (#93611)

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
3 years agogh-85454: Remove distutils documentation (#95239)
Christian Heimes [Mon, 25 Jul 2022 13:50:46 +0000 (15:50 +0200)] 
gh-85454: Remove distutils documentation (#95239)

Most places now refer to setuptools or link to setuptools documentation.
Some examples like zipapp need to be updated later.

3 years agogh-85454: Remove links from historical mentions of distutils (GH-95192)
Oleg Iarygin [Mon, 25 Jul 2022 10:20:09 +0000 (13:20 +0300)] 
gh-85454: Remove links from historical mentions of distutils (GH-95192)

3 years agogh-95233: Correct grp.getgrgid parameter name in documentation (gid -> id) (gh-95232)
Adam Dangoor [Mon, 25 Jul 2022 09:54:42 +0000 (11:54 +0200)] 
gh-95233: Correct grp.getgrgid parameter name in documentation (gid -> id) (gh-95232)

3 years agogh-95205: Improve wasm README (#95206)
Erlend Egeberg Aasland [Mon, 25 Jul 2022 07:42:50 +0000 (09:42 +0200)] 
gh-95205: Improve wasm README (#95206)

Co-authored-by: Christian Heimes <christian@python.org>
3 years agogh-95087: Fix IndexError in parsing invalid date in the email module (GH-95201)
Serhiy Storchaka [Mon, 25 Jul 2022 06:17:25 +0000 (09:17 +0300)] 
gh-95087: Fix IndexError in parsing invalid date in the email module (GH-95201)

Co-authored-by: wouter bolsterlee <wouter@bolsterl.ee>
3 years agogh-95212: make multiprocessing test case parallel-safe (GH-95213)
Christian Heimes [Mon, 25 Jul 2022 04:44:40 +0000 (06:44 +0200)] 
gh-95212: make multiprocessing test case parallel-safe (GH-95213)

3 years agogh-95218: Move tests for importlib.resources into test_importlib.resources. (#95219)
Jason R. Coombs [Mon, 25 Jul 2022 00:53:10 +0000 (20:53 -0400)] 
gh-95218: Move tests for importlib.resources into test_importlib.resources. (#95219)

* gh-95218: Move tests for importlib.resources into test_importlib.resources.

* Also update makefile

* Include test_importlib/resources in code ownership rule.

3 years agogh-95173: Revert commit 51ed2c56a1852cd6b09c85ba81312dc9782772ce (#95176)
Pablo Galindo Salgado [Sun, 24 Jul 2022 21:33:06 +0000 (22:33 +0100)] 
gh-95173: Revert commit 51ed2c56a1852cd6b09c85ba81312dc9782772ce (#95176)

3 years agogh-95051: ensure that timeouts scheduled with `asyncio.Timeout` that have already...
Thomas Grainger [Sun, 24 Jul 2022 20:18:05 +0000 (21:18 +0100)] 
gh-95051: ensure that timeouts scheduled with `asyncio.Timeout` that have already expired are deliverered promptly (#95109)

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
3 years agolog2() is faster than log() (#95214)
Raymond Hettinger [Sun, 24 Jul 2022 19:21:29 +0000 (14:21 -0500)] 
log2() is faster than log() (#95214)

3 years agogh-95185: Check recursion depth in the AST constructor (#95186)
Pablo Galindo Salgado [Sun, 24 Jul 2022 14:58:52 +0000 (15:58 +0100)] 
gh-95185: Check recursion depth in the AST constructor (#95186)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
3 years agogh-95199: upgrade bundled setuptools to 63.2.0 (gh-95200)
Stéphane Bidoul [Sun, 24 Jul 2022 11:01:03 +0000 (13:01 +0200)] 
gh-95199: upgrade bundled setuptools to 63.2.0 (gh-95200)

3 years agogh-95194: upgrade bundled pip to 22.2 (gh-95195)
Stéphane Bidoul [Sun, 24 Jul 2022 09:55:25 +0000 (11:55 +0200)] 
gh-95194: upgrade bundled pip to 22.2 (gh-95195)

upgrade bundled pip to 22.2

3 years agogh-95174: Handle missing waitpid and gethostbyname in WASI (GH-95181)
Christian Heimes [Sun, 24 Jul 2022 06:04:06 +0000 (08:04 +0200)] 
gh-95174: Handle missing waitpid and gethostbyname in WASI (GH-95181)

3 years agogh-93157: Fix fileinput didn't support `errors` in `inplace` mode (GH-95128)
Inada Naoki [Sun, 24 Jul 2022 02:42:11 +0000 (11:42 +0900)] 
gh-93157: Fix fileinput didn't support `errors` in `inplace` mode (GH-95128)

3 years agoCompute v only when needed. (#95183)
Raymond Hettinger [Sat, 23 Jul 2022 23:07:17 +0000 (18:07 -0500)] 
Compute v only when needed. (#95183)

3 years agogh-90385: Add skip_unless_symlink decorator to test_walk_symlink_location (GH-95182)
Christian Heimes [Sat, 23 Jul 2022 21:42:04 +0000 (23:42 +0200)] 
gh-90385: Add skip_unless_symlink decorator to test_walk_symlink_location (GH-95182)

3 years agogh-93351: Add news entry and what's new entry for changes in gh-93351 (#95175)
Pablo Galindo Salgado [Sat, 23 Jul 2022 18:35:44 +0000 (19:35 +0100)] 
gh-93351: Add news entry and what's new entry for changes in gh-93351 (#95175)

3 years agogh-90473: Check for HAVE_KILL in main.c:exit_sigint (GH-95165)
Christian Heimes [Sat, 23 Jul 2022 10:29:00 +0000 (12:29 +0200)] 
gh-90473: Check for HAVE_KILL in main.c:exit_sigint (GH-95165)

3 years agogh-90473: Fix more tests on platforms without umask (GH-95164)
Christian Heimes [Sat, 23 Jul 2022 10:26:31 +0000 (12:26 +0200)] 
gh-90473: Fix more tests on platforms without umask (GH-95164)

3 years agogh-89758: Track all socket module dependencies (#95157)
Christian Heimes [Sat, 23 Jul 2022 09:34:50 +0000 (11:34 +0200)] 
gh-89758: Track all socket module dependencies (#95157)

3 years agoDoc: Add omitted secondary prompt in inputoutput tutorial (GH-30317)
Chenwei Xiao [Sat, 23 Jul 2022 09:25:42 +0000 (17:25 +0800)] 
Doc: Add omitted secondary prompt in inputoutput tutorial (GH-30317)

For the continuation lines, "..." should present as secondary prompt

3 years agogh-95132: Correctly relay *args and **kwds from sqlite3.connect to factory (#95146)
Erlend Egeberg Aasland [Sat, 23 Jul 2022 07:51:28 +0000 (09:51 +0200)] 
gh-95132: Correctly relay *args and **kwds from sqlite3.connect to factory (#95146)

This PR partially reverts gh-24421 (PR) and fixes the remaining concerns
given in gh-93044 (issue):

- keyword arguments are passed as positional arguments to factory()
- if an argument is not passed to sqlite3.connect(), its default value
  is passed to factory()

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
3 years agogh-90385: Add `pathlib.Path.walk()` method (GH-92517)
Stanislav Zmiev [Fri, 22 Jul 2022 23:55:46 +0000 (03:55 +0400)] 
gh-90385: Add `pathlib.Path.walk()` method (GH-92517)

Automerge-Triggered-By: GH:brettcannon
3 years agoGH-94438: Handle extended arguments and conditional pops in mark_stacks (GH-95110)
Brandt Bucher [Fri, 22 Jul 2022 23:28:03 +0000 (16:28 -0700)] 
GH-94438: Handle extended arguments and conditional pops in mark_stacks (GH-95110)

3 years agoGH-94036: Fix more attribute location quirks (GH-95028)
Brandt Bucher [Fri, 22 Jul 2022 20:13:16 +0000 (13:13 -0700)] 
GH-94036: Fix more attribute location quirks (GH-95028)

3 years agoFix copy-friendliness of tutorial example (GH-93424)
Chenwei Xiao [Fri, 22 Jul 2022 20:11:48 +0000 (04:11 +0800)] 
Fix copy-friendliness of tutorial example (GH-93424)

3 years agoGH-95113: Don't use EXTENDED_ARG_QUICK in unquickened code (GH-95121)
Brandt Bucher [Fri, 22 Jul 2022 18:04:20 +0000 (11:04 -0700)] 
GH-95113: Don't use EXTENDED_ARG_QUICK in unquickened code (GH-95121)

3 years agoFix async method reference links in `compound_stmts` docs (GH-94935)
July Tikhonov [Fri, 22 Jul 2022 17:03:17 +0000 (20:03 +0300)] 
Fix async method reference links in `compound_stmts` docs (GH-94935)

3 years agoFix scheme count in `sysconfig` whatsnew entry (GH-94110)
Frank Dana [Fri, 22 Jul 2022 16:51:14 +0000 (12:51 -0400)] 
Fix scheme count in `sysconfig` whatsnew entry (GH-94110)

3 years agoFix incorrect directive in multiprocessing module documentation (GH-93517)
oda-gitso [Fri, 22 Jul 2022 16:46:42 +0000 (23:46 +0700)] 
Fix incorrect directive in multiprocessing module documentation (GH-93517)

3 years agoCloses gh-95133: docs, fix indentation level in TestCase.assertLogs example (GH-95134)
Alexandru Mărășteanu [Fri, 22 Jul 2022 16:37:22 +0000 (19:37 +0300)] 
Closes gh-95133: docs, fix indentation level in TestCase.assertLogs example (GH-95134)

3 years agoUse Markdown Headers in GitHub Issue templates (GH-95111)
Mariatta Wijaya [Fri, 22 Jul 2022 16:19:08 +0000 (09:19 -0700)] 
Use Markdown Headers in GitHub Issue templates (GH-95111)

The Issue templates are using the markup to make text bold.
We should be using proper text headers instead.

I replaced the **bold** text markup with L1 headers.

3 years agogh-81040: Improve sqlite3.Cursor.rowcount docs (#94940)
Erlend Egeberg Aasland [Fri, 22 Jul 2022 07:34:39 +0000 (09:34 +0200)] 
gh-81040: Improve sqlite3.Cursor.rowcount docs (#94940)

3 years agoFix typo in PROTOCOL_TO_TLS_VERSION in test_ssl (GH-95119)
David Benjamin [Fri, 22 Jul 2022 00:38:15 +0000 (17:38 -0700)] 
Fix typo in PROTOCOL_TO_TLS_VERSION in test_ssl (GH-95119)

This appears to be a typo. It causes try_protocol_combo to try to turn
on SSL 3.0 when testing PROTOCOL_SSLv23 (aka PROTOCOL_TLS), which
doesn't make any sense. Fix it to be PROTOCOL_SSLv3.

Without this, try_protocol_combo is actually setting
context.minimum_version to SSLv3 when called as
try_protocol_combo(ssl.PROTOCOL_TLS, ssl.PROTOCOL_TLS, True)

One would think this causes a no-ssl3 OpenSSL build to fail, but OpenSSL
forgot to make SSL_CTX_set_min_proto_version(SSL3_VERSION) does not
notice no-ssl3, so this typo has gone undetected. But we should still
fix the typo because, presumably, a future version of OpenSSL will
remove SSL 3.0 and do so more thoroughly, at which point this will
break.

3 years agogh-95112: Fix What's New 3.12 contribution note periods (#95118)
Terry Jan Reedy [Fri, 22 Jul 2022 00:36:53 +0000 (20:36 -0400)] 
gh-95112: Fix What's New 3.12 contribution note periods (#95118)

A couple, so far, are missing.

3 years agogh-95112: Fix What's New 3.11 contribution note periods (#95115)
Terry Jan Reedy [Fri, 22 Jul 2022 00:35:56 +0000 (20:35 -0400)] 
gh-95112: Fix What's New 3.11 contribution note periods (#95115)

Some are missing, a few placed after the ')'.

3 years agogh-95112: Fix What's New 3.10 contribution note periods (#95114)
Terry Jan Reedy [Fri, 22 Jul 2022 00:00:52 +0000 (20:00 -0400)] 
gh-95112: Fix What's New 3.10 contribution note periods (#95114)

Some are missing, a few placed after the ')'.
One ') was missing.

3 years agogh-95105: Return Iterator from wsgiref.types.InputStream.__iter__ (#95106)
Shantanu [Thu, 21 Jul 2022 20:26:04 +0000 (13:26 -0700)] 
gh-95105: Return Iterator from wsgiref.types.InputStream.__iter__ (#95106)

3 years agogh-95095: Use SSL_CTX_get_max_proto_version instead of SSL_CTX_ctrl (GH-95096)
David Benjamin [Thu, 21 Jul 2022 18:44:30 +0000 (11:44 -0700)] 
gh-95095: Use SSL_CTX_get_max_proto_version instead of SSL_CTX_ctrl (GH-95096)

The wrapper macros are more readable and match the form recommended in
the OpenSSL documentation. They also slightly less error-prone, as the
mapping of arguments to SSL_CTX_ctrl is not always clear. (Though in
this case it's straightforward.)
https://www.openssl.org/docs/man1.1.1/man3/SSL_CTX_get_max_proto_version.html

3 years agoFix PyCode_Addr2Location when addrq < 0 (GH-95091)
Ken Jin [Thu, 21 Jul 2022 13:49:49 +0000 (21:49 +0800)] 
Fix PyCode_Addr2Location when addrq < 0 (GH-95091)

3 years agogh-95010: Fix asyncio GenericWatcherTests.test_create_subprocess_fails_with_inactive_...
Thomas Grainger [Thu, 21 Jul 2022 11:35:20 +0000 (12:35 +0100)] 
gh-95010: Fix asyncio GenericWatcherTests.test_create_subprocess_fails_with_inactive_watcher (GH-95009)

The test was never run, because it was missing the TestCase class.
The test failed because the wrong attribute was patched.

3 years agoGH-95029: Describe Windows Store package isolation and redirection in more detail...
Anthony Shaw [Thu, 21 Jul 2022 00:01:23 +0000 (01:01 +0100)] 
GH-95029: Describe Windows Store package isolation and redirection in more detail (GH-95030)

3 years agodocs: use 'recursively' in the description of rglob, and mention globs in the os...
Ned Batchelder [Wed, 20 Jul 2022 21:47:43 +0000 (14:47 -0700)] 
docs: use 'recursively' in the description of rglob, and mention globs in the os equivalences (GH-94954)

The r in `rglob` stands for "recursively", so use the word in the description. Also, glob and rglob can usefully be mentioned as the pathlib equivalent of os.walk.

Automerge-Triggered-By: GH:brettcannon
3 years agogh-82116: add comment explaining use of `list(scandir_it)` in pathlib. (GH-94939)
Barney Gale [Wed, 20 Jul 2022 21:34:13 +0000 (22:34 +0100)] 
gh-82116: add comment explaining use of `list(scandir_it)` in pathlib. (GH-94939)

Automerge-Triggered-By: GH:brettcannon
3 years agoGH-91409: Don't overwrite valid locations with NOP locations (GH-95067)
Brandt Bucher [Wed, 20 Jul 2022 21:27:31 +0000 (14:27 -0700)] 
GH-91409: Don't overwrite valid locations with NOP locations (GH-95067)

3 years agogh-91102: Port 8-argument _warnings.warn_explicit to Argument Clinic (#92891)
Oleg Iarygin [Wed, 20 Jul 2022 20:24:51 +0000 (23:24 +0300)] 
gh-91102: Port 8-argument _warnings.warn_explicit to Argument Clinic (#92891)

Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
3 years agogh-90016: Deprecate default sqlite3 adapters and converters (#94276)
Erlend Egeberg Aasland [Wed, 20 Jul 2022 19:37:59 +0000 (21:37 +0200)] 
gh-90016: Deprecate default sqlite3 adapters and converters (#94276)

Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
3 years agoGH-94382: port multiprocessing static types to heap types (#94336)
Kumar Aditya [Wed, 20 Jul 2022 19:26:01 +0000 (00:56 +0530)] 
GH-94382: port multiprocessing static types to heap types (#94336)

3 years agogh-54781: Move NEWS item to Tests, and improve wording (#95063)
Erlend Egeberg Aasland [Wed, 20 Jul 2022 19:23:59 +0000 (21:23 +0200)] 
gh-54781: Move NEWS item to Tests, and improve wording (#95063)

3 years agogh-94998: Remove redundant condition in test_sqlite3/__main__.py (#95052)
Erlend Egeberg Aasland [Wed, 20 Jul 2022 16:07:47 +0000 (18:07 +0200)] 
gh-94998: Remove redundant condition in test_sqlite3/__main__.py (#95052)

3 years agogh-94844: Add pathlib support to shutil archive management (GH-94846)
Oleg Iarygin [Wed, 20 Jul 2022 15:55:12 +0000 (18:55 +0300)] 
gh-94844: Add pathlib support to shutil archive management (GH-94846)

Co-authored-by: Barney Gale <barney.gale@gmail.com>
3 years agoGH-94851: fix immortal objects refcounting in compiler (gh-95040)
Kumar Aditya [Wed, 20 Jul 2022 09:53:27 +0000 (15:23 +0530)] 
GH-94851: fix immortal objects refcounting in compiler (gh-95040)

3 years agogh-90654: Remove unneeded blank line (#95044)
Terry Jan Reedy [Wed, 20 Jul 2022 09:38:56 +0000 (05:38 -0400)] 
gh-90654: Remove unneeded blank line (#95044)

3 years agogh-90654: Add item missing from idlelib/NEWS.txt (#95038)
Terry Jan Reedy [Wed, 20 Jul 2022 07:18:10 +0000 (03:18 -0400)] 
gh-90654: Add item missing from idlelib/NEWS.txt (#95038)

3 years agogh-93939: Use new MODULE_name_STATE in wasm_assets script (GH-95035)
Christian Heimes [Wed, 20 Jul 2022 06:53:26 +0000 (08:53 +0200)] 
gh-93939: Use new MODULE_name_STATE in wasm_assets script (GH-95035)

3 years agoGH-90699: fix ref counting of static immortal strings (gh-94850)
Kumar Aditya [Wed, 20 Jul 2022 06:23:30 +0000 (11:53 +0530)] 
GH-90699: fix ref counting of static immortal strings (gh-94850)

3 years agoRemove blurb boilerplate from news item (#95033)
Terry Jan Reedy [Wed, 20 Jul 2022 05:48:35 +0000 (01:48 -0400)] 
Remove blurb boilerplate from news item (#95033)

3 years agogh-95007: Remove the NoneType return converter (GH-95019)
Serhiy Storchaka [Wed, 20 Jul 2022 05:42:02 +0000 (08:42 +0300)] 
gh-95007: Remove the NoneType return converter (GH-95019)

It has confusing semantic which does not provide any benefit (the
only difference is that you should write "return Py_None" instead
of "Py_RETURN_NONE"), it is not currently used, and it is broken.

3 years agogh-93370: Don't print deprecated pysqlite version in test_sqlite3 (#95017)
Erlend Egeberg Aasland [Tue, 19 Jul 2022 21:04:20 +0000 (23:04 +0200)] 
gh-93370: Don't print deprecated pysqlite version in test_sqlite3 (#95017)

3 years agogh-91256: Ensure help text has the program name even before getpath is called (GH...
Steve Dower [Tue, 19 Jul 2022 18:39:11 +0000 (19:39 +0100)] 
gh-91256: Ensure help text has the program name even before getpath is called (GH-94929)