-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Rule RUF017 cause panic #7718
Comments
@charliermarsh can you check again if this is really fixed? |
Ah, I think I fixed a different issue here having not looked at the trace closely. Thanks! |
(This requires that the statement is at the start of the file.) |
charliermarsh
added a commit
that referenced
this issue
Oct 1, 2023
## Summary If we have, e.g.: ```python sum(( factor.dims for factor in bases ), []) ``` We generate three edits: two insertions (for the `operator` and `functools` imports), and then one replacement (for the `sum` call itself). We need to ensure that the insertions come before the replacement; otherwise, the edits will appear overlapping and out-of-order. Closes #7718.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ruff 0.0.291 (latest changes from main branch)
file content:
error
python_compressed.zip
The text was updated successfully, but these errors were encountered: