]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
4 years agobpo-45116: Py_DEBUG ignores Py_ALWAYS_INLINE (GH-28419)
Victor Stinner [Fri, 17 Sep 2021 20:46:38 +0000 (22:46 +0200)] 
bpo-45116: Py_DEBUG ignores Py_ALWAYS_INLINE (GH-28419)

If the Py_DEBUG macro is defined, the Py_ALWAYS_INLINE macro does
nothing.

4 years agobpo-45187: Fix dangling threads in test_socket.CreateServerFunctionalTest (GH-28422)
Serhiy Storchaka [Fri, 17 Sep 2021 18:56:41 +0000 (21:56 +0300)] 
bpo-45187: Fix dangling threads in test_socket.CreateServerFunctionalTest (GH-28422)

4 years agobpo-45020: Fix build out of source tree (GH-28410)
Victor Stinner [Fri, 17 Sep 2021 18:20:43 +0000 (20:20 +0200)] 
bpo-45020: Fix build out of source tree (GH-28410)

* Makefile.pre.in: Add $(srcdir) when needed, remove it when it was
  used by mistake.
* freeze_modules.py tool uses ./Programs/_freeze_module if the
  executable doesn't exist in the source tree.

4 years agobpo-45231: update_file.py preserves end of line (GH-28411)
Victor Stinner [Fri, 17 Sep 2021 18:12:25 +0000 (20:12 +0200)] 
bpo-45231: update_file.py preserves end of line (GH-28411)

The update_file.py tool now preserves the end of line of the updated
file. Fix the "make regen-frozen" command: it no longer changes the
end of line of PCbuild/ files on Unix. Git changes the end of line
depending on the platform.

4 years agoRemove compatibility check for Python versions below 2.2. (GH-28314)
Omer Katz [Fri, 17 Sep 2021 13:36:41 +0000 (16:36 +0300)] 
Remove compatibility check for Python versions below 2.2. (GH-28314)

`os.path.realpath()` already exists in all our supported Python versions.
There's no longer a need to check if it exists or not.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-45212: Add a comment for time.sleep() in tests (GH-28414)
Serhiy Storchaka [Fri, 17 Sep 2021 13:20:15 +0000 (16:20 +0300)] 
bpo-45212: Add a comment for time.sleep() in tests (GH-28414)

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45116: Add the Py_ALWAYS_INLINE macro (GH-28390)
Victor Stinner [Fri, 17 Sep 2021 12:09:14 +0000 (14:09 +0200)] 
bpo-45116: Add the Py_ALWAYS_INLINE macro (GH-28390)

Add the Py_ALWAYS_INLINE macro to ask the compiler to always inline a
static inline function. The compiler can ignore it and decides to not
inline the function.

4 years agobpo-45219: Factor dictkey indexing (GH-28389)
Mark Shannon [Fri, 17 Sep 2021 11:20:51 +0000 (12:20 +0100)] 
bpo-45219: Factor dictkey indexing (GH-28389)

4 years agobpo-45217: adds note that `allow_no_value` in `configparser` is optional (GH-28396)
Nikita Sobolev [Fri, 17 Sep 2021 10:55:51 +0000 (13:55 +0300)] 
bpo-45217: adds note that `allow_no_value` in `configparser` is optional (GH-28396)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-45107: Make LOAD_METHOD_CLASS safer and faster, clean up comments (GH-28177)
Ken Jin [Fri, 17 Sep 2021 10:47:36 +0000 (18:47 +0800)] 
bpo-45107: Make LOAD_METHOD_CLASS safer and faster, clean up comments (GH-28177)

* Improve comments

* Check cls is a type, remove dict calculation

4 years agobpo-45162: Remove many old deprecated unittest features (GH-28268)
Serhiy Storchaka [Fri, 17 Sep 2021 10:33:27 +0000 (13:33 +0300)] 
bpo-45162: Remove many old deprecated unittest features (GH-28268)

* "fail*" and "assert*" aliases of TestCase methods.
* Broken from start TestCase method assertDictContainsSubset().
* Ignored TestLoader.loadTestsFromModule() parameter use_load_tests.
* Old alias _TextTestResult of TextTestResult.

4 years agobpo-45187: Collect test_socket tests using unittest (GH-28317)
Serhiy Storchaka [Fri, 17 Sep 2021 10:13:09 +0000 (13:13 +0300)] 
bpo-45187: Collect test_socket tests using unittest (GH-28317)

Previously, test classes ISOTPTest, J1939Test, BasicUDPLITETest and
UDPLITETimeoutTest were not included in the list of tests and
were not run by regrtest.

