Skip to content

Comments

3.8#17624

Closed
fongchinghinunsw wants to merge 1021 commits intomasterfrom
3.8
Closed

3.8#17624
fongchinghinunsw wants to merge 1021 commits intomasterfrom
3.8

Conversation

@fongchinghinunsw
Copy link

@fongchinghinunsw fongchinghinunsw commented Dec 16, 2019

No description provided.

nascheme and others added 30 commits October 1, 2019 09:49
This is a revert of the revert (GH-15826).  Having a tp_clear for
functions should be safe (and helpful) now that bpo-38006 has been
fixed.
…size (GH-16491) (#16506)

(cherry picked from commit 94e1650)

Co-authored-by: Giampaolo Rodola <g.rodola@gmail.com>
PyConfig_InitPythonConfig() and PyConfig_InitIsolatedConfig() no
longer return PyStatus: they cannot fail anymore.
(cherry picked from commit 8462a49)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
* Windows: Fix counter name in WindowsLoadTracker. Counter names are
  localized: use the registry to get the counter name. Original
  change written by Lorenz Mende.
* Regrtest.main() now ensures that the Windows load tracker is also
  killed if an exception is raised
* TestWorkerProcess now ensures that worker processes are no longer
  running before exiting: kill also worker processes when an
  exception is raised.
* Enhance regrtest messages and warnings: include test name,
  duration, add a worker identifier, etc.
* Rename MultiprocessRunner to TestWorkerProcess
* Use print_warning() to display warnings.

Co-Authored-By: Lorenz Mende <Lorenz.mende@gmail.com>
(cherry picked from commit 982bfa4)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
* bpo-38321: Fix _asynciomodule.c compiler warning (GH-16493)

bpo-38248, bpo-38321: Fix warning:

    modules\_asynciomodule.c(2667):
    warning C4102: 'set_exception': unreferenced label

The related goto has been removed by
commit edad4d8.

(cherry picked from commit efe74b6)

* bpo-38321: Fix PyCStructUnionType_update_stgdict() warning (GH-16492)

bpo-22273, bpo-38321: Fix following warning:

    modules\_ctypes\stgdict.c(704):
    warning C4244: 'initializing': conversion from 'Py_ssize_t' to 'int', possible loss of data

(cherry picked from commit c9a413e)
(cherry picked from commit 891e9e3)

Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
(cherry picked from commit b9a8b82)

Co-authored-by: Steve Dower <steve.dower@python.org>
* Fix TestWorkerProcess.__repr__(): start_time is only valid
  if _popen is not None.
* Fix _kill(): don't set _killed to True if _popen is None.
* _run_process(): only set _killed to False after calling
  run_test_in_subprocess().
(cherry picked from commit 2ea71a0)

Co-authored-by: Victor Stinner <vstinner@python.org>
test.pythoninfo now logs environment variables used by OpenSSL and
Python ssl modules, and logs attributes of 3 SSL contexts
(SSLContext, default HTTPS context, stdlib context).
(cherry picked from commit b3e7045)

Co-authored-by: Victor Stinner <vstinner@python.org>
…H-16550) (GH-16560)

* bpo-36670, regrtest: Fix WindowsLoadTracker() for partial line (GH-16550)

WindowsLoadTracker.read_output() now uses a short buffer for
incomplete line.

(cherry picked from commit 3e04cd2)

* bpo-36670: Enhance regrtest WindowsLoadTracker (GH-16553)

The last line is now passed to the parser even if it does not end
with a newline, but only if it's a valid value.

(cherry picked from commit c65119d)

* bpo-36670: Enhance regrtest (GH-16556)

* Add log() method: add timestamp and load average prefixes
  to main messages.
* WindowsLoadTracker:

  * LOAD_FACTOR_1 is now computed using SAMPLING_INTERVAL
  * Initialize the load to the arithmetic mean of the first 5 values
    of the Processor Queue Length value (so over 5 seconds), rather
    than 0.0.
  * Handle BrokenPipeError and when typeperf exit.

* format_duration(1.5) now returns '1.5 sec', rather than
  '1 sec 500 ms'

(cherry picked from commit 098e256)
(cherry picked from commit a0e3d27)

Co-authored-by: Steve Dower <steve.dower@python.org>
)

(cherry picked from commit 353fb1e)

Co-authored-by: Steve Dower <steve.dower@python.org>
)

(cherry picked from commit b23a842)

Co-authored-by: idomic <michael.ido@gmail.com>
…16571) (GH-16576)

(cherry picked from commit 3142c66)

Co-authored-by: Ashley Whetter <AWhetter@users.noreply.github.com>
…cl. (GH-16545)

On Windows use UTF-16 (or UTF-32 for 32-bit Tcl_UniChar) with the
"surrogatepass" error handler for converting to/from Tcl Unicode objects.

On Linux use UTF-8 with the "surrogateescape" error handler for converting
to/from Tcl String objects.

Converting strings from Tcl to Python and back now never fails
(except MemoryError).
(cherry picked from commit 06cb94b)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
… bytearray. (GH-16603)

(cherry picked from commit 24ddd9c)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
…16588)

The `required` argument to `argparse.add_subparsers` was added in GH-3027. This PR specifies the earliest version of Python where it is available.

https://bugs.python.org/issue26510

Automerge-Triggered-By: @merwok
(cherry picked from commit 9e71917)

Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
(cherry picked from commit 038503e)

Co-authored-by: Krishna Oza <krishoza15sep@gmail.com>
(cherry picked from commit 321def8)

Co-authored-by: Ben Harper <btharper1221@gmail.com>
Always define _PyUnicode_CheckConsistency() in the CPython C API.
…tion. (GH-16442)

Prior to 3.7, re.escape escaped many characters that don't have
special meaning in Python, but that use to require escaping in other
tools and languages. This commit aims to make it clear which characters
were, but are no longer escaped.
(cherry picked from commit 15ae75d)

Co-authored-by: Ricardo Bánffy <rbanffy@gmail.com>
(cherry picked from commit e310af9)

Co-authored-by: James Abel <j@abel.co>
(cherry picked from commit 5dfbb4d)

Co-authored-by: Hansraj Das <raj.das.136@gmail.com>
…o stderr. (GH-16583)

It now escapes them with a backslash, as the regular Python interpreter.
Added the "errors" field to the standard streams.
(cherry picked from commit b690a27)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Valgrind emits "Conditional jump or move depends on uninitialised
value(s)" false alarms on GCC builtin strcmp() function. The GCC code
is correct.

Valgrind bug: https://bugs.kde.org/show_bug.cgi?id=264936
(cherry picked from commit 03ab6b4)

Co-authored-by: Victor Stinner <vstinner@python.org>
…H-16641)

(cherry picked from commit 13abda4)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
(cherry picked from commit 8252c52)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…H-16662)

The implementation of weakref.proxy's methods call back into the Python
API using a borrowed references of the weakly referenced object
(acquired via PyWeakref_GET_OBJECT). This API call may delete the last
reference to the object (either directly or via GC), leaving a dangling
pointer, which can be subsequently dereferenced.

To fix this, claim a temporary ownership of the referenced object when
calling the appropriate method. Some functions because at the moment they
do not need to access the borrowed referent, but to protect against
future changes to these functions, ownership need to be fixed in
all potentially affected methods..
(cherry picked from commit 10cd00a)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.