Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

🤖 drafts: empty-row edge cases in creation draft list cleanup (deferred from #5232)

Open
#5,239 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
typescript
Domain
backend

Research direction

Read src/node/services/draftService.ts, focusing first on deleteProjectDrafts, putListEntry, importLegacyList, and collectOrphanedCreationDrafts, along with the referenced review threads. Verify both re-added-project cleanup and orphan-directory failures leave no empty listed draft rows, while preserving the existing lock order and cleanup behavior.

Written by the indexing model from the issue text.

Description

backlog

Deferred from the #5232 round-4 review (creation draft list on the backend, src/node/services/draftService.ts). Both are narrow cases in project-removal cleanup that leave or drop an empty listed draft row; no typed input is involved. The coordinator stopped the review loop on #5232 after round 4 and deferred them here.

  1. Re-added project vs. removal cleanup (thread on deleteProjectDrafts). If the same project path is registered again while deleteProjectDrafts holds the project's drafts dir lock, putListEntry (which takes only the list lock) can list a new empty draft that the cleanup's delisting then removes. Fix shape: have putListEntry/importLegacyList take the project dir lock too (dir lock, then list lock, the existing order), or record a project generation and delist only rows older than the removal.
  2. List GC stops at the first failing orphan dir (thread on collectOrphanedCreationDrafts). If clearing one orphan project dir throws, the outer catch skips removeUnownedListEntries, so empty rows of unconfigured projects stay until the next start (and show again if that path is re-added). Fix shape: catch per directory, or run the list cleanup as its own guarded step.

Refs #5225


Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high • Cost: $31.20

Dominant language
TypeScript
Stars
2k
Forks
139
Avg merge
6h 58m
Merged PRs (30d)
774

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from coder/xum

All issues in coder/xum

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.