Repository navigation
fix(cicd): stop benchmark.sh deleting the tracked scripts/benchmark harness - #3595
Merged
KuSh merged 1 commit intoAug 20, 2026
Merged
Conversation
…arness `BENCH_DIR="$(pwd)/scripts/benchmark"` is a tracked directory: besides the gitignored `unix/`, `rtk/` and `diff/` output dirs it holds the TypeScript VM-benchmark harness (`run.ts`, `cleanup.ts`, `rebuild.ts`, `lib/*.ts`, `cloud-init.yaml`). `rm -rf "$BENCH_DIR"` therefore wiped all 7 tracked files from the working tree on every local run (`$CI` unset), which is exactly when a contributor runs the benchmark before pushing. Wipe only the three gitignored output subdirectories instead. Stale output is still cleared between runs; the harness survives. Follow-up to rtk-ai#3430 (rtk-ai#3430 review).
Merged
social4hyq
pushed a commit
to social4hyq/homebrew-core
that referenced
this pull request
Sep 20, 2026
rtk 0.46.0 Created-by: HarmonybrewBot Commit-by: HarmonybrewBot Merged-by: HarmonybrewBot Description: Created by `brew bump` --- Created with `brew bump-formula-pr`.<details> <summary>release notes</summary> <pre>## [0.46.0](rtk-ai/rtk@v0.45.0...v0.46.0) (2026-08-26) ### Features - find: dispatch on find's grammar; compress find output for unmodeled predicates ([#3603](rtk-ai/rtk#3603)) - find: tee tail hint when rtk imposes the result cap ([#3603](rtk-ai/rtk#3603)) ### Bug Fixes - find: never-worse guard, recovery hint, and dispatch on find's grammar ([#3603](rtk-ai/rtk#3603)) - git: don't misdetect a value-taking option's argument as a patch flag ([#3575](rtk-ai/rtk#3575)) - cicd: stop benchmark.sh deleting the tracked scripts/benchmark harness ([#3595](rtk-ai/rtk#3595)) - tee: hash long recovery-file slugs to prevent collisions and shorten hints ([#3266](rtk-ai/rtk#3266)) - benchmark: avoid negative curl/cargo cases that fail the benchmark job ([#3430](rtk-ai/rtk#3430)) - test: accept both Ask and Allow verdicts in rewrite tests ([#3147](rtk-ai/rtk#3147)) — Closes [#3146](rtk-ai/rtk#3146) - core: decode process output using Windows console code page ([#2717](rtk-ai/rtk#2717)) — Closes [#2452](rtk-ai/rtk#2452) - git: preserve patch output from log commands ([#2951](rtk-ai/rtk#2951)) — Closes [#2944](rtk-ai/rtk#2944) - discover: sanitize drive-letter colon so Windows discover finds sessions ([#2952](rtk-ai/rtk#2952)) — Closes [#2919](rtk-ai/rtk#2919) - stream: decode lossily instead of dropping lines on invalid UTF-8 ([#2997](rtk-ai/rtk#2997)) — Closes [#2994](rtk-ai/rtk#2994) ### Other - test(find): use the platform temp dir instead of /tmp ([#3717](https://github.com/rtk-ai/rtk/pull/3717))</pre> <p>View the full release notes at <a href="https://github.com/rtk-ai/rtk/releases/tag/v0.46.0">https://github.com/rtk-ai/rtk/releases/tag/v0.46.0</a>.</p> </details> <hr> See merge request: Harmonybrew/homebrew-core!17826
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.
Summary
scripts/benchmark.shdeleted the trackedscripts/benchmark/TypeScript VM-benchmark harness from the working tree on every local run.unix/,rtk/,diff/) instead of the whole$BENCH_DIR.Follow-up to #3430 — @KuSh asked for this in the merge comment.
Problem
.gitignoreonly ignores the three output subdirectories:$BENCH_DIRitself is tracked and also holds the VM-benchmark harness —run.ts,cleanup.ts,rebuild.ts,lib/report.ts,lib/test.ts,lib/vm.ts,cloud-init.yaml. Sorm -rf "$BENCH_DIR"removed all 7 of them.The guard is
[ -z "$CI" ], so CI never hits it (fresh checkout anyway) — it only fires locally, i.e. exactly when a contributor runs the benchmark before pushing.Test verification (RED → GREEN)
There is no shell test harness in this repo, so this is a real observed run of the setup block against a clean checkout.
RED — on unmodified
develop(ba7a9ce):GREEN — with this patch:
Stale output is still cleared — seeded a
STALE.mdin each of the three output dirs, ran the block again:Full local CI replay,
CIdeliberately unset so the local path is the one exercised:develop(ba7a9ce)--all)34 good / 27 warn / 0 negative / 1 fail34 good / 27 warn / 0 negative / 1 failThe benchmark's single remaining
❌(empty output) is pre-existing and identical ondevelop.Test plan
cargo fmt --all && cargo clippy --all-targets -- -D warnings && cargo test --all./scripts/benchmark.shwithCIunset — harness intact afterwards