Skip to content

Commit 4593843

Browse files
zsquarepluscdpgeorge
authored andcommitted
extmod/asyncio: Pass globals in __import__ call.
`globals()` needs to be provided in case `__import__` is a Python function.
1 parent 48d96b4 commit 4593843

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

extmod/asyncio/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ def __getattr__(attr):
2626
mod = _attrs.get(attr, None)
2727
if mod is None:
2828
raise AttributeError(attr)
29-
value = getattr(__import__(mod, None, None, True, 1), attr)
29+
value = getattr(__import__(mod, globals(), None, True, 1), attr)
3030
globals()[attr] = value
3131
return value

0 commit comments

Comments
 (0)