-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
bugSomething isn't workingSomething isn't workingfixesRelated to suggested fixes for violationsRelated to suggested fixes for violations
Description
In ruff 99a755f, the following snippet causes the autofix RUF005 to introduce a syntax error:
f"{a() + ['b']}"$ ./ruff --no-cache --select RUF005 --fix code.py
error: Autofix introduced a syntax error. Reverting all changes.
This indicates a bug in `ruff`. If you could open an issue at:
https://github.com/charliermarsh/ruff/issues/new?title=%5BAutofix%20error%5D
...quoting the contents of `code.py`, the rule codes RUF005, along with the `pyproject.toml` settings and executed command, we'd be very appreciative!
code.py:1:4: RUF005 Consider `[*a(), "b"]` instead of concatenation
Found 1 error.
This was originally discovered in https://github.com/Mojino01/hugging_face/blob/3dae0d7b4fb8d7e9383b893e4e1799191bb2ab7b/src/transformers/pipelines/base.py#L1181
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingfixesRelated to suggested fixes for violationsRelated to suggested fixes for violations