Skip to content

Conversation

@geruh
Copy link
Contributor

@geruh geruh commented Jan 26, 2026

Rationale for this change

While working on the ty integration, I've been auditing the pre-commit hooks. This PR removes the flynt pre-commit hook since it;s redundant with ruff's UP031 and UP032 rules which are already enabled via the UP selector in our ruff.toml.

flynt converts .format() and % style string formatting to f-strings. Ruff's pyupgrade rules do the same:

and both produce identical results

Are these changes tested?

make lint

Manual tests:

Code: "Hello, {}".format(name)

  • flynt: f"Hello, {name}"
  • ruff: f"Hello, {name}"

Are there any user-facing changes?

No

Copy link
Contributor

@kevinjqliu kevinjqliu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

flynt was added here
4616d03

@kevinjqliu kevinjqliu merged commit 4769d07 into apache:main Jan 26, 2026
11 checks passed
kevinjqliu pushed a commit that referenced this pull request Jan 26, 2026
# Rationale for this change

Like #2953, doing a dive into the linted dependencies we can replace the
`debug-statements` pre-commit hook with ruff's [`T100` rule
flake8-debugger](https://docs.astral.sh/ruff/rules/debugger/).

This will lighten the linters needed when working on cb. 

T100 catches more modern debuggers (`debugpy`, `ptvsd`,
`IPython.embed`). It seems like there are rare debuggers it misses but
aren't used like `bpdb`.

## Are these changes tested?

`make lint`

```
> ruff check --select T100 pyiceberg/ tests/
All checks passed!
```

## Are there any user-facing changes?
No
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants