-
-
Notifications
You must be signed in to change notification settings - Fork 95
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
isort-pre commit bug #717
Comments
hey @arkid15r I know why is this happening! |
hey @arkid15r could you assign it to me ? |
I didn't verify this bug, you're on your own here :) |
Thanks @arkid15r! I’ll go ahead and remove isort as Ruff handles import sorting already. I’ll update the PR and test it again to make sure everything works smoothly |
Describe the bug
The isort pre-commit hook keeps modifying the same file (schema/tests/project_test.py) in a loop, causing make pre-commit to fail. Even after running git add and committing, isort continues to make changes, preventing a successful commit.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
After running make pre-commit and staging the changes, isort should not modify the file again on commit. The pre-commit hooks should pass without infinite modification loops.
Are you going to work on fixing this?
yes.
Screenshots
https://github.com/user-attachments/assets/c32f4fea-7955-41da-a4df-d0dab835fb24
Desktop (please complete the following information):
Additional context
The issue seems to be caused by a conflict between isort and ruff, as ruff also handles import sorting. Adding --profile=black to isort args in .pre-commit-config.yaml may resolve the issue.
The text was updated successfully, but these errors were encountered: