Skip to content

feat(manager): read the subtree from the agent, and surface a delete that left host copies behind - #262

Merged
stormer78 merged 1 commit into
mainfrom
feat/context-preview-subcontexts-wire
Sep 19, 2026
Merged

stormer78 merged 1 commit into
mainfrom
feat/context-preview-subcontexts-wire

Conversation

@stormer78

Copy link
Copy Markdown
Contributor

Follows #261. Takes the two members trust-tasks 0.21.4 added (trustoverip/dtgwg-trust-tasks-tf#513), served by OpenVTC/verifiable-trust-infrastructure#1577.

The console stops deriving the cascade

#261 named the sub-contexts a delete would take, but had to work them out from contexts/list and match paths itself, because vta/contexts/preview-delete/1.0 had no member for them. It does now (subContexts), so descendantsOf goes.

This matters beyond tidiness. The agent decides what its cascade reaches; a console that computes that independently is a second implementation of the rule, sitting in front of an irreversible prompt. It agreed today — nothing kept it agreeing, and the disagreement would have shown up as a confirmation dialog that understated what was about to be destroyed.

A delete that isn't finished says so

contextDelete now returns daemonCleanupErrors: the DIDs whose records are gone while their published logs may still be served. A success that is not a completed deletion, which the specification says a consumer MUST surface — and which the client was dropping on the floor.

Tests

The render tests feed subContexts through the agent double instead of the records list, so what they pin is the panel's reading of the agent's answer rather than its own path matching. Two new core tests cover the cleanup report in both casings.

  • npm run lint (tsc -b, all workspaces) — clean
  • npm test — 1528 tests across five workspaces, 0 failures
  • npm run build — clean

Ordering

Independent of #1577 in the sense that nothing breaks if this lands first: the members are optional, absent reads as empty, and the panel renders correctly either way. But the console only shows sub-contexts once an agent on #1577 is serving them, so there is no reason to land this ahead of it.

`vta/contexts/preview-delete/1.0` gained `subContexts` in trust-tasks
0.21.4, so the console no longer derives the cascade from the context
list — the agent decides what the deletion reaches, so the agent is the
one that should name it.

`vta/contexts/delete/1.0` gained `daemonCleanupErrors`: DIDs whose host
copy the agent could not confirm removing. A success carrying a
non-empty list is not a finished deletion, and the spec says a consumer
MUST surface it, so it is returned rather than dropped.

Signed-off-by: Glenn Gore <glenn.g@affinidi.com>
@stormer78
stormer78 merged commit 6f3e979 into main Sep 19, 2026
4 checks passed
@stormer78
stormer78 deleted the feat/context-preview-subcontexts-wire branch September 19, 2026 17:24
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.

1 participant