ci: add non-blocking sentinel for the #25 OpenTUI chunk regression#47
Conversation
1488bc8 to
dc705a3
Compare
|
Thanks for the contribution! To get this ready to merge:
Full conventions: |
|
Thanks for the review! I've updated the PR description to include I've also verified that
The PR is ready for review. |
|
Hi @Lion-1209, the CI sentinel is a nice preventive fix. The repo's CONTRIBUTING.md requires every PR to reference an issue (CI link-check enforces this). This PR mentions #25 in the description but doesn't formally close or reference it with . Could you add that so the PR passes the link-check CI gate? |
Hi @li-xiu-qi, it's there — Refs #25 at the bottom of the description (## Related). CI's already green on this PR. |
|
dc705a3 to
8388de3
Compare
|
Hi @ZouR-Ma, both items done. 1. Dropped the docs commit. File list is now just 2. Rebased onto current main (which now includes #28) and force-pushed. One heads-up on the three-platform CI: the Also opened #100 to track flipping the sentinel to a hard gate ( |
…ression Neither the installer smoke test (`step --version`) nor CI exercise the interactive TUI path, so when tsdown/rolldown tree-shook the `local-tui-app` dynamic-import target into an empty chunk (stepfun-ai#25), it shipped undetected — `step` failed at runtime with "OpenTUI runtime did not export createLocalTuiClientApp()". Add a build-output sentinel that checks the built `local-tui-app` chunk for the required exports and warns when they're missing. It is non-blocking (`continue-on-error`) on purpose so it can land independently of stepfun-ai#28: on current `main` it warns (expected, since stepfun-ai#25 is unfixed); once stepfun-ai#28 merges the warning clears automatically. Flipping to `--enforce` (and dropping `continue-on-error`) turns it into a hard gate for the future. Runs on the Windows CI lane, which already produces a build; tsdown output shape is platform-consistent, so one lane covers the build regression. Complements stepfun-ai#28. See stepfun-ai#25.
stepfun-ai#28 (the build fix that makes the OpenTUI runtime chunk carry its exports) has landed on main, so the sentinel no longer needs to warn-only. Drop continue-on-error and pass --enforce so a missing/empty chunk fails the Windows lane. Rebased onto current main so the chunk is populated.
8388de3 to
3d8e49f
Compare
What
Adds a non-blocking build-output sentinel that warns in CI when the OpenTUI runtime chunk is missing its exports — the exact condition behind #25.
Why
stepfailed at runtime withOpenTUI runtime did not export createLocalTuiClientApp()(#25) because tsdown/rolldown tree-shooksrc/runtime/local-tui-app.tsinto an empty chunk:This shipped undetected because no existing check exercises the interactive TUI path:
setup.ps1/setup.shsmoke tests only runstep --versionstep --version/step aec status/step vad status/step voice --help— none triggershouldUseTui(which requiresstdin/stdout.isTTY === true)So a regression that empties the chunk is invisible until a user runs
stepin a real terminal.How
scripts/check-build-output.mjsscansdist/for anylocal-tui-app*.jschunk and asserts it containscreateLocalTuiClientAppandLocalStepCliTuiApp. It is wired into CI as a new step after the Windows build (tsdownoutput shape is platform-consistent, so one lane covers the regression).Non-blocking by design (
continue-on-error: true, script exits 0 on failure and just logs⚠):stepfails withcreateLocalTuiClientAppnot exported #25 was unfixed there.main(verified locally: chunk now contains both exports, sentinel reports✓ build output check passed).--enforce(and droppingcontinue-on-error) turns it into a hard gate — tracked in [chore] Flip the #25 build-output sentinel to a hard gate (--enforce) #100 for after this PR merges.Tested
node scripts/check-build-output.mjsagainst the pre-fix(build): emit OpenTUI runtime chunk and build agent-sdk #28 (empty) chunk → logs⚠ ... missing createLocalTuiClientApp, LocalStepCliTuiApp, exits 0.✓ build output check passed, exits 0.--enforceflag flips the empty-chunk case to exit 1.scripts/check-build-output.test.ts, 7 tests) covers chunk discovery (post-fix(build): emit OpenTUI runtime chunk and build agent-sdk #28 layout, hashed variants, skipping.map/.cjs, missing dir) and symbol detection (complete chunk, the build: bundled OpenTUI chunk is empty,stepfails withcreateLocalTuiClientAppnot exported #25 empty-shell regression, partial chunk).pnpm checkpasses (test / lint / dep-guard / deadcode / tsc / format).Review feedback addressed
Per @ZouR-Ma's review:
docs/skills/pr-review-decision.mdfrom this PR (was a separatestyle(docs)commit). File list is now exactlytest.yml+ the sentinel script + its test.main(now includes fix(build): emit OpenTUI runtime chunk and build agent-sdk #28); full three-platform CI will run on this push.Scope
Single commit, three files (
test.yml,scripts/check-build-output.mjs,scripts/check-build-output.test.ts). No runtime changes.Related
stepfails withcreateLocalTuiClientAppnot exported #25