Repository navigation
fix(host): read Markdown under .github/workflows as instructions, not workflows (#1110) - #1139
Merged
Merged
Conversation
… workflows (#1110) The repository reader filed every source the boundary registry found under `.github/workflows/` as a GitHub workflow (`_source_kind`) under host `github` (`_audit_hosts`), before the Markdown check ran. The `AGENTS.md` Codex reads there and the `CLAUDE.md` Claude Code reads were parsed as workflow documents and recorded as blocking `parse_failed`, so pydantic/pydantic-ai PR #12653 came back `incomparable` with no rows, hiding its changes to `bots.yml` and `ci.yml`. With the Markdown unchanged the comparison held but listed it under `Not compared`, `check` added `BOUNDARY-INPUT-INCOMPLETE`, and `--save-baseline` refused the repository. Both classifiers now ask one registry predicate, `is_github_workflow_path`: exactly the shared adapter's root workflow globs (`.github/workflows/*.yml|*.yaml`), case-folded as before, which is also what `check` evaluates for these files. Anything else the registry enumerates there is read by its own adapter, as in any other directory. A nested copy keeps its handling; root workflow grant ids, `config_sha256` and `sources_expected` do not move.
Conflicts: CHANGELOG.md keeps both Unreleased entries (Host comparison, then #1130's Changes); tests/shard_seconds.json keeps both files' weights and both supplemental measurements.
Conflict: tests/shard_seconds.json keeps both files' weights and both supplemental measurements. CHANGELOG.md auto-merged.
This was referenced Nov 15, 2026
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.
What was wrong
The repository reader behind
diff,verify's host comparison,check's rows andaudit --host --driftfiled every source the boundary registry finds under.github/workflows/as a GitHub workflow, before its Markdown check ran:_source_kindreturnedworkflowfor any path under.github/workflows/;_audit_hostsforced hostgithubfor the same prefix.The registry enumerates
.github/workflows/AGENTS.md(shared adapter,**/AGENTS.md) and.github/workflows/CLAUDE.md(Claude Code adapter,**/CLAUDE.md), because Codex and Claude Code read nested instruction files. The reader then parsed that Markdown as a workflow document and recorded a blockingparse_failedundergithub.pydantic/pydantic-aiPR #12653 (basee2332baa, headb86b6ff9) came backincomparable(base_inventory_incomplete; head_inventory_incomplete) with zero rows, hiding the PR's changes to.github/workflows/bots.ymlandci.yml.Not compared … github .github/workflows/AGENTS.md — parse_failed, andcheckaddedBOUNDARY-INPUT-INCOMPLETE.audit --host --save-baselinerefused any repository with Markdown in that directory ("inventory is incomplete").check's own evaluator (_is_workflow_path) and the Stop hook'shost_config_change_patternsalready took only.yml/.yamlworkflows in the root directory. The diff/verify/drift reader was the odd one out.The fix
core/boundary_registry.pygainsGITHUB_WORKFLOW_GLOBS(.github/workflows/*.yml,.github/workflows/*.yaml) andis_github_workflow_path, which is exactly a case-folded match against those globs. The shared adapter now splats the same constant into its globs, so its values and order are unchanged._source_kindand_audit_hostsincore/host_grants.pycall that one predicate, so a source isgithubexactly when it is read as a workflow.AGENTS.mdunderclaude-code,codexandcursor;CLAUDE.mdunderclaude-code. Both are plain instruction (guidance) sources, so a prose edit is achanged_without_grant_changesource with no row, exactly as fordocs/AGENTS.md..mcp.json,.codex/config.tomland.claude/hooks/hooks.jsonbelow the directory had been published as emptygithubworkflow grants. They are now read as MCP, Codex and hook configuration..GitHub/Workflows/CI.YMLis a workflow). A nested copy (samples/x/.github/workflows/ci.yml) keeps today's handling. Reusable-workflow resolution already refused a non-.yml/.yamltarget, so nothing starts treating Markdown as a reusable workflow; a test now pins that.check's_is_workflow_pathis not changed; see Out of scope below.Public result after the fix
./shipgate diff --workspace <pydantic-ai clone> --base e2332baaba4feb2c92f5ed47b7343374c2ba3546returnscomparable, with noincomparable_reasonsand nounchanged_limits. It has two rows:critical changed github .github/workflows/bots.ymlhigh changed github .github/workflows/ci.ymlThe coverage items for the instruction files:
.github/workflows/AGENTS.md:changed_without_grant_change, hosts claude-code/codex/cursor..github/workflows/CLAUDE.md: the mode-120000 link toAGENTS.md, read through at its target (Read through an in-tree symlink at a boundary path:CLAUDE.md -> AGENTS.mdand.claude/skills -> ../.agents/skillsstill leave the inventory incomplete #700) under claude-code. It isunchanged_not_proven, because its target changed. That status limits nothing, and adocs/CLAUDE.md -> AGENTS.mdlink reads the same way.Nothing blocks the comparison. The #1004 directory-link rule is not involved.
Published changes
.github/workflows/only. Their artifacthost,kindandartifact_idchange, and theirparse_failedissues and bogusgithubworkflow grants are gone. So do theNot comparedline andcheck'sBOUNDARY-INPUT-INCOMPLETEthat they caused.config_sha256are unchanged;ci.yml'shost_grant_a85864…is the same on main and here.sources_expected, the registry's glob values, the Stop hook patterns, goldens and fingerprints are unchanged too.githubgrant reads as removed and its own grants as added. The CHANGELOG says so..github/workflows/*cell now says.github/workflows/*.ymland*.yaml, which is what was always meant. No distribution-surface claim changes (docs/distribution-surfaces.mduntouched).Tests
tests/test_workflow_directory_instructions.pyhas 23 cases. Its shard weight is intests/shard_seconds.json, appended at the end, away from #1138's lines. All its route cases failed on main before the fix..yml/.yaml(case-folded) are workflows.AGENTS.md,CLAUDE.md,Agents.md, a subdirectoryAGENTS.mdand a.mcp.jsonin the directory keep their adapters' kinds and hosts.samples/x/.github/workflows/ci.ymlkeeps kindconfigand the shared hosts.checkagreement.diff's classification agrees withcheck's_is_workflow_pathon those files.AGENTS.md(besideci.yml) andCLAUDE.md(besiderelease.yaml), each next to a widened workflow, go throughdifftext and JSON,verify --preview,audit --host --driftagainst a baseline saved at the base,checkandaudit --host. Each must be:workflow_write_changedfrom drift;parse_failed,Not comparedorBOUNDARY-INPUT-INCOMPLETE;.github/workflows/AGENTS.mdproduces the same coverage item as todocs/AGENTS.md.CLAUDE.mdis an unchanged link toAGENTS.md: comparable, read through, and the same as adocs/link.Checks.
-m "not perf" -n auto): 24088 passed, 2 failed, 16 skipped, 120 xfailed in 36 min. The 2 failures are the known environmentaltests/test_check_unmodelled_host_config_keys.py[local_settings_enabled_plugins-worktree|git_range]: the fixture'sgit commit -qm baseexits 1 because this machine's global git-ignore excludes the local settings file.ruff check .: clean.python scripts/generate_schemas.py --check: clean.Out of scope (noted, not fixed)
check's_is_workflow_path(core/host_boundary.py) has a latent bug of its own. It never checks the.github/workflows/prefix; it slicespath[len(".github/workflows/"):]after the shared adapter matched. Sopolicies/agent-boundary.shipgate.yamland anypolicies/<name>.shipgate.yamllong enough returnTrue, andcheckevaluates a changed policy pack as a workflow. Verified on this branch and main alike: a malformedpolicies/foo.shipgate.yamlgetsHOST-CONFIG-PARSE-FAILED(workflow_yaml_parse_failed), and one with a top-levelpermissions: write-allgetsHOST-WORKFLOW-WRITE-ALLandblock. It also compares the extension case-sensitively, so.github/workflows/CI.YMLis not evaluated, while the registry and this reader fold case. Making it callis_github_workflow_pathwould fix both. That change touchescheck's decisions andhost_boundary.py's import block (PR #1133's area), so it is left for a follow-up.Surface discipline
No new public surface. The fix moves blocked-recall: a workflow permission change was hidden behind an
incomparableresult.Notes
CHANGELOG.md### Host comparisonheading (checked withgit merge-tree).host_grants.py,shard_seconds.jsonanddocs/host-boundary-support.mdauto-merge.Closes #1110
🤖 Generated with Claude Code