Skip to content

fix(macos): forget outcome, Try it on new profiles, reload, assign mode, settings edits, upgrade preview, toolbar add (Spec 108-retro-mac) - #1452

Merged
github-actions[bot] merged 3 commits into
mainfrom
108-retro-sol-fixes-macos
Oct 1, 2026
Merged

github-actions[bot] merged 3 commits into
mainfrom
108-retro-sol-fixes-macos

Conversation

@Dumbris

@Dumbris Dumbris commented Oct 1, 2026

Copy link
Copy Markdown
Member

Fixes the verified post-merge review findings of the macOS profiles work (#1442, Spec 108-k) and of the toolbar hand-off (#1427, Spec 109-i). Code changes are under native/macos/ only; the REST, CLI, MCP and Web surfaces and the wire contract are unchanged.

Spec: specs/108-profiles-v3/ (tasks T120a-T120f, FR-047 note, quickstart unit-gate filter) and specs/109-ux-navigation-consistency/ (task T141a). Findings R1-R6 are Spec 108 work; F4.1 (with F6.1) belongs to Spec 109-i and is fixed in ServersView.swift, which both specs touch.

User-visible changes (macOS app)

  • R1, Forget: the sheet now runs the forget itself and always shows the outcome, with the Web UI's wording. A credential that was revoked while its config entry could not be removed shows a warning ("Credential revoked; the config entry could not be removed: ...") instead of closing silently. A Close button dismisses it, the list reloads either way, and the result is announced to VoiceOver. New accessibility ids: forget-result, forget-close.
  • R2, Try it: a new, never-saved profile now offers Try it (the draft is sent to POST /profiles/try without a name). A new profile has no tool table because there is no saved profile to compute effective tools for. The editor layout is driven by ProfileEditorModel.sections.
  • R3, Reload: "Changed elsewhere - Reload" now discards the draft and adopts the saved profile. Before, it raised the banner again. Edits typed while the reload is in flight are kept and re-raise the marker, so a draft is never overwritten without a click.
  • R4, Assign: the sheet sends the profile and the wanted lock in one PUT /clients/{id}/binding, so it can change only the lock of a client already on the profile. When the binding already matches, nothing is sent and the sheet says "already on ...".
  • R5, Anonymous callers: saving adopts only the anonymous_profile key in the Settings store (ConfigStore.adoptSaved) instead of reloading everything, so other unsaved edits on the same tab survive. The Raw tab still shows the saved value.
  • R6, Admin-key upgrade: changing the profile after a preview drops the preview (a generation counter also drops a late response), disables Apply, and loads a fresh preview. Apply sends exactly the previewed request.
  • F4.1 and F6.1, toolbar "+ -> Server": the hand-off and pending routes are consumed by ServersView.body, which stays mounted, so the Add Server sheet opens over an open server detail and is no longer replayed when the detail closes. A route that arrives while a detail is open is consumed immediately.

Decisions

  • F6.1 is folded in because it has the same root cause and fix as F4.1.
  • The duplicate .onReceive(.showAddServer/.showServerDetail) handlers inside serverListView are left as they are; they are harmless and will be tracked as a low follow-up.
  • The checklist lines for docs/development/macos-tray.md stay with the docs PR (108-l, T124).

Tests

All new tests were written first. Red was a compile failure for the model, section and settings tests (missing ForgetResult, assign, AssignOutcome, sections, adoptSaved, commitSaved); the two source-guard tests for the toolbar hand-off failed at runtime before the ServersView change.

  • ClientBindingModelTests: Forget result texts and announcement, Assign (one request, lock-only change, unchanged sends nothing, refused without a client credential, guard refusal kept, note wording), upgrade preview invalidation, previewed profile is what Apply sends, a late preview is dropped.
  • ProfileEditorModelTests: Reload adopts the server version, edits during a reload are kept, sections for new and existing profiles, Try on a new profile sends the unsaved draft, the view renders model.sections.
  • AnonymousProfileSectionTests: unrelated unsaved edits survive a save, adoptSaved before load is a no-op, the section never calls store.load().
  • ServersViewRoutingTests: the add hand-off and route consumers live on body, not serverListView.

swift build and the full swift test suite pass (1611 tests).

…de, settings edits, upgrade preview, toolbar add (Spec 108-retro-mac)

Forget shows its result (and a disconnect_error warning) in the sheet. A new profile gets Try it. Reload discards the draft and adopts the saved profile. Assign sends profile and mode in one binding change. Saving Anonymous callers adopts only its own key. A profile change invalidates the admin-key upgrade preview. The toolbar plus hand-off and pending routes are consumed while a server detail is open.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Deploying mcpproxy-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: dcf1a39
Status: ✅  Deploy successful!
Preview URL: https://09b922de.mcpproxy-docs.pages.dev
Branch Preview URL: https://108-retro-sol-fixes-macos.mcpproxy-docs.pages.dev

View logs

F1.1: ClientBindingModel.forget() and finalizeRotation() now clear
guardRefusal (not only errorMessage), so a stale binding refusal from an
earlier row action no longer shows in the Forget sheet and masks the real
failure.

F3.1: ServersView mounts ServerDetailView with .id(server.id), so a
.serverDetail route or notification for another server while a detail is
open remounts the detail instead of leaving it on the old server.
@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

📦 Build Artifacts

Workflow Run: View Run
Branch: 108-retro-sol-fixes-macos

Available Artifacts

  • archive-darwin-amd64 (31 MB)
  • archive-darwin-arm64 (28 MB)
  • archive-linux-amd64 (18 MB)
  • archive-linux-arm64 (17 MB)
  • archive-windows-amd64 (31 MB)
  • archive-windows-arm64 (27 MB)
  • frontend-dist-pr (0 MB)
  • installer-dmg-darwin-amd64 (26 MB)
  • installer-dmg-darwin-arm64 (24 MB)
  • smart-mcp-proxymcpproxy-goULIHZD.dockerbuild (0 MB)

How to Download

Option 1: GitHub Web UI (easiest)

  1. Go to the workflow run page linked above
  2. Scroll to the bottom "Artifacts" section
  3. Click on the artifact you want to download

Option 2: GitHub CLI

gh run download 36832713361 --repo smart-mcp-proxy/mcpproxy-go

Note: Artifacts expire in 14 days.

@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@github-actions github-actions Bot 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.

Approved (Model B): Paperclip review verdicts = ACCEPT and qa-gate green at this head SHA. Arming auto-merge; GitHub merges when all required checks pass.

@github-actions
github-actions Bot merged commit 3ad5a87 into main Oct 1, 2026
62 of 63 checks passed
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