Skip to content

PIE800 fix introduces a syntax error for {**{},} #15997

@dscorbett

Description

@dscorbett

Description

The fix for unnecessary-spread (PIE800) in Ruff 0.9.4 introduces a syntax error when unpacking an empty dictionary that appears before a comma.

$ echo '{**{},}' | ruff --isolated check --select PIE800 - --diff

error: Fix introduced a syntax error. Reverting all changes.

This indicates a bug in Ruff. If you could open an issue at:

    https://github.com/astral-sh/ruff/issues/new?title=%5BFix%20error%5D

...quoting the contents of `-`, the rule codes PIE800, along with the `pyproject.toml` settings and executed command, we'd be very appreciative!

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfixesRelated to suggested fixes for violations

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions