CopilotKit / CopilotKit/outpost
Worker: unregistered job types are never claimed, so the no-handler failure path is dead
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 7
- Forks
- 3
- Avg merge
- 7d 16h
- Merged PRs (30d)
- 15
Description
packages/outpost/queue/src/worker.ts has a branch that marks a job FAILED with "No handler registered for job type: X". Under per-type claiming that branch is unreachable in production: the claim query only asks for types that have a registered handler, so a job of an unregistered type is never claimed at all. It sits PENDING forever — no failure, no dead letter, no log.
This is live today: TICKET_CLASSIFY has no handler registered in apps/worker/src/index.ts. Anything that enqueues it accumulates silently.
Two things to decide:
- Should an unregistered type fail loudly (claim it and mark
FAILED, matching the existing branch's intent) or be swept by a periodic reaper? - Is
TICKET_CLASSIFYstill wanted?handleAiResponseperforms classification inline, so the separate job type may be vestigial — in which case remove it fromJobTyperather than leaving a job type nothing consumes.
Found by: CR round 2 on #150 (slots 1-2, 2-1, 4-1, 5-1).
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with packages/outpost/queue/src/worker.ts and inspect the claim query and existing no-handler failure branch. Check apps/worker/src/index.ts for registered job types and trace TICKET_CLASSIFY through handleAiResponse. Done requires a decided policy for unregistered types and a resolution for whether TICKET_CLASSIFY remains in JobType, with behavior that prevents such jobs from accumulating silently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- backend, distributed-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100