Skip to content

feat(projects): archive projects instead of losing them; delete only unused ones (TL-907) - #107

Merged
Keloran merged 1 commit into
mainfrom
feat/tl-907-project-archive
Nov 19, 2026
Merged

Keloran merged 1 commit into
mainfrom
feat/tl-907-project-archive

Conversation

@Keloran

@Keloran Keloran commented Nov 19, 2026 •

Copy link
Copy Markdown
Member

A project created by accident couldn't be removed from the app. The only way out was DELETE /api/projects/{id}, which also wiped used projects, along with their boards, tickets and history.

Now:

  • Delete works only for a never-used project (no tickets, no sprints). A used one gets 409 project_used.
  • Archive (POST /api/projects/{id}/archive) takes a used project off the lists and keeps its history. Its boards' open sprints close and their planned sprints are dropped, the same as when a board is archived.
  • Restore (POST /api/projects/{id}/restore) puts it back.

All three are org admin only. GET /api/projects leaves archived projects out, and ?archived=true (admins) lists only them. Projects now include archived_at and deletable. Audit records project.archived and project.restored (migration 000119). Archived projects still count towards the plan limit.

The web page is in TrackLines/frontend (TL-908). Ships before the frontend.

Tests: go vet, go build and go test ./... all pass.

Created with Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

… (TL-907)

Accidentally created projects had no way out but a hard-delete API that
also wiped used projects. Delete is now limited to never-used projects
(409 otherwise), and used ones are archived instead, keeping history.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Keloran
Keloran merged commit b6ef3ea into main Nov 19, 2026
4 checks passed
@Keloran
Keloran deleted the feat/tl-907-project-archive branch November 19, 2026 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant