The test depended on '/usr/share/zoneinfo/posixrules' or equivalent
because it set TZ without explicit DST transition rules. At least
on OpenSUSE Tumbleweed that file is linked to '/etc/localtime',
making the test fail with certain local timezones,
such as 'Europe/Moscow' which doesn't have DST transitions since 2011.
(cherry picked from commit f1b9ad3d38)
Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
(This should have been done with the first PR for this issue.)
(cherry picked from commit f1d3efc2fb)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
The section is renamed from "IDLE -- console differences". It mostly
covers the implications of using custom sys.stdxxx objects.
(cherry picked from commit 5e79090324)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
§31.5.6.3. Importing a source file directly: `module_from_spec` is new in Python 3.5.
(cherry picked from commit 16c8a53490)
Co-authored-by: E Kawashima <e-kwsm@users.noreply.github.com>
Two kind of mistakes:
1. Missed space. After concatenating there is no space between words.
2. Missed comma. Causes unintentional concatenating in a list of strings.
(cherry picked from commit 34fd4c2019)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Some methods in the os module can accept path-like objects. This is documented in the general documentation but not in the function docstrings. To keep both in sync, the docstrings need to be updated to reflect that path-like objects are also accepted..
(cherry picked from commit b942707fc2)
Co-authored-by: BNMetrics <luna@bnmetrics.com>
* Include memo in the documented signature of copy.deepcopy()
The memo argument is mentioned lower on the doc page under writing a
`__deepcopy__` method, but is not included in the documented function signature.
This makes it easy to miss, and can lead to incorrect/buggy implementations of
`__deepcopy__` -- which is exatly what just happpend to me!
(cherry picked from commit 0200928e8d)
Co-authored-by: Stephan Hoyer <shoyer@gmail.com>
Needs backport to 3.7. In 3.6 the description is correct.
(cherry picked from commit b83d917faf)
Co-authored-by: Andriy Maletsky <andriy.maletsky@gmail.com>
Don't call _Py_FatalError_PrintExc() nor flush_std_files() if the
current thread doesn't hold the GIL, or if the current thread
has no Python state thread.
(cherry picked from commit 3a228ab17c)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
_io.IncrementalNewlineDecoder's initializer possibly assigns out-of-range
value to the bitwise struct field.
(cherry picked from commit b08746bfdf)
Co-authored-by: Xiang Zhang <angwerzx@126.com>
The root widget was accessed as a global variable in the Application's method.
(cherry picked from commit a80af77087)
Co-authored-by: Daniel Lovell <lovell.daniel92@gmail.com>
* Add _Py_GetForceASCII(): check if Python forces the usage of ASCII
in Py_DecodeLocale() and Py_EncodeLocale().
* initfsencoding() now uses ASCII if _Py_GetForceASCII() is true.
After commit d0f49d2f50, the output of the
test suite is always buffered as the test output needs to be included in
the JUnit file in same cases (as when a test fails). This has the
consequence that printing or using debuggers (like pdb) in the test
suite does not result in a good user experience anymore.
This commit modifies the test suite runner so it only captures the test
output when the JUnit file is requested to fix the regression so prints
and debuggers are usable again.
(cherry picked from commit 02277482ea)
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Topics include opening, title and status bar, .py* extension, and running.
(cherry picked from commit ea9c8bd443)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* Fix potential division by zero in BZ2_Malloc()
* Avoid division by zero in PyLzma_Malloc()
* Avoid division by zero and integer overflow in PyZlib_Malloc()
Reported by Svace static analyzer.
(cherry picked from commit 3d4fabb2a4)
Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
Add a paragraph in "Help and preferences", "Help sources" subsection.
(cherry picked from commit 18032632ab)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Fix a bug I introduced in GH-9864 by which coroutines are treated as synonymous of function coroutines.
Also, fix the same mistake (coroutines == function coroutines) already present in other parts of the reference.
I'm very sorry for the hassle.
(cherry picked from commit 95f68b10d5)
Co-authored-by: Andrés Delfino <adelfino@gmail.com>
We now use git and backporting instead of hg and forward merging.
(cherry picked from commit 2b555fc1f0)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
There is only one trivial change to idle.rst. Nearly all the changes to help.html are the elimination of chapter and section numbers on headers due to changes in the build system. help.py no longer requires header numbering.
(cherry picked from commit db40cb50eb)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Declare functions with EXTINLINE:
* mpd_del()
* mpd_uint_zero()
* mpd_qresize()
* mpd_qresize_zero()
* mpd_minalloc()
These functions are implemented with "inline" or "ALWAYS_INLINE", but
declared without inline which cause linker error on Visual Studio in
Debug mode when using /Ob1.
(cherry picked from commit 3b1cba3701)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
Prior to this revision, after the shutdown of a `BaseServer`,
the server accepted a last single request
if it was sent between the server socket polling
and the polling timeout.
This can be problematic for instance for a server restart
for which you do not want to interrupt the service,
by not closing the listening socket during the restart.
One request failed because of this behavior.
Note that only one request failed,
following requests were not accepted, as expected.
(cherry picked from commit 10cb3760e8)
Co-authored-by: Denis Ledoux <be.ledoux.denis@gmail.com>