Fix pre-commit workflow path and normalize Windows output paths#288
Open
HKrshan wants to merge 3 commits into
Open
Fix pre-commit workflow path and normalize Windows output paths#288HKrshan wants to merge 3 commits into
HKrshan wants to merge 3 commits into
Conversation
Review Summary by QodoUpdate pre-commit GitHub Actions workflow versions
WalkthroughsDescription• Updated GitHub Actions versions for pre-commit workflow • Upgraded actions/checkout from v3 to v4 • Upgraded actions/setup-python from v3 to v5 • Updated pre-commit/action from v3.0.0 to v3.0.1 • Improved YAML formatting with consistent indentation Diagramflowchart LR
A["Pre-commit Workflow"] --> B["actions/checkout v3"]
A --> C["actions/setup-python v3"]
A --> D["pre-commit/action v3.0.0"]
B --> B1["Updated to v4"]
C --> C1["Updated to v5"]
D --> D1["Updated to v3.0.1"]
File Changes1. .github/pre-commit.yml
|
Code Review by Qodo
1. Workflow not executed
|
Comment on lines
9
to
+16
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - uses: actions/setup-python@v3 | ||
| with: | ||
| python-version: '3.11' | ||
| - uses: pre-commit/action@v3.0.0 | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.11" | ||
|
|
||
| - uses: pre-commit/action@v3.0.1 |
There was a problem hiding this comment.
1. Workflow not executed 🐞 Bug ≡ Correctness
The pre-commit workflow is stored at .github/pre-commit.yml rather than under .github/workflows/, so GitHub Actions will not run it and CI will silently miss pre-commit enforcement on pushes/PRs.
Agent Prompt
## Issue description
The pre-commit GitHub Actions workflow is placed at `.github/pre-commit.yml`, which prevents it from being picked up/executed as a workflow. As a result, the intended pre-commit CI gate will not run.
## Issue Context
This PR’s stated intent is to update the GitHub Actions pre-commit workflow, but the workflow file is not located alongside other workflows.
## Fix Focus Areas
- .github/pre-commit.yml[1-16]
- .github/workflows/test.yml[1-30]
## Suggested fix
- Move/rename `.github/pre-commit.yml` to `.github/workflows/pre-commit.yml`.
- Ensure no other workflow needs updating to reference/call it (if it was intended to be reusable, convert it to a reusable workflow and keep it in `.github/workflows/`).
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools
Owner
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Moved pre-commit workflow file into .github/workflows/pre-commit.yml so GitHub Actions recognizes it. Normalized CSV export paths in src/entry.py to use POSIX separators with Path.as_posix(). Updated snapshot path handling in src/tests/test_all_samples.py by normalizing os.path.relpath(...).replace(os.sep, '/').## Validation- Verified full test suite passes locally with: python -m pytest -q
This PR is ready for review.