Commit Graph

106594 Commits

Author SHA1 Message Date
Stefan Krah b3b9ade4a3
bpo-39776: Lock ++interp->tstate_next_unique_id. (GH-18746) (#18746)
- Threads created by PyGILState_Ensure() could have a duplicate tstate->id.
2020-03-02 21:22:36 +01:00
Serhiy Storchaka 2d2f85517f
bpo-39831: Fix a reference leak in PyErr_WarnEx(). (GH-18750) 2020-03-02 22:05:08 +02:00
Batuhan Taşkaya 89aa4694fc
bpo-38870: Add docstring support to ast.unparse (GH-17760)
Allow ast.unparse to detect docstrings in functions, modules and classes and produce
nicely formatted unparsed output for said docstrings.

Co-Authored-By: Pablo Galindo <Pablogsal@gmail.com>
2020-03-02 18:59:01 +00:00
Victor Stinner 66b7973c1b
bpo-39796: Fix _warnings module initialization (GH-18739)
* Add _PyWarnings_InitState() which only initializes the _warnings
  module state (tstate->interp->warnings) without creating a module
  object
* Py_InitializeFromConfig() now calls _PyWarnings_InitState() instead
  of _PyWarnings_Init()
* Rename also private functions of _warnings.c to avoid confusion
  between the public C API and the private C API.
2020-03-02 15:02:18 +01:00
Lidi Zheng 4482337dec
bpo-39764: Make Task.get_stack accept ag_frame (#18669)
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2020-03-02 14:45:54 +02:00
Erlend Egeberg Aasland 1382c3289b
bpo-38380: Update macOS & Windows builds to SQLite v3.31.1 (GH-18678)
Automerge-Triggered-By: @zooba
2020-03-02 04:25:10 -08:00
Inada Naoki 2110551761
bpo-39775: inspect: Change Signature.parameters back to OrderedDict. (GH-18684) 2020-03-02 18:54:48 +09:00
Mark Dickinson 9f1cb1bb49
Fix misleading statement about mixed-type numeric comparisons (GH-18615) 2020-03-02 08:57:27 +00:00
Serhiy Storchaka 28d0bcac8b
bpo-38913: Fix segfault in Py_BuildValue("(s#O)", ...) if entered with exception raised. (GH-18656) 2020-03-02 08:42:39 +02:00
Chris A 2565edec2c
bpo-38971: Open file in codecs.open() closes if exception raised. (GH-17666)
Open issue in the BPO indicated a desire to make the implementation of
codecs.open() at parity with io.open(), which implements a try/except to
assure file stream gets closed before an exception is raised.
2020-03-02 08:39:50 +02:00
Shantanu 4edc95cf0a
bpo-39495: Remove default value from C impl of TreeBuilder.start (GH-18275) 2020-03-02 08:33:24 +02:00
Hai Shi 1f577ce363
bpo-39378: partial of PickleState struct should be traversed. (GH-18046) 2020-03-02 08:28:44 +02:00
Pablo Galindo 114081f8ad
bpo-39199: Add descriptions of non-deprecated nodes to the AST module documentation (GH-17812)
Adapted from https://greentreesnakes.readthedocs.io

Co-authored-by: Karthikeyan Singaravelan <tir.karthi@gmail.com>
Co-authored-by: Carol Willing <carolcode@willingconsulting.com>
2020-03-02 03:14:06 +00:00
Andy Lester 3fe9117779
closes bpo-39803: Remove unused str from _PyLong_FormatAdvancedWriter. (GH-18709) 2020-03-01 13:26:43 -08:00
Hakan Çelik 217dce9ee6
bpo-39815: add cached_property to all (GH-18726)
Automerge-Triggered-By: @pablogsal
2020-03-01 13:01:34 -08:00
Thomas Moreau 0e89076247
bpo-39678: refactor queue manager thread (GH-18551) 2020-03-01 21:49:14 +01:00
Batuhan Taşkaya 397b96f6d7
bpo-38870: Implement a precedence algorithm in ast.unparse (GH-17377)
Implement a simple precedence algorithm for ast.unparse in order to avoid redundant
parenthesis for nested structures in the final output.
2020-03-01 20:12:17 +00:00
Batuhan Taşkaya 185903de12
bpo-39520: Fix un-parsing of ext slices with no dimensions (GH-18304) 2020-03-01 20:07:22 +00:00
Vlad Emelianov 768d739c1c
bpo-38641: Add lib2to3 support for starred expressions in return/yield statements (GH-16994) 2020-03-01 19:59:26 +00:00
Stefan Krah 0b0d29fce5
Mention backports (GH-18715) 2020-02-29 22:39:23 +01:00
Stephen Balousek 5e260e0fde
bpo-39548: Fix handling of 'WWW-Authenticate' header for Digest Auth (GH-18338)
* bpo-39548: Fix handling of 'WWW-Authenticate' header for Digest authentication

 - The 'qop' value in the 'WWW-Authenticate' header is optional. The
   presence of 'qop' in the header should be checked before its value
   is parsed with 'split'.

Signed-off-by: Stephen Balousek <stephen@balousek.net>

* bpo-39548: Fix handling of 'WWW-Authenticate' header for Digest authentication

 - Add NEWS item

Signed-off-by: Stephen Balousek <stephen@balousek.net>

* Update Misc/NEWS.d/next/Library/2020-02-06-05-33-52.bpo-39548.DF4FFe.rst

Co-Authored-By: Brandt Bucher <brandtbucher@gmail.com>

Co-authored-by: Brandt Bucher <brandtbucher@gmail.com>
2020-02-29 12:31:58 -08:00
Stefan Krah eb47fd58ab
Cosmetic change to match the surrounding code. (#18704) 2020-02-29 20:07:48 +01:00
Stefan Krah 815280eb16
bpo-39794: Add --without-decimal-contextvar (#18702) 2020-02-29 19:43:42 +01:00
Jason R. Coombs 0aeab5c438
bpo-39667: Sync zipp 3.0 (GH-18540)
* bpo-39667: Improve pathlib.Path compatibility on zipfile.Path and correct performance degradation as found in zipp 3.0

* 📜🤖 Added by blurb_it.

* Update docs for new zipfile.Path.open

* Rely on dict, faster than OrderedDict.

* Syntax edits on docs

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2020-02-29 10:34:11 -06:00
Ananthakrishnan 1f0cd3c61a
bpo-39379: Remove reference to sys.path[0] being absolute path in whatsnew (GH-18561)
Remove reference to sys.path[0] being absolute path in whatsnew

Co-Authored-By: Kyle Stanley <aeros167@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Kyle Stanley <aeros167@gmail.com>
2020-02-29 17:55:22 +05:30
Henry Harutyunyan dc04a0571e
bpo-37534: Allow adding Standalone Document Declaration when generating XML documents (GH-14912) 2020-02-29 09:22:19 +01:00
Gregory P. Smith 02673352b5
bpo-39769: Fix compileall ddir for subpkgs. (GH-18676)
Fix compileall.compile_dir() ddir= behavior on sub-packages.

Fixes compileall.compile_dir's ddir parameter and compileall command
line flag `-d` to no longer write the wrong pathname to the generated
pyc file for submodules beneath the root of the directory tree being
compiled.  This fixes a regression introduced with Python 3.5.

Also marks the _new_ in 3.9 from PR #16012 parameters to compile_dir as keyword only (as that is the only way they will be used) and fixes an omission of them in one place from the docs.
2020-02-28 17:28:37 -08:00
Steve Dower 03153dd145
bpo-39789: Update Windows release build machines to VS 2019 (GH-18695)
Also fixes some potential Nuget build issues.
2020-02-29 00:21:46 +00:00
Shantanu c2f7eb254b
bpo-39718: add TYPE_IGNORE, COLONEQUAL to py38 changes in token (GH-18598) 2020-02-28 18:25:36 -05:00
Terry Jan Reedy 916895f939
bpo-13790: Change 'string' to 'specification' in format doc (GH-18690) 2020-02-28 14:59:16 -05:00
Terry Jan Reedy c705fd1e89
bpo-39781: Do not jump when select in IDLE codecontext (GH-18683)
Previously, the button-up part of selecting with a mouse was treated as a click
that meant 'jump' to this line, which modified the context and undid the selection
2020-02-28 13:22:55 -05:00
Vinay Sajip 4f17c5cd9a
bpo-12915: Improve Unicode support for package names and attributes. (GH-18517) 2020-02-28 14:26:27 +00:00
Ammar Askar e263bb1e97
Fuzz struct.unpack and catch RecursionError in re.compile (GH-18679) 2020-02-27 23:05:02 -08:00
Andy Lester 384f3c536d
closes bpo-39721: Fix constness of members of tok_state struct. (GH-18600)
The function PyTokenizer_FromUTF8 from Parser/tokenizer.c had a comment:

    /* XXX: constify members. */

This patch addresses that.

In the tok_state struct:
    * end and start were non-const but could be made const
    * str and input were const but should have been non-const

Changes to support this include:
    * decode_str() now returns a char * since it is allocated.
    * PyTokenizer_FromString() and PyTokenizer_FromUTF8() each creates a
        new char * for an allocate string instead of reusing the input
        const char *.
    * PyTokenizer_Get() and tok_get() now take const char ** arguments.
    * Various local vars are const or non-const accordingly.

I was able to remove five casts that cast away constness.
2020-02-27 18:44:52 -08:00
Ammar Askar 766b7546a5
bpo-39704: Explicitly pass the path to codecov config (GH-18680) 2020-02-27 15:08:30 -08:00
Markus Mohrhard 374d998b50
bpo-39609: set the thread_name_prefix for the default asyncio executor (GH-18458)
Just a small debugging improvement to identify the asyncio executor threads.
2020-02-27 12:01:47 -08:00
Inada Naoki 02a4d57263
bpo-39087: Optimize PyUnicode_AsUTF8AndSize() (GH-18327)
Avoid using temporary bytes object.
2020-02-27 13:48:59 +09:00
Andrew Svetlov 0c6e3aa67b
Suppress the hang (#18457) 2020-02-27 00:15:12 +02:00
Brandt Bucher d0ca9bd93b
bpo-36144: Document PEP 584 (GH-18659) 2020-02-26 12:01:48 -08:00
Ammar Askar 6aa1f1ecf7
bpo-39699: Don't silence make on Azure and Github CIs (GH-18583) 2020-02-26 19:21:41 +00:00
opavlyuk 21da76d1f1
bpo-34788: Add support for scoped IPv6 addresses (GH-13772)
Automerge-Triggered-By: @asvetlov
2020-02-26 06:33:57 -08:00
sweeneyde be7ead62db
bpo-39737: Remove code repitition in list_richcompare (GH-18638)
I may speed up list comparison on some platforms.
2020-02-26 09:00:35 +02:00
Inada Naoki 57c7a0bdf4
Doc: int -> int or Py_ssize_t (GH-18663) 2020-02-26 15:04:39 +09:00
Łukasz Langa 541e0ffbc8
Post 3.9.0a4 2020-02-26 01:31:04 +01:00
Łukasz Langa 9e52330415 Python 3.9.0a4
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE4/8oOcBIslwITevpsmmV4xAlBWgFAl5VnLMACgkQsmmV4xAl
 BWgOrxAAhpv1CJtFDT0st4Apksq6mZNvZ/Fn03wiKjoR88qGMQXlHLF0uI48Rh0Z
 AuxfzBu/PsuDo7JHCeMG4sEsaJ1OSD7nl6Xq4Q8EWFiiP6QwMQuS8yxQgTi8Vonf
 EjujegOT4HpD9gAnw8esjFK+ln89kaeTYWoUi62f9mEi3EMw9wFBt0JfZ0SWkQvf
 tuJ401zstVTNv2D0GV1l10QAKDEzjjxj/oelEGM1urxMAbv/Ztls6SEpCEvMQp3c
 cUP1GaHJcu1tQIXCDvUWeLDdEb+uW5mDzbRPTbMSwqcnTvr1HHdzsNMlJTwKcjpV
 wgJ88TraN9oonvv63oJ//38I1zxh+WnZHLc2jlh4aksLz6J98W/2rw0UT4LOoPdR
 6cdjL4jSkFAZqJb5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geQ4uHu267TqsYEAzv+lOL2OkA/4NcXzuBCD2GsoQTakBr3CLhC8BVht
 LegRXHDDmQ==
 =A6+h
 -----END PGP SIGNATURE-----

Merge tag 'v3.9.0a4'

Python 3.9.0a4
2020-02-26 01:30:02 +01:00
Łukasz Langa 6e02691f30
Python 3.9.0a4 2020-02-25 22:06:39 +01:00
Steve Dower d644891970
bpo-38403: Update nuspec file for deprecated field and git repository (GH-18657) 2020-02-25 20:07:00 +00:00
Brandt Bucher eb8ac57af2
bpo-36144: Dictionary Union (PEP 584) (#12088) 2020-02-24 19:47:34 -08:00
Berker Peksag ba22e8f174
bpo-30566: Fix IndexError when using punycode codec (GH-18632)
Trying to decode an invalid string with the punycode codec
shoud raise UnicodeError.
2020-02-25 06:19:03 +03:00
idomic 8af4712a16
bpo-39128: Added algorithm description (GH-18624)
# [bpo-39128](https://bugs.python.org/issue39128): happy eyeballs description

# [3.9] 39128 - happy eyeballs description (GH-18624)
# [3.8] 39128 - happy eyeballs description (GH-18624)



https://bugs.python.org/issue39128
2020-02-24 06:59:40 -08:00