Skip to content

Commit

Permalink
[Fix] Fix is builtin_module
Browse files Browse the repository at this point in the history
  • Loading branch information
HAOCHENYE committed Oct 25, 2024
1 parent c9b5996 commit 3d808c1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mmengine/config/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,8 @@ def _is_builtin_module(module_name: str) -> bool:
return True
if module_name in sys.builtin_module_names:
return True
if sys.version_info >= (3, 10) and module_name in sys.stdlib_module_names():
return True
spec = find_spec(module_name.split('.')[0])
# Module not found
if spec is None:
Expand Down

0 comments on commit 3d808c1

Please sign in to comment.