Skip to content

Commit 359774f

Browse files
authored
Update __init__.py
1 parent de9cf4d commit 359774f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lazy_loader/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,10 @@ def myfunc():
193193
if have_module and require is None:
194194
return module
195195

196-
if "." in fullname:
196+
if not suppress_warning and "." in fullname:
197197
msg = (
198198
"subpackages can technically be lazily loaded, but it causes the "
199-
"package to be eagerly loaded even if it is already lazily loaded."
199+
"package to be eagerly loaded even if it is already lazily loaded. "
200200
"So, you probably shouldn't use subpackages with this lazy feature."
201201
)
202202
warnings.warn(msg, RuntimeWarning)

0 commit comments

Comments
 (0)