From b553efbd8307ec728b4f50357735184228488e95 Mon Sep 17 00:00:00 2001 From: AnchialC Date: Tue, 22 Jul 2025 23:50:27 +0800 Subject: [PATCH] Strengthen warning against using 'import *' in tutorial --- Doc/tutorial/modules.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Doc/tutorial/modules.rst b/Doc/tutorial/modules.rst index f8105cd5441fec..472cd1de4406ac 100644 --- a/Doc/tutorial/modules.rst +++ b/Doc/tutorial/modules.rst @@ -112,8 +112,8 @@ an unknown set of names into the interpreter, possibly hiding some things you have already defined. Note that in general the practice of importing ``*`` from a module or package is -frowned upon, since it often causes poorly readable code. However, it is okay to -use it to save typing in interactive sessions. +frowned upon, since it often causes poorly readable code. However, it's acceptable +only in interactive sessions for exploration; avoid in production code. If the module name is followed by :keyword:`!as`, then the name following :keyword:`!as` is bound directly to the imported module.