feat(6243): a directory moved in the tree keeps its shape judgments
CI & Build / Python lint (push) Successful in 3s
CI & Build / Plugin hooks (push) Failing after 15s
CI & Build / TypeScript typecheck (push) Successful in 55s
CI & Build / integration (push) Successful in 1m15s
CI & Build / Python tests (push) Successful in 2m9s
CI & Build / Build & push image (push) Successful in 30s
CI & Build / Python lint (push) Successful in 3s
CI & Build / Plugin hooks (push) Failing after 15s
CI & Build / TypeScript typecheck (push) Successful in 55s
CI & Build / integration (push) Successful in 1m15s
CI & Build / Python tests (push) Successful in 2m9s
CI & Build / Build & push image (push) Successful in 30s
Ledger rows are keyed by path, so after a directory moves the next sync marks every judged row vanished and lists the same shapes again, unjudged. move_shapes(project_id, from_path, to_path) re-keys the rows under one path to the other, in every repo of the project, keeping each row's judgment, uses edges and history and adding a `moved` event that records the path it left. A row already at the target is replaced when nobody judged it; a judged one stands, and the old row is reported in `kept`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -41,6 +41,13 @@ row carries a status:
|
||||
nothing. Rows, never prose — a consumer list in a note or verification
|
||||
detail cannot be sorted, queried, or diffed.
|
||||
|
||||
Rows are keyed by repo and path, so a move in the tree is a move in the
|
||||
ledger. When a file or directory moves, run `move_shapes(project_id,
|
||||
from_path, to_path)` before the next refresh. For a repo renamed on its
|
||||
forge, run `bind_repo(new_url, project_id, moved_from=old_url)`. Otherwise
|
||||
the refresh marks every judged row vanished and lists the same shapes again,
|
||||
unjudged.
|
||||
|
||||
## The writer judges; audits check that it happened
|
||||
|
||||
The ledger is filled from your answers, given while you still know them. When
|
||||
@@ -157,8 +164,8 @@ Three questions the ledger answers mechanically:
|
||||
it), `variant` with the why if the departure is deliberate. The write-path
|
||||
hint asks the same question in-band the moment such a shape is written.
|
||||
- **History** — `shape_history(project_id, path, symbol?)`: the current rows
|
||||
plus every `classified` / `vanished` / `reappeared` / `drifted` event with
|
||||
its commit — "instance of #N from <date>, re-judged variant of #M because
|
||||
plus every `classified` / `vanished` / `reappeared` / `drifted` / `moved`
|
||||
event with its commit — "instance of #N from <date>, re-judged variant of #M because
|
||||
R, vanished at C". Rows, not recollection.
|
||||
- **Recheck** — `list_shapes(project_id, flag="recheck")`: judged
|
||||
instances/variants whose body changed since judged. The judgment stands;
|
||||
|
||||
Reference in New Issue
Block a user