Repository navigation
Fix check-required-ci silently accepting malformed --run-* flags - #498
Open
Akhil Gupta (akhil9tiet) wants to merge 10 commits into
Open
Akhil Gupta (akhil9tiet) wants to merge 10 commits into
Akhil Gupta (akhil9tiet) wants to merge 10 commits into
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Both changed files require Ruff formatting before the mandatory quality gate can pass.
2 open findings
What changed in this PR
Strictly validates required-CI scheduling flags to prevent malformed values from being treated as false.
Changes:
- Restricts all four
--run-*flags tofalseortrue. - Adds parser regression coverage for valid and malformed values.
| File | Description |
|---|---|
scripts/nvx.py |
Adds strict argparse choices. |
scripts/test_nvx_tools.py |
Tests flag validation. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.

Fixes #496
command_check_required_cicompared each--run-*flag with== "true", so any malformed value (empty string, "tru", "TRUE", "1", "yes") was silently treated as false — letting required-status checking pass with required jobs skipped. The flags now declarechoices=("false", "true")so argparse rejects malformed values with a clear error. Also adds a unit test covering malformed and valid values for all four flags.