Repository navigation
feat(setup): let doctor, update and uninstall see MCPorter registrations - #10702
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 308bfb8ddd
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
[Medium impact] The PR appears safe to merge; no new blocking issue remains. SummaryMCPorter now uses the shared client table, so doctor, update, and uninstall can inspect registrations REA wrote.
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Shared MCPorter client row] --> B{Location resolved?}
B -->|No| C[Doctor reports unknown]
C --> D[Update skips this client and keeps recovery]
C --> E[Uninstall stops]
B -->|Yes| F{REA registration present?}
F -->|No| G[Doctor omits row unless selected]
F -->|Yes| H[Inspect registration and ownership]
H --> I[Update selects enabled owned registrations]
H --> J[Uninstall removes only owned registrations]
A --> K[Setup detection excludes MCPorter]
Reviews (3) · Last reviewed commit: "fix(update): keep unknown clients in eve..." · Reviewed by Greptile |
308bfb8 to
e30c022
Compare
e395912 to
6b441b7
Compare
e30c022 to
417c686
Compare
478e09b to
17d3f35
Compare
5f87aef to
b72c793
Compare
441e26c to
a646960
Compare
|
Greptile findings on 308bfb8: (1) Unselected MCPorter blocks maintenance - resolved by the coordinator's per-client fail-closed decision (e52c10d, see the reply on the review thread): an unresolved location is reported as |
b72c793 to
9bf3550
Compare
a646960 to
78e6fc8
Compare
|
@greptileai review — the findings on 308bfb8 are addressed on the current head (see the comment above); please re-review 9bf3550. |
MCPorter becomes a client-table row, so a registration rea mcp add or rea setup --client mcporter wrote is inspected, refreshed and removed like other clients. MCPorter already imports setup-managed clients' registrations, so the row is applicable only through REA's own registration: setup never selects it from detection and doctor reports it only when its file holds a rea row or the caller selects it. A relative MCPORTER_CONFIG is refused because MCPorter resolves it per command directory.
With an absolute XDG_CONFIG_HOME and only a legacy ~/.mcporter file, the row returned the legacy file but the absent XDG folder as its detection evidence, so default registration and setup skipped MCPorter.
…' maintenance A client whose configuration location cannot be resolved (for example a relative MCPORTER_CONFIG) is reported as unknown, never missing or absent. Update maintenance leaves each unresolved client out of its scope and names it with its own recovery, while still maintaining the other clients; uninstall still stops, because it cannot tell whether that client's file holds REA's row.
78e6fc8 to
40b1c5c
Compare
9bf3550 to
9c8d3d7
Compare
|
Greptile finding on 9bf3550 (Failed plans hide skipped clients) is valid and fixed in 9c8d3d7. Root cause: @greptileai review |
…ons (#10702) * feat(setup): let doctor, update and uninstall see MCPorter registrations MCPorter becomes a client-table row, so a registration rea mcp add or rea setup --client mcporter wrote is inspected, refreshed and removed like other clients. MCPorter already imports setup-managed clients' registrations, so the row is applicable only through REA's own registration: setup never selects it from detection and doctor reports it only when its file holds a rea row or the caller selects it. A relative MCPORTER_CONFIG is refused because MCPorter resolves it per command directory. * fix(setup): detect MCPorter by the folder of the file it loads With an absolute XDG_CONFIG_HOME and only a legacy ~/.mcporter file, the row returned the legacy file but the absent XDG folder as its detection evidence, so default registration and setup skipped MCPorter. * fix(setup): keep an unresolved client unknown without blocking others' maintenance A client whose configuration location cannot be resolved (for example a relative MCPORTER_CONFIG) is reported as unknown, never missing or absent. Update maintenance leaves each unresolved client out of its scope and names it with its own recovery, while still maintaining the other clients; uninstall still stops, because it cannot tell whether that client's file holds REA's row. * docs(setup): restore MCPorter's release note and client-table row after rebase * fix(update): keep unknown clients in every failed maintenance plan
…ons (#10702) * feat(setup): let doctor, update and uninstall see MCPorter registrations MCPorter becomes a client-table row, so a registration rea mcp add or rea setup --client mcporter wrote is inspected, refreshed and removed like other clients. MCPorter already imports setup-managed clients' registrations, so the row is applicable only through REA's own registration: setup never selects it from detection and doctor reports it only when its file holds a rea row or the caller selects it. A relative MCPORTER_CONFIG is refused because MCPorter resolves it per command directory. * fix(setup): detect MCPorter by the folder of the file it loads With an absolute XDG_CONFIG_HOME and only a legacy ~/.mcporter file, the row returned the legacy file but the absent XDG folder as its detection evidence, so default registration and setup skipped MCPorter. * fix(setup): keep an unresolved client unknown without blocking others' maintenance A client whose configuration location cannot be resolved (for example a relative MCPORTER_CONFIG) is reported as unknown, never missing or absent. Update maintenance leaves each unresolved client out of its scope and names it with its own recovery, while still maintaining the other clients; uninstall still stops, because it cannot tell whether that client's file holds REA's row. * docs(setup): restore MCPorter's release note and client-table row after rebase * fix(update): keep unknown clients in every failed maintenance plan
#10698) * fix(mcp): register fx and MCPorter where they read their configuration fx reads $FX_HOME/mcp.json when FX_HOME is set, and MCPorter reads MCPORTER_CONFIG exclusively or prefers an absolute XDG_CONFIG_HOME file. rea mcp add always wrote ~/.fx/mcp.json and ~/.mcporter/mcporter.json, which those clients then ignored. Resolve both from the clients' own rules, and refuse an FX_HOME fx itself refuses. * fix(mcp): detect MCPorter by its selected file and refuse FX_HOME aliases Address review findings: MCPORTER_CONFIG now also names the detection marker, so default registration includes MCPorter when only that file exists, and is resolved with path.resolve as MCPorter does. FX_HOME with . or .. segments is refused, so the private profile mode cannot reach the home folder through an alias. Override tests use the host's path rules for real temporary paths. * fix(mcp): never apply fx's private folder mode to the home folder A linked parent in FX_HOME can name the caller's home folder after the textual root and home checks pass. The private profile writer now compares the opened folder's identity with the caller's home folder and refuses before changing modes or publishing. * feat(setup): let doctor, update and uninstall see MCPorter registrations (#10702) * feat(setup): let doctor, update and uninstall see MCPorter registrations MCPorter becomes a client-table row, so a registration rea mcp add or rea setup --client mcporter wrote is inspected, refreshed and removed like other clients. MCPorter already imports setup-managed clients' registrations, so the row is applicable only through REA's own registration: setup never selects it from detection and doctor reports it only when its file holds a rea row or the caller selects it. A relative MCPORTER_CONFIG is refused because MCPorter resolves it per command directory. * fix(setup): detect MCPorter by the folder of the file it loads With an absolute XDG_CONFIG_HOME and only a legacy ~/.mcporter file, the row returned the legacy file but the absent XDG folder as its detection evidence, so default registration and setup skipped MCPorter. * fix(setup): keep an unresolved client unknown without blocking others' maintenance A client whose configuration location cannot be resolved (for example a relative MCPORTER_CONFIG) is reported as unknown, never missing or absent. Update maintenance leaves each unresolved client out of its scope and names it with its own recovery, while still maintaining the other clients; uninstall still stops, because it cannot tell whether that client's file holds REA's row. * docs(setup): restore MCPorter's release note and client-table row after rebase * fix(update): keep unknown clients in every failed maintenance plan
Summary
MCPorter becomes a row in the client table. Registrations that
rea mcp addorrea setup --client mcporterwrote are now inspected by doctor, refreshed by update and removed by uninstall. As the maintainer decided, setup never selects MCPorter from detection: MCPorter already imports the registrations setup writes for Claude Code, Codex, Cursor and others.Stacked on #10698, which is stacked on #10694. Refs #7181.
Problem and expected behavior
Before, MCPorter was a
registration-onlycatalog entry, so doctor, update and uninstall never saw whatmcp addwrote. Expected: REA can inspect, refresh and remove its own MCPorter row, without offering MCPorter to every user who has~/.mcporter.Change and scope
SupportedClients.ts:mcporterrow. Its synchronous location follows MCPorter's rules:MCPORTER_CONFIGis exclusive; otherwise the first existing XDG or legacy candidate; a new file goes to the XDG path.MCPORTER_CONFIGbecomes aconfigPathError, because MCPorter resolves it against each command's directory.registrationApplicability: only a registration REA wrote makes the client applicable.detectClientsskips such rows, so setup never selects or proposes them from detection.mcporterbecomestableClient("mcporter"). The async resolver from fix(mcp): register fx and MCPorter where they read their configuration #10698 is removed.Contract and boundary impact
Semantic owner and earliest changed stage: the client table row. The catalog copy is removed.
Contribution scope fit and linked maintainer decision: coordinator decision, "keep MCPorter out of setup's default selection, but registrations REA wrote must be visible to doctor/update/uninstall".
CLI and MCP/tool-catalog contract:
--client mcporteris accepted by setup and doctor.mcp add --agent mcporternow refuses a relativeMCPORTER_CONFIG.mcp add's own default selection is unchanged.Provider, bridge, target-format, or platform compatibility: none.
Evidence, artifact, provenance, or reconstruction contract: none.
Target selection, authority, upstream behavior, and cleanup details: writes only after approval (setup) or explicit selection (
mcp add). Uninstall removes only REA-owned rows.Generated metadata: the product catalog
setup_clientsgainsmcporter. The cursor-plugin skill copy was regenerated.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
mcpAddClientLifecycle.test.tsgains an MCPorter case:mcp addwrites, doctor reports itowned, update selects it, setup can plan it, uninstall removes it. A new test checks that an existing~/.mcporterfile withoutreais neither detected by setup nor reported by doctor, while an explicit selection reportsmissing.McpRegistrationCatalog.test.tsadds the relativeMCPORTER_CONFIGrefusal. The existing location cases from fix(mcp): register fx and MCPorter where they read their configuration #10698 now run through the table row.Validation performed
npm run test:focused -- tests/boundary/filesystem/mcpAddClientLifecycle.test.ts tests/boundary/filesystem/clientLifecycle.test.ts— 70 passed.npm run test:focused -- tests/boundary/filesystem/clientRegistrationStatus.test.ts tests/process-global/updateMaintenance.test.ts tests/acceptance/setup/automaticClientSetup.test.ts tests/boundary/cli/cliSetup.test.ts tests/boundary/cli/mcpAddDiscovery.test.ts— 121 passed.npm run test:local -- src/application/McpRegistrationCatalog.test.ts— 32 passed.npm run test:local -- src/application/McpRegistrationCatalog.test.ts src/application/McpClientRegistration.test.ts src/application/McpClientRegistration.formats.test.ts src/application/SetupPlan.test.ts src/application/Setup.planning.test.ts src/application/Doctor.test.ts src/application/Uninstall.test.ts— 213 passed, 1 skipped.npm run check:fast— passed.npm run docs:check— passed.unknown; update maintains the other clients and names the unknown one with its recovery; uninstall still stops.npm run test:focused -- tests/boundary/filesystem/clientRegistrationStatus.test.ts tests/process-global/updateMaintenance.test.ts src/application/Update.test.ts tests/boundary/filesystem/mcpAddClientLifecycle.test.ts tests/boundary/filesystem/claudeDesktopClientConfiguration.test.ts tests/boundary/filesystem/setupConfig.test.ts— all passed;tsc --noEmit; oxlint/oxfmt on changed files. The new regressions were not run against the code before the fix; two existing Windows Claude Desktop assertions changed frominvalidtounknown.npm run test:focused -- tests/process-global/updateMaintenance.test.ts src/application/Update.test.ts tests/boundary/filesystem/setupClientConfigCleanupOwnership.test.tspassed; the new case failed with theUpdateMaintenance.tschange reverted. Pre-pushnpm run check:fastpassed.Compatibility, safety, and release
MCPORTER_CONFIGnow fails registration instead of writing a cwd-relative file.mcporterrequires a release after 6.9.0.Author readiness
Human owner:
Before merge
type(scope): outcome.