Skip to content

[Bug] No TTL extension on persistent Assertion storage #1

Description

@collinsezedike

Description

Persistent Assertion storage entries never have their TTL extended after creation. Only instance storage gets extend_ttl, at initialize. A long-lived Pending or Disputed assertion can have its ledger entry archived before dispute, finalize, or resolve is ever called on it, since nothing bumps its TTL in the meantime.

Steps to reproduce

  1. Deploy and initialize the contract with a long challenge_window_secs.
  2. Call assert_outcome to create an assertion.
  3. Let enough ledgers pass for the persistent entry's TTL to expire (no extend_ttl call happens anywhere on this entry).
  4. Attempt to call dispute, finalize, or resolve on that assertion id.

Expected behavior

The assertion should remain reachable and actionable for at least the duration of its challenge window, and ideally longer, to allow for resolver deliberation after a dispute.

Actual behavior

The persistent storage entry can be archived, since assert_outcome, dispute, finalize, and resolve never call extend_ttl on DataKey::Assertion(id).

Environment

  • Network: testnet / local
  • Contract: tholos
  • Commit or tag: v0.2.0

Possible impact

This affects fund availability: an asserter's bond could become practically unreachable if their assertion's storage entry is archived before it can be finalized or resolved. Not a fund theft issue, but a fund availability one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions