]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
5 years agobpo-41428: Fix compiler warning in unionobject.c (GH-22416)
Victor Stinner [Sat, 26 Sep 2020 10:48:41 +0000 (12:48 +0200)] 
bpo-41428: Fix compiler warning in unionobject.c (GH-22416)

Use Py_ssize_t type rather than int, to store lengths in
unionobject.c. Fix the warning:

Objects\unionobject.c(205,1): warning C4244: 'initializing':
conversion from 'Py_ssize_t' to 'int', possible loss of data

5 years agoFix logging error message (GH-22410)
Eric Larson [Fri, 25 Sep 2020 18:08:50 +0000 (14:08 -0400)] 
Fix logging error message (GH-22410)

Same changes as #22276 squashed to a single commit. Just hoping to get Travis to cooperate by opening a new PR...

Automerge-Triggered-By: @vsajip
5 years agobpo-39934: Account for control blocks in 'except' in compiler. (GH-22395)
Mark Shannon [Fri, 25 Sep 2020 13:04:19 +0000 (14:04 +0100)] 
bpo-39934: Account for control blocks in 'except' in compiler. (GH-22395)

* Account for control blocks in 'except' in compiler. Fixes #39934.

5 years agobpo-41775: Make 'IDLE Shell' the shell title (#22399)
Terry Jan Reedy [Thu, 24 Sep 2020 19:30:09 +0000 (15:30 -0400)] 
bpo-41775: Make 'IDLE Shell' the shell title  (#22399)

'Python Shell' may have contributed to some beginners confusing 'IDLE' with ' Python'.

5 years agobpo-41428: Fix compiler warnings in unionobject.c (GH-22388)
Victor Stinner [Wed, 23 Sep 2020 21:25:54 +0000 (23:25 +0200)] 
bpo-41428: Fix compiler warnings in unionobject.c (GH-22388)

Use Py_ssize_t type rather than int, to store lengths in
unionobject.c. Fix warnings:

Objects\unionobject.c(189,71): warning C4244: '+=':
conversion from 'Py_ssize_t' to 'int', possible loss of data

Objects\unionobject.c(182,1): warning C4244: 'initializing':
conversion from 'Py_ssize_t' to 'int', possible loss of data

Objects\unionobject.c(205,1): warning C4244: 'initializing':
conversion from 'Py_ssize_t' to 'int', possible loss of data

Objects\unionobject.c(437,1): warning C4244: 'initializing':
conversion from 'Py_ssize_t' to 'int', possible loss of data

5 years agobpo-41654: Fix compiler warning in MemoryError_dealloc() (GH-22387)
Victor Stinner [Wed, 23 Sep 2020 21:25:40 +0000 (23:25 +0200)] 
bpo-41654: Fix compiler warning in MemoryError_dealloc() (GH-22387)

Fix warning:

Objects\exceptions.c(2324,56): warning C4098:
'MemoryError_dealloc': 'void' function returning a value

5 years agobpo-41833: threading.Thread now uses the target name (GH-22357)
Victor Stinner [Wed, 23 Sep 2020 21:21:19 +0000 (23:21 +0200)] 
bpo-41833: threading.Thread now uses the target name (GH-22357)

5 years agobpo-30155: Add macros to get tzinfo from datetime instances (GH-21633)
Zackery Spytz [Wed, 23 Sep 2020 18:43:45 +0000 (12:43 -0600)] 
bpo-30155: Add macros to get tzinfo from datetime instances (GH-21633)

Add PyDateTime_DATE_GET_TZINFO() and PyDateTime_TIME_GET_TZINFO()
macros.

5 years agobpo-33822: Update IDLE section of What's New 3.8 (GH-22383)
Terry Jan Reedy [Wed, 23 Sep 2020 15:19:05 +0000 (11:19 -0400)] 
bpo-33822: Update IDLE section of What's New 3.8 (GH-22383)

5 years agobpo-41844: Add IDLE section to What's New 3.9 (GN-22382)
Terry Jan Reedy [Wed, 23 Sep 2020 15:17:26 +0000 (11:17 -0400)] 
bpo-41844: Add IDLE section to What's New 3.9 (GN-22382)

5 years agobpo-41841: Prepare IDLE News for 3.10 (GH-22379)
Terry Jan Reedy [Wed, 23 Sep 2020 13:44:31 +0000 (09:44 -0400)] 
bpo-41841: Prepare IDLE News for 3.10 (GH-22379)

5 years agobpo-37779 : Add information about the overriding behavior of ConfigParser.read (GH...
sblondon [Wed, 23 Sep 2020 12:28:58 +0000 (14:28 +0200)] 
bpo-37779 : Add information about the overriding behavior of ConfigParser.read (GH-15177)

Co-Authored-By: Kyle Stanley <aeros167@gmail.com>
Co-Authored-By: Paul Ganssle <p.ganssle@gmail.com>
5 years agobpo-40170: Use inline _PyType_HasFeature() function (GH-22375)
Victor Stinner [Wed, 23 Sep 2020 12:08:38 +0000 (14:08 +0200)] 
bpo-40170: Use inline _PyType_HasFeature() function (GH-22375)

Use _PyType_HasFeature() in the _io module and in structseq
implementation. Replace PyType_HasFeature() opaque function call with
_PyType_HasFeature() inlined function.

5 years agobpo-40941: Fix stackdepth compiler warnings (GH-22377)
Victor Stinner [Wed, 23 Sep 2020 12:07:16 +0000 (14:07 +0200)] 
bpo-40941: Fix stackdepth compiler warnings (GH-22377)

Explicitly cast a difference of two pointers to int:
PyFrameObject.f_stackdepth is an int.

5 years agobpo-40941: Fix fold_tuple_on_constants() compiler warnings (GH-22378)
Victor Stinner [Wed, 23 Sep 2020 12:06:55 +0000 (14:06 +0200)] 
bpo-40941: Fix fold_tuple_on_constants() compiler warnings (GH-22378)

Add explicit casts to fix compiler warnings in
fold_tuple_on_constants().

The limit of constants per code is now INT_MAX, rather than UINT_MAX.

5 years agobpo-40521: Fix PyUnicode_InternInPlace() (GH-22376)
Victor Stinner [Wed, 23 Sep 2020 12:05:32 +0000 (14:05 +0200)] 
bpo-40521: Fix PyUnicode_InternInPlace() (GH-22376)

Fix PyUnicode_InternInPlace() when the INTERNED_STRINGS macro is not
defined (when the EXPERIMENTAL_ISOLATED_SUBINTERPRETERS macro is
defined).

5 years agobpo-41834: Remove _Py_CheckRecursionLimit variable (GH-22359)
Victor Stinner [Wed, 23 Sep 2020 12:04:57 +0000 (14:04 +0200)] 
bpo-41834: Remove _Py_CheckRecursionLimit variable (GH-22359)

Remove the global _Py_CheckRecursionLimit variable: it has been
replaced by ceval.recursion_limit of the PyInterpreterState
structure.

There is no need to keep the variable for the stable ABI, since
Py_EnterRecursiveCall() and Py_LeaveRecursiveCall() were not usable
in Python 3.8 and older: these macros accessed PyThreadState members,
whereas the PyThreadState structure is opaque in the limited C API.

5 years agobpo-1635741, unicodedata: add ucd_type parameter to UCD_Check() macro (GH-22328)
Mohamed Koubaa [Wed, 23 Sep 2020 10:38:16 +0000 (05:38 -0500)] 
bpo-1635741, unicodedata: add ucd_type parameter to UCD_Check() macro (GH-22328)

Co-authored-by: Victor Stinner <vstinner@python.org>
5 years agobpo-1635741: Port _lsprof extension to multi-phase init (PEP 489) (GH-22220)
Mohamed Koubaa [Wed, 23 Sep 2020 10:33:21 +0000 (05:33 -0500)] 
bpo-1635741: Port _lsprof extension to multi-phase init (PEP 489) (GH-22220)

5 years agobpo-41513: Improve order of adding fractional values. Improve variable names. (GH...
Raymond Hettinger [Wed, 23 Sep 2020 03:01:12 +0000 (20:01 -0700)] 
bpo-41513: Improve order of adding fractional values. Improve variable names. (GH-22368)

5 years agobpo-41816: `StrEnum.__str__` is `str.__str__` (GH-22362)
Ethan Furman [Tue, 22 Sep 2020 20:00:07 +0000 (13:00 -0700)] 
bpo-41816: `StrEnum.__str__` is `str.__str__` (GH-22362)

use `str.__str__` for `StrEnum` so that `str(StrEnum.member)` is the same as directly accessing the string value of the `StrEnum` member

5 years agobpo-35764: Rewrite the IDLE Calltips doc section (GH-22363)
Terry Jan Reedy [Tue, 22 Sep 2020 17:21:58 +0000 (13:21 -0400)] 
bpo-35764: Rewrite the IDLE Calltips doc section  (GH-22363)

5 years agobpo-41810: Reintroduce `types.EllipsisType`, `.NoneType` & `.NotImplementedType`...
Bas van Beek [Tue, 22 Sep 2020 15:55:34 +0000 (17:55 +0200)] 
bpo-41810: Reintroduce `types.EllipsisType`, `.NoneType` & `.NotImplementedType` (GH-22336)

closes issue 41810

5 years agobpo-41602: raise SIGINT exit code on KeyboardInterrupt from pymain_run_module (#21956)
Thomas Grainger [Tue, 22 Sep 2020 15:53:03 +0000 (16:53 +0100)] 
bpo-41602: raise SIGINT exit code on KeyboardInterrupt from pymain_run_module (#21956)

Closes bpo issue 41602

5 years agobpo-41817: use new StrEnum to ensure all members are strings (GH-22348)
Ethan Furman [Tue, 22 Sep 2020 15:01:17 +0000 (08:01 -0700)] 
bpo-41817: use new StrEnum to ensure all members are strings (GH-22348)

* use new StrEnum to ensure all members are strings

5 years agobpo-40670: More reliable validation of statements in timeit.Timer. (GH-22358)
Serhiy Storchaka [Tue, 22 Sep 2020 13:16:46 +0000 (16:16 +0300)] 
bpo-40670: More reliable validation of statements in timeit.Timer. (GH-22358)

It now accepts "empty" statements (only whitespaces and comments)
and rejects misindentent statements.

5 years agoPy_IS_TYPE() macro uses Py_TYPE() (GH-22341)
Victor Stinner [Tue, 22 Sep 2020 10:42:28 +0000 (12:42 +0200)] 
Py_IS_TYPE() macro uses Py_TYPE() (GH-22341)

5 years agoEnum: add extended AutoNumber example (GH-22349)
Ethan Furman [Tue, 22 Sep 2020 07:05:27 +0000 (00:05 -0700)] 
Enum: add extended AutoNumber example (GH-22349)

5 years agobpo-40181: Remove '/' reminder in IDLE calltips. (GH-22350)
Terry Jan Reedy [Tue, 22 Sep 2020 05:43:55 +0000 (01:43 -0400)] 
bpo-40181: Remove '/' reminder in IDLE calltips. (GH-22350)

The marker was added to the language in 3.8 and
3.7 only gets security patches.

5 years agobpo-41756: Refactor gen_send_ex(). (GH-22330)
Serhiy Storchaka [Tue, 22 Sep 2020 05:08:54 +0000 (08:08 +0300)] 
bpo-41756: Refactor gen_send_ex(). (GH-22330)

5 years agobpo-41816: add `StrEnum` (GH-22337)
Ethan Furman [Tue, 22 Sep 2020 00:23:13 +0000 (17:23 -0700)] 
bpo-41816: add `StrEnum` (GH-22337)

`StrEnum` ensures that its members were already strings, or intended to
be strings.

5 years agobpo-40084: Enum - dir() includes member attributes (GH-19219)
Angelin BOOZ [Mon, 21 Sep 2020 13:11:06 +0000 (15:11 +0200)] 
bpo-40084: Enum - dir() includes member attributes (GH-19219)

5 years agobpo-1635741: Convert an _lsprof method to argument clinic (GH-22240)
Mohamed Koubaa [Mon, 21 Sep 2020 12:40:42 +0000 (07:40 -0500)] 
bpo-1635741: Convert an  _lsprof method to argument clinic (GH-22240)

5 years agobpo-41819: Fix compiler warning in init_dump_ascii_wstr() (GH-22332)
Samuel Marks [Mon, 21 Sep 2020 08:35:17 +0000 (18:35 +1000)] 
bpo-41819: Fix compiler warning in init_dump_ascii_wstr() (GH-22332)

Fix the compiler warning:

format specifies type `wint_t` (aka `int`) but the argument has type `unsigned int`

5 years agobpo-41513: Add accuracy tests for math.hypot() (GH-22327)
Raymond Hettinger [Mon, 21 Sep 2020 04:47:56 +0000 (21:47 -0700)] 
bpo-41513: Add accuracy tests for math.hypot() (GH-22327)

5 years ago[doc] Teach 0-args form of super in Programming FAQ (GH-22176)
Andre Delfino [Sun, 20 Sep 2020 17:09:50 +0000 (14:09 -0300)] 
[doc] Teach 0-args form of super in Programming FAQ (GH-22176)

5 years agobpo-12178: Fix escaping of escapechar in csv.writer() (GH-13710)
Berker Peksag [Sun, 20 Sep 2020 06:38:07 +0000 (09:38 +0300)] 
bpo-12178: Fix escaping of escapechar in csv.writer() (GH-13710)

Co-authored-by: Itay Elbirt <anotahacou@gmail.com>
5 years agobpo-41815: SQLite: segfault if backup called on closed database (GH-22322)
Peter McCormick [Sun, 20 Sep 2020 03:40:46 +0000 (23:40 -0400)] 
bpo-41815: SQLite: segfault if backup called on closed database (GH-22322)

# [bpo-41815](): SQLite: fix segfault if backup called on closed database

Attempting to backup a closed database will trigger segfault:

```python
import sqlite3
target = sqlite3.connect(':memory:')
source = sqlite3.connect(':memory:')
source.close()
source.backup(target)
```

5 years agoAdd missing whatsnew entry for TestCase.assertNoLogs (GH-22317)
Mark Dickinson [Sat, 19 Sep 2020 20:38:11 +0000 (21:38 +0100)] 
Add missing whatsnew entry for TestCase.assertNoLogs (GH-22317)

5 years agobpo-33689: Blank lines in .pth file cause a duplicate sys.path entry (GH-20679)
idomic [Sat, 19 Sep 2020 19:13:29 +0000 (15:13 -0400)] 
bpo-33689: Blank lines in .pth file cause a duplicate sys.path entry (GH-20679)

5 years agobpo-41811: create SortKey members using first given value (GH-22316)
Ethan Furman [Sat, 19 Sep 2020 18:12:57 +0000 (11:12 -0700)] 
bpo-41811: create SortKey members using first given value (GH-22316)

5 years agobpo-41756: Introduce PyGen_Send C API (GH-22196)
Vladimir Matveev [Sat, 19 Sep 2020 01:38:38 +0000 (18:38 -0700)] 
bpo-41756: Introduce PyGen_Send C API (GH-22196)

The new API allows to efficiently send values into native generators
and coroutines avoiding use of StopIteration exceptions to signal
returns.

ceval loop now uses this method instead of the old "private"
_PyGen_Send C API. This translates to 1.6x increased performance
of 'await' calls in micro-benchmarks.

Aside from CPython core improvements, this new API will also allow
Cython to generate more efficient code, benefiting high-performance
IO libraries like uvloop.

5 years agoMake fractional value accumulation consistent inside and outside the loop. (GH-22315)
Raymond Hettinger [Sat, 19 Sep 2020 00:57:28 +0000 (17:57 -0700)] 
Make fractional value accumulation consistent inside and outside the loop. (GH-22315)

5 years agobpo-35293: Travis CI uses "make venv" for the doc (GH-22307)
Victor Stinner [Fri, 18 Sep 2020 14:23:18 +0000 (16:23 +0200)] 
bpo-35293: Travis CI uses "make venv" for the doc (GH-22307)

Doc/requirements.txt becomes the reference for packages and package
versions needed to build the Python documentation.

* Doc/Makefile now uses Doc/requirements.txt
* .travis.yml now uses "make env" of Doc/Makefile

5 years agobpo-35293: Remove RemovedInSphinx40Warning (GH-22198)
Dong-hee Na [Fri, 18 Sep 2020 09:22:36 +0000 (18:22 +0900)] 
bpo-35293: Remove RemovedInSphinx40Warning (GH-22198)

* bpo-35293: Remove RemovedInSphinx40Warning

* Update Misc/NEWS.d/next/Documentation/2020-09-12-17-37-13.bpo-35293._cOwPD.rst

Co-authored-by: Victor Stinner <vstinner@python.org>
* bpo-35293: Apply Victor's review

Co-authored-by: Victor Stinner <vstinner@python.org>
5 years agobpo-41762: Fix usage of productionlist markup in the doc (GH-22281)
Victor Stinner [Fri, 18 Sep 2020 07:10:15 +0000 (09:10 +0200)] 
bpo-41762: Fix usage of productionlist markup in the doc (GH-22281)

Use an unique identifier for the different grammars documented using
the Sphinx productionlist markup.

productionlist markups of the same grammar, like "expressions" or
"compound statements", use the same identifier "python-grammar".

5 years agoRemove duplicated words words (GH-22298)
Serhiy Storchaka [Fri, 18 Sep 2020 06:54:42 +0000 (09:54 +0300)] 
Remove duplicated words words (GH-22298)

5 years agobpo-41808: Add What's New 3.9 entry missing from master (#22294)
Terry Jan Reedy [Fri, 18 Sep 2020 01:56:58 +0000 (21:56 -0400)] 
bpo-41808: Add What's New 3.9 entry missing from master (#22294)

Entry was added by bpo-40939, #21012 and #21039.

5 years agobpo-27032, bpo-37328: Document removing HTMLParser.unescape(). (GH-22288)
Serhiy Storchaka [Thu, 17 Sep 2020 08:49:01 +0000 (11:49 +0300)] 
bpo-27032, bpo-37328: Document removing HTMLParser.unescape(). (GH-22288)

5 years agobpo-41662: Fix bugs in binding parameters in sqlite3 (GH-21998)
Serhiy Storchaka [Thu, 17 Sep 2020 07:35:44 +0000 (10:35 +0300)] 
bpo-41662: Fix bugs in binding parameters in sqlite3 (GH-21998)

* When the parameters argument is a list, correctly handle the case
  of changing it during iteration.
* When the parameters argument is a custom sequence, no longer
  override an exception raised in ``__len__()``.

5 years agobpo-41715: Fix potential catastrofic backtracking in c_analyzer. (GH-22091)
Serhiy Storchaka [Thu, 17 Sep 2020 07:34:20 +0000 (10:34 +0300)] 
bpo-41715: Fix potential catastrofic backtracking in c_analyzer. (GH-22091)

5 years agoEnum: make `Flag` and `IntFlag` members iterable (GH-22221)
Ethan Furman [Wed, 16 Sep 2020 20:01:00 +0000 (13:01 -0700)] 
Enum: make `Flag` and `IntFlag` members iterable (GH-22221)

5 years ago_auto_called cleanup (GH-22285)
Ethan Furman [Wed, 16 Sep 2020 19:37:54 +0000 (12:37 -0700)] 
_auto_called cleanup (GH-22285)

5 years agobpo-41746: Add type information to asdl_seq objects (GH-22223)
Pablo Galindo [Wed, 16 Sep 2020 18:42:00 +0000 (19:42 +0100)] 
bpo-41746: Add type information to asdl_seq objects (GH-22223)

* Add new capability to the PEG parser to type variable assignments. For instance:
```
       | a[asdl_stmt_seq*]=';'.small_stmt+ [';'] NEWLINE { a }
```

* Add new sequence types from the asdl definition (automatically generated)
* Make `asdl_seq` type a generic aliasing pointer type.
* Create a new `asdl_generic_seq` for the generic case using `void*`.
* The old `asdl_seq_GET`/`ast_seq_SET` macros now are typed.
* New `asdl_seq_GET_UNTYPED`/`ast_seq_SET_UNTYPED` macros for dealing with generic sequences.
* Changes all possible `asdl_seq` types to use specific versions everywhere.

5 years agoacknowledge Weipeng Hong's contributions (GH-22284)
Ethan Furman [Wed, 16 Sep 2020 18:37:24 +0000 (11:37 -0700)] 
acknowledge Weipeng Hong's contributions (GH-22284)

5 years agobpo-39728: Enum: fix duplicate `ValueError` (GH-22277)
Ethan Furman [Wed, 16 Sep 2020 17:26:50 +0000 (10:26 -0700)] 
bpo-39728: Enum: fix duplicate `ValueError` (GH-22277)

fix default `_missing_` to return `None` instead of raising a `ValueError`
Co-authored-by: Andrey Darascheka <andrei.daraschenka@leverx.com>
5 years ago[doc] Minor improvements to is_typeddict (GH-22280)
Andre Delfino [Wed, 16 Sep 2020 15:06:23 +0000 (12:06 -0300)] 
[doc] Minor improvements to is_typeddict (GH-22280)

1. The check is on the type
2. Add link to TypeDict

5 years agobpo-41517: do not allow Enums to be extended (#22271)
Ethan Furman [Wed, 16 Sep 2020 14:11:57 +0000 (07:11 -0700)] 
bpo-41517: do not allow Enums to be extended (#22271)

fix bug that let Enums be extended via multiple inheritance

5 years agobpo-41792: Add is_typeddict function to typing.py (GH-22254)
Patrick Reader [Wed, 16 Sep 2020 04:58:32 +0000 (05:58 +0100)] 
bpo-41792: Add is_typeddict function to typing.py (GH-22254)

Closes issue41792.

Also closes https://github.com/python/typing/issues/751.

5 years agobpo-41789: honor object overrides in Enum classes (GH-22250)
Ethan Furman [Tue, 15 Sep 2020 23:28:25 +0000 (16:28 -0700)] 
bpo-41789: honor object overrides in Enum classes (GH-22250)

EnumMeta double-checks that `__repr__`, `__str__`, `__format__`, and `__reduce_ex__` are not the same as `object`'s, and replaces them if they are -- even if that replacement was intentionally done in the Enum being constructed.  This patch fixes that.

Automerge-Triggered-By: @ethanfurman
5 years agoDoc: Fix broken manpage link (GH-21937)
Tim Burke [Tue, 15 Sep 2020 23:26:06 +0000 (16:26 -0700)] 
Doc: Fix broken manpage link (GH-21937)

sigprocmask is in section 2, not 3.

5 years agobpo-39587: Enum - use correct mixed-in data type (GH-22263)
Ethan Furman [Tue, 15 Sep 2020 22:56:26 +0000 (15:56 -0700)] 
bpo-39587: Enum - use correct mixed-in data type (GH-22263)

5 years agobpo-41780: Fix __dir__ of types.GenericAlias (GH-22262)
Batuhan Taskaya [Tue, 15 Sep 2020 21:58:32 +0000 (00:58 +0300)] 
bpo-41780: Fix __dir__ of types.GenericAlias (GH-22262)

Automerge-Triggered-By: @gvanrossum
5 years agoFix all Python Cookbook links (#22205)
Andre Delfino [Tue, 15 Sep 2020 20:13:26 +0000 (17:13 -0300)] 
Fix all Python Cookbook links (#22205)

5 years agominor reformat of enum tests (GH-22259)
Ethan Furman [Tue, 15 Sep 2020 19:27:06 +0000 (12:27 -0700)] 
minor reformat of enum tests (GH-22259)

Automerge-Triggered-By: @ethanfurman
5 years agoImprove the description of difflib in the documentation (GH-22253)
Mandeep [Tue, 15 Sep 2020 19:20:49 +0000 (15:20 -0400)] 
Improve the description of difflib in the documentation (GH-22253)

From "can produce difference information in various formats ..."
to " can produce information about file differences in various formats ..."

Automerge-Triggered-By: @Mariatta
5 years agobpo-41631: _ast module uses again a global state (#21961)
Victor Stinner [Tue, 15 Sep 2020 16:03:34 +0000 (18:03 +0200)] 
bpo-41631: _ast module uses again a global state (#21961)

Partially revert commit ac46eb4ad6662cf6d771b20d8963658b2186c48c:
"bpo-38113: Update the Python-ast.c generator to PEP384 (gh-15957)".

Using a module state per module instance is causing subtle practical
problems.

For example, the Mercurial project replaces the __import__() function
to implement lazy import, whereas Python expected that "import _ast"
always return a fully initialized _ast module.

Add _PyAST_Fini() to clear the state at exit.

The _ast module has no state (set _astmodule.m_size to 0). Remove
astmodule_traverse(), astmodule_clear() and astmodule_free()
functions.

5 years agobpo-41776: Revise example of "continue" in the tutorial documentation (GH-22234)
Neeraj Samtani [Tue, 15 Sep 2020 13:39:29 +0000 (17:39 +0400)] 
bpo-41776: Revise example of "continue" in the tutorial documentation (GH-22234)

Revise example of "continue" in the tutorial documentation

5 years agobpo-41513: Remove broken tests that fail on Gentoo (GH-22249)
Raymond Hettinger [Tue, 15 Sep 2020 00:13:49 +0000 (17:13 -0700)] 
bpo-41513: Remove broken tests that fail on Gentoo (GH-22249)

5 years agobpo-40721: add note about enum member name case (GH-22231)
Ethan Furman [Mon, 14 Sep 2020 20:32:44 +0000 (13:32 -0700)] 
bpo-40721: add note about enum member name case (GH-22231)

* UPPER_CASE preferred as enum members are constants

5 years agobpo-41744: Package python.props with correct name in NuGet package (GH-22154)
Václav Slavík [Mon, 14 Sep 2020 19:30:15 +0000 (21:30 +0200)] 
bpo-41744: Package python.props with correct name in NuGet package (GH-22154)

NuGet automatically includes .props file from the build directory in the
target using the package, but only if the .props file has the correct
name: it must be $(id).props

Rename python.props correspondingly in all the nuspec variants. Also
keep python.props as it were for backward compatibility.

5 years agobpo-41646: Mention path-like objects support in the docs for shutil.copy() (GH-22208)
Zackery Spytz [Mon, 14 Sep 2020 19:28:46 +0000 (13:28 -0600)] 
bpo-41646: Mention path-like objects support in the docs for shutil.copy() (GH-22208)

5 years agoFix a typo in locale Docs (#22233)
abdo [Mon, 14 Sep 2020 17:36:34 +0000 (20:36 +0300)] 
Fix a typo in locale Docs (#22233)

5 years agobpo-41513: Add docs and tests for hypot() (GH-22238)
Raymond Hettinger [Mon, 14 Sep 2020 06:33:41 +0000 (23:33 -0700)] 
bpo-41513: Add docs and tests for hypot() (GH-22238)

5 years agobpo-39883: Update macOS installer copy of LICENSE. (GH-22235)
Ned Deily [Mon, 14 Sep 2020 05:18:01 +0000 (01:18 -0400)] 
bpo-39883: Update macOS installer copy of LICENSE. (GH-22235)

5 years agobpo-41778: Change a punctuation on documentation. (GH-22229)
Emmanuel Arias [Sun, 13 Sep 2020 21:05:44 +0000 (18:05 -0300)] 
bpo-41778: Change a punctuation on documentation. (GH-22229)

On this paragrapah the clarification about IIS7 seems there's not
connection beacuase is in other sentence. Move the punctuation
to connect both the last sentence with the information in the
parenthesis.

I think the NEWS is not necessary here.

Automerge-Triggered-By: @ericvsmith
5 years agobpo-38967: Improve the error msg for reserved _sunder_ names in enum (GH-18370)
Zackery Spytz [Sun, 13 Sep 2020 20:27:51 +0000 (14:27 -0600)] 
bpo-38967: Improve the error msg for reserved _sunder_ names in enum (GH-18370)

5 years agobpo-33239: Fix default value of 'buffering' parameter in docs of tempfile.* functions...
Sergey Fedoseev [Sun, 13 Sep 2020 17:59:01 +0000 (22:59 +0500)] 
bpo-33239: Fix default value of 'buffering' parameter in docs of tempfile.* functions (GH-21763)

`None` doesn't work:

```python
>>> import tempfile
>>> tempfile.TemporaryFile(buffering=None)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/sergey/tmp/cpython-dev/Lib/tempfile.py", line 607, in TemporaryFile
    return _io.open(fd, mode, buffering=buffering,
TypeError: 'NoneType' object cannot be interpreted as an integer
```

Automerge-Triggered-By: @vsajip
5 years agobpo-41672: Fix type mismatches in imaplib docs (GH-22207)
Norbert Cyran [Sat, 12 Sep 2020 07:58:56 +0000 (09:58 +0200)] 
bpo-41672: Fix type mismatches in imaplib docs (GH-22207)

5 years agobpo-39651: Fix asyncio proactor _write_to_self() (GH-22197)
Victor Stinner [Sat, 12 Sep 2020 06:50:18 +0000 (08:50 +0200)] 
bpo-39651: Fix asyncio proactor _write_to_self() (GH-22197)

Fix a race condition in the call_soon_threadsafe() method of
asyncio.ProactorEventLoop: do nothing if the self-pipe socket has
been closed.

5 years agobpo-41731: Make test_cmd_line_script pass with -vv (GH-22206)
Terry Jan Reedy [Sat, 12 Sep 2020 06:25:36 +0000 (02:25 -0400)] 
bpo-41731: Make test_cmd_line_script pass with -vv (GH-22206)

Argument script_exec_args is usually an absolute file name,
but twice has form ['-m', 'module_name'].

5 years agobpo-41729: Fix test_winconsole failures (3) and hang (GH-22146)
Terry Jan Reedy [Sat, 12 Sep 2020 05:51:52 +0000 (01:51 -0400)] 
bpo-41729: Fix test_winconsole failures (3) and hang (GH-22146)

The problems occured with a repository build on machine
with freshly updated Windows 10 Pro.

5 years ago[doc] struct: update note about network byte order form to be more helpful (GH-22201)
Stargirl Flowers [Fri, 11 Sep 2020 15:20:12 +0000 (08:20 -0700)] 
[doc] struct: update note about network byte order form to be more helpful (GH-22201)

Update the sentence to provide some context on why network byte order is defined as big endian.

5 years agoDoc: Fix alphabetical ordering of removeprefix/suffix. (GH-22194)
Benjamin Peterson [Thu, 10 Sep 2020 23:59:02 +0000 (18:59 -0500)] 
Doc: Fix alphabetical ordering of removeprefix/suffix. (GH-22194)

5 years agobpo-37149: Change Shipman tkinter link from archive.org to TkDocs (GH-22188)
Mark Roseman [Thu, 10 Sep 2020 20:04:20 +0000 (13:04 -0700)] 
bpo-37149: Change Shipman tkinter link from archive.org to TkDocs (GH-22188)

The new link responds much faster and begins with a short explanation of the status of the doc.

5 years agobpo-1635741: Port cmath to multi-phase init (PEP 489) (GH-22165)
Mohamed Koubaa [Thu, 10 Sep 2020 14:09:04 +0000 (09:09 -0500)] 
bpo-1635741: Port cmath to multi-phase init (PEP 489) (GH-22165)

5 years agoUpdate logging documentation to tidy up formatting (GH-22173)
Bar Harel [Thu, 10 Sep 2020 10:50:23 +0000 (13:50 +0300)] 
Update logging documentation to tidy up formatting (GH-22173)

5 years ago[doc] Remove superfluous comment about equal in f-strings (GH-22006)
Andre Delfino [Thu, 10 Sep 2020 06:33:13 +0000 (03:33 -0300)] 
[doc] Remove superfluous comment about equal in f-strings (GH-22006)

Automerge-Triggered-By: @kushaldas
5 years agoUpdate idlelib/help.html to current IDLE doc (GH-22181)
Terry Jan Reedy [Wed, 9 Sep 2020 22:53:18 +0000 (18:53 -0400)] 
Update idlelib/help.html to current IDLE doc (GH-22181)

5 years agoAdd missing colon to IDLE doc markup (GH-22007)
Andre Delfino [Wed, 9 Sep 2020 22:17:14 +0000 (19:17 -0300)] 
Add missing colon to IDLE doc markup (GH-22007)

5 years agobpo-41428: Implementation for PEP 604 (GH-21515)
Maggie Moss [Wed, 9 Sep 2020 20:23:24 +0000 (13:23 -0700)] 
bpo-41428: Implementation for PEP 604 (GH-21515)

See https://www.python.org/dev/peps/pep-0604/ for more information.

Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
5 years agobpo-41687: Fix error handling in Solaris sendfile implementation (GH-22128)
Jakub Kulík [Wed, 9 Sep 2020 19:29:42 +0000 (21:29 +0200)] 
bpo-41687: Fix error handling in Solaris sendfile implementation (GH-22128)

I just realized that my recent PR with sendfile on Solaris ([PR 22040](https://github.com/python/cpython/pull/22040)) has broken error handling.

Sorry for that, this simple followup fixes that.

Automerge-Triggered-By: @1st1
5 years agoAdd minor clarification in logging documentation. (GH-22167)
Vinay Sajip [Wed, 9 Sep 2020 10:21:22 +0000 (11:21 +0100)] 
Add minor clarification in logging documentation. (GH-22167)

5 years agoFix compiler warnings in init_dump_ascii_wstr() (GH-22150)
Victor Stinner [Wed, 9 Sep 2020 10:07:17 +0000 (12:07 +0200)] 
Fix compiler warnings in init_dump_ascii_wstr() (GH-22150)

Fix GCC 9.3 (using -O3) warnings on x86:

initconfig.c: In function ‘init_dump_ascii_wstr’:
initconfig.c:2679:34: warning: format ‘%lc’ expects argument of type
‘wint_t’, but argument 2 has type ‘wchar_t’ {aka ‘long int’}
 2679 |             PySys_WriteStderr("%lc", ch);
initconfig.c:2682:38: warning: format ‘%x’ expects argument of type
‘unsigned int’, but argument 2 has type ‘wchar_t’ {aka ‘long int’}
 2682 |             PySys_WriteStderr("\\x%02x", ch);
initconfig.c:2686:38: warning: format ‘%x’ expects argument of type
‘unsigned int’, but argument 2 has type ‘wchar_t’ {aka ‘long int’}
 2686 |             PySys_WriteStderr("\\U%08x", ch);
initconfig.c:2690:38: warning: format ‘%x’ expects argument of type
‘unsigned int’, but argument 2 has type ‘wchar_t’ {aka ‘long int’}
 2690 |             PySys_WriteStderr("\\u%04x", ch);

5 years agobpo-41726: Update the refcounts info of PyType_FromModuleAndSpec in refcounts.dat...
Hai Shi [Wed, 9 Sep 2020 09:48:44 +0000 (17:48 +0800)] 
bpo-41726: Update the refcounts info of PyType_FromModuleAndSpec in refcounts.dat (GH-22112)

Update refcounts info of PyType_FromModuleAndSpec in refcounts.dat

5 years agobpo-1635741: port scproxy to multi-phase init (GH-22164)
Mohamed Koubaa [Wed, 9 Sep 2020 03:28:48 +0000 (22:28 -0500)] 
bpo-1635741: port scproxy to multi-phase init (GH-22164)

5 years agobpo-41525: Make the Python program help ASCII-only (GH-21836)
Serhiy Storchaka [Wed, 9 Sep 2020 00:28:02 +0000 (03:28 +0300)] 
bpo-41525: Make the Python program help ASCII-only (GH-21836)

5 years ago[doc] Fix padding in timeit (GH-22152)
Andre Delfino [Tue, 8 Sep 2020 23:39:19 +0000 (20:39 -0300)] 
[doc] Fix padding in timeit (GH-22152)

Compare -p and -u options help in rendered output to see the difference.

5 years agoFix typo in typing.py (GH-22121)
Graham Bleaney [Tue, 8 Sep 2020 22:41:10 +0000 (18:41 -0400)] 
Fix typo in typing.py (GH-22121)

This is a trivial PR to fix a typo in a docstring in typing.py. From reverences -> references

5 years agobpo-38762: Extend logging.test_multiprocessing to cover missing cases. (GH-22142)
Irit Katriel [Tue, 8 Sep 2020 19:40:04 +0000 (20:40 +0100)] 
bpo-38762: Extend logging.test_multiprocessing to cover missing cases. (GH-22142)