Skip to content

Comments

feat(ci): only run precommit on changed files#38155

Open
hainenber wants to merge 3 commits intomasterfrom
feat/only-run-precommit-on-changed-files-in-pr
Open

feat(ci): only run precommit on changed files#38155
hainenber wants to merge 3 commits intomasterfrom
feat/only-run-precommit-on-changed-files-in-pr

Conversation

@hainenber
Copy link
Contributor

@hainenber hainenber commented Feb 21, 2026

feat(ci): only run precommit on change files

SUMMARY

Only run precommit Git hooks for changed files in a PR.
Additionally, It doesn't make sense for PR's author to fix for issues in files they didn't modify. Plus we'll save off CI resources by not running pre-commit excessively so.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

N/A

TESTING INSTRUCTIONS

Green CI as acceptance of threshold.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

Signed-off-by: hainenber <dotronghai96@gmail.com>
@dosubot
Copy link

dosubot bot commented Feb 21, 2026

Related Documentation

Checked 0 published document(s) in 2 knowledge base(s). No updates required.

How did I do? Any feedback?  Join Discord

@bito-code-review
Copy link
Contributor

bito-code-review bot commented Feb 21, 2026

Bito Automatic Review Skipped - Files Excluded

Bito didn't auto-review this change because all changed files are in the exclusion list for automatic reviews. No action is needed if you didn't intend for the agent to review it. Otherwise, to manually trigger a review, type /review in a comment and save.
You can change the excluded files settings here, or contact your Bito workspace admin at evan@preset.io.

@github-actions github-actions bot added the github_actions Pull requests that update GitHub Actions code label Feb 21, 2026
@codeant-ai-for-open-source
Copy link
Contributor

Sequence Diagram

The workflow change runs pre-commit hooks only against files changed in the PR by calling a local FilesChangeAction, then invokes pre-commit with that file list and fails the job if hooks modify files or report issues. This reduces unnecessary checks on unrelated files.

sequenceDiagram
    participant GitHub as GitHub Actions
    participant Repo as Repository (checkout)
    participant FilesAction as FilesChangeAction
    participant PreCommit as pre-commit
    participant Git as Git

    GitHub->>Repo: Checkout & setup environment
    GitHub->>FilesAction: Run action to list changed files
    FilesAction-->>GitHub: outputs.files (changed file list)
    GitHub->>PreCommit: Run pre-commit --files <changed files>
    PreCommit->>Git: Modify or report issues (if any)
    Git-->>GitHub: git diff status
    GitHub->>GitHub: Fail job if pre-commit failed or repo dirty
Loading

Generated by CodeAnt AI

@hainenber hainenber changed the title feat(ci): only run precommit on change files feat(ci): only run precommit on changed files Feb 22, 2026
Signed-off-by: hainenber <dotronghai96@gmail.com>
Signed-off-by: hainenber <dotronghai96@gmail.com>
@bito-code-review
Copy link
Contributor

bito-code-review bot commented Feb 22, 2026

Code Review Agent Run #582ddb

Actionable Suggestions - 0
Review Details
  • Files reviewed - 2 · Commit Range: 91ca9e5..9eaa19c
    • superset-frontend/src/dashboard/components/nativeFilters/FiltersConfigModal/FilterTitleContainer.tsx
    • superset-frontend/src/dashboard/components/nativeFilters/FiltersConfigModal/ItemTitleContainer.tsx
  • Files skipped - 2
    • .github/workflows/pre-commit.yml - Reason: Filter setting
    • superset-frontend/oxlint.json - Reason: Filter setting
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.

Documentation & Help

AI Code Review powered by Bito Logo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update GitHub Actions code size/S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant