-
-
Notifications
You must be signed in to change notification settings - Fork 626
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
pants fmt
, isort
does not follow PEP8
#20386
Comments
Have you tried configuring isort to following the formatting you want? |
Configuring with [tool.isort]
profile = "black"
line_length = 125
known_first_party = ["lib"] Apart from that, the peculiar thing is that the other first party imports locate the proper positions. (without configuring option of For instance, if a project hierarcy like as follows, .
├── project_A
├── project_B
└── lib
import os
import time
from fastapi import FastAPI, Request
from lib.logging import set_logger_from_config << 1st party
from project_A.foo.bar << 1st party
from project_B.bar.foo << 1st party It means that There could be some differences between IDE and pants settings.. but I'm not sure.. |
Yeah, the current workaround is to manually set |
@eunseo0u0 I will close this assuming that workaround works for you. Feel free to reopen if not. |
Describe the bug
When running the
pants fmt
command, the formatting results of isort do not adhere to PEP8 standards.With IDE isort extensions, from VScode and PyCharm, are working well that I expected.
How to solve this problem?
Pants version
OS
Additional info
5.12.0
When formatting..
pants fmt
)The text was updated successfully, but these errors were encountered: