diff --git a/README.md b/README.md index ecec1a8a46..d2d37ab1c1 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ English | [简体中文](README_zh-CN.md) ## What's New -v0.10.4 was released on 2024-4-23. +v0.10.5 was released on 2024-9-11. Highlights: diff --git a/README_zh-CN.md b/README_zh-CN.md index 6ce45e0ac5..7a67cdbf76 100644 --- a/README_zh-CN.md +++ b/README_zh-CN.md @@ -59,7 +59,7 @@ ## 最近进展 -最新版本 v0.10.4 在 2024.4.23 发布。 +最新版本 v0.10.5 在 2024.9.11 发布。 版本亮点: diff --git a/docs/en/notes/changelog.md b/docs/en/notes/changelog.md index 8d5413124b..6faefbd68a 100644 --- a/docs/en/notes/changelog.md +++ b/docs/en/notes/changelog.md @@ -1,5 +1,9 @@ # Changelog of v0.x +## v0.10.5 (11/9/2024) + +- Fix `_is_builtin_module`. by [@HAOCHENYE](https://github.com/HAOCHENYE) in https://github.com/open-mmlab/mmengine/pull/1571 + ## v0.10.4 (23/4/2024) ### New Features & Enhancements diff --git a/mmengine/config/utils.py b/mmengine/config/utils.py index 9e9f990885..81b58fb49a 100644 --- a/mmengine/config/utils.py +++ b/mmengine/config/utils.py @@ -12,6 +12,7 @@ from mmengine.utils import check_file_exist PYTHON_ROOT_DIR = osp.dirname(osp.dirname(sys.executable)) +SYSTEM_PYTHON_PREFIX = '/usr/lib/python' MODULE2PACKAGE = { 'mmcls': 'mmcls', @@ -177,7 +178,7 @@ def _is_builtin_module(module_name: str) -> bool: origin_path = osp.abspath(origin_path) if ('site-package' in origin_path or 'dist-package' in origin_path or not origin_path.startswith( - (PYTHON_ROOT_DIR, '/usr/lib/python'))): + (PYTHON_ROOT_DIR, SYSTEM_PYTHON_PREFIX))): return False else: return True diff --git a/mmengine/version.py b/mmengine/version.py index 20624d834f..d9e981bdb3 100644 --- a/mmengine/version.py +++ b/mmengine/version.py @@ -1,6 +1,6 @@ # Copyright (c) OpenMMLab. All rights reserved. -__version__ = '0.10.4' +__version__ = '0.10.5' def parse_version_info(version_str):