fix: validate manual release versions before workflow outputs - #1794
fix: validate manual release versions before workflow outputs#1794mldangelo-oai wants to merge 1 commit into
Conversation
|
@codex review |
|
Codex Review: Didn't find any major issues. Another round soon, please! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
There was a problem hiding this comment.
Pull request overview
This PR hardens the release workflow’s manual version inputs by validating root_version and picklescan_version before any GitHub Actions outputs are written, preventing malformed semver and output/shell injection attempts from influencing downstream release steps.
Changes:
- Add strict
X.Y.Zsemver validation (novprefix, prerelease tags, leading zeroes, or metacharacters/newlines) for manualroot_versionandpicklescan_versioninputs in therelease-pleaseworkflow step. - Refactor release-workflow tests to reuse a shared harness for executing the “Resolve manual release inputs” Bash step.
- Add regression tests covering invalid/manual-injection inputs (ensuring no outputs file is created) and valid semver paths (ensuring expected outputs are written).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
tests/test_release_workflow.py |
Adds a shared helper to execute the manual-input resolution step and expands test coverage for invalid/valid manual version inputs. |
.github/workflows/release-please.yml |
Validates manual version inputs via a strict semver regex prior to writing $GITHUB_OUTPUT or proceeding with release logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Security review completed. No security issues were found in this pull request. Reviewed commit: ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1794 +/- ##
==========================================
- Coverage 76.29% 76.29% -0.01%
==========================================
Files 217 217
Lines 115676 115676
Branches 27245 27245
==========================================
- Hits 88258 88256 -2
- Misses 20022 20023 +1
- Partials 7396 7397 +1 🚀 New features to boost your workflow:
|
Summary
Validation