Skip to content

Define and implement completed-todo retention #478

Description

@ladislas

Summary

Define and implement completed-todo retention. Priority: P2.

Motivation

Todo garbage collection ages closed items from creation time. A month-old item closed now can be deleted at the next session startup; the focused reproduction demonstrated this behavior. Retention should explicitly define which lifecycle event starts the clock.

Reviewed source: extensions/todos/storage.ts. Revalidate against current main before implementation.

Acceptance Criteria

  • Record the retention-policy decision, including the treatment of legacy closed todos; completion-based retention is the proposed default.
  • Implement the agreed policy, including close/reopen/reclose transitions and a conservative migration that does not invent historical completion dates.
  • Respect disabled GC and configured retention duration, and preserve open or concurrently reopened/edited items.
  • Lifecycle tests cover old-created freshly closed items, genuinely expired closed items, reopening, legacy data, and disabled GC.
  • Document retention and migration behavior for users.

Scope and verification

Resolve the lifecycle policy before implementation. Keep storage/locking changes proportional to the identified deletion risk.

Run affected regression coverage and required repository checks for any implementation; update relevant documentation/changelog under repository conventions. Record measurements and decisions durably in this issue or its linked PR.

Type

HITL — requires a policy or design review informed by the investigation before committing to the implementation approach. Investigation can proceed autonomously; publication follows existing authorization rules.

Parent

#466

Blocked by

None — investigation can start immediately; implement after the policy/design review described above.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestpac:hitlpac execution: requires human-in-the-loop decisions or approval

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions