| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
The importlib module now ignores the PYTHONCASEOK
environment variable when the -E or -I command line
options are being used.
|
|
|
|
| |
Move required blanking of error text to non-overridden entry_ok().
(Omit news item.)
|
| |
|
| |
|
|
|
|
|
| |
Since clicking to get an IDLE context menu moves the cursor,
any text selection should be and now is cleared.
|
|
|
|
|
|
| |
It appears standard that moving the text insert cursor away from a selection clears the
selection. Clearing prevents accidental deletion of a possibly off-screen bit of text.
The update is for Ln and Col on the status bar.
|
|
|
|
| |
Fix typo in cmdline.rst
Add space between the `-m` option and the module name (`timeit`).
|
| |
|
|
|
|
| |
(GH-18499)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* exit_thread_if_finalizing() does now access directly _PyRuntime
variable, rather than using tstate->interp->runtime since tstate
can be a dangling pointer after Py_Finalize() has been called.
* exit_thread_if_finalizing() is now called *before* calling
take_gil(). _PyRuntime.finalizing is an atomic variable,
we don't need to hold the GIL to access it.
* Add ensure_tstate_not_null() function to check that tstate is not
NULL at runtime. Check tstate earlier. take_gil() does not longer
check if tstate is NULL.
Cleanup:
* PyEval_RestoreThread() no longer saves/restores errno: it's already
done inside take_gil().
* PyEval_AcquireLock(), PyEval_AcquireThread(),
PyEval_RestoreThread() and _PyEval_EvalFrameDefault() now check if
tstate is valid with the new is_tstate_valid() function which uses
_PyMem_IsPtrFreed().
|
| |
|
|
|
| |
We make `|=` raise TypeError, since it would be surprising if `C.__dict__ |= {'x': 0}` silently did nothing, while `C.__dict__.update({'x': 0})` is an error.
|
| |
|
|
|
| |
Co-Authored-By: Serhiy Storchaka <storchaka@gmail.com>
|
|
|
|
|
| |
insufficient permissions (GH-18815)
Co-authored-by: Matt Wozniski <mwozniski@bloomberg.net>
|
| |
|
|
|
|
|
| |
calc_number_widths -> PyObject *number
fill_number -> Py_ssize_t d_end
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Py_FatalError() function is replaced with a macro which logs
automatically the name of the current function, unless the
Py_LIMITED_API macro is defined.
Changes:
* Add _Py_FatalErrorFunc() function.
* Remove the function name from the message of Py_FatalError() calls
which included the function name.
* Update tests.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Convert _PyRuntimeState.finalizing field to an atomic variable:
* Rename it to _finalizing
* Change its type to _Py_atomic_address
* Add _PyRuntimeState_GetFinalizing() and _PyRuntimeState_SetFinalizing()
functions
* Remove _Py_CURRENTLY_FINALIZING() function: replace it with testing
directly _PyRuntimeState_GetFinalizing() value
Convert _PyRuntimeState_GetThreadState() to static inline function.
|
|
|
| |
Co-authored-by: Victor Stinner <vstinner@python.org>
|
| |
|
|
|
|
| |
Remove redundant check on Py_TYPE() value: it's already checked
inside _PyType_CheckConsistency().
|
|
|
| |
For PEP 585 (this isn't in the PEP but is an obvious follow-up).
|
|
|
|
| |
symtable_visit_annotations. (GH-18800)
|
|
|
|
|
|
| |
Avoid duplicated code:
* PyObject_Init() uses PyObject_INIT()
* PyObject_InitVar() uses PyObject_INIT_VAR()
|
| |
|
|
|
| |
Add _PyObject_CAST_CONST() macro: cast a pointer to (const PyObject *).
|
| |
|
|
|
|
|
| |
set_herror builds a string by calling hstrerror but downcasts its return value to char *. It should be const char *.
Automerge-Triggered-By: @benjaminp
|
|
|
| |
Also move int err to its innermost scope.
|
|
|
|
|
|
| |
Eliminate repeat of 'Options', reported by Jules Lasne, and improve wording elsewhere.
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
| |
subprocess _posix_spawn() should stay in sync with _Py_RestoreSignals().
|
|
|
|
|
| |
test_subprocess.test_user() now skips the test on an user name if the
user name doesn't exist. For example, skip the test if the user
"nobody" doesn't exist on Linux.
|
|
|
|
|
|
|
|
| |
(GH-18786)
`list(sys.modules.items())` was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky.
|
|
|
|
| |
(GH-18784)
|
| |
|
|
|
|
|
|
|
| |
(GH-16959)" (GH-18767)
This reverts commit e471e72977c83664f13d041c78549140c86c92de.
The mode will be removed from Python 3.10.
|
|
|
|
|
| |
Split long build_extensions() method into sub-methods.
Fix also a typo in Popen.wait(): replace sts with status.
|
|
|
|
|
|
|
|
| |
The AST "Suite" node is no longer used and it can be removed from the ASDL definition and related structures (compiler, visitors, ...).
Co-Authored-By: Victor Stinner <vstinner@python.org>
Co-authored-by: Brett Cannon <54418+brettcannon@users.noreply.github.com>
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Reimplement distutils.spawn.spawn() function with the subprocess
module.
setup.py now uses a basic implementation of the subprocess module if
the subprocess module is not available: before required C extension
modules are built.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Add a section in What's New In Python 3.9 to strongly advice to check
for DeprecationWarning in your Python projects.
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
|
|
|
|
| |
deprecation warning (GH-13195)
|
| |
|