Skip to content

[pull] main from Tencent:main - #73

Merged
pull[bot] merged 1 commit into
Walternater:mainfrom
Tencent:main
Sep 26, 2026
Merged

pull[bot] merged 1 commit into
Walternater:mainfrom
Tencent:main

Conversation

@pull

@pull pull Bot commented Sep 26, 2026 •

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

* fix(pull): report hooks and MCP entry warnings on a dry run

`pull --dry-run` returned before the hooks and MCP reconcile stages, so the
warnings those stages raise never reached the maintainer who ran the dry run
to see exactly them: an unknown entry id, a per-entry `roles:` key, a
hooks.yaml that does not parse. A dry run must resolve and warn, then skip
the write (#822, item 3).

MCP already had the capability — `McpReconcileOptions.dryRun` gates every
write in mcp-reconcile.ts and `teamai mcp inject --dry-run` uses it — so
`reconcileMcpAllScopes` only forwards it. Hooks had no dry-run path at all,
so `reconcileTeamHooksForConfig` gained one: it resolves the entries, reports
what it found, and stops before the first write. `resolveTeamHooks` takes a
`preview` flag so the transparency line reads "Would apply N team hook(s)"
instead of claiming they were applied.

The tests drive `pull()` rather than the reconcile functions, the way
pull-env-shape-warning.test.ts does: the defect was in the orchestration
layer, so that is where it has to be pinned. They cover the dry-run warning,
the zero writes, the unchanged real-pull behavior, and the dryRun forwarding.

* fix(pull): preview-word the MCP dry-run summary and update the design doc

Review follow-up: with dryRun forwarded, the MCP summary still read as a
completed apply — "N change(s) ... Restart your AI tool session to load them"
after a run that wrote nothing. A dry run now reads "Would make N change(s)"
and omits the restart instruction; a real pull keeps the applied wording.

docs/designs/multi-project-management.md still said `pull --dry-run` prints
no hooks or MCP warnings; it now describes the resolve-and-warn behavior this
PR ships. The new tests pin the wording on each side of the dry-run boundary:
the dry-run case failed on the previous commit, the real-pull case passed.

* fix(pull): preview-word the hooks debug trail on a dry run

The [scope] "Reconciled N team hook(s)" debug line still claimed a reconcile
after a run that wrote nothing. It now reads "Would apply N team hook(s)" on a
dry run and keeps "Reconciled" on a real pull; both wordings are pinned by the
dry-run tests.

* fix(hooks): report the Pi skip on a dry run, like a real reconcile does

The per-entry `tools: [pi]` case: a real pull warns "Pi supports built-in
lifecycle hooks only; skipping N custom team hook(s)" during the per-tool
pass, but the dry run returned before that pass, so its "Would apply" line
promised hooks no tool will run.

Extract the Pi report from the loop so both paths print the same warning —
the dry run gated on the same toolPaths and agent filters the real pass uses
— and pin it with a test that is RED without the fix.

---------

Co-authored-by: ydflow <[email protected]>
@pull pull Bot locked and limited conversation to collaborators Sep 26, 2026
@pull pull Bot added the ⤵️ pull label Sep 26, 2026
@pull
pull Bot merged commit fe03787 into Walternater:main Sep 26, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant