Summary
Every GitHub Actions run on master (and all feature branches) fails instantly with:
Invalid workflow file
.github/workflows/ci.yml
(Line: 18, Col: 1): 'env' is already defined
The same error affects ios-testflight.yml (line 18) and windows-smoke.yml (line 23). All three workflows have two top-level env: blocks, which GitHub Actions rejects as a duplicate mapping key. Runs show 0s duration — nothing executes.
Root cause
Commit e644e42 ("Mark CI telemetry explicitly", Aug 20) prepended a new top-level block:
name: CI
env:
JCODE_CI: "1"
on:
...
to ci.yml, ios-testflight.yml, and windows-smoke.yml, each of which already had a top-level env: block further down (e.g. CARGO_TERM_COLOR / BUNDLE_ID / SCHEME / TEAM_ID). Every push since Aug 20 has had zero CI.
Consequences beyond the parse failure itself: with CI unable to run, unformatted code has also landed on master — cargo fmt --check currently fails on crates/jcode-tui/src/tui/app/input.rs:2931 and crates/jcode-tui/src/tui/ui_header.rs:850 (from the recent SSH feature wave).
Evidence
gh run list on this repo: every run since e644e42 completed in 0s with "Invalid workflow file"
- Current master still has both blocks:
grep -n '^env:' .github/workflows/ci.yml → lines 3 and 16
Fix
Fold JCODE_CI: "1" into each file's existing env: block (one block per file, semantics unchanged — top-level env is a flat map). A PR follows with the three-line fix. The formatting fallout can be a separate cargo fmt commit.
Found while syncing the ra-co88/jcode fork, whose CI hit the same parse failure.
Summary
Every GitHub Actions run on
master(and all feature branches) fails instantly with:The same error affects
ios-testflight.yml(line 18) andwindows-smoke.yml(line 23). All three workflows have two top-levelenv:blocks, which GitHub Actions rejects as a duplicate mapping key. Runs show0sduration — nothing executes.Root cause
Commit e644e42 ("Mark CI telemetry explicitly", Aug 20) prepended a new top-level block:
to
ci.yml,ios-testflight.yml, andwindows-smoke.yml, each of which already had a top-levelenv:block further down (e.g.CARGO_TERM_COLOR/BUNDLE_ID/SCHEME/TEAM_ID). Every push since Aug 20 has had zero CI.Consequences beyond the parse failure itself: with CI unable to run, unformatted code has also landed on master —
cargo fmt --checkcurrently fails oncrates/jcode-tui/src/tui/app/input.rs:2931andcrates/jcode-tui/src/tui/ui_header.rs:850(from the recent SSH feature wave).Evidence
gh run liston this repo: every run since e644e42 completed in 0s with "Invalid workflow file"grep -n '^env:' .github/workflows/ci.yml→ lines 3 and 16Fix
Fold
JCODE_CI: "1"into each file's existingenv:block (one block per file, semantics unchanged — top-levelenvis a flat map). A PR follows with the three-line fix. The formatting fallout can be a separatecargo fmtcommit.Found while syncing the ra-co88/jcode fork, whose CI hit the same parse failure.