Skip to content

feat(setup): mark a shared enable:false registration as a manual conflict in doctor status - #11019

Merged
morluto merged 1 commit into
mainfrom
feat/client-registration-disabled-conflict
Nov 15, 2026
Merged

morluto merged 1 commit into
mainfrom
feat/client-registration-disabled-conflict

Conversation

@morluto

@morluto morluto commented Nov 15, 2026

Copy link
Copy Markdown
Owner

Summary

Refs #10508 (Phase 6.1). When a shared registration row (~/.agents/mcp.json, also ZCode's fallback) carries enable: false, setup preserves the flag, so doctor's stale status for that row is a manual conflict, not something setup repairs. Only the remediation sentence said so. The status now carries manual_conflict: "shared_disabled_activation", and the FreeBuff and ZCode tests assert it instead of the sentence.

Problem and expected behavior

  • ClientRegistrationStatus computed the conflict (activation === "disabled", enable === false, setupPreservesDisabledActivation) inline in the remediation chain and kept only the chosen text. A caller (doctor JSON, setup selection, an agent) could not tell "rerun setup" from "re-enable it in the other product" without parsing prose; tests matched "enable: false" and "will not change".
  • Expected: the status names the conflict as a field, and a ZCode native row (which setup does repair) does not carry it.

Change and scope

  • src/application/ClientRegistrationStatus.ts: the conflict is computed once (sharedDisabledConflict), used for the existing remediation choice, and recorded as optional manual_conflict on any non-aligned status. Remediation text is unchanged.
  • freebuffClientConfiguration.test.ts: the conflict test asserts manual_conflict instead of two remediation fragments.
  • zcodeClientConfiguration.test.ts: the native-row test asserts the field is absent (was not.toContain("enable: false")); the fallback-row test asserts it (was stringContaining("enable: false")). The native test keeps remediation: stringContaining("rea setup"), since that route is what it checks.
  • docs/getting-started/client-configuration.md: documents the field next to the ZCode enable: false paragraph.

Not included: other stale causes (package drift, ownership, policy) still carry only remediation text; no tests in this slice read them for routing.

Follow the contribution scope.
Unresolved scope, authority, side effects, or required verification block
integration. Link the required maintainer scope decision for new providers or
capabilities involving target execution, injection, mutation, or protection
recovery; ordinary fixes within existing boundaries may state "not applicable".
Draft PRs may leave the scope decision pending and the readiness and merge checklists
unchecked. Maintainers can help resolve open questions.

Contract and boundary impact

  • Semantic owner and earliest changed stage: ClientRegistrationStatus (registration inspection); consumers: doctor JSON, setup and update maintenance via the status type
  • Contribution scope fit and linked maintainer decision: not applicable (additive status field, Phase 6.1 tracker [Design] Assert structured remediation facts instead of guidance prose #10508)
  • CLI and MCP/tool-catalog contract: additive optional manual_conflict on doctor registration statuses; no zod schema covers this record
  • Provider, bridge, target-format, or platform compatibility: none
  • Evidence, artifact, provenance, or reconstruction contract: none
  • Target selection, authority, upstream behavior, and cleanup details (if applicable): not applicable; setup behaviour unchanged
  • Generated metadata (docs/public/product-catalog.json), package, or installation impact (CI generates and validates ignored catalogs and skills/; edit authored instructions in .agents/skills/reverse-engineer-anything/ and never commit build outputs): none

Expected effects (check known effects; use documentation-only on its own).
Unchecked items do not establish absence; leave uncertainties visible.

  • Read existing files or captured data.
  • Launch or attach to a process.
  • Inject instrumentation or run scripts/code.
  • Change process memory, registers, files, or configuration.
  • Contact network services.
  • Recover protected code or work around protections.
  • Documentation or usability only; no target interaction.
  • Not sure yet; investigation or maintainer guidance needed.

Evidence and regression coverage

  • Tests: 48 in the two files before and after.
  • Mutation (run locally, then reverted): without the field, 2 of 48 fail ("reports disabled fallback registrations as stale at the fallback path", "reports a preserved shared disable as a manual conflict, not a setup repair").
  • Wall/CPU (npm run test:focused, after): 10.7 s wall, 14.0 s user, 3.4 s sys including build; vitest 3.0 s.
  • User-visible CLI/MCP output: rea doctor --json registration entries for a shared disabled row gain manual_conflict.

For boundary fixes, identify the applicable boundary regressions
and lifecycle regressions
covered by the evidence above, and explain relevant gaps.

For evidence-bearing changes:

  • Observed, derived, and inferred claims remain distinguishable.
  • Artifact identity, source provenance, and failed attempts remain preserved.
  • Unsupported, incomplete, unavailable, or uncertain outcomes remain visible.

Validation performed

  • npm run test:focused -- tests/boundary/filesystem/freebuffClientConfiguration.test.ts tests/boundary/filesystem/zcodeClientConfiguration.test.ts: 48 passed
  • Same with the field removed: 2 failed (expected)
  • npm run check:fast: passed
  • npm run docs:check: passed

Compatibility, safety, and release

  • Breaking changes or migration steps: none
  • Real Hopper/Ghidra, browser, or OS coverage: macOS only; no real client launched
  • Package or release metadata impact: none
  • Security, privacy, process, or containment review: none

Author readiness

Human owner:

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

Before merge

  • This PR addresses a concrete problem or an agreed enhancement.
  • Material scope and authority questions are resolved, and any required maintainer scope decision covers the final diff.
  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above.
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed.
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-15T10:16:32.518468Z 3a433a7 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@greptile-apps

greptile-apps Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5 Tier: plus

[Medium impact] The PR appears safe to merge; no actionable issue was found in the added status field.

Summary

Adds manual_conflict: "shared_disabled_activation" to non-aligned statuses for shared registrations carrying a preserved enable: false.

  • Doctor marks disabled shared registrations for manual repair.

Reviews (1) · Last reviewed commit: "feat(setup): mark a shared enable:false ..." · Reviewed by Greptile

@morluto
morluto merged commit b572dba into main Nov 15, 2026
7 checks passed
@morluto
morluto deleted the feat/client-registration-disabled-conflict branch November 15, 2026 10:21
@morluto morluto added area: setup Setup, packaging, upgrade, install, Doctor, and client registration enhancement New feature or request labels Nov 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: setup Setup, packaging, upgrade, install, Doctor, and client registration enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant