Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
ac2655c
docs: record first connection lifecycle UX decisions
tnaum-ms Nov 27, 2026
dd11ca7
docs: record implementaiton plan for ux issues
tnaum-ms Nov 27, 2026
1d8b12a
docs: record iteration 2 WI-0 operator approvals
tnaum-ms Nov 27, 2026
5d00558
fix: WI-4 clarify retained-content and saved-password wording
tnaum-ms Nov 27, 2026
e4a6ad3
fix: WI-5 unify readable connection and worker statistics
tnaum-ms Nov 27, 2026
e586744
docs: record WI-4 WI-5 outcomes and WI-1 expansion deferral
tnaum-ms Nov 27, 2026
2e3a74a
docs: align WI-4 copy and index approved lifecycle UX decisions
tnaum-ms Nov 27, 2026
57f96b2
fix: WI-1b keep tree command failures in one modal
tnaum-ms Nov 27, 2026
6a1de16
docs: record WI-1b and first lifecycle batch verification
tnaum-ms Nov 27, 2026
773b055
docs: record WI-6 parsing approval and WI-3 runtime control constraint
tnaum-ms Nov 27, 2026
a2eba52
fix: WI-2a clarify retained Shell and Playground recovery guidance
tnaum-ms Nov 27, 2026
08e591e
docs: record WI-2a outcome and approved Retry and completion scopes
tnaum-ms Nov 27, 2026
6d2e107
fix: WI-3 keep Retry feedback and actions within the unavailable episode
tnaum-ms Nov 27, 2026
515a011
docs: record WI-3 sticky Retry outcome and recovery guidance
tnaum-ms Nov 27, 2026
c77ba21
fix: WI-1c-tree refresh and explain explicit stale recovery actions
tnaum-ms Nov 27, 2026
b928ee4
docs: record WI-1c-tree outcome and preserved worker guards
tnaum-ms Nov 27, 2026
aea0810
feat: WI-6 open an unauthenticated diagnostic Shell from failure rows
tnaum-ms Nov 27, 2026
e57fe68
docs: record WI-6 outcome and anonymous recovery boundaries
tnaum-ms Nov 27, 2026
0a01a24
fix: WI-1c-worker explain failed stale recovery on its own surface
tnaum-ms Nov 27, 2026
039c1cb
test: WI-3 fixture acknowledge Document View dirty-state reports
tnaum-ms Nov 27, 2026
92d6896
docs: record worker recovery outcome and browser fixture repair
tnaum-ms Nov 27, 2026
6959c70
chore: update localization for lifecycle UX changes
tnaum-ms Nov 27, 2026
9d43473
fix: WI-2b separate disconnect status from retained Shell input
tnaum-ms Nov 27, 2026
e3d425f
docs: finalize lifecycle UX work items, verification and usage
tnaum-ms Nov 27, 2026
6a8ad87
chore: format lifecycle UX changes for Case 2
tnaum-ms Nov 27, 2026
9553a38
Fix lint scope for nested Git worktrees
tnaum-ms Nov 27, 2026
feb640c
fix: resolve scoped Case 2 lint diagnostics
tnaum-ms Nov 27, 2026
dec9ac6
docs: record Case 2 verification and lint worktree fixes
tnaum-ms Nov 27, 2026
405b200
docs: record accepted PR1146 refinements and deferred C01/C02
tnaum-ms Nov 27, 2026
70c095b
docs: include C01/C02 after operator scope correction
tnaum-ms Nov 27, 2026
233fe56
docs: record advised PR1146 implementation mapping
tnaum-ms Nov 27, 2026
1fdcfd4
fix(C04): keep stale Playground feedback on its owning connection
tnaum-ms Nov 27, 2026
2688f86
fix(C06): keep genuine sign-in dismissal quiet after supersession
tnaum-ms Nov 27, 2026
5742662
docs: record C04/C06 verification and per-thread replies
tnaum-ms Nov 27, 2026
476e651
fix(C01): allow diagnostic auth holds through worker startup
tnaum-ms Nov 27, 2026
7c1dd1a
docs: record C01 startup verification and thread reply
tnaum-ms Nov 27, 2026
61f09ff
fix(C11): avoid duplicate modals for index command failures
tnaum-ms Nov 27, 2026
6f03170
docs: record C11 feedback ownership verification and reply
tnaum-ms Nov 27, 2026
e3bd77b
fix(C02): bind VM diagnostic Shell to the attempted endpoint
tnaum-ms Nov 27, 2026
c952e96
fix(C03): explain stale diagnostic Shell actions from current state
tnaum-ms Nov 27, 2026
bd70e32
fix(C08): keep anonymous Shell startup failures in the terminal
tnaum-ms Nov 27, 2026
3ed042b
docs: record C02 C03 C08 verified outcomes and thread replies
tnaum-ms Nov 27, 2026
ce2cf8d
fix(C07): restore the cursor with retained Shell input
tnaum-ms Nov 27, 2026
30645a8
docs: record C07 cursor verification and link the refinement review
tnaum-ms Nov 27, 2026
0adff1a
docs: clarify C09 async feedback render-origin sequence
tnaum-ms Nov 27, 2026
ba0820e
docs: record individual C05 C10 C12 no-code thread outcomes
tnaum-ms Nov 27, 2026
b32d0a0
fix(C09): preserve Shell input during asynchronous sign-in feedback
tnaum-ms Nov 27, 2026
b89c031
docs: record completed refinement checks and lead usage
tnaum-ms Nov 27, 2026
e33bb7b
chore: format accepted refinements for Case 2
tnaum-ms Nov 27, 2026
2589ec7
test(C11): keep primitive and cleanup fixtures lint-safe
tnaum-ms Nov 27, 2026
209a162
docs: record successful Case 2 refinement verification
tnaum-ms Nov 27, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/skills/error-translation/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,11 @@ A cluster item's first-connect catch must render through `showClusterConnectFail
it **before** evicting `CredentialCache` or deleting the client: the Entra and Atlas providers read
the cached credentials.

The failure-row anonymous diagnostic Shell must not ask credential-backed explainers about a
different saved authentication context. Its pre-terminal failures use one modal directly at the
command call site; later driver failures stay in the terminal. Preserve the raw safe server
rejection, never reinterpret it as rejected saved credentials or fall back to saved authentication.

### Do not call it from background paths

Background work shows nothing, so translating there costs I/O for no benefit. Leave these alone:
Expand Down
10 changes: 8 additions & 2 deletions .github/skills/tree-cluster-architecture/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ router, shell, playground, task, or clipboard state.
- Shell and playground workers may keep their own connection, but pin the originating identity and
obey the same fingerprint and epoch checks when they respawn.

The failure-row **Open shell without authentication** entry is separate from normal authenticated
Shell startup. It binds to a sanitized endpoint and re-reads it with epoch/latch checks, without
`CredentialCache`, an authentication pin or a token relay. Only credential-rejection/sign-in/missing
credential holds may be bypassed; Disconnect, removal and updates still block it. Keep local
completion behavior, but exclude shared authenticated metadata and credential-backed explainers.

## Design Rendering and Lookup Together

When adding a cluster hierarchy or a tree/list mode, specify these four functions before coding:
Expand Down Expand Up @@ -202,7 +208,7 @@ If a command is intentionally unavailable, gate it explicitly with context value
The tree shows **actions, never error or information rows**. When expanding a cluster fails, the
reason goes in a **modal** (`showErrorMessage(..., { modal: true, detail })`, translated through
`ErrorExplanationService` where available). The children are only recovery actions:
"Diagnose connection…", "Open shell" (on every failure, so experts can debug
"Diagnose connection…", "Open shell without authentication" (on every failure, so experts can debug
in the shell even when connecting or sign-in failed), and provider-owned
actions such as "Update credentials…" via `errorRecoveryActions`
(`ClusterItemBase.createErrorRecoveryChildren`).
Expand All @@ -211,7 +217,7 @@ Keep a fixed relative order: configuration/targeted repairs, diagnosis/inspectio
destructive recovery, and **Retry always last** (including "Retry setup…").
Providers prepend repairs; **Update connection string** precedes **Update credentials** when both
exist. Then `ClusterItemBase` renders **Retry sign-in** when a verified Entra identity can recover,
followed by **Diagnose connection…** and **Open shell**. **Retry** is last. When **Retry sign-in** or
followed by **Diagnose connection…** and **Open shell without authentication**. **Retry** is last. When **Retry sign-in** or
the stored-credential rejection action replaces Retry, do not add an ordinary Retry row too.
Failure classification changes availability, never ordering. When healthy resources coexist with
recovery actions, render the healthy resources first and the recovery block last.
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
### New Features & Improvements

- **Resilient Connections**: Renews Microsoft Entra ID tokens silently, refreshes Azure discovery credentials, and replaces closed or transient failed clients with the same binding on a later foreground operation. [#990](https://github.com/microsoft/vscode-documentdb/issues/990), [#1102](https://github.com/microsoft/vscode-documentdb/issues/1102)
- **Explicit Connection Teardown**: Adds Disconnect and Reconnect, a shared disconnect and deletion flow, a Close all or Keep open (disabled) choice, and protection for active copy, export, or import work. [#566](https://github.com/microsoft/vscode-documentdb/issues/566), [#1059](https://github.com/microsoft/vscode-documentdb/issues/1059)
- **Explicit Connection Teardown**: Adds Disconnect and Reconnect, a shared disconnect and deletion flow, a Close all or Keep open choice, and protection for active copy, export, or import work. [#566](https://github.com/microsoft/vscode-documentdb/issues/566), [#1059](https://github.com/microsoft/vscode-documentdb/issues/1059)
- **Identity-Bound Open Views**: Keeps open views and editor state tied to the connection that created them. Expired sign-in or unavailable connections receive bounded recovery, while changed saved settings require a new view instead of changing identity behind it. [#1102](https://github.com/microsoft/vscode-documentdb/issues/1102)

## 1.1.0
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -541,6 +541,7 @@ Case 2 is also where the AI pre-review in [§6](#6-ai-assisted-review-workflow)
- **`npm run l10n`** regenerates the localization bundle from the strings passed to `vscode.l10n.t()`. **Never resolve a conflict in `l10n/bundle.l10n.json` by hand** — the file is generated. Take either side, or delete it, then re-run `npm run l10n` and commit the result.
- **`npm run l10n:check`** validates localization against the source without regenerating files. Run it even when no strings changed, matching CI.
- **`npm run prettier-fix`** covers Markdown as well as source, so documentation formatting does not drift whenever a file is touched. Fenced code blocks are left exactly as authored: they are often partial or illustrative, and reformatting them to the Markdown tab width would leave every example disagreeing with the code it documents.
- **`npm run lint`** checks the current checkout, including new source files, and skips nested Git worktrees and clones. To lint another worktree, run the command from that worktree.
- **`npm run typecheck:tests`** checks every participating workspace's tests with its own TypeScript configuration, including strict checks that the root build and Vitest runtime do not cover.
- **`npm run package`** catches Vite host and webview bundling issues and missing assets that unit tests alone will not surface.

Expand Down
1 change: 1 addition & 0 deletions build/verification/browser/fixtures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -541,6 +541,7 @@ export const fixtures = {
],
rpc: {
...common,
'mongoClusters.documentView.reportDirty': reply('mutation', null),
'mongoClusters.documentView.getDocumentById': reply<
Outputs['mongoClusters']['documentView']['getDocumentById']
>('query', JSON.stringify({ _id: 'stage0-1', name: 'Stage 0 document payload', quantity: 7 }, null, 2)),
Expand Down
2 changes: 1 addition & 1 deletion build/verification/browser/scenarios.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2709,7 +2709,7 @@ const collectionViewScenarios = {
selector: '.disconnectedOverlayBackground',
attribute: 'inert',
expected: null,
steps: [{ action: 'click', role: 'button', name: 'Dismiss dialog to copy view contents' }],
steps: [{ action: 'click', role: 'button', name: 'Dismiss dialog to access view contents' }],
},
{
kind: 'text',
Expand Down
39 changes: 39 additions & 0 deletions build/verification/eslint-worktrees.test.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/

const { deepStrictEqual } = require('node:assert/strict');
const { mkdtempSync, mkdirSync, rmSync, writeFileSync } = require('node:fs');
const { tmpdir } = require('node:os');
const { join, resolve } = require('node:path');
const { test } = require('node:test');
const { ESLint } = require('eslint');

test('ESLint checks the current checkout but not nested Git checkouts', async (t) => {
const root = mkdtempSync(join(tmpdir(), 'documentdb-eslint-'));
t.after(() => rmSync(root, { recursive: true, force: true }));

const source = join(root, 'src');
const worktree = join(root, 'nested worktree');
const clone = join(root, 'nested-clone');
mkdirSync(join(root, '.git'));
mkdirSync(source);
mkdirSync(worktree);
mkdirSync(join(clone, '.git'), { recursive: true });
writeFileSync(join(worktree, '.git'), 'gitdir: ../.git/worktrees/nested\n');
const localFile = join(source, 'new.js');
const worktreeFile = join(worktree, 'worktree.js');
writeFileSync(localFile, '');
writeFileSync(worktreeFile, '');
writeFileSync(join(clone, 'clone.js'), '');

const overrideConfigFile = resolve(__dirname, '../../eslint.config.mjs');
const lintPaths = async (cwd) => {
const eslint = new ESLint({ cwd, overrideConfigFile });
return (await eslint.lintFiles(['.'])).map(({ filePath }) => filePath);
};

deepStrictEqual(await lintPaths(root), [localFile]);
deepStrictEqual(await lintPaths(worktree), [worktreeFile]);
});
32 changes: 24 additions & 8 deletions docs/ai-and-plans/features/connection-lifecycle/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,10 @@ entries are unpublished drafts and do not represent a shipped release.
the available credentials. Credential repair stays in the tree. Dismissing the dialog with
its **X** exposes the existing contents for copying without resuming database operations.
Trying another operation shows the dialog again. **Close view** asks for confirmation.
- **Do not remove Retry during an unavailable episode once it has been offered.** A failed attempt
or a runtime reason change keeps the control, while the reason remains truthful and host guards
still reject unsafe recovery. Dismissing the dialog does not reset this choice. Successful
recovery ends the episode; a later initially Close-only episode does not inherit Retry.
- After an explicit Disconnect, the tree offers **Reconnect**. If reconnecting automatically
opens the existing Dashboard for the same identity, it retries that view without replaying
an operation. Other retained views still require **Retry**.
Expand All @@ -96,6 +100,10 @@ entries are unpublished drafts and do not represent a shipped release.
- After a database rejects a verified Entra identity, discard the client but keep its in-memory
connection settings for explicit sign-in. Do not retain the rejected token or retry silently.
When the tree offers **Retry sign-in**, it does not also offer **Retry**.
- Failure rows offer **Open shell without authentication** as a separate diagnostic entry.
It never uses the failed saved authentication or shared authenticated metadata, and does not
promise that anonymous commands are authorized. Normal context-menu Shell startup is unchanged.
Pre-terminal failures use a tree modal; later failures stay in the terminal.
- **Disconnect and Remove Connection** share a teardown and a tab choice. Saving a change to
connection details (including a password-only change) in this window keeps old tabs open and
copyable, but they cannot recover. Open new tabs from the tree. Unchanged settings still
Expand All @@ -105,14 +113,16 @@ entries are unpublished drafts and do not represent a shipped release.

## Documents

| Document | Kind |
| ------------------------------------------------------------------------------ | --------- |
| [research-findings.md](./research-findings.md) | research |
| [decisions.md](./decisions.md) | decisions |
| [iterations/01-implementation-plan.md](./iterations/01-implementation-plan.md) | plan |
| [iterations/01-dev-plan.md](./iterations/01-dev-plan.md) | plan |
| [iterations/01-pr1136-final-review.md](./iterations/01-pr1136-final-review.md) | review |
| [iterations/01-pr1136-ux-review.md](./iterations/01-pr1136-ux-review.md) | ux-review |
| Document | Kind |
| ------------------------------------------------------------------------------------ | --------- |
| [research-findings.md](./research-findings.md) | research |
| [decisions.md](./decisions.md) | decisions |
| [iterations/01-implementation-plan.md](./iterations/01-implementation-plan.md) | plan |
| [iterations/01-dev-plan.md](./iterations/01-dev-plan.md) | plan |
| [iterations/02-ux-implementation-plan.md](./iterations/02-ux-implementation-plan.md) | plan |
| [iterations/02-pr1146-copilot-review.md](./iterations/02-pr1146-copilot-review.md) | review |
| [iterations/01-pr1136-final-review.md](./iterations/01-pr1136-final-review.md) | review |
| [iterations/01-pr1136-ux-review.md](./iterations/01-pr1136-ux-review.md) | ux-review |

## Decisions index

Expand All @@ -139,6 +149,11 @@ See [decisions.md](./decisions.md):
- 0019 require a fresh Dashboard delete after Disconnect and retain tree-only Paste.
- 0020 defer the late-failure comparison across releases and retain descriptive telemetry.
- 0021 key the in-memory connection fingerprint per extension host.
- 0022 separately unauthenticated Shell entry from failure rows only.
- 0023 keep failed retained-view Retry feedback inside the unavailable dialog.
- 0024 classify explicit stale recovery clicks without disturbing quiet background paths.
- 0025 use modal feedback for tree-origin commands, leaving webview feedback unchanged;
descendant expansion is deferred to #1143 until foreground attribution is supported.

## Timeline

Expand All @@ -151,3 +166,4 @@ See [decisions.md](./decisions.md):
| 2026-11-24 | WI-6 through WI-8 implement bound views, teardown and Dashboard behavior |
| 2026-11-25 | WI-2 review fixes and WI-9 lifecycle measurements |
| 2026-11-26 | WI-10 documentation draft, skill updates and unpublished 1.2.0 notes |
| 2026-11-27 | UX review findings organized into a draft implementation plan |
Loading
Loading