A restore on the live pasture: its own scenario, and two fixes it found
tools/pasture/scenarios/restore.sh backs the pasture up from the administrator's endpoint, then alice_restore deletes a post and makes another, mastouser follows her, she blocks bob_restore and carol_restore is made; the restore, asked for from the endpoint, keeps every protective act (19 checks). town.sh renew <peer> signs a peer's town accounts in again, since a restore ends every session. It found that a backup listed media files already missing when it was made, so verifying it failed and the restore was refused: a manifest now lists only the files it holds (refusals are cut to five lines). And a local post made after the backup now comes back as a deleted row, as a deletion leaves it, so it answers 410 and its id is never given again; DeletedObject holds remote tombstones only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LsXgEaXee4GCU1hwYgPJXw
This commit is contained in:
1 parent
9ad96f560d
commit
bdc8be4508
8 files changed
+133
-26
No files matched your search
@@ -5,6 +5,7 @@
|
||||
drive <peer> <user> <verb> '<json>' one action as one town account, printed as JSON
|
||||
stored <peer> <uri>... what a peer holds of each object (from its database, never fetching)
|
||||
seen <peer> <user> <uri>... what one account can see of each object
|
||||
renew <peer>... its accounts signed in again (after a PrivaPub restore ends every session)
|
||||
plan <spec> the deterministic plan of a spec, printed as JSON lines
|
||||
seed <spec> replays a spec's plan against the pasture, writing out/<run>/ledger.jsonl
|
||||
check [run] sweeps every peer for what the ledger expects
|
||||
@@ -47,6 +48,13 @@ def main(argv):
|
||||
rows = driver(args[0]).stored(args[1:])
|
||||
print(json.dumps({u: {k: v for k, v in r.__dict__.items() if k != "raw"} for u, r in rows.items()}, default=str))
|
||||
return 0
|
||||
if cmd == "renew":
|
||||
# a peer's town accounts signed in again (a PrivaPub restore ends every session): new tokens, nothing else
|
||||
for platform in args:
|
||||
stored = state.sessions(platform)
|
||||
state.remember(driver(platform).provision([s.account for s in stored]))
|
||||
print(f"{platform}: {len(stored)} accounts signed in again")
|
||||
return 0
|
||||
if cmd == "seen":
|
||||
s = state.session(args[0], args[1])
|
||||
print(json.dumps(driver(args[0]).seen(s, args[2:])))
|
||||
|
||||
Reference in new issue
Block a user