feat(mcp): compact mcp doctor output by default, add --verbose - #327
Merged
Merged
Conversation
The default view now prints one line per component and one for all healthy editors, expanding only failing or warning checks with their hints. --verbose keeps the full per-check listing. Informational notes (Copilot checklist, VS Code log) move behind --verbose. Also reword checks that read as errors on a pass: server network no longer shows the probe's HTTP 401, authentication says what was verified, and deduplicated launch rows name the check they reference.
Test Coverage Reporttotal: (statements) 72.5% Coverage by function |
There was a problem hiding this comment.
Note
Copilot was unable to run its full agentic suite in this review.
Copilot review overview
Review effort: Lite
Findings: 2
Open (2)
What changed in this PR
This PR adds a compact/plain “doctor” output mode with a new --verbose flag, and enriches doctor checks with editor and summary metadata to support folded views and clearer reporting.
Changes:
- Add
EditorandSummarymetadata toDoctorCheck, plus helper APIs to tag checks and set compact summaries. - Update plain output to default to a compact view (summary + attention-needed checks), with
--verboseto list all checks. - Improve/adjust details for certain checks (probe de-dup messaging, server network OK detail) and expand tests accordingly.
| File | Description |
|---|---|
| internal/install/doctor_vscode.go | Tag VS Code registration checks as editor-related via addEditor. |
| internal/install/doctor_checks_test.go | Extend tests for editor tagging and refined network OK detail. |
| internal/install/doctor.go | Add editor/summary fields & helpers; update probe and multiple checks to use compact summaries and editor tagging. |
| internal/cmd/mcp_doctor_test.go | Update plain output tests and add coverage for the new compact output behavior and --verbose flag. |
| internal/cmd/mcp_doctor.go | Implement --verbose flag, compact/plain output rendering, and new compact/verbose printers. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+295
to
+303
| var rows []doctorRow | ||
| var notes []string | ||
| for _, comp := range components { | ||
| var server, editors []install.DoctorCheck | ||
| for _, c := range byComponent[comp] { | ||
| switch { | ||
| case c.Status == install.StatusInfo: | ||
| notes = append(notes, c.Name) | ||
| case c.Editor != "": |
Comment on lines
+383
to
+387
| c := &checks[i] | ||
| if c.Status == install.StatusOK { | ||
| continue | ||
| } | ||
| rows = append(rows, doctorRow{status: c.Status, label: label, text: c.Name + ": " + c.Detail, check: c}) |
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.

Follow-up to #326. These changes were left uncommitted when #326 merged.
What
A healthy
armis-cli mcp doctorrun printed 24+ rows plus a Copilot troubleshooting checklist, which made a passing result look alarming. The default output is now a summary:→hints. Healthy editors stay on the shared line.--verbose, and the footer points there.--verbose/-vflag keeps the full per-check listing.Wording fixes (visible in
--verbose)server networkno longer shows the unauthenticated probe'sHTTP 401next to a ✓. The status is still in the bundle'snetwork-probe.txt.authenticationnow says the client ID/secret in.envwere accepted, so it doesn't look like it contradictsdebug_configreporting SSO.launchrows name the check they reference, e.g.same launch command as the "Antigravity live handshake" check above. Before, the text was inconsistent (scanner / live handshakevsscanner / Antigravity live handshake).Implementation
DoctorCheckgetsEditor(included in JSON aseditor, omitted when empty) andSummary(not in JSON).addEditor. The probe tags its rows with the editor and sets summaries only for the server's own launch.Testing
go test ./internal/install/ ./internal/cmd/passes, including new tests for the compact view (all passing, and problems expanding) and the network, dedup, and editor-tag changes.make lint: 0 issues../bin/armis-cli mcp doctorandmcp doctor -vagainst a real install.