Repository navigation
fix(gate): restore run-gate.sh syntax — missing done, POSIX_MODE guard - #1594
Merged
Merged
Conversation
…d (winx#1590) #1589's restore of the wave4b sources dropped four closers in run_case(): the done closing the for side loop, the if [ "$POSIX_MODE" -eq 1 ] guard around the landing-leak check, and the fi closing if [ -n "$setup" ] and if [ -e "$cand" ]. The script could not execute at all (bash -n: line 368 syntax error near unexpected token 'fi'), and no workflow ever called it, so the defect lurked on master. The POSIX_MODE guard is restored, not removed: the section is titled '(posix mode)', the deletion came in the same mangled hunk as the other three dropped closers with no evidence of deliberation, and the landfall concept (niubash#346) is posix-mode-specific. The same hunk's new MSYS_NO_PATHCONV=1 / PATH lines were misplaced inside the leak-check while loop, where they could only pollute gate stdout and never reach run.sh. They are moved into the per-side run.sh writing block, which is where they function: GATE-REPORT.md documents them as 'exported inside both Windows-side run.sh scripts'. Also adds a bash -n parse check for the script to the Windows CI job so a future bad restore fails CI instead of silently shipping an unrunnable gate. Refs #1590
Member
Author
复核结论:PASSPR #1594(Refs #1590,头 逐腿结果(复核员独立重跑,非车道自述)
终头 CI 全读(runs 43269903722 / 43269904040)8 pass + 5 skipping + 1 fail:compare / baseline / baseline-growth / arm64 default / arm64 full / x64 full / i18n-drift / oracle 全部 pass;5 项 skipping;唯一红腿 build-windows (x64, default)(1h10m42s),红步仅 红腿定性 base-red:头腿 ctest 失败 23 名;与基底 合入条件
|
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
rust2/gate/run-gate.shis a syntax error on master:bash -nfails withline 368: syntax error near unexpected token 'fi'. The gate script could not execute at all, and no workflow ever called it, so the defect lurked silently after #1589 was merged. This PR restores the four closers #1589's restore dropped and adds abash -nparse check to CI so a future bad restore fails loudly.Refs #1590
Changes
rust2/gate/run-gate.shdoneclosing thefor side in rust cpploop (line 368).if [ "$POSIX_MODE" -eq 1 ]; thenguard around the landing-leak check, with its closingfi(which had sat orphaned on master, now re-balanced). The guard is restored, not removed: the section is titled "(posix mode)", the deletion came in the same mangled hunk as the other three dropped closers with no evidence of deliberation, and the landfall concept (niubash#346) is posix-mode-specific.ficlosers forif [ -n "$setup" ]andif [ -e "$cand" ].whileloop (where they could only pollute gate stdout and never reach arun.sh) into the per-siderun.sh-writing block, as its first two lines — matchingrust2/GATE-REPORT.md, which documents them as "exported inside both Windows-side run.sh scripts".git diff c2fa3db0 -- rust2/gate/run-gate.shon the fixed tree shows only the +11 MSYS lines; everything else is byte-identical to the reviewed pre-recover wave4b: restore the eight command sources + shared childproc spawner lost in the #1577 merge #1589 version..github/workflows/build-winuxcmd.yml: newCheck gate shell scripts parsestep in the Windows job (right after Checkout) that runsbash -n rust2/gate/run-gate.sh.Verification
bash -n rust2/gate/run-gate.sh: rc=0 on the fixed tree; rc=2 (line 368: syntax error near unexpected token 'fi') on master6fc5ebf7; rc=0 on pre-recover wave4b: restore the eight command sources + shared childproc spawner lost in the #1577 merge #1589 basec2fa3db0(control).run.shcontent checked via a stubbed copy of the writing block: first two lines areexport MSYS_NO_PATHCONV=1andexport PATH="$PATH:/d/winux/bin", then the command line.bash rust2/gate/run-gate.sh --help: rc=0, prints GATE SUMMARY (0/0 cases — no--help.tsvtable); the script executes end to end.yaml.safe_loadOK).本 PR 删除了什么
rust2/gate/run-gate.sh中被 recover wave4b: restore the eight command sources + shared childproc spawner lost in the #1577 merge #1589 误删的四个闭合结构(done/if/fi/fi),并把同 hunk 错置的 MSYS 两行从while循环内移到run.sh写出块;不删除任何命令实现、测试用例或文档内容。UNVERIFIED-BY-CAPTAIN