Description:
Soroban archives persistent entries whose TTL lapses, and they have to be restored before use. Build tests that force archival of each key type (the intent, solver, bond, fill history, proof, and idempotency keys) at every lifecycle stage. Assert that the contract behaves safely, either failing loudly or working after restore, and never silently treats archived as absent.
Problem Statement & Context:
"Absent" and "archived" look similar to naive code. An archived ExtensionGranted or proof replay key that reads as false or None enables a double extension or a replay.
Scope & Acceptance Criteria:
- A test per key type per relevant state, using the testutils ledger TTL controls.
- Identify every
has() / get().unwrap_or(default) whose default would be unsafe if the entry were archived, and fix each one (a longer TTL, a tombstone, or keeping it with the parent record).
- Document the findings in
docs/145-*.md or a new archival doc.
- Out of scope: off-chain restore automation.
Implementation Guidelines:
- Key Files/Modules: all contracts' storage helpers, and the test files.
- Design/Architecture: Replay and one-shot flags must live at least as long as the thing they guard.
- Edge Cases/Constraints: Behaviour differences between the test environment and the network for archived reads. Confirm them against the Soroban docs.
- Testing: As described in the scope.
Definition of "Done":
- Tests plus fixes merged, and the doc updated.
- Reviewed and approved.
Resources:
Complexity: High (200 points)
Description:
Soroban archives persistent entries whose TTL lapses, and they have to be restored before use. Build tests that force archival of each key type (the intent, solver, bond, fill history, proof, and idempotency keys) at every lifecycle stage. Assert that the contract behaves safely, either failing loudly or working after restore, and never silently treats archived as absent.
Problem Statement & Context:
"Absent" and "archived" look similar to naive code. An archived
ExtensionGrantedor proof replay key that reads asfalseorNoneenables a double extension or a replay.Scope & Acceptance Criteria:
has()/get().unwrap_or(default)whose default would be unsafe if the entry were archived, and fix each one (a longer TTL, a tombstone, or keeping it with the parent record).docs/145-*.mdor a new archival doc.Implementation Guidelines:
Definition of "Done":
Resources:
docs/ttl-constants-rationale.md,docs/145-ttl-bump-frequency-review.mdproof_registry's persistent storage #236, [High] Fix missing TTL management forCancelCooldown/MinBondMultiplier/ExtensionGranted/UserIntents#271Complexity: High (200 points)