Skip to content

feat(desktop): guide connection activation into exact Scope selection - #2292

Merged
hidb4ai merged 4 commits into
oceanbase:masterfrom
jackie-cqz:fix/desktop-connection-scope-journey
Oct 30, 2026
Merged

hidb4ai merged 4 commits into
oceanbase:masterfrom
jackie-cqz:fix/desktop-connection-scope-journey

Conversation

@jackie-cqz

Copy link
Copy Markdown
Contributor

Which issue or RFC does this PR close?

Refs #2103 (existing-Server portion of PR 02-B), #2101 and RFC #1455. #2103 remains open for approved local setup/default-Scope handoff with #2117 and installed-platform acceptance.

This PR targets master independently of #2291 and uses the existing native state/IPC contract. #2291 separately supplies deployment identity isolation.

Rationale for this change

Saving, checking and activating a connection need distinct feedback, and successful activation should guide users into an exact authorized Scope. Previously activation left users in the editor without that handoff.

What changes are included in this PR?

  • Show separate save/check/activate/remove progress and save/check completion feedback. Saving and passive checking remain separate from activation.
  • Open the shared Scope picker after compatible, identity-verified activation. A successful exact selection opens Memory and focuses its heading; cancelling the guide restores the activation button without selecting a Scope.
  • Keep ordinary global Scope changes on the current page. Preserve cancelled drafts and discard an open connection draft after a confirmed successful Scope change.
  • Make rejected stale native states prevent activation/selection navigation. Preserve pending-operation protections, specific-profile navigation and per-operation restrictions.
  • Associate complete Scope IDs with selection buttons as accessible descriptions, distinguishing duplicate titles; add actionable empty-state guidance.
  • Adapt the installed WebDriver journey to the automatic Scope dialog and extend the real-Server probe to verify save/passive-check do not activate. Update both README locales and validation evidence.

Are there any user-facing changes?

Existing Server setup becomes save → check → explicitly activate → choose an exact Scope → Memory. Reopening still loads saved profiles without activating a private session. No public API, persisted-profile, credential or IPC format changes.

Local installation/lifecycle implementation and approved default-Scope handoff remain with #2117 and its producer dependencies. Readiness separation remains follow-up work under #2101/#2105.

How was this change tested?

Windows 10 x64, Python 3.11.15, Rust 1.95.0:

  • Frontend: 130 passed. Covers the complete English/Chinese journey, keyboard/focus, duplicate-title Scope descriptions, reopening, cancelled/confirmed drafts, partial support, rejected stale states and late Scope pages. These tests use jsdom and mocked native IPC.
  • TypeScript, lint, generated contract/icon drift, formatting and production build: passed.
  • Python contract/fixture tests: 7 passed. Rust formatting, Clippy with --all-targets -- -D warnings, native probe build and IPC drift: passed.
  • The built-wheel SQLite harness passed anonymous loopback, static Bearer, HTTPS with explicit CA/base path and enforced Provider. The native Manager verified saving and passive checking leave active unset, followed by explicit activation, exact Scope selection and Memory save/search/exact reads.
  • Server source: aedf7beb1ecff2ea1fade6ccdd8e4bf6a298f799; wheel SHA-256: fde108a81a872a6228aad54832f2cd8f899a53bb4a7ff5c321871891fdbc5b68. This used disposable fixture qualification with a dirty Desktop tree; executable/contract identities and limits are recorded in desktop/VALIDATION.md. Production qualification records are unchanged.
  • The updated installed WebDriver flow was not executed locally. Native WebView/vault, IME, screen readers, small-window/scaling and signed Windows 11/macOS acceptance remain platform work; native protocol execution does not establish installed UI acceptance.
  • uv run --no-sync prek run -a: all file hooks passed; default Windows type checking retains existing POSIX-only attribute diagnostics in unchanged Python files. ty check --python-platform linux: passed.

AI usage statement

OpenAI Codex (GPT-6) assisted with implementation, local review, testing and documentation. Commands and real-Server harnesses were executed locally; validation limits are recorded above.

Copilot AI balanced review requested due to automatic review settings October 28, 2026 08:24

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@hireview001 hireview001 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hidb4ai hidb4ai 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.

The new draft-discard regression has a reproducible timing failure that also fails the macOS CI job. Please stabilize it before merging; details inline.

await user.click(screen.getByRole("button", { name: "Scope B" }));
await answerConfirmation(user, true);
expect(screen.queryByRole("dialog")).toBeNull();
expect((screen.getByLabelText("连接名称") as HTMLInputElement).value).toBe(

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.

[P2] Await the connection draft reset before asserting its value

This assertion races the passive effect in Connections that resets the form when discardDraft changes. Closing the Scope dialog does not establish that this subsequent form update has completed. On head b55226e7, repeating this scenario 50 times reproduced 19 failures with Second draft instead of Second; the macOS ARM CI job fails at the same assertion. A probe that only awaited the reset with waitFor passed all 50 repetitions. Await the observable input reset (for example, with waitFor) before checking the remaining navigation behavior, and rerun the affected macOS check. This establishes a test synchronization defect, not evidence of a persistent production draft leak.

Copilot AI balanced review requested due to automatic review settings October 29, 2026 05:11

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@hireview001 hireview001 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@hidb4ai hidb4ai 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.

Re-reviewed e898e71. The earlier draft-reset test race is fixed by awaiting the observable input update, while the navigation and discard assertions remain intact. No blocking findings remain in this PR diff, and it adds no database tables or HTTP/MCP/IPC endpoints relative to the current base. Installed WebView/vault acceptance and the local-setup handoff remain separate qualification work.

Copilot AI balanced review requested due to automatic review settings October 30, 2026 07:14

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@hidb4ai
hidb4ai merged commit 607b656 into oceanbase:master Oct 30, 2026
14 of 15 checks passed
@hidb4ai hidb4ai added the 1.5.0 v1.5.0 release tracking label Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1.5.0 v1.5.0 release tracking

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants