mirror of
https://github.com/sotashimozono/obsidian-remote-ssh.git
synced 2026-07-22 06:52:07 +00:00
Follow-up to the R1/R2/R3 shadow-vault fix, from a 6-agent review. - resolveLayout no longer reports a spurious migrated=true on every reconnect for a profile parked in a collision ` (2)` dir: the early-return now compares `found` to the collision-resolved target, not the bare `<name>--<tail>`, so it stops a no-op same-path rename + re-showing the one-time "restart Obsidian" notice. (code-reviewer) - findShadowByProfileId / uniqueVaultDir no longer silently swallow a transient read error on this profile's OWN data.json (AV / Dropbox lock / mid-write), which could fork a duplicate ` (2)` shadow and strand the real one. Extracted readShadowProfileId(): ENOENT stays silent (not a shadow), an existing-but-unreadable/malformed data.json is logged; also narrows a non-string id to "no match". (silent-failure-hunter, code-simplifier) - ObsidianRegistry.isOpen now fails SAFE: an unreadable obsidian.json is treated as OPEN (defer the rename) rather than "not open" (proceed and risk renaming a live vault — the corruption R2 prevents), and logs. (silent-failure-hunter) - Stale comments corrected: class layout diagram, BootstrapResult.migrated and layoutFor/findShadowByProfileId docs; sanitisePathTail's dead `~` guard made live so a bare `~` remotePath falls back to `vault`. (comment-analyzer) Tests: ObsidianRegistry.isOpen direct unit tests (open/closed/absent/ unregistered/unreadable-defer); collision-reconnect asserts migrated=false; sanitisePathTail `~` + backslash edges. tsc/lint/vitest green (1184). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| e2e | ||
| scripts | ||
| src | ||
| tests | ||
| esbuild.config.mjs | ||
| eslint.config.mjs | ||
| manifest.json | ||
| package-lock.json | ||
| package.json | ||
| styles.css | ||
| tsconfig.json | ||
| versions.json | ||
| vitest.config.ts | ||
| vitest.integration.config.ts | ||
| vitest.replay.config.ts | ||
| vitest.setup.ts | ||