mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-10-30 17:52:26 +01:00
test: avoid tuple-list allocation in the import-stub guard
This commit is contained in:
@@ -189,7 +189,7 @@ def bare_module_stubs():
|
||||
test modules install them on purpose.
|
||||
"""
|
||||
found = set()
|
||||
for name, mod in list(sys.modules.items()):
|
||||
for name, mod in sys.modules.copy().items():
|
||||
if not name.startswith(_GUARDED_PREFIXES):
|
||||
continue
|
||||
if type(mod) is not types.ModuleType:
|
||||
|
||||
Reference in New Issue
Block a user