mirror of
https://github.com/ets-labs/python-dependency-injector.git
synced 2024-11-29 21:14:00 +03:00
Fix pypy3 tests
This commit is contained in:
parent
47f8c6ebe8
commit
35a6f47aff
|
@ -1,5 +1,6 @@
|
||||||
"""Schema module."""
|
"""Schema module."""
|
||||||
|
|
||||||
|
import builtins
|
||||||
import importlib
|
import importlib
|
||||||
from typing import Dict, Any, Type, Optional
|
from typing import Dict, Any, Type, Optional
|
||||||
|
|
||||||
|
@ -204,7 +205,7 @@ def _import_string(string_name: str) -> Optional[object]:
|
||||||
segments = string_name.split('.')
|
segments = string_name.split('.')
|
||||||
|
|
||||||
if len(segments) == 1:
|
if len(segments) == 1:
|
||||||
member = __builtins__.get(segments[0])
|
member = getattr(builtins, segments[0], None)
|
||||||
if member:
|
if member:
|
||||||
return member
|
return member
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user