Skip to content

fix(ci): derive editor browser cache in a step instead of job-level env - #515

Merged
athNdev merged 1 commit into
mainfrom
codex/editor-dialog-fix
Nov 18, 2026
Merged

athNdev merged 1 commit into
mainfrom
codex/editor-dialog-fix

Conversation

@athNdev

@athNdev athNdev commented Nov 18, 2026

Copy link
Copy Markdown
Owner

Problem

.github/workflows/editor-dialog.yml set PLAYWRIGHT_BROWSERS_PATH: ${{ runner.temp }}/... in the job-level env block. Per the GitHub Actions context availability table, runner is not available at jobs.<job_id>.env (only github, needs, strategy, matrix, vars, secrets, inputs). Main runs 44228944733 and 44231036412 both failed with "workflow file issue" before any job started.

Reproduced locally with actionlint v1.7.7:

.github/workflows/editor-dialog.yml:43:37: context "runner" is not allowed here.

Fix

  • Removed the job-level env block. A first runner step now derives the owned cache from RUNNER_TEMP and exports it to all subsequent steps via GITHUB_ENV:
    echo "PLAYWRIGHT_BROWSERS_PATH=$RUNNER_TEMP/carbonpanel-editor-browsers" >> "$GITHUB_ENV"
  • Preserves the private browser cache name carbonpanel-editor-browsers, the no-global-install behavior, Windows no-UAC behavior, and does not touch PLAYWRIGHT_BROWSER_GC.
  • Added scripts/workflow-contract.test.mjs: asserts no runner. context in any job-level env block across all workflows, and that editor-dialog derives the path from RUNNER_TEMP with the owned cache name. Wired into toolchain-policy.yml (already triggers on .github/workflows/**).
  • Updated the governing Release knowledge concept with the durable context rule.

Verification (head f610dba)

  • actionlint v1.7.7 on both changed workflows: exit 0, no findings.
  • bun test scripts/workflow-contract.test.mjs: 2 pass / 0 fail; node --test same: 2 pass / 0 fail.
  • Bun.YAML.parse on both workflows: parsed OK (editor-dialog, policy jobs present).
  • go run ./cmd/knowledge-lint -root . -fix then without -fix: exit 0, 60 concepts, indexes current, 38/38 queries. (Pre-existing unrelated WARN on invariants/data-safety review date; not touched by this change.)
  • Full-repo actionlint has one pre-existing unrelated finding in release.yml (macos-15-intel label).

Do not merge — independent review and CI required. Please confirm the editor-dialog job actually schedules on this head (not just "no checks").

runner.temp is not an available context in jobs.<job_id>.env; GitHub rejected the workflow before any job could be scheduled (runs 44228944733, 44231036412). A runner step now derives PLAYWRIGHT_BROWSERS_PATH from RUNNER_TEMP into GITHUB_ENV, preserving the owned carbonpanel-editor-browsers cache and no-UAC/no-global-install behavior. Adds a workflow-contract test and wires it into toolchain-policy CI.
@athNdev
athNdev merged commit f6e8d1c into main Nov 18, 2026
14 checks passed
@athNdev
athNdev deleted the codex/editor-dialog-fix branch November 18, 2026 04:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant