| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
(GH-112770) (GH-113105)
It was raised in two cases:
* in the import statement when looking up __import__
* in pickling some builtin type when looking up built-ins iter, getattr, etc.
(cherry picked from commit 1161c14e8c68296fc465cd48970b32be9bee012e)
|
|
|
|
|
|
|
| |
inside bytearray.join (GH-112626) (GH-112694)
(cherry picked from commit 0e732d0997cff08855d98c17af4dd5527f10e419)
Co-authored-by: chilaxan <chilaxan@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
gh-110393: Remove watchdog with hardcoded timeout (GH-110400)
test_builtin and test_socketserver no longer use signal.alarm() to
implement a watchdog with a hardcoded timeout (2 and 60 seconds).
Python test runner regrtest has two watchdogs: faulthandler and
timeout on running worker processes. Tests using short hardcoded
timeout can fail on slowest buildbots just because the timeout is too
short.
(cherry picked from commit 1328fa31fe9c72748fc6fd11d017c82aafd48a49)
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
|
|
|
|
| |
(GH-108421) (GH-108799)
Only mark tests which spend significant system or user time,
by itself or in subprocesses.
(cherry picked from commit f3ba0a74cd50274acdcd592d4ce8395b92492b7c)
|
| |
|
|
|
|
|
|
| |
Add thrashcan macros to the deallocator of the filter objects to protect against deeply nested destruction of chains of nested filters.
(cherry picked from commit 66aa78cbe604a7c5731f074b869f92174a8e3b64)
Co-authored-by: Marta Gómez Macías <mgmacias@google.com>
|
|
|
|
|
| |
(cherry picked from commit c32bc1bffd9d63ede0d0505abab983247a3ad0c6)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
|
|
|
|
| |
(GH-99091)
|
|
|
|
|
|
|
| |
(cherry picked from commit 3adb4d864bb18a51334c922a732e5e3602799ba1)
Co-authored-by: Michael Droettboom <mdboom@gmail.com>
Co-authored-by: Michael Droettboom <mdboom@gmail.com>
|
|
|
|
|
| |
(cherry picked from commit d81d57e9598dea741e049f3876ccd87072a38906)
Co-authored-by: Christian Heimes <christian@python.org>
|
|
|
| |
Add a closure keyword-only parameter to exec(). It can only be specified when exec-ing a code object that uses free variables. When specified, it must be a tuple, with exactly the number of cell variables referenced by the code object. closure has a default value of None, and it must be None if the code object doesn't refer to any free variables.
|
|
|
| |
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
| |
Co-authored-by: Brett Cannon <brett@python.org>
|
|
|
|
|
|
| |
Use common error message for non-string attribute name in the builtin
functions getattr and hasattr.
The special check no longer needed since Python 3.0.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Skip test_builtin PTY tests on non-ASCII characters if the readline
module is loaded. The readline module changes input() behavior, but
test_builtin is not intented to test the readline module.
When the readline module is loaded, PyOS_Readline() uses the readline
implementation. In some cases, the Python readline callback
rlhandler() is called by readline with a string without non-ASCII
characters.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* test__xxsubinterpreters
* test_builtin
* test_doctest
* test_exceptions
* test_opcodes
* test_support
* test_argparse
* test_baseexception
* test_bdb
* test_bool
* test_asdl_parser
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Several built-in and standard library types now ensure that their internal result tuples are always tracked by the garbage collector:
- collections.OrderedDict.items
- dict.items
- enumerate
- functools.reduce
- itertools.combinations
- itertools.combinations_with_replacement
- itertools.permutations
- itertools.product
- itertools.zip_longest
- zip
Previously, they could have become untracked by a prior garbage collection.
|
| |
|
|
|
|
| |
(GH-21363)
|
|
|
|
|
| |
3.8.3 had a regression where compiling with
ast.PyCF_ALLOW_TOP_LEVEL_AWAIT woudl agressively mark things are
coroutine even if there were not.
|
|
|
|
|
|
|
|
| |
zip() now supports PEP 618's strict parameter, which raises a
ValueError if the arguments are exhausted at different lengths.
Patch by Brandt Bucher.
Co-authored-by: Brandt Bucher <brandtbucher@gmail.com>
Co-authored-by: Ram Rachum <ram@rachum.com>
|
|
|
|
|
|
|
|
| |
test_builtin.PtyTests now registers an handler for SIGHUP signal.
Closing the PTY file descriptor can emit a SIGHUP signal: just ignore
it.
run_child() now also closes the PTY file descriptor before waiting
for the process completition, otherwise the test hangs on AIX.
|
|
|
|
| |
bpo-31160, bpo-40094: Wait until the process completes before closing
the PTY to prevent sending SIGHUP to the child process.
|
|
|
|
|
|
|
|
|
| |
Moreover, the following tests now check the child process exit code:
* test_os.PtyTests
* test_mailbox.test_lock_conflict()
* test_tempfile.test_process_awareness()
* test_uuid.testIssue8621()
* multiprocessing resource tracker tests
|
|
|
|
|
| |
(GH-18968)
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
|
|
|
|
| |
functions when PyCF_ALLOW_TOP_LEVEL_AWAIT is set (GH-19010)
|
|
|
|
| |
deprecation warning (GH-13195)
|
|
|
|
| |
Correct the error message when calling the min() or max() with
no arguments.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
passable (GH-16302)
Edit: `math.pow` changes removed on Mark's request.
https://bugs.python.org/issue38237
Automerge-Triggered-By: @rhettinger
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Relative imports use resolve_name to get the absolute target name,
which first seeks the current module's absolute package name from the globals:
If __package__ (and __spec__.parent) are missing then
import uses __name__, truncating the last segment if
the module is a submodule rather than a package __init__.py
(which it guesses from whether __path__ is defined).
The __name__ attempt should fail if there is no parent package (top level modules),
if __name__ is '__main__' (-m entry points), or both (scripts).
That is, if both __name__ has no subcomponents and the module does not seem
to be a package __init__ module then import should fail.
|
|
|
|
|
|
|
|
| |
* Optimize sum() for bools.
* Fix sum([], False).
* Add a NEWS entry.
|
|
|
|
|
|
| |
* Use the 'p' format unit instead of manually called PyObject_IsTrue().
* Pass boolean value instead 0/1 integers to functions that needs boolean.
* Convert some arguments to boolean only once.
|
| |
|
| |
|
| |
|
|
|
| |
See also PR GH-13148.
|
|
|
| |
Co-Authored-By: Yury Selivanov <yury@magic.io>
|
|
|
|
|
| |
Handle the case of an empty module name in PYTHONBREAKPOINT.
Fixes a regression introduced in bpo-34756.
|
|
|
|
|
|
|
|
|
|
| |
(GH-10284)
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.
|
|
|
|
|
|
|
| |
When dict subclass overrides order (`__iter__()`, `keys()`, and `items()`), `dict(o)`
should use it instead of dict ordering.
https://bugs.python.org/issue34320
|
|
|
|
| |
argument. (GH-9208)
|
|
|
| |
Improve consistency with the signature for sorted(), heapq.nsmallest(), heapq.nlargest(), and itertools.groupby().
|
|
|
| |
This fixes also bpo-22091.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add -X utf8 command line option, PYTHONUTF8 environment variable
and a new sys.flags.utf8_mode flag.
* If the LC_CTYPE locale is "C" at startup: enable automatically the
UTF-8 mode.
* Add _winapi.GetACP(). encodings._alias_mbcs() now calls
_winapi.GetACP() to get the ANSI code page
* locale.getpreferredencoding() now returns 'UTF-8' in the UTF-8
mode. As a side effect, open() now uses the UTF-8 encoding by
default in this mode.
* Py_DecodeLocale() and Py_EncodeLocale() now use the UTF-8 encoding
in the UTF-8 Mode.
* Update subprocess._args_from_interpreter_flags() to handle -X utf8
* Skip some tests relying on the current locale if the UTF-8 mode is
enabled.
* Add test_utf8mode.py.
* _Py_DecodeUTF8_surrogateescape() gets a new optional parameter to
return also the length (number of wide characters).
* pymain_get_global_config() and pymain_set_global_config() now
always copy flag values, rather than only copying if the new value
is greater than the old value.
|
|
|
| |
Implement PEP 553, built-in breakpoint() with support from sys.breakpointhook(), along with documentation and tests. Closes bpo-31353
|