perf(ci): gate docs-drift on paths; scope publish-images to changed images - #902
Merged
Merged
Conversation
sabbour
enabled auto-merge (squash)
August 25, 2026 12:27
sabbour
disabled the stack merge
August 25, 2026 12:33
sabbour
force-pushed
the
perf/docs-drift-and-publish-images-scoping
branch
2 times, most recently
from
August 25, 2026 12:35
49292f3 to
90f9484
Compare
sabbour
force-pushed
the
perf/docs-drift-and-publish-images-scoping
branch
from
August 25, 2026 14:33
90f9484 to
8b0dcd1
Compare
sabbour
force-pushed
the
perf/docs-drift-and-publish-images-scoping
branch
from
August 25, 2026 14:48
8b0dcd1 to
17b52c0
Compare
…mages docs-drift ran on every PR regardless of content, burning ~600 min/month. publish-images rebuilt all 4 containers on every dev push. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 11857092-1327-41bd-8708-b2ca85e674dd
sabbour
force-pushed
the
perf/docs-drift-and-publish-images-scoping
branch
from
August 25, 2026 15:30
17b52c0 to
ba1478a
Compare
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
Two independent CI cost/noise reductions.
1.
docs-drift.yml— gate on pathsPreviously ran on every PR (
[opened, synchronize, reopened], nopaths:filter) — 624 runs in August, more than any individual CI suite job, including on NuGet bumps, backend logic changes, and unrelated workflow edits that can never affect generated docs.Added a
paths:filter covering every input the two jobs actually depend on:generated-stalenessrunsnode scripts/gen-docs.mjs --check, whose source of truth isapps/Agentweaver.Mcp/Tools/**([McpServerTool]attributes), and which validatesdocs/reference/mcp-tools.md,.github/agents/agentweaver.agent.md, andapps/Agentweaver.Api/Projects/Templates/agentweaver.agent.md.curated-drift-nudge(non-blocking) diffsdocs/**againstapps/Agentweaver.Api/{Endpoints,Workflows,Blueprints}/**andpackages/Agentweaver.Squad/Catalog/Resources/{blueprints,workflows}/**.All of the above are included in the filter, plus the workflow file itself, so the check can never silently pass on a stale-doc regression.
2.
publish-images.yml— scope matrix to changed imagesPreviously rebuilt all 4 container images (
api,frontend,mcp,agent-host) on every push todev/release/*— 196 runs × 4 builds ≈ 800 redundant build-minutes/month.Added a
changesjob usingdorny/paths-filter@v3, with filters mirroring the existingwatchedPathsper image already defined inscripts/azure/image-spec.mjs(the deploy toolchain's single source of truth for what feeds each image), so the two never disagree.The
buildjob'sstrategy.matrixis unchanged (still derived fromplan/image-spec.mjs), but each matrix job now has anif:that only runs when its image's watched paths changed — except:main(always builds all 4 — release must be complete)release: published(always builds all 4)workflow_dispatch(always builds all 4 — explicit manual request)Testing
yaml.safe_load).docs-drift.ymlfilter andpublish-images.ymlchangesfilters exist in the repo and matchscripts/gen-docs.mjs/scripts/azure/image-spec.mjssource-of-truth lists.Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com