Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

_imports.determine_path_of does not adhere to precedence in sys.path. #21

Open
r4f opened this issue Jun 5, 2024 · 0 comments
Open

Comments

@r4f
Copy link

r4f commented Jun 5, 2024

Since the existence of the complete module path is checked in https://github.com/hartwork/no-cyclic-imports/blob/cf8d23771f055f430265f4354d8e05b0087e9b08/no_cyclic_imports/_imports.py#L58C1-L63C41
if two top level modules of the same name exist in the sys.path, but only in the one with less precedence, the sub-module is found, the path of that one is returned from determine_path_of, although because of import order it will never be imported.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant