Skip to content

CI: Replace flake8-no-print with flake8-debug and pin repos to hashes#24572

Open
jpodivin wants to merge 2 commits into
ggml-org:masterfrom
jpodivin:freeze
Open

CI: Replace flake8-no-print with flake8-debug and pin repos to hashes#24572
jpodivin wants to merge 2 commits into
ggml-org:masterfrom
jpodivin:freeze

Conversation

@jpodivin

Copy link
Copy Markdown
Contributor

Overview

The flake8-no-print[1] package has been superseded by flake8-debug[2] from the same developer.
In fact, flake8-debug is reusing the original flake8-no-print repository.

In addition to flagging print calls, the flake8-debug also flags set_trace and breakpoints.

I've also frozen the hooks repos,[3] pinning them to hashes, rather than repository tags. This is a proactive measure against possible supply chain compromises. Unlike tags, hashes can not be assigned different repository states after they are created. This protects us against attacker taking over repository of, for example base pre-commit hooks, deleting original tags and making new ones, all pointing to a compromised hook that steals secrets.

I've deliberately decide not to apply pre-commit on all files in the repo, as that would inflate the PR size substantially. IMHO, it's better to introduce this gradually.

Additional information

[1] https://pypi.org/project/flake8-no-print/
[2] https://github.com/vyahello/flake8-debug
[3] https://pre-commit.com/index.html#pre-commit-autoupdate

Requirements

jpodivin added 2 commits June 13, 2026 13:00
Signed-off-by: Jiri Podivin <jpodivin@redhat.com>
Signed-off-by: Jiri Podivin <jpodivin@redhat.com>
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.

1 participant