]>
git.ipfire.org Git - thirdparty/Python/cpython.git/log
Anthony Shaw [Tue, 14 Jan 2020 06:40:10 +0000 (17:40 +1100)]
bpo-39160 Align the verbs, grammar and defaults for `./configure --help` (GH-17747)
Dong-hee Na [Mon, 13 Jan 2020 19:34:34 +0000 (04:34 +0900)]
bpo-39259: ftplib.FTP/FTP_TLS now reject timeout = 0 (GH-17959)
Chris Withers [Mon, 13 Jan 2020 19:11:34 +0000 (19:11 +0000)]
remove unused __version__ from mock.py (#17977)
This isn't included in `__all__` and could be a source of confusion.
Victor Stinner [Mon, 13 Jan 2020 17:46:59 +0000 (18:46 +0100)]
bpo-38644: Pass tstate to _Py_FinishPendingCalls() (GH-17990)
_Py_FinishPendingCalls() now expects a tstate argument, instead of a
runtime argument.
Julien Danjou [Mon, 13 Jan 2020 16:30:14 +0000 (17:30 +0100)]
bpo-39164: Add private _PyErr_GetExcInfo() function (GH-17752)
This adds a new function named _PyErr_GetExcInfo() that is a variation of the
original PyErr_GetExcInfo() taking a PyThreadState as its first argument.
That function allows to retrieve the exceptions information of any Python
thread -- not only the current one.
Karthikeyan Singaravelan [Mon, 13 Jan 2020 14:39:36 +0000 (20:09 +0530)]
bpo-39299: Add more tests for mimetypes and its cli. (GH-17949)
* Add tests for case insensitive check of types and extensions as fallback.
* Add tests for data url with no comma.
* Add tests for read_mime_types.
* Add tests for the mimetypes cli and refactor __main__ code to private function.
* Restore mimetypes.knownfiles value at the end of the test.
Victor Stinner [Mon, 13 Jan 2020 13:57:14 +0000 (14:57 +0100)]
bpo-20443: Update What's New In Python 3.9 (GH-17986)
The sys.argv[0] change has been reverted.
Mark Shannon [Mon, 13 Jan 2020 12:51:26 +0000 (12:51 +0000)]
Cleanup exit code for interpreter. (GH-17756)
Pablo Galindo [Mon, 13 Jan 2020 12:25:05 +0000 (12:25 +0000)]
Fix typos in gcmodule.c and restructure comments for clarity (GH-17983)
Emmanuel Arias [Mon, 13 Jan 2020 11:58:52 +0000 (08:58 -0300)]
Remove unused functions in Parser/parsetok.c (GH-17365)
Victor Stinner [Mon, 13 Jan 2020 11:44:35 +0000 (12:44 +0100)]
bpo-39310: Add math.ulp(x) (GH-17965)
Add math.ulp(): return the value of the least significant bit
of a float.
Alex Henrie [Mon, 13 Jan 2020 10:35:47 +0000 (03:35 -0700)]
bpo-39307: Fix memory leak on error path in parsetok (GH-17953)
Philip McMahon [Sun, 12 Jan 2020 22:31:49 +0000 (22:31 +0000)]
bpo-32021: Support brotli .br encoding in mimetypes (#12200)
Add support for brotli encoding in the encoding_map.
Batuhan Taşkaya [Sun, 12 Jan 2020 22:13:31 +0000 (01:13 +0300)]
bpo-39313: Add an option to RefactoringTool for using exec as a function (GH-17967)
https://bugs.python.org/issue39313
Automerge-Triggered-By: @pablogsal
Ram Rachum [Sun, 12 Jan 2020 20:53:00 +0000 (22:53 +0200)]
Fix outdated comment in _strptime.py (GH-17929)
Can I please get the tags for skipping bpo and skipping a news item?
Batuhan Taşkaya [Sun, 12 Jan 2020 20:38:53 +0000 (23:38 +0300)]
bpo-3530: Add advice on when to correctly use fix_missing_locations in the AST docs (GH-17172)
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Guðni Natan Gunnarsson [Sun, 12 Jan 2020 17:41:49 +0000 (17:41 +0000)]
bpo-38293: Allow shallow and deep copying of property objects (GH-16438)
Copying property objects results in a TypeError. Steps to reproduce:
```
>>> import copy
>>> obj = property()
>>> copy.copy(obj)
````
This affects both shallow and deep copying.
My idea for a fix is to add property objects to the list of "atomic" objects in the copy module.
These already include types like functions and type objects.
I also added property objects to the unit tests test_copy_atomic and test_deepcopy_atomic. This is my first PR, and it's highly likely I've made some mistake, so please be kind :)
https://bugs.python.org/issue38293
Victor Stinner [Sun, 12 Jan 2020 11:57:47 +0000 (12:57 +0100)]
bpo-39288: Add examples to math.nextafter() documentation (GH-17962)
Kyle Stanley [Sun, 12 Jan 2020 11:02:50 +0000 (06:02 -0500)]
bpo-38356: Fix ThreadedChildWatcher thread leak in test_asyncio (GH-16552)
Motivation for this PR (comment from @vstinner in bpo issue):
```
Warning seen o AMD64 Ubuntu Shared 3.x buildbot:
https://buildbot.python.org/all/#/builders/141/builds/2593
test_devnull_output (test.test_a=syncio.test_subprocess.SubprocessThreadedWatcherTests) ...
Warning -- threading_cleanup() failed to cleanup 1 threads (count: 1, dangling: 2)
```
The following implementation details for the new method are TBD:
1) Public vs private
2) Inclusion in `close()`
3) Name
4) Coroutine vs subroutine method
5) *timeout* parameter
If it's a private method, 3, 4, and 5 are significantly less important.
I started with the most minimal implementation that fixes the dangling threads without modifying the regression tests, which I think is particularly important. I typically try to avoid directly modifying existing tests as much as possible unless it's necessary to do so. However, I am open to changing any part of this.
https://bugs.python.org/issue38356
Zac Hatfield-Dodds [Sun, 12 Jan 2020 09:04:14 +0000 (19:04 +1000)]
bpo-12159: Document sys.maxsize limit in len() function reference (GH-17934)
Vinay Sajip [Sun, 12 Jan 2020 08:54:00 +0000 (08:54 +0000)]
bpo-16575: Disabled checks for union types being passed by value. (GH-17960)
Although the underlying libffi issue remains open, adding these
checks have caused problems in third-party projects which are in
widespread use. See the issue for examples.
The corresponding tests have also been skipped.
Victor Stinner [Sun, 12 Jan 2020 01:15:42 +0000 (02:15 +0100)]
bpo-39288: Add math.nextafter(x, y) (GH-17937)
Return the next floating-point value after x towards y.
Dong-hee Na [Sat, 11 Jan 2020 17:39:15 +0000 (02:39 +0900)]
bpo-39259: nntplib.NNTP/NNTP_SSL now reject timeout = 0 (GH-17936)
nntplib.NNTP and nntplib.NNTP_SSL now raise a ValueError
if the given timeout for their constructor is zero to
prevent the creation of a non-blocking socket.
Jason R. Coombs [Sat, 11 Jan 2020 15:37:28 +0000 (10:37 -0500)]
bpo-39297: Update for importlib_metadata 1.4. (GH-17947)
* bpo-39297: Update for importlib_metadata 1.4. Includes performance updates.
* 📜🤖 Added by blurb_it.
* Update blurb
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Dong-hee Na [Sat, 11 Jan 2020 15:07:36 +0000 (00:07 +0900)]
bpo-39259: nntplib.NNTP/NNTP_SSL refactoring (GH-17939)
Karthikeyan Singaravelan [Sat, 11 Jan 2020 05:16:30 +0000 (10:46 +0530)]
Fix host in address of socket.create_server example. (GH-17706)
Host as None in address raises TypeError since it should be string, bytes or bytearray.
Vinay Sajip [Fri, 10 Jan 2020 19:37:48 +0000 (19:37 +0000)]
bpo-39292: Add missing syslog facility codes. (GH-17945)
Dong-hee Na [Fri, 10 Jan 2020 16:31:43 +0000 (01:31 +0900)]
bpo-39200: Correct the error message for min/max builtin function (GH-17814)
Correct the error message when calling the min() or max() with
no arguments.
Dong-hee Na [Fri, 10 Jan 2020 14:34:05 +0000 (23:34 +0900)]
bpo-39259: poplib now rejects timeout = 0 (GH-17912)
poplib.POP3 and poplib.POP3_SSL now raise a ValueError
if the given timeout for their constructor is zero to
prevent the creation of a non-blocking socket.
Pablo Galindo [Fri, 10 Jan 2020 09:24:22 +0000 (09:24 +0000)]
bpo-39166: Fix trace of last iteration of async for loops (#17800)
Serhiy Storchaka [Fri, 10 Jan 2020 08:12:55 +0000 (10:12 +0200)]
bpo-39235: Check end_lineno and end_col_offset of AST nodes. (GH-17926)
Guido van Rossum [Thu, 9 Jan 2020 19:18:47 +0000 (11:18 -0800)]
bpo-39235: Fix end location for genexp in call args (GH-17925)
The fix changes copy_location() to require an extra node from which to extract the end location, and fixing all 5 call sites.
https://bugs.python.org/issue39235
Daniel Hahler [Thu, 9 Jan 2020 17:07:32 +0000 (18:07 +0100)]
Fix typo in test's docstring (GH-17856)
* Fix typo in test's docstring. contination -> continuation.
Steve Dower [Thu, 9 Jan 2020 17:00:29 +0000 (09:00 -0800)]
bpo-25172: Reduce scope of crypt import tests (GH-17881)
Karthikeyan Singaravelan [Thu, 9 Jan 2020 13:41:46 +0000 (19:11 +0530)]
Add test cases for dataclasses. (#17909)
* Add test cases for dataclasses.
* Add test for repr output of field.
* Add test for ValueError to be raised when both default and default_factory are passed.
Petr Viktorin [Thu, 9 Jan 2020 12:05:18 +0000 (13:05 +0100)]
bpo-39161: Document multi-phase init modules under Py_NewInterpreter() (GH-17896)
\+ this also adds a stronger warning against sharing objects between (sub-)interpreters.
https://bugs.python.org/issue39161
Alex Henrie [Thu, 9 Jan 2020 09:14:11 +0000 (09:14 +0000)]
bpo-39270: Remove dead assignment from config_init_module_search_paths (GH-17914)
Alex Henrie [Thu, 9 Jan 2020 09:12:12 +0000 (09:12 +0000)]
bpo-39272: Remove dead assignment from _ssl__SSLContext_load_verify_locations_impl (GH-17916)
Alex Henrie [Thu, 9 Jan 2020 06:27:52 +0000 (06:27 +0000)]
bpo-39271: Remove dead assignment from pattern_subx (GH-17915)
Alex Henrie [Thu, 9 Jan 2020 02:48:52 +0000 (02:48 +0000)]
closes bpo-39262: Use specific out-of-memory message in _sharedexception_bind. (GH-17908)
Alex Henrie [Thu, 9 Jan 2020 02:46:55 +0000 (02:46 +0000)]
closes bpo-39261: Remove dead assignment from pyinit_config. (GH-17907)
Victor Stinner [Wed, 8 Jan 2020 20:03:45 +0000 (21:03 +0100)]
Py_DECREF: only pass filename if Py_REF_DEBUG is defined (GH-17870)
Filename and line numbers are not needed when Py_REF_DEBUG are not
defined.
The static inline _Py_DECREF() function was introduced by
commit
2aaf0c12041bcaadd7f2cc5a54450eefd7a6ff12 .
An Long [Wed, 8 Jan 2020 18:28:14 +0000 (02:28 +0800)]
bpo-35292: Avoid calling mimetypes.init when http.server is imported (GH-17822)
Dong-hee Na [Wed, 8 Jan 2020 15:29:34 +0000 (00:29 +0900)]
bpo-39242: Updated the Gmane domain into news.gmane.io (GH-17903)
Pablo Galindo [Wed, 8 Jan 2020 13:00:14 +0000 (13:00 +0000)]
bpo-39233: Update positional-only section in the glossary (GH-17874)
https://bugs.python.org/issue39233
Alex Henrie [Wed, 8 Jan 2020 12:52:44 +0000 (12:52 +0000)]
bpo-39237, datetime: Remove redundant call to round from delta_new (GH-17877)
Dong-hee Na [Tue, 7 Jan 2020 17:30:55 +0000 (02:30 +0900)]
bpo-38871: Fix lib2to3 for filter-based statements that contain lambda (GH-17780)
Correctly parenthesize filter-based statements that contain lambda
expressions in lib2to3.
Dong-hee Na [Tue, 7 Jan 2020 17:28:10 +0000 (02:28 +0900)]
bpo-38615: Add timeout parameter for IMAP4 and IMAP4_SSL constructor (GH-17203)
imaplib.IMAP4 and imaplib.IMAP4_SSL now have an
optional *timeout* parameter for their constructors.
Also, the imaplib.IMAP4.open() method now has an optional *timeout* parameter
with this change. The overridden methods of imaplib.IMAP4_SSL and
imaplib.IMAP4_stream were applied to this change.
Derek Brown [Tue, 7 Jan 2020 16:40:23 +0000 (08:40 -0800)]
bpo-39198: Ensure logging global lock is released on exception in isEnabledFor (GH-17689)
Victor Stinner [Tue, 7 Jan 2020 14:00:02 +0000 (15:00 +0100)]
bpo-39239: epoll.unregister() no longer ignores EBADF (GH-17882)
The select.epoll.unregister() method no longer ignores the EBADF
error.
Andrew Svetlov [Tue, 7 Jan 2020 13:23:01 +0000 (15:23 +0200)]
bpo-39191: Fix RuntimeWarning in asyncio test (GH-17863)
https://bugs.python.org/issue39191
Inada Naoki [Tue, 7 Jan 2020 07:58:40 +0000 (16:58 +0900)]
bpo-38623: Doc: Add section for site module CLI. (GH-17858)
Inada Naoki [Tue, 7 Jan 2020 06:52:44 +0000 (15:52 +0900)]
Doc: Change Python 2 status to EOL. (GH-17885)
YoSTEALTH [Mon, 6 Jan 2020 22:04:43 +0000 (16:04 -0600)]
bpo-39234: `enum.auto()` default initial value as 1 (GH-17878)
Updated as Eric mentioned "By default, the initial value starts at 1"
https://bugs.python.org/issue39234
Automerge-Triggered-By: @ericvsmith
Steve Dower [Mon, 6 Jan 2020 21:23:10 +0000 (13:23 -0800)]
bpo-39041: Fix coverage upload command for GitHub Actions (GH-17873)
https://bugs.python.org/issue39041
Automerge-Triggered-By: @zooba
YoSTEALTH [Mon, 6 Jan 2020 19:53:36 +0000 (13:53 -0600)]
bpo-39234: Doc: `enum.auto()` incrementation value not specified. (GH-17872)
* `enum.auto()` initial value is now specified as being `1`.
Anthony Wee [Mon, 6 Jan 2020 16:57:34 +0000 (08:57 -0800)]
bpo-29778: Fix incorrect NULL check in _PyPathConfig_InitDLLPath() (GH-17818)
Pablo Galindo [Mon, 6 Jan 2020 15:59:09 +0000 (15:59 +0000)]
bpo-39209: Manage correctly multi-line tokens in interactive mode (GH-17860)
Chandan Singh [Mon, 6 Jan 2020 15:18:16 +0000 (15:18 +0000)]
Fix link to bpo issue in Changelog (GH-17692)
Jason R. Coombs [Mon, 6 Jan 2020 12:59:36 +0000 (07:59 -0500)]
bpo-38907: Suppress any exception when attempting to set V6ONLY. (GH-17864)
Fixes error attempting to bind to IPv4 address.
Dong-hee Na [Mon, 6 Jan 2020 10:46:04 +0000 (19:46 +0900)]
argument-clinic: Simplify multi-line string handling (GH-17852)
Jason R. Coombs [Mon, 6 Jan 2020 03:32:19 +0000 (22:32 -0500)]
bpo-38907: In http.server script, restore binding to IPv4 on Windows. (GH-17851)
Tal Einat [Sun, 5 Jan 2020 23:51:48 +0000 (01:51 +0200)]
Minor formatting improvements and fixes to idle.rst (GH-17165)
Khalid Mammadov [Sun, 5 Jan 2020 22:39:38 +0000 (22:39 +0000)]
bpo-39130: Dict reversed was added in v3.8 so should say in the doc as well (GH-17694)
To be consistent with document layout, it should say when the feature was added.
Although it's mentioned few other places in the doc but it's not explicitly say that at that place.
https://bugs.python.org/issue39130
HongWeipeng [Sun, 5 Jan 2020 22:20:29 +0000 (16:20 -0600)]
Fix the parameter list of object. _rpow_ (#GH-16477)
Oleg Höfling [Sun, 5 Jan 2020 22:08:14 +0000 (23:08 +0100)]
Replace links in howto/pyporting.rst with sphinx references (GH-17781)
Signed-off-by: Oleg Höfling <oleg.hoefling@gmail.com>
Pablo Galindo [Sun, 5 Jan 2020 18:52:39 +0000 (18:52 +0000)]
Organise and clean test_positional_only_arg and add more tests (GH-17842)
Pablo Galindo [Sun, 5 Jan 2020 17:30:53 +0000 (17:30 +0000)]
bpo-39200: Correct the error message for range() empty constructor (GH-17813)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Anthony Sottile [Sun, 5 Jan 2020 17:03:56 +0000 (12:03 -0500)]
Fix constant folding optimization for positional only arguments (GH-17837)
Terry Jan Reedy [Sun, 5 Jan 2020 16:23:58 +0000 (11:23 -0500)]
bpo-39152: add missing ttk.Scale.configure return value (GH-17815)
tkinter.ttk.Scale().configure([name]) now returns a configuration tuple for name
or a list thereof for all options. Based on patch Giovanni Lombardo.
Serhiy Storchaka [Sun, 5 Jan 2020 12:15:50 +0000 (14:15 +0200)]
bpo-39055: Reject a trailing \n in base64.b64decode() with validate=True. (GH-17616)
Serhiy Storchaka [Sun, 5 Jan 2020 12:15:27 +0000 (14:15 +0200)]
bpo-39056: Fix handling invalid warning category in the -W option. (GH-17618)
No longer import the re module if it is not needed.
Serhiy Storchaka [Sun, 5 Jan 2020 12:14:31 +0000 (14:14 +0200)]
bpo-39057: Fix urllib.request.proxy_bypass_environment(). (GH-17619)
Ignore leading dots and no longer ignore a trailing newline.
Anthony Sottile [Sun, 5 Jan 2020 01:57:21 +0000 (20:57 -0500)]
Fix SystemError when nested function has annotation on positional-only argument (GH-17826)
Anthony Shaw [Sat, 4 Jan 2020 12:56:31 +0000 (23:56 +1100)]
bpo-28367: Add additional baud rates for termios (GH-13142)
Co-authored-by: Andrey Smirnov <andrew.smirnov@gmail.com>.
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Andrew Svetlov [Sat, 4 Jan 2020 09:10:14 +0000 (11:10 +0200)]
Fix #39191: Don't spawn a task before failing (#17796)
Zackery Spytz [Fri, 3 Jan 2020 12:16:12 +0000 (05:16 -0700)]
bpo-38532: Add missing decrefs in PyCFuncPtr_FromDll() (GH-16857)
Emmanuel Nosa E [Fri, 3 Jan 2020 12:10:16 +0000 (13:10 +0100)]
Add link to zlib v1.1.3 vulnerability (GH-17156)
Raymond Hettinger [Fri, 3 Jan 2020 05:21:18 +0000 (22:21 -0700)]
bpo-39158: ast.literal_eval() doesn't support empty sets (GH-17742)
Ned Deily [Fri, 3 Jan 2020 03:28:37 +0000 (22:28 -0500)]
Update copyright year in macOS installer license copy (GH-17806)
Benjamin Peterson [Fri, 3 Jan 2020 02:56:34 +0000 (18:56 -0800)]
Bring Python into the next decade. (GH-17801)
Batuhan Taşkaya [Thu, 2 Jan 2020 18:20:04 +0000 (21:20 +0300)]
bpo-38870: Throw ValueError on invalid yield from usage (GH-17798)
Anthony Shaw [Thu, 2 Jan 2020 17:32:55 +0000 (04:32 +1100)]
Remove outdated mention of hg.exe from Tools/msi/README.txt (GH-17792)
Pablo Galindo [Thu, 2 Jan 2020 11:38:44 +0000 (11:38 +0000)]
bpo-39114: Fix tracing of except handlers with name binding (GH-17769)
When producing the bytecode of exception handlers with name binding (like `except Exception as e`) we need to produce a try-finally block to make sure that the name is deleted after the handler is executed to prevent cycles in the stack frame objects. The bytecode associated with this try-finally block does not have source lines associated and it was causing problems when the tracing functionality was running over it.
Rafael Fontenelle [Wed, 1 Jan 2020 22:26:33 +0000 (19:26 -0300)]
bpo-39183: Fix formatting in library/ensurepip (GH-17787)
Remove extra space to fix formatting and avoid from splitting text in to strings.
https://bugs.python.org/issue39183
Jendrik Seipp [Wed, 1 Jan 2020 22:21:43 +0000 (23:21 +0100)]
bpo-13601: always use line-buffering for sys.stderr (GH-17646)
Vinay Sajip [Wed, 1 Jan 2020 19:32:11 +0000 (19:32 +0000)]
bpo-39142: Avoid converting namedtuple instances to ConvertingTuple. (GH-17773)
This uses the heuristic of assuming a named tuple is a subclass of
tuple with a _fields attribute. This change means that contents of
a named tuple wouldn't be converted - if a user wants to have
ConvertingTuple functionality from a namedtuple, they will have to
implement it themselves.
Anthony Sottile [Wed, 1 Jan 2020 06:11:16 +0000 (01:11 -0500)]
Document CodeType.replace (GH-17776)
Ned Batchelder [Wed, 1 Jan 2020 02:40:58 +0000 (21:40 -0500)]
bpo-39176: Improve error message for 'named assignment' (GH-17777)
Terry Jan Reedy [Tue, 31 Dec 2019 18:34:22 +0000 (13:34 -0500)]
Fix idlelib README typo. (GH-17770)
Борис Верховский [Tue, 31 Dec 2019 12:28:18 +0000 (07:28 -0500)]
Minor doc fixes in urllib.parse (GH-17745)
Batuhan Taşkaya [Tue, 31 Dec 2019 02:31:52 +0000 (05:31 +0300)]
closes bpo-37446: resolve undefined behavior in Python/hamt.c (GH-17727)
Inada Naoki [Tue, 31 Dec 2019 01:58:37 +0000 (10:58 +0900)]
bpo-38588: Optimize list comparison. (GH-17766)
Mitigate performance regression of the list comparison caused by
2d5bf56 .
Dong-hee Na [Tue, 31 Dec 2019 01:04:22 +0000 (10:04 +0900)]
bpo-38588: Fix possible crashes in dict and list when calling PyObject_RichCompareBool (GH-17734)
Take strong references before calling PyObject_RichCompareBool to protect against the case
where the object dies during the call.
Terry Jan Reedy [Mon, 30 Dec 2019 22:16:43 +0000 (17:16 -0500)]
bpo-34118: memoryview, range, and tuple are classes (GH-17761)
Tag memoryview, range, and tuple as classes, the same as list, etcetera, in
the library manual built-in functions list.
Zackery Spytz [Mon, 30 Dec 2019 19:32:58 +0000 (12:32 -0700)]
bpo-38610: Fix possible crashes in several list methods (GH-17022)
Hold strong references to list elements while calling PyObject_RichCompareBool().
Batuhan Taşkaya [Mon, 30 Dec 2019 16:08:08 +0000 (19:08 +0300)]
bpo-39019: Implement missing __class_getitem__ for SpooledTemporaryFile (GH-17560)
Batuhan Taşkaya [Mon, 30 Dec 2019 16:02:04 +0000 (19:02 +0300)]
bpo-39019: Implement missing __class_getitem__ for subprocess classes (GH-17558)
Kyle Stanley [Mon, 30 Dec 2019 11:50:19 +0000 (06:50 -0500)]
bpo-34790: Implement deprecation of passing coroutines to asyncio.wait() (GH-16977)
Mark Shannon [Mon, 30 Dec 2019 09:53:36 +0000 (09:53 +0000)]
Fix handling of line numbers around finally-blocks. (#17737)