Problem
Docs Agent accepts base_ref and uses it for recipe metadata and workspace materialization, but omits the corresponding base field from the runner_workspace JSON passed to WP Codebox. WP Codebox therefore applies its generic main fallback during publication.
This breaks consumers whose base branch is not main. Build with WordPress uses trunk; after all integrity and verification gates pass, publication fails with:
GitHub API GET /git/ref/heads/main failed with 404.
Acceptance evidence: https://github.com/Automattic/build-with-wordpress/actions/runs/29645661510
Root cause
.github/workflows/maintain-docs.yml builds runner workspace JSON with from: ("origin/" + $baseRef) but no base: $baseRef. WP Codebox publication reads config.base || config.base_branch || "main", so clone/materialization and publication disagree.
Acceptance criteria
- Include
base: $baseRef in the emitted runner workspace config.
- Add deterministic contract coverage proving a non-main
base_ref reaches both base and from.
- Keep the generic WP Codebox fallback unchanged.
- Build with WordPress manual PR-required maintenance publishes against
trunk.
Problem
Docs Agent accepts
base_refand uses it for recipe metadata and workspace materialization, but omits the correspondingbasefield from therunner_workspaceJSON passed to WP Codebox. WP Codebox therefore applies its genericmainfallback during publication.This breaks consumers whose base branch is not
main. Build with WordPress usestrunk; after all integrity and verification gates pass, publication fails with:Acceptance evidence: https://github.com/Automattic/build-with-wordpress/actions/runs/29645661510
Root cause
.github/workflows/maintain-docs.ymlbuilds runner workspace JSON withfrom: ("origin/" + $baseRef)but nobase: $baseRef. WP Codebox publication readsconfig.base || config.base_branch || "main", so clone/materialization and publication disagree.Acceptance criteria
base: $baseRefin the emitted runner workspace config.base_refreaches bothbaseandfrom.trunk.