diff options
| author | Eric Snow <ericsnowcurrently@gmail.com> | 2024-04-03 16:58:39 (GMT) |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-03 16:58:39 (GMT) |
| commit | 976bcb2379709da57073a9e07b518ff51daa617a (patch) | |
| tree | 66fca9084cbae6c0b503491f627829d703df19bc /Python/pystate.c | |
| parent | 7ecd55d604a8fa287c1d131cac14d10260be826b (diff) | |
| download | cpython-976bcb2379709da57073a9e07b518ff51daa617a.zip cpython-976bcb2379709da57073a9e07b518ff51daa617a.tar.gz cpython-976bcb2379709da57073a9e07b518ff51daa617a.tar.bz2 | |
gh-76785: Raise InterpreterError, Not RuntimeError (gh-117489)
I had meant to switch everything to InterpreterError when I added it a while back. At the time I missed a few key spots.
As part of this, I've added print-the-exception to _PyXI_InitTypes() and fixed an error case in `_PyStaticType_InitBuiltin().
Diffstat (limited to 'Python/pystate.c')
| -rw-r--r-- | Python/pystate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/pystate.c b/Python/pystate.c index 925d1cf..892e740 100644 --- a/Python/pystate.c +++ b/Python/pystate.c @@ -1073,7 +1073,7 @@ int _PyInterpreterState_FailIfRunningMain(PyInterpreterState *interp) { if (interp->threads.main != NULL) { - PyErr_SetString(PyExc_RuntimeError, + PyErr_SetString(PyExc_InterpreterError, "interpreter already running"); return -1; } |
