Repository navigation
fix(local): require ripgrep for the forbidden-content scans - #1103
Draft
Walternater wants to merge 1 commit into
Draft
Walternater wants to merge 1 commit into
Walternater wants to merge 1 commit into
Conversation
The validate and release-local workflows never installed ripgrep, and validate.sh reads a missing rg (exit 127) as "no match" inside if-rg, so every forbidden-content scan skipped silently while the job printed "Validation passed." (issue Tencent#1044). - validate.sh now fails loudly when rg is not on PATH. - Both workflows install ripgrep before running validate.sh. Merge after Tencent#909: apt ships rg 15.1.0 on resolute (ubuntu-latest) and 14.1.0 on noble; with rg present, 15.x glob handling self-matches scripts/validate.sh in scan 1 (the known bug Tencent#909 fixes, noble unaffected). Until Tencent#909 merges, validate (3.12) shows that known failure on this branch. Co-Authored-By: Claude Code <noreply@anthropic.com>
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.
What changed
The
validateandrelease-localworkflows never installed ripgrep, andlocal/scripts/validate.shreads a missingrg(exit 127) as "no match" insideif rg .... All three forbidden-content scans skipped silently while the job printedValidation passed.— the CI run quoted in #1044 showsrg: command not foundthree times followed by success.Closes #1044:
validate.shnow fails loudly (exit 1) whenrgis not on PATH, instead of silently skipping the scans.validatejob installs ripgrep;release-localgets it inside the existing "Install validation dependencies" step (that job calls the same script, so without the install the new loud failure would break releases).Scope
validate.yml→scripts/validate.sh)release-local.ymlruns the same script)Verification
PATHwithoutrg→ripgrep (rg) is required; the forbidden-content scans cannot run., exit 1 (previously silent success).bash local/scripts/validate.shon macOS with ripgrep 14.1.1 → all six steps pass.bash -non the script; both workflow files parse as YAML.smoke-install.sh/e2e.sh/test-observability.sh— unchanged scripts; this PR's CI runs them on both cells.Merge order: after #909
apt publishes rg 15.1.0 for resolute (what ubuntu-latest resolves to) and 14.1.0 for noble (ubuntu-24.04) per Launchpad published sources. With ripgrep actually present, the 15.x glob handling self-matches
scripts/validate.shin scan 1 — the known bug #909 fixes (noble's 14.1 is unaffected; verified locally on 14.1.1). Until #909 merges, this PR'svalidate (3.12)cell will show that known self-match failure, which is the sequencing dependency stated in #1044. Keeping this as a draft so it can be flipped to ready once #909 lands.🤖 Generated with Claude Code