Open thejcannon opened 1 year ago
:wave:
I come from pantsbuild land! I'm looking at trying to help world-model in this issue
One attempt was to specify each "known" module that we're going to supply (with -p=...) but ran into an interesting corner case.
-p=...
Given
import requests from subdirA import fileA
Running isort -p=subdir.fileA file.py (where subdir.fileA isn't in the sandbox we're running isort in) puts both imports together. Whereas:
isort -p=subdir.fileA file.py
subdir.fileA
isort
import requests import subdirA.fileA
doesn't.
I guess it's a flavor of ambiguity whether fileA is assumed to be a non-module object in subdirA, or whether we can also be OK with maybe thinking fileA could also be a module.
fileA
subdirA
:wave:
I come from pantsbuild land! I'm looking at trying to help world-model in this issue
One attempt was to specify each "known" module that we're going to supply (with
-p=...
) but ran into an interesting corner case.Given
Running
isort -p=subdir.fileA file.py
(wheresubdir.fileA
isn't in the sandbox we're runningisort
in) puts both imports together. Whereas:doesn't.