Stability & agent-UX: snapshot fingerprint + headless refresh, trash-first delete, settings diagnostics - #64
Merged
Conversation
…esh command
Two additive extensions to the ADR 020 v1 envelope, completing the agent
contract:
- Every snapshot write stamps an optional repo fingerprint ({ branch, head,
isDirty, staged, unstaged, untracked }) captured at write time via an
injectable provider wired from the GitProvider at activation, so agents
can compare repo.head against git rev-parse HEAD to detect staleness.
Fail-soft and all-or-nothing: any failed lookup omits the field; a
provider failure can never lose a snapshot. New GitProvider.getHeadCommit.
- Meridian: Refresh Latest Snapshots (meridian.latest.refresh) recomputes
all three reports through the router and rewrites .meridian/latest/
without opening any panel — snapshots no longer go stale waiting for a
human to render a webview. Semantics widen from 'latest = last rendered'
to 'latest = last computed'; pull-only, no daemon, no LM surface.
Docs: ADR 020 addendum, FEATURES.md, AGENTS.md template.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DfWfFUQrqAoH7xETXyRrtU
…manent deleteFile was a raw fs.unlink: a mis-confirmed Delete File lost the file permanently. createWorkspaceProvider now accepts an injected MoveToTrashFn (main.ts supplies vscode.workspace.fs.delete with useTrash) so the provider stays vscode-free; path-guard and the directory refusal are unchanged and run before the trash fn. Where the host filesystem has no trash (e.g. some remotes) deletion falls back to a permanent unlink with a logged warning, and the confirmation dialog wording now reflects the real semantics. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DfWfFUQrqAoH7xETXyRrtU
… per change Unknown keys, type-mismatched values, and malformed JSON in the workspace overrides file were silently ignored — a typo'd key simply did nothing, forever. Each reparse (keyed to the file's mtime, so at most once per file change) now audits the overrides and emits diagnostics through an injectable listener; main.ts wires it to a logger warn plus one line in the Meridian output channel. Read-time fall-through semantics are unchanged, including the JSON-null 'not supplied' idiom, which stays unflagged. Also caches a failed parse against the file's mtime — a malformed file was previously re-read and re-parsed on every readSetting() call. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DfWfFUQrqAoH7xETXyRrtU
scscodes
marked this pull request as ready for review
July 13, 2026 10:41
|
🎉 This PR is included in version 2.16.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Three high-ROI, low-impact improvements to stability and the human/agent report experience.
1. Latest-snapshot contract, completed for agents (ADR 020 addendum)
.meridian/latest/*.v1.jsonwrite now stamps an optionalrepo: { branch, head, isDirty, staged, unstaged, untracked }captured at write time. Agents comparerepo.headagainstgit rev-parse HEADto know whether a snapshot predates recent commits, instead of guessing from wall-clockgeneratedAt. Fail-soft and all-or-nothing: any failed lookup omits the field; a fingerprint failure can never lose a snapshot. Resolved through an injectable provider wired from the GitProvider at activation —latest-snapshot.tsstaysvscode-free and never shells git. NewGitProvider.getHeadCommit().Meridian: Refresh Latest Snapshots(meridian.latest.refresh). Snapshots previously refreshed only when a human rendered a webview. The new palette command dispatches all three report commands through the router and rewrites the snapshots without opening a panel (analytics first, so the briefing reuses the warmed analyzer cache). Semantics widen from "latest = last rendered" to "latest = last computed" — still pull-only, no daemon, no LM surface (the ADR 012 posture is untouched). Reports tree freshness rows update automatically.Both are additive within the v1 envelope. ADR 020 addendum + FEATURES.md + generated AGENTS.md template updated.
2. Trash-first file deletion
WorkspaceProvider.deleteFilewas a rawfs.unlink— a mis-confirmed Delete File was unrecoverable. Deletion now routes through an injectedMoveToTrashFn(vscode.workspace.fs.deletewithuseTrash), falling back to permanent unlink with a logged warning where the host filesystem has no trash. Path-guard and the directory refusal are unchanged and run first. Confirmation dialog wording updated to match the real semantics.3.
.meridian/settings.jsonmisconfiguration diagnosticsUnknown keys, type-mismatched values, and malformed JSON were silently ignored — a typo'd key did nothing, forever. Each reparse (keyed to file mtime, so at most once per file change) now audits the overrides and reports findings via one line in the
Meridianoutput channel + a logger warn. Read-time fall-through semantics unchanged (including the JSON-null"not supplied" idiom). Bonus fix: a malformed file was re-read and re-parsed on everyreadSetting()call; the failed parse is now cached against its mtime.Verification
tsc --noEmitclean;npm run bundle(esbuild) clean.🤖 Generated with Claude Code
https://claude.ai/code/session_01DfWfFUQrqAoH7xETXyRrtU
Generated by Claude Code