4 years agobpo-45203: fix compiler warnings (GH-28357)
Ken Jin [Fri, 17 Sep 2021 09:48:44 +0000 (17:48 +0800)] 
bpo-45203: fix compiler warnings (GH-28357)

Co-authored-by: Mark Shannon <mark@hotpy.org>
4 years agobpo-5846: Fix deprecations for obsolete unittest functions and add tests. (GH-28382)
Serhiy Storchaka [Fri, 17 Sep 2021 09:09:32 +0000 (12:09 +0300)] 
bpo-5846: Fix deprecations for obsolete unittest functions and add tests. (GH-28382)

4 years agobpo-45228: Fix stack buffer overflow in parsing J1939 address (GH-28404)
Serhiy Storchaka [Fri, 17 Sep 2021 08:46:19 +0000 (11:46 +0300)] 
bpo-45228: Fix stack buffer overflow in parsing J1939 address (GH-28404)

4 years agoFix typo and add a module prefix (GH-28401)
Raymond Hettinger [Fri, 17 Sep 2021 04:49:41 +0000 (23:49 -0500)] 
Fix typo and add a module prefix (GH-28401)

4 years agobpo-45020: Drop the frozen .h files from the repo. (gh-28392)
Eric Snow [Thu, 16 Sep 2021 20:20:52 +0000 (14:20 -0600)] 
bpo-45020: Drop the frozen .h files from the repo. (gh-28392)

The main advantage is that the files will no longer show up in diffs and PRs. That means, for a PR, the number of files / lines changed will more clearly reflect the actual change.  (This is essentially an un-revert of gh-28375.)

https://bugs.python.org/issue45020

4 years agobpo-45225: use map function instead of genexpr in capwords (GH-28342)
speedrun-program [Thu, 16 Sep 2021 19:49:38 +0000 (12:49 -0700)] 
bpo-45225: use map function instead of genexpr in capwords (GH-28342)

4 years agobpo-45220: Avoid automatically selecting the Windows 11 SDK preview when building...
Steve Dower [Thu, 16 Sep 2021 18:29:32 +0000 (19:29 +0100)] 
bpo-45220: Avoid automatically selecting the Windows 11 SDK preview when building (GH-28393)

4 years agobpo-45212: Fix dangling threads in skipped tests in test_socket (GH-28361)
Serhiy Storchaka [Thu, 16 Sep 2021 10:30:00 +0000 (13:30 +0300)] 
bpo-45212: Fix dangling threads in skipped tests in test_socket (GH-28361)

tearDown() is not called if setUp() raises an exception
(including SkipTest). addCleanup() should be used for guaranteed
execution of the cleanup code.

4 years agodocs: correct references to __isub__ etc (GH-28297)
David Hewitt [Thu, 16 Sep 2021 08:33:41 +0000 (09:33 +0100)] 
docs: correct references to __isub__ etc (GH-28297)

4 years agobpo-45020: Revert "Drop the frozen .h files from the repo." (gh-28380)
Eric Snow [Thu, 16 Sep 2021 05:27:38 +0000 (23:27 -0600)] 
bpo-45020: Revert "Drop the frozen .h files from the repo." (gh-28380)

gh-28375 broke one of the buildbots. Until I figure out why, I'm rolling the change back.

https://bugs.python.org/issue45020

