daybook/artifacts/migrations
peter 4254164bef v0.5.0: Trash (soft-delete) + Keep folder
Delete now moves an artifact to a recoverable Trash instead of hard-removing.

- Model: Artifact.deleted_at (nullable, indexed) = in Trash.
- Soft-delete everywhere: DELETE /api/artifacts/{id} sets deleted_at
  (idempotent 204); session POST /a/{id}/delete for the feed's hover Delete
  icon; POST /a/{id}/undelete restores; POST /feed/empty-trash purges.
- Trashed artifacts are off-quota (deleting frees quota) and eviction-protected
  (never evicted early); hidden from feed, sources, counts, and all API reads
  (list/detail/raw).
- Sidebar: "Deleted" and "Keep" system folders at the bottom (counts, hidden
  when empty); ?folder=deleted / ?folder=keep views reuse the row rendering.
  Deleted view has hover Undelete + an Empty Trash button. Keep = view over
  is_kept. Live-poll disabled in folder views.
- Docs (api.md delete section, CLAUDE.md), 10 new/updated tests. 150 passing;
  API soft-delete lifecycle verified live.

Purge is manual (Empty Trash) this release; auto purge-on-delete (background,
~3-day retention) is the planned fast-follow.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-09-07 12:48:43 +01:00
..
0001_initial.py Initial public commit 2026-09-01 21:55:02 +01:00
0002_artifact_metadata_artifact_source_id_and_more.py Initial public commit 2026-09-01 21:55:02 +01:00
0003_tagcolor.py Initial public commit 2026-09-01 21:55:02 +01:00
0004_rename_persona_to_source.py Initial public commit 2026-09-01 21:55:02 +01:00
0005_add_owner_nullable.py Initial public commit 2026-09-01 21:55:02 +01:00
0006_backfill_owner.py Initial public commit 2026-09-01 21:55:02 +01:00
0007_owner_required.py Initial public commit 2026-09-01 21:55:02 +01:00
0008_artifact_read_at.py Initial public commit 2026-09-01 21:55:02 +01:00
0009_quota_and_keep.py Initial public commit 2026-09-01 21:55:02 +01:00
0010_backfill_sizes_and_profiles.py Initial public commit 2026-09-01 21:55:02 +01:00
0011_add_asset.py Initial public commit 2026-09-01 21:55:02 +01:00
0012_alter_artifact_kind.py Add json and csv artifact kinds with interactive viewers 2026-09-02 14:56:20 +01:00
0013_artifact_share_token.py Add per-artifact public sharing 2026-09-02 16:00:39 +01:00
0014_apikey.py Release v0.2.0: multiple named API keys per user 2026-09-04 10:52:43 +01:00
0015_migrate_tokens_to_apikeys.py Release v0.2.0: multiple named API keys per user 2026-09-04 10:52:43 +01:00
0016_artifact_deleted_at.py v0.5.0: Trash (soft-delete) + Keep folder 2026-09-07 12:48:43 +01:00
__init__.py Initial public commit 2026-09-01 21:55:02 +01:00