From 07f1573a99f8394f4ae4d1bbe33f02ca3366b931 Mon Sep 17 00:00:00 2001 From: Tim Stumbaugh Date: Tue, 19 May 2026 16:17:51 -0600 Subject: [PATCH] PEP 810 - Update some language As I was reading #150052, I remembered a comment we got in the initial pass about using the language "deferred" instead of "lazy" in this error. So, fix it up. I looked around for other similar language and found just one more --- Objects/lazyimportobject.c | 2 +- Python/import.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Objects/lazyimportobject.c b/Objects/lazyimportobject.c index 451f335e033f16..fa1eb25047d961 100644 --- a/Objects/lazyimportobject.c +++ b/Objects/lazyimportobject.c @@ -135,7 +135,7 @@ PyDoc_STRVAR(lazy_import_doc, "lazy_import(builtins, name, fromlist=None, /)\n" "--\n" "\n" -"Represents a deferred import that will be resolved on first use.\n" +"Represents a lazy import that will be resolved on first use.\n" "\n" "Instances of this object accessed from the global scope will be\n" "automatically imported based upon their name and then replaced with\n" diff --git a/Python/import.c b/Python/import.c index 60a5ee6e770f59..469f17f0d45209 100644 --- a/Python/import.c +++ b/Python/import.c @@ -4049,7 +4049,7 @@ _PyImport_LoadLazyImportTstate(PyThreadState *tstate, PyObject *lazy_import) // Create a cause exception showing where the lazy import was declared. PyObject *msg = PyUnicode_FromFormat( - "deferred import of '%U' raised an exception during resolution", + "lazy import of '%U' raised an exception during resolution", import_name ); Py_DECREF(import_name); // Done with import_name.