From 7229a54e97a68f06e67b1b5532f6a4865a9f86b8 Mon Sep 17 00:00:00 2001 From: jsconan Date: Tue, 5 Sep 2023 22:37:40 +0200 Subject: [PATCH 1/4] fix: wrong use of the module path --- toolbox/files/path.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/toolbox/files/path.py b/toolbox/files/path.py index 3148204..99e7014 100644 --- a/toolbox/files/path.py +++ b/toolbox/files/path.py @@ -32,10 +32,7 @@ def get_module_folder_path(name: str) -> PurePath(): Returns: PurePath: The path to the folder containing the given module. """ - if name in sys.modules: - return PurePath(sys.modules[name].__path__) - - return PurePath() + return get_module_path(name).parent def get_application_path(name: str) -> PurePath: From eadd105972f11cde835b6cdae1532d248d95c512 Mon Sep 17 00:00:00 2001 From: jsconan Date: Tue, 5 Sep 2023 22:39:12 +0200 Subject: [PATCH 2/4] chore: update the changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index bf61baf..92049ce 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Fixed + +- Wrong use of the module path + ## [0.1.1] - 2023-09-05 ### Changed From 39af4f679a6025bbc787e082ab282d49325547d2 Mon Sep 17 00:00:00 2001 From: jsconan Date: Tue, 5 Sep 2023 22:41:44 +0200 Subject: [PATCH 3/4] chore: bump version --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a02b830..840b421 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "py-toolbox" -version = "0.1.1" +version = "0.1.2" authors = [{ name = "Jean-Sébastien CONAN", email = "jsconan@gmail.com" }] description = "A set of utilities for Python projects" readme = "README.md" From a919dfa004cda69820508c197e15b79543d8b18b Mon Sep 17 00:00:00 2001 From: jsconan Date: Tue, 5 Sep 2023 22:42:02 +0200 Subject: [PATCH 4/4] chore: update the changelog --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 92049ce..da1671a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [0.1.2] - 2023-09-05 + ### Fixed - Wrong use of the module path