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

module incorrectly indentified as STDLIB instead of FIRSTPARTY #2383

Open
Flamefire opened this issue Mar 6, 2025 · 0 comments
Open

module incorrectly indentified as STDLIB instead of FIRSTPARTY #2383

Flamefire opened this issue Mar 6, 2025 · 0 comments

Comments

@Flamefire
Copy link

This might be another effect of #1704 but it seems different enough to have an own issue.
In short: We import a module from the same package using an absolute import but it gets classified as STDLIB

Basically we have a repo with 2 modules: The main module and a test module:

- easybuild
  - __ini__t.py
  - base
    - __ini__t.py
    - fanclogger.py
- test
  - __ini__t.py
  - easyblocks
    - __ini__t.py
    - specific.py
    - foo.py

Now the file foo.py imports files from the main module and another test:

import easybuild.base.fancylogger

import test.easyblocks.specific

isort somehow determines that the specific.py import is STDLIB which seems wildly off. I'd have understood it being classified as FIRSTPARTY or THIRDPARTY but STDLIB?

Output of isort -v:

                    VERSION 6.0.1

from-type place_module for easybuild.base returned THIRDPARTY
else-type place_module for test.easyblocks.easyblock_specific returned STDLIB

Can there anything be done that test.easyblocks.foo does not consider test.easyblocks.specific as STDLIB?

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