From b39d11f7e8393c32bbdce002bae89a2a94cbb7c3 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Sat, 24 Oct 2026 22:39:33 -0700 Subject: [PATCH 1/3] chore(quest): claim quest/m0/nightly/shallow-base.md Quest-Claim: d7514a99be25dad9 From 8f8b522cb1c7cbc5843bd559304c684b6226a17b Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Sat, 24 Oct 2026 22:42:02 -0700 Subject: [PATCH 2/3] fix(nightly): build the paired-base test's own git history Nightly's Tests matrix checks out at depth 1, so HEAD~1 did not resolve and the test exited 128. It now commits two revisions in a temporary repository and runs nightly.sh there. Co-Authored-By: Claude Opus 5.5 --- quest/m0/nightly/README.md | 1 - quest/m0/nightly/shallow-base.md | 15 ----------- sh/gh/nightly.test.py | 44 +++++++++++++++++++------------- 3 files changed, 26 insertions(+), 34 deletions(-) delete mode 100644 quest/m0/nightly/shallow-base.md diff --git a/quest/m0/nightly/README.md b/quest/m0/nightly/README.md index 39fd3c3db0b..741d52f1aa6 100644 --- a/quest/m0/nightly/README.md +++ b/quest/m0/nightly/README.md @@ -37,5 +37,4 @@ Public API: none. Wire: none. - [Feature shapes in the gate](/quest/m0/nightly/feature-shapes.md) - feature-gated dead code fails the PR that adds it, not the next Nightly - [qmux fallback closes cleanly](/quest/m0/nightly/qmux-fallback-close.md) - the WebSocket fallback startup benchmark stops failing "not cleanly closed" - [ts_schedule regression](/quest/m0/nightly/ts-schedule.md) - the moq-mux `ts_schedule` benches return to their old cost -- [Nightly's base in a shallow checkout](/quest/m0/nightly/shallow-base.md) - `sh/gh/nightly.test.py` passes in Nightly's depth-1 checkout - [Advisory bumps](/quest/m0/nightly/advisories.md) - both audits pass on today's advisories diff --git a/quest/m0/nightly/shallow-base.md b/quest/m0/nightly/shallow-base.md deleted file mode 100644 index 636fb21b259..00000000000 --- a/quest/m0/nightly/shallow-base.md +++ /dev/null @@ -1,15 +0,0 @@ -# [XS] Nightly's base in a shallow checkout - -## Goal - -`test_paired_base_is_the_previous_scheduled_nightly` -(`sh/gh/nightly.test.py:46`) passes in Nightly's Tests matrix. - -## Plan - -The test runs `git rev-parse HEAD~1`, but the Tests matrix in `nightly.yml` -checks out with the default `fetch-depth: 1`, so it exits 128. Added by -[moq-dev/moq#6511](https://github.com/moq-dev/moq/pull/6511). Make the test -build its own history instead of reading the checkout's. - -Public API: none. Wire: none. diff --git a/sh/gh/nightly.test.py b/sh/gh/nightly.test.py index 0fd4c592e42..6c95cb31123 100644 --- a/sh/gh/nightly.test.py +++ b/sh/gh/nightly.test.py @@ -16,7 +16,7 @@ class NightlyTest(unittest.TestCase): - def run_group(self, group, fail="", **environment): + def run_group(self, group, fail="", cwd=ROOT, **environment): with tempfile.TemporaryDirectory() as directory: scratch = Path(directory) calls = scratch / "calls" @@ -38,28 +38,36 @@ def run_group(self, group, fail="", **environment): MOQ_BENCH_RESULTS=str(scratch / "results"), NIGHTLY_CALLS=str(calls), NIGHTLY_FAIL=fail, BASH_ENV="/dev/null") env.pop("MOQ_BENCH_BASE", None) env.update(environment) - result = subprocess.run(["bash", "sh/gh/nightly.sh", group], cwd=ROOT, + result = subprocess.run(["bash", ROOT / "sh/gh/nightly.sh", group], cwd=cwd, env=env, capture_output=True, text=True) self.bases = set(Path(f"{calls}.base").read_text().splitlines()) if calls.exists() else set() return result, calls.read_text().splitlines() if calls.exists() else [] def test_paired_base_is_the_previous_scheduled_nightly(self): - head, parent = (subprocess.run(["git", "rev-parse", revision], cwd=ROOT, capture_output=True, text=True, - check=True).stdout.strip() for revision in ("HEAD", "HEAD~1")) - # This run is the newest scheduled one; the previous run's commit is the base. - runs = json.dumps([{"databaseId": 2, "headSha": parent}, {"databaseId": 1, "headSha": head}]) - result, _ = self.run_group("rust-uring", MOQ_BENCH_BASE="previous-nightly", GITHUB_RUN_ID="2", NIGHTLY_RUNS=runs) - self.assertEqual(result.returncode, 0, result.stderr) - self.assertEqual(self.bases, {head}) - # A named revision reaches the runner as its commit. - result, _ = self.run_group("rust-uring", MOQ_BENCH_BASE="HEAD~1") - self.assertEqual(result.returncode, 0, result.stderr) - self.assertEqual(self.bases, {parent}) - result, calls = self.run_group("rust-uring", MOQ_BENCH_BASE="previous-nightly", GITHUB_RUN_ID="1", - NIGHTLY_RUNS=json.dumps([{"databaseId": 1, "headSha": head}])) - self.assertEqual(result.returncode, 1) - self.assertIn("no previous scheduled Nightly", result.stderr) - self.assertEqual(calls, []) + # Nightly checks out shallowly, so the test builds the history it resolves against. + with tempfile.TemporaryDirectory() as repo: + git = ["git", "-C", repo, "-c", "user.name=nightly", "-c", "user.email=nightly@example.com", + "-c", "commit.gpgsign=false"] + subprocess.run([*git, "init", "-q"], check=True) + for message in ("parent", "head"): + subprocess.run([*git, "commit", "-q", "--allow-empty", "-m", message], check=True) + head, parent = (subprocess.run([*git, "rev-parse", revision], capture_output=True, text=True, + check=True).stdout.strip() for revision in ("HEAD", "HEAD~1")) + # This run is the newest scheduled one; the previous run's commit is the base. + runs = json.dumps([{"databaseId": 2, "headSha": parent}, {"databaseId": 1, "headSha": head}]) + result, _ = self.run_group("rust-uring", cwd=repo, MOQ_BENCH_BASE="previous-nightly", GITHUB_RUN_ID="2", + NIGHTLY_RUNS=runs) + self.assertEqual(result.returncode, 0, result.stderr) + self.assertEqual(self.bases, {head}) + # A named revision reaches the runner as its commit. + result, _ = self.run_group("rust-uring", cwd=repo, MOQ_BENCH_BASE="HEAD~1") + self.assertEqual(result.returncode, 0, result.stderr) + self.assertEqual(self.bases, {parent}) + result, calls = self.run_group("rust-uring", cwd=repo, MOQ_BENCH_BASE="previous-nightly", + GITHUB_RUN_ID="1", NIGHTLY_RUNS=json.dumps([{"databaseId": 1, "headSha": head}])) + self.assertEqual(result.returncode, 1) + self.assertIn("no previous scheduled Nightly", result.stderr) + self.assertEqual(calls, []) def test_paired_base_applies_only_to_rust_bench_groups(self): for group in ("js", "rust-test"): From dd331e0a684a477de12c962ff0f058a668462475 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Sun, 25 Oct 2026 15:31:44 -0700 Subject: [PATCH 3/3] quest: size the nightly epic now that its children are done Co-Authored-By: Claude Opus 5.5 --- quest/m0/nightly/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/quest/m0/nightly/README.md b/quest/m0/nightly/README.md index 3f5961c7085..e58a48a54c5 100644 --- a/quest/m0/nightly/README.md +++ b/quest/m0/nightly/README.md @@ -1,4 +1,4 @@ -# Nightly passes on main +# [S] Nightly passes on main ## Goal @@ -16,7 +16,7 @@ Decided 2026-10-24 (maintainer), from a triage of run child per distinct cause, each landing on its own. The PR gate keeps skipping benches and examples; a green Nightly catches them within a day. -This README's own work, after the children: +This README's own work: - Nightly's multi-step jobs (Features first) keep going past a failed step and fail at the end, so one break never hides the steps after it.