Skip to content

node-repo-scope: an always-modules floor the narrowing never drops - #2685

Merged
rbuergi merged 2 commits into
mainfrom
fix/scope-always-modules
Aug 29, 2026
Merged

rbuergi merged 2 commits into
mainfrom
fix/scope-always-modules

Conversation

@rbuergi

@rbuergi rbuergi commented Aug 29, 2026

Copy link
Copy Markdown
Contributor

A node repo's gates compose a fixed set of module bundles from the same run's artifacts — the AI engine (registers Skill/Agent) and, since the collaboration carve-out, MeshWeaver.Markdown.Collaboration. But a narrowed pull_request run builds only the diff-affected bundles, so a Hosting-only PR builds neither, the gates' download-artifact pattern matches nothing, and both required gates fail with "the modules job's artifact matched nothing" — correctly refusing an empty reference set, on an input the workflow itself failed to produce (Plugins #915). main passes only because every bundle is affected there.

  • node-repo-scope.py --always <names>: those matrix entries stay in every narrowed selection with a named why ("always built: the caller's gates compose this bundle on every run"); a floor name the matrix lacks falls back to the FULL set and says which name drifted (loud, safe bias). Three --self-test cases added (53 green).
  • node-repo-module-pack.yml: new optional input always-modules (comma-separated), passed through to the script. Default empty → behaviour unchanged for every current caller.

Plugins follows with always-modules: MeshWeaver.AI,MeshWeaver.Markdown.Collaboration once this is on main (the reusable workflow is referenced @main, so the input must exist first).

🤖 Generated with Claude Code

https://claude.ai/code/session_01ETgRRMRVzYMg1WU4pMywed

The caller's gates COMPOSE a fixed set of module bundles from the same run's
artifacts (the AI engine that registers Skill/Agent; since the collaboration
carve-out, MeshWeaver.Markdown.Collaboration). A narrowed PR run built only
the diff-affected bundles, so a Hosting-only PR built neither and both
required gates went red with 'the modules job's artifact matched nothing' —
an input the workflow itself failed to produce (Plugins #915, 2026-08-29).
Main passed only because everything is affected there.

--always <names> (node-repo-module-pack.yml input always-modules) keeps those
entries in every narrowed selection with a named reason; a floor name the
matrix does not carry falls back to the full set and says why. Three
self-test cases pin it: floor-only on a diff reaching nothing, floor never
shrinks a real selection, unknown floor is loud.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ETgRRMRVzYMg1WU4pMywed
Copilot AI lite review requested due to automatic review settings August 29, 2026 17:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR hardens the node-repo module-pack reusable workflow’s narrowing logic by introducing an “always build” floor for module bundles that downstream gates compose on every run (e.g., the AI engine bundle), preventing narrowed PR runs from producing an empty artifact set that causes required gates to fail.

Changes:

  • Adds an optional always-modules workflow_call input to .github/workflows/node-repo-module-pack.yml and threads it into the scope selection step.
  • Extends .github/scripts/node-repo-scope.py with --always to force-include specific module matrix entries during narrowing, with a loud full-scope fallback if the floor names drift from the matrix.
  • Adds self-test coverage for the new “floor” behavior and its drift-safe fallback.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
.github/workflows/node-repo-module-pack.yml Introduces always-modules input and passes it to the scope selector so required gate-composed bundles are always present in narrowed runs.
.github/scripts/node-repo-scope.py Implements --always floor selection logic (with drift detection) and adds self-tests to pin the behavior.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 3)

689 tests   497 ✅  4m 40s ⏱️
  5 suites  192 💤
  5 files      0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 2)

941 tests   941 ✅  5m 1s ⏱️
  6 suites    0 💤
  6 files      0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 0)

913 tests   913 ✅  5m 29s ⏱️
  6 suites    0 💤
  6 files      0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 4)

   10 files     10 suites   5m 57s ⏱️
3 449 tests 3 449 ✅ 0 💤 0 ❌
4 083 runs  4 083 ✅ 0 💤 0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 5)

1 528 tests   1 528 ✅  6m 46s ⏱️
    8 suites      0 💤
    8 files        0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 1)

788 tests   784 ✅  7m 37s ⏱️
  6 suites    4 💤
  6 files      0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Test Results

   41 files     41 suites   35m 32s ⏱️
8 308 tests 8 112 ✅ 196 💤 0 ❌
8 942 runs  8 746 ✅ 196 💤 0 ❌

Results for commit a842a3c.

♻️ This comment has been updated with latest results.

@rbuergi
rbuergi merged commit ba8c883 into main Aug 29, 2026
24 checks passed
@rbuergi
rbuergi deleted the fix/scope-always-modules branch October 10, 2026 13:11
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.

2 participants