4 years agobpo-45155 : Default arguments for int.to_bytes(length=1, byteorder=sys.byteorder...
Barry Warsaw [Thu, 16 Sep 2021 02:55:24 +0000 (19:55 -0700)] 
bpo-45155 : Default arguments for int.to_bytes(length=1, byteorder=sys.byteorder) (#28265)

Add default arguments for int.to_bytes() and int.from_bytes()

Co-authored-by: Brandt Bucher <brandtbucher@gmail.com>
4 years agobpo-45020: Drop the frozen .h files from the repo. (gh-28375)
Eric Snow [Thu, 16 Sep 2021 01:15:26 +0000 (19:15 -0600)] 
bpo-45020: Drop the frozen .h files from the repo. (gh-28375)

The main advantage is that the files will no longer show up in diffs and PRs. That means, for a PR, the number of files / lines changed will more clearly reflect the actual change.

https://bugs.python.org/issue45020

4 years agobpo-39710: Remove Python 2-specific sentence from calendar documentation (GH-26985)
Hubert Badocha [Wed, 15 Sep 2021 20:36:38 +0000 (22:36 +0200)] 
bpo-39710: Remove Python 2-specific sentence from calendar documentation (GH-26985)

4 years agobpo-45019: Clean up the frozen __hello__ module. (gh-28374)
Eric Snow [Wed, 15 Sep 2021 20:15:32 +0000 (14:15 -0600)] 
bpo-45019: Clean up the frozen __hello__ module. (gh-28374)

Here's one more small cleanup that should have been in PR gh-28319. We eliminate stdout side-effects from importing the frozen __hello__ module, and update tests accordingly. We also move the module's source file into Lib/ from Toos/freeze/flag.py.

https://bugs.python.org/issue45019

4 years agoFix typo in Lib/sqlite3/test/test_types.py (GH-28226)
Konstantin Popov [Wed, 15 Sep 2021 20:09:08 +0000 (23:09 +0300)] 
Fix typo in Lib/sqlite3/test/test_types.py (GH-28226)

preceeding -> preceding

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-45019: Silence a warning in test_ctypes. (gh-28362)
Eric Snow [Wed, 15 Sep 2021 19:33:05 +0000 (13:33 -0600)] 
bpo-45019: Silence a warning in test_ctypes. (gh-28362)

This was missed in PR gh-28319.

https://bugs.python.org/issue45019

4 years agobpo-45089: Improve sqlite3 trace callback docs (GH-28238)
Erlend Egeberg Aasland [Wed, 15 Sep 2021 18:39:05 +0000 (20:39 +0200)] 
bpo-45089: Improve sqlite3 trace callback docs (GH-28238)

- Add link to str object and sqlite3 transaction control
- Mention that exceptions are not propagated

4 years agobpo-5846: Deprecate obsolete methods in `unittest` (GH-28299)
Erlend Egeberg Aasland [Wed, 15 Sep 2021 18:33:31 +0000 (20:33 +0200)] 
bpo-5846: Deprecate obsolete methods in `unittest` (GH-28299)

Deprecate makeSuite, findTestCases, and getTestCaseNames. Scheduled for removal in Python 3.13.

4 years agobpo-45193: News for IDLE PR_28343 (GH-28348)
Terry Jan Reedy [Wed, 15 Sep 2021 18:26:43 +0000 (14:26 -0400)] 
bpo-45193: News for IDLE PR_28343 (GH-28348)

4 years agobpo-45167: Fix deepcopying of GenericAlias (GH-28324)
Serhiy Storchaka [Wed, 15 Sep 2021 18:25:41 +0000 (21:25 +0300)] 
bpo-45167: Fix deepcopying of GenericAlias (GH-28324)

4 years agobpo-45207: Make test_gdb.test_pycfunction() quiet (GH-28355)
Victor Stinner [Wed, 15 Sep 2021 18:21:06 +0000 (20:21 +0200)] 
bpo-45207: Make test_gdb.test_pycfunction() quiet (GH-28355)

test_gdb.test_pycfunction() now ignores gdb stderr, it no longer logs
messages like:

    Function "meth_varargs" not defined.

4 years agobpo-45205: Make test_compileall quiet (GH-28356)
Victor Stinner [Wed, 15 Sep 2021 18:20:45 +0000 (20:20 +0200)] 
bpo-45205: Make test_compileall quiet (GH-28356)

Make test_compileall quiet: test_year_2038_mtime_compilation() and
test_larger_than_32_bit_times() of test_compileall no longer log
"Compiling ..." messages to stdout.

4 years agobpo-45208: Make test_pdb.test_checkline_is_not_executable() quiet (GH-28354)
Victor Stinner [Wed, 15 Sep 2021 18:19:31 +0000 (20:19 +0200)] 
bpo-45208: Make test_pdb.test_checkline_is_not_executable() quiet (GH-28354)

test_pdb.test_checkline_is_not_executable() no longer writes output
to stdout.

Remove also unused variables 'f'.

4 years agobpo-45204: Reduce verbosity of test_peg_generator (GH-28360)
Pablo Galindo Salgado [Wed, 15 Sep 2021 18:16:51 +0000 (19:16 +0100)] 
bpo-45204: Reduce verbosity of test_peg_generator (GH-28360)

4 years agobpo-45188: Windows now regenerates frozen modules at the start of build instead of...
Steve Dower [Wed, 15 Sep 2021 17:11:12 +0000 (18:11 +0100)] 
bpo-45188: Windows now regenerates frozen modules at the start of build instead of late (GH-28322)

This will enable us to drop the frozen module header files from the repository.

It does currently cause many source files to be built twice, which just takes more time. For whoever comes to fix this in the future, the files shared between freeze_module and pythoncore should be put into a static library that is consumed by both.

4 years agobpo-45185: enables `TestEnumerations` in `test_ssl` (GH-28330)
Nikita Sobolev [Wed, 15 Sep 2021 16:57:03 +0000 (19:57 +0300)] 
bpo-45185: enables `TestEnumerations` in `test_ssl` (GH-28330)

4 years agobpo-45020: Freeze some of the modules imported during startup. (gh-28335)
Eric Snow [Wed, 15 Sep 2021 16:19:30 +0000 (10:19 -0600)] 
bpo-45020: Freeze some of the modules imported during startup. (gh-28335)

Doing this provides significant performance gains for runtime startup (~15% with all the imported modules frozen). We don't yet freeze all the imported modules because there are a few hiccups in the build systems we need to sort out first. (See bpo-45186 and bpo-45188.)

Note that in PR GH-28320 we added a command-line flag (-X frozen_modules=[on|off]) that allows users to opt out of (or into) using frozen modules. The default is still "off" but we will change it to "on" as soon as we can do it in a way that does not cause contributors pain.

https://bugs.python.org/issue45020

4 years agobpo-44786: Fix a warning in RE in c-analyzer (GH-28351)
Serhiy Storchaka [Wed, 15 Sep 2021 14:08:48 +0000 (17:08 +0300)] 
bpo-44786: Fix a warning in RE in c-analyzer (GH-28351)

4 years agobpo-45203: Cleanup stats gathering code for LOAD_METHOD (GH-28352)
Mark Shannon [Wed, 15 Sep 2021 13:55:49 +0000 (14:55 +0100)] 
bpo-45203: Cleanup stats gathering code for LOAD_METHOD (GH-28352)

4 years agobpo-21302: Add _PyTime_AsNanoseconds() (GH-28350)
Victor Stinner [Wed, 15 Sep 2021 12:26:43 +0000 (14:26 +0200)] 
bpo-21302: Add _PyTime_AsNanoseconds() (GH-28350)

Refactor pytime.c:

* Add pytime_from_nanoseconds() and pytime_as_nanoseconds(),
  and use explicitly these functions
* Add two empty lines between functions
* PEP 7: add braces { ... }
* C99: declare variables where they are set
* Rename private functions to lowercase
* Rename error_time_t_overflow() to pytime_time_t_overflow()
* Rename win_perf_counter_frequency() to py_win_perf_counter_frequency()
* py_get_monotonic_clock(): add an assertion to detect overflow when
  mach_absolute_time() unsigned uint64_t is casted to _PyTime_t
  (signed int64_t).

_testcapi: use _PyTime_FromNanoseconds().

4 years agobpo-45152: refactor the dis module to make handling of hasconst opcodes more generic...
Irit Katriel [Wed, 15 Sep 2021 09:14:15 +0000 (10:14 +0100)] 
bpo-45152: refactor the dis module to make handling of hasconst opcodes more generic (GH-28258)

4 years agobpo-45193: Restore IDLE completion boxes on Ubuntu (GH-28343)
Terry Jan Reedy [Wed, 15 Sep 2021 07:13:23 +0000 (03:13 -0400)] 
bpo-45193: Restore IDLE completion boxes on Ubuntu (GH-28343)

The line that should not have been needed on macOS tk 8.6.8 but was,
should not be a problem on Ubuntu, but is.  It is not needed on macOS
tk 8.6.11, installed with 3.10.  Disable it but leave it for
now in case some system needs it.

4 years agobpo-45020: Don't test IDLE with frozen module. (GH-28344)
Terry Jan Reedy [Wed, 15 Sep 2021 07:08:44 +0000 (03:08 -0400)] 
bpo-45020: Don't test IDLE with frozen module. (GH-28344)

Otherwise, test would need special import.

4 years agobpo-45020: Add -X frozen_modules=[on|off] to explicitly control use of frozen modules...
Eric Snow [Tue, 14 Sep 2021 23:31:45 +0000 (17:31 -0600)] 
bpo-45020: Add -X frozen_modules=[on|off] to explicitly control use of frozen modules. (gh-28320)

Currently we freeze several modules into the runtime. For each of these modules it is essential to bootstrapping the runtime that they be frozen. Any other stdlib module that we later freeze into the runtime is not essential. We can just as well import from the .py file.  This PR lets users explicitly choose which should be used, with the new "-X frozen_modules=[on|off]" CLI flag. The default is "off" for now.

https://bugs.python.org/issue45020

4 years agobpo-4356: Mention the new key arguments for the bisect module APIs in the 3.10 What...
Pablo Galindo Salgado [Tue, 14 Sep 2021 19:53:14 +0000 (20:53 +0100)] 
bpo-4356: Mention the new key arguments for the bisect module APIs in the 3.10 What's new (GH-28339)

4 years agobpo-45196: prevent unittest crash on address sanitizer builds (GH-28331)
junyixie [Tue, 14 Sep 2021 18:31:50 +0000 (02:31 +0800)] 
bpo-45196: prevent unittest crash on address sanitizer builds (GH-28331)

4 years agocloses bpo-45190: Update Unicode data to version 14.0.0. (GH-28336)
Benjamin Peterson [Tue, 14 Sep 2021 18:00:38 +0000 (11:00 -0700)] 
closes bpo-45190: Update Unicode data to version 14.0.0. (GH-28336)

4 years agobpo-45195: Fix test_readline.test_nonascii() (GH-28329)
Victor Stinner [Tue, 14 Sep 2021 15:38:04 +0000 (17:38 +0200)] 
bpo-45195: Fix test_readline.test_nonascii() (GH-28329)

Fix test_readline.test_nonascii(): sometimes, the newline character
is not written at the end, so don't expect it in the output.

4 years agobpo-45156: Fixes inifite loop on unittest.mock.seal() (GH-28300)
Nikita Sobolev [Tue, 14 Sep 2021 10:20:40 +0000 (13:20 +0300)] 
bpo-45156: Fixes inifite loop on unittest.mock.seal() (GH-28300)

Fixes infinite loop on unittest.mock.seal() of mocks created by
unittest.create_autospec().

Co-authored-by: Dong-hee Na <donghee.na92@gmail.com>
4 years agobpo-45168: change dis output to omit missing values rather than replacing them by...
Irit Katriel [Tue, 14 Sep 2021 09:09:05 +0000 (10:09 +0100)] 
bpo-45168: change dis output to omit missing values rather than replacing them by their index (GH-28313)

4 years agobpo-45152: Add HAS_CONST macro and get_const_value() function and use… (#28262)
Irit Katriel [Tue, 14 Sep 2021 08:53:32 +0000 (09:53 +0100)] 
bpo-45152: Add HAS_CONST macro and get_const_value() function and use… (#28262)

4 years agobpo-42135 Correct version slated for importlib.find_loader removal (GH-28312)
Hugo van Kemenade [Mon, 13 Sep 2021 22:57:50 +0000 (01:57 +0300)] 
bpo-42135 Correct version slated for importlib.find_loader removal (GH-28312)

importlib.find_loader should also be slated for 3.12 like the others in GH-25169 and as documented in https://docs.python.org/3.11/whatsnew/3.10.html#deprecated.

4 years agobpo-45019: Do some cleanup related to frozen modules. (gh-28319)
Eric Snow [Mon, 13 Sep 2021 22:18:37 +0000 (16:18 -0600)] 
bpo-45019: Do some cleanup related to frozen modules. (gh-28319)

There are a few things I missed in gh-27980. This is a follow-up that will make subsequent PRs cleaner. It includes fixes to tests and tools that reference the frozen modules.

https://bugs.python.org/issue45019

4 years agobpo-45173 Remove configparser deprecations (GH-28292)
Hugo van Kemenade [Mon, 13 Sep 2021 17:12:36 +0000 (20:12 +0300)] 
bpo-45173 Remove configparser deprecations (GH-28292)

In the configparser module, these have been deprecated since Python 3.2:

* the SafeConfigParser class,
* the filename property of the ParsingError class,
* the readfp method of the ConfigParser class,

4 years agobpo-21302: Update time.sleep() doc for clock_nanosleep() (GH-28311)
Victor Stinner [Mon, 13 Sep 2021 15:40:25 +0000 (17:40 +0200)] 
bpo-21302: Update time.sleep() doc for clock_nanosleep() (GH-28311)

Clean-up also What's New in Python 3.11 doc: move entries to the
correct sections.

4 years agobpo-21302: Add clock_nanosleep() implementation for time.sleep() (GH-28111)
Livius [Mon, 13 Sep 2021 12:37:38 +0000 (14:37 +0200)] 
bpo-21302: Add clock_nanosleep() implementation for time.sleep() (GH-28111)

In Unix operating systems, time.sleep() now uses the clock_nanosleep() function,
if available, which allows to sleep for an interval specified with nanosecond precision.

Co-authored-by: Victor Stinner <vstinner@python.org>
4 years agobpo-45181: Simplify loading sqlite3 tests (GH-28304)
Serhiy Storchaka [Mon, 13 Sep 2021 11:16:26 +0000 (14:16 +0300)] 
bpo-45181: Simplify loading sqlite3 tests (GH-28304)

Use unittest discover instead of manually enumerating all
test modules and classes.
Also add support for filtering them by pattern.

4 years agobpo-45182: Fix incorrect use of requires_zlib in test_bdist_rpm (GH-28305)
Serhiy Storchaka [Mon, 13 Sep 2021 11:10:16 +0000 (14:10 +0300)] 
bpo-45182: Fix incorrect use of requires_zlib in test_bdist_rpm (GH-28305)

It is a decorator factory and should be always followed by "()".

4 years agobpo-5846: Do not use obsolete unittest functions. (GH-28303)
Serhiy Storchaka [Mon, 13 Sep 2021 07:49:53 +0000 (10:49 +0300)] 
bpo-5846: Do not use obsolete unittest functions. (GH-28303)

Get rid of use of makeSuite() and findTestCases().
Also make test_math and test_threading_local discoverable.

4 years agobpo-45126: Fix ref. leak in `sqlite3.Connection.__init__` (GH-28231)
Erlend Egeberg Aasland [Sun, 12 Sep 2021 12:27:42 +0000 (14:27 +0200)] 
bpo-45126: Fix ref. leak in `sqlite3.Connection.__init__` (GH-28231)

4 years agobpo-43413: Fix handling keyword arguments in subclasses of some buitin classes (GH...
Serhiy Storchaka [Sun, 12 Sep 2021 10:27:50 +0000 (13:27 +0300)] 
bpo-43413: Fix handling keyword arguments in subclasses of some buitin classes (GH-26456)

* Constructors of subclasses of some buitin classes (e.g. tuple, list,
  frozenset) no longer accept arbitrary keyword arguments.
* Subclass of set can now define a __new__() method with additional
  keyword parameters without overriding also __init__().

4 years agobpo-44987: Fix typo whatsnew 3.11 (GH-28293)
Dong-hee Na [Sat, 11 Sep 2021 19:05:55 +0000 (19:05 +0000)] 
bpo-44987: Fix typo whatsnew 3.11 (GH-28293)

4 years agobpo-44987: Speed up unicode normalization of ASCII strings (GH-28283)
Dong-hee Na [Sat, 11 Sep 2021 15:04:38 +0000 (15:04 +0000)] 
bpo-44987: Speed up unicode normalization of ASCII strings (GH-28283)

4 years agobpo-35474: Fix mimetypes.guess_all_extensions() potentially mutating list (GH-28286)
Serhiy Storchaka [Sat, 11 Sep 2021 14:44:44 +0000 (17:44 +0300)] 
bpo-35474: Fix mimetypes.guess_all_extensions() potentially mutating list (GH-28286)

* Calling guess_all_extensions() with strict=False potentially
  mutated types_map_inv.
* Mutating the result of guess_all_extensions() mutated types_map_inv.

4 years agobpo-45163: Haiku build fix. (GH-28269)
David CARLIER [Sat, 11 Sep 2021 08:46:22 +0000 (09:46 +0100)] 
bpo-45163: Haiku build fix. (GH-28269)

linkage issues mainly for shared libs and missing system library,
also little nit into the signal extension as strsignal returns
a constant in this platform.

4 years agoIDLE: adjust Python version in doc url for 3.10+ (GH-28228)
giovanniwijaya [Fri, 10 Sep 2021 21:10:28 +0000 (05:10 +0800)] 
IDLE: adjust Python version in doc url for 3.10+ (GH-28228)

Expression 'python_version()[:3]' truncated '3.10.0' to '3.1' instead of '3.10'.

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
4 years agobpo-45144: use subTests in test_peepholer (GH-28247)
Irit Katriel [Fri, 10 Sep 2021 16:29:21 +0000 (17:29 +0100)] 
bpo-45144: use subTests in test_peepholer (GH-28247)

4 years agobpo-9811: [doc] strftime handling of unsupported format specifiers is platform depend...
Irit Katriel [Fri, 10 Sep 2021 16:26:57 +0000 (17:26 +0100)] 
bpo-9811: [doc] strftime handling of unsupported format specifiers is platform dependent (GH-28264)

4 years agobpo-25894: Always report skipped and failed subtests separately (GH-28082)
Serhiy Storchaka [Fri, 10 Sep 2021 15:55:05 +0000 (18:55 +0300)] 
bpo-25894: Always report skipped and failed subtests separately (GH-28082)

* In default mode output separate characters for skipped and failed subtests.
* In verbose mode output separate lines (including description) for skipped
   and failed subtests.
* In verbose mode output test description for errors in test cleanup.

4 years agobpo-44964: Correct the note about the f_lasti field (GH-28208)
Pablo Galindo Salgado [Fri, 10 Sep 2021 15:53:42 +0000 (16:53 +0100)] 
bpo-44964: Correct the note about the f_lasti field (GH-28208)

4 years agobpo-44219: Mention GH-28250 is a deadlock bugfix (GH-28261)
Łukasz Langa [Fri, 10 Sep 2021 15:51:43 +0000 (17:51 +0200)] 
bpo-44219: Mention GH-28250 is a deadlock bugfix (GH-28261)

4 years agoFix typos in pep384_macrocheck.py (GH-28220)
Ikko Ashimine [Fri, 10 Sep 2021 14:44:03 +0000 (23:44 +0900)] 
Fix typos in pep384_macrocheck.py (GH-28220)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
4 years agobpo-45132: Fix the reStructuredText markup error. (GH-28270)
Serhiy Storchaka [Fri, 10 Sep 2021 12:40:07 +0000 (15:40 +0300)] 
bpo-45132: Fix the reStructuredText markup error. (GH-28270)

4 years agobpo-40563: Support pathlike objects on dbm/shelve (GH-21849)
Henry-Joseph Audéoud [Fri, 10 Sep 2021 12:26:16 +0000 (14:26 +0200)] 
bpo-40563: Support pathlike objects on dbm/shelve (GH-21849)

Co-authored-by: Hakan Çelik <hakancelik96@outlook.com>
4 years agobpo-45024 and bpo-23864: Document how interface testing works with the collections...
Raymond Hettinger [Fri, 10 Sep 2021 02:51:07 +0000 (21:51 -0500)] 
bpo-45024 and bpo-23864: Document how interface testing works with the collections ABCs (GH-28218)

4 years agobpo-45067 - Verify the version of ncurses for extended color support feature usage...
Senthil Kumaran [Thu, 9 Sep 2021 18:32:11 +0000 (11:32 -0700)] 
bpo-45067 - Verify the version of ncurses for extended color support feature usage. (GH-28260)

* issue45067 - Fix _curses compilation in CentOS 7. Verify the version of ncurses
for extended color support feature usage.

The function extended_color_content was introduced in 2017.  The ncurses-devel
package in CentOS 7 had a older version ncurses resulted in compilation error.
For compiling ncurses with extended color support, we verify the version of the
ncurses library.

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
4 years agoFix minor typo in 3.10.rst (GH-28253)
D.Lintin [Thu, 9 Sep 2021 16:02:01 +0000 (00:02 +0800)] 
Fix minor typo in 3.10.rst (GH-28253)

4 years agobpo-44219: Release the GIL during isatty syscalls (GH-28250)
Vincent Michel [Thu, 9 Sep 2021 13:12:03 +0000 (15:12 +0200)] 
bpo-44219: Release the GIL during isatty syscalls (GH-28250)

Release the GIL while performing isatty() system calls on arbitrary
file descriptors. In particular, this affects os.isatty(),
os.device_encoding() and io.TextIOWrapper. By extension,
io.open() in text mode is also affected.

4 years agobpo-45017: move opcode-related logic from modulefinder to dis (GH-28246)
Irit Katriel [Thu, 9 Sep 2021 13:04:12 +0000 (14:04 +0100)] 
bpo-45017: move opcode-related logic from modulefinder to dis (GH-28246)

4 years agobpo-44860: Update test_sysconfig for posix_user platlib (GH-28235)
Victor Stinner [Thu, 9 Sep 2021 09:02:48 +0000 (11:02 +0200)] 
bpo-44860: Update test_sysconfig for posix_user platlib (GH-28235)

Update test_sysconfig.test_user_similar() for the posix_user scheme:
"platlib" doesn't use sys.platlibdir.

4 years agoSpecify default order in memoryview.tobytes() docs (GH-27936)
andrei kulakov [Thu, 9 Sep 2021 08:30:56 +0000 (04:30 -0400)] 
Specify default order in memoryview.tobytes() docs (GH-27936)

4 years agoFix small mistake in fileinput documentation (GH-28241)
Jean-Abou-Samra [Thu, 9 Sep 2021 08:01:10 +0000 (10:01 +0200)] 
Fix small mistake in fileinput documentation (GH-28241)

4 years agobpo-20499: Rounding error in statistics.pvariance (GH-28230)
Raymond Hettinger [Thu, 9 Sep 2021 03:00:12 +0000 (22:00 -0500)] 
bpo-20499: Rounding error in statistics.pvariance (GH-28230)

4 years agobpo-38371: Remove deprecated `tkinter` split() method (GH-28237)
Erlend Egeberg Aasland [Wed, 8 Sep 2021 20:02:19 +0000 (22:02 +0200)] 
bpo-38371: Remove deprecated `tkinter` split() method (GH-28237)

4 years agobpo-44340: Update whatsnews for ThinLTO (GH-28229)
Dong-hee Na [Wed, 8 Sep 2021 17:29:33 +0000 (17:29 +0000)] 
bpo-44340: Update whatsnews for ThinLTO (GH-28229)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-45129 Remove deprecated reuse_address (GH-28207)
Hugo van Kemenade [Wed, 8 Sep 2021 16:58:43 +0000 (19:58 +0300)] 
bpo-45129 Remove deprecated reuse_address (GH-28207)

Due to significant security concerns, the reuse_address parameter of
asyncio.loop.create_datagram_endpoint, deprecated in Python 3.9, is
now removed. This is because of the behavior of the socket option
SO_REUSEADDR in UDP.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
4 years agobpo-19113: Remove unused test_errors from ctypes tests (GH-28008)
andrei kulakov [Wed, 8 Sep 2021 15:28:32 +0000 (11:28 -0400)] 
bpo-19113: Remove unused test_errors from ctypes tests (GH-28008)

This test was forever shadowed by another test method named `test_errors`.

4 years agobpo-44959: Add fallback to extension modules with '.sl' suffix on HP-UX (GH-27857)
Florin Spătar [Wed, 8 Sep 2021 12:43:00 +0000 (15:43 +0300)] 
bpo-44959: Add fallback to extension modules with '.sl' suffix on HP-UX (GH-27857)

4 years agobpo-45121: Fix RecursionError when calling Protocol.__init__ from a subclass' __init_...
Yurii Karabas [Wed, 8 Sep 2021 10:25:09 +0000 (13:25 +0300)] 
bpo-45121: Fix RecursionError when calling Protocol.__init__ from a subclass' __init__ (GH-28206)

4 years agobpo-45132 Remove deprecated __getitem__ methods (GH-28225)
Hugo van Kemenade [Wed, 8 Sep 2021 10:07:40 +0000 (13:07 +0300)] 
bpo-45132 Remove deprecated __getitem__ methods (GH-28225)

Remove deprecated __getitem__ methods of xml.dom.pulldom.DOMEventStream,
wsgiref.util.FileWrapper and fileinput.FileInput, deprecated since Python 3.9.

4 years agobpo-39573: Py_TYPE becomes a static inline function (GH-28128)
Victor Stinner [Wed, 8 Sep 2021 09:59:13 +0000 (11:59 +0200)] 
bpo-39573: Py_TYPE becomes a static inline function (GH-28128)

Convert the Py_TYPE() and Py_SIZE() macros to static inline
functions. The Py_SET_TYPE() and Py_SET_SIZE() functions must now be
used to set an object type and size.

4 years agobpo-45022: Fix libffi DLL name in Windows installer sources (GH-28203)
giovanniwijaya [Tue, 7 Sep 2021 19:18:32 +0000 (03:18 +0800)] 
bpo-45022: Fix libffi DLL name in Windows installer sources (GH-28203)

4 years agobpo-24888: Clarify subprocess.check_call propagates exceptions if unable to start...
DonnaDia [Tue, 7 Sep 2021 18:16:44 +0000 (21:16 +0300)] 
bpo-24888: Clarify subprocess.check_call propagates exceptions if unable to start process (GH-28018)

4 years agoRemove documentation for non-existing socket class attributes (GH-28029)
Matti Picus [Tue, 7 Sep 2021 18:09:11 +0000 (21:09 +0300)] 
Remove documentation for non-existing socket class attributes (GH-28029)

The functions in question are available on the module-level only.

4 years agobpo-45012: Release GIL around stat in os.scandir (GH-28085)
Stanisław Skonieczny [Tue, 7 Sep 2021 17:55:20 +0000 (19:55 +0200)] 
bpo-45012: Release GIL around stat in os.scandir (GH-28085)

Releasing GIL allows other threads to continue
its work when os.scandir is fetching DirEntry.stat
info from file system.

4 years agoAdd more itertool recipes (GH-28165)
Raymond Hettinger [Tue, 7 Sep 2021 17:29:00 +0000 (12:29 -0500)] 
Add more itertool recipes (GH-28165)

4 years agobpo-38820: Test with OpenSSL 3.0.0 final (GH-28205)
Christian Heimes [Tue, 7 Sep 2021 17:04:55 +0000 (20:04 +0300)] 
bpo-38820: Test with OpenSSL 3.0.0 final (GH-28205)

Signed-off-by: Christian Heimes <christian@python.org>
4 years agobpo-45118: Fix regrtest second summary for re-run tests (GH-28183)
Victor Stinner [Tue, 7 Sep 2021 16:21:00 +0000 (18:21 +0200)] 
bpo-45118: Fix regrtest second summary for re-run tests (GH-28183)

Fix regrtest second summary when using -w/--verbose2 command line
option: lists re-run tests in the second test summary.