Let claimants withdraw their own pending developer-profile claim - #165
Merged
Conversation
Adds POST /developers/claims/{id}/cancel, scoped to the caller's own
pending claim, so a claim can be retracted without waiting on a
moderator to reject it — needed alongside blocking "Create" on the
extensions account pages while a claim is outstanding, since a user
can only ever own one developer profile.
Claude-Session: https://claude.ai/code/session_01QaaK546yMRs9xgyGrnu7Vx
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
api | cae13e8 | Commit Preview URL Branch Preview URL |
Jul 28 2026, 06:52 PM |
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 2 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
The D1 mock had no branch for the new DELETE, so any test exercising it failed with a simulated DATABASE_ERROR; add the mock branch plus route tests for own/foreign/non-pending claims. Also narrows the cancel handler's error-status mapping to 404/500 (the shared statusFromErrorCode helper's 409 case doesn't apply here and doesn't match the route's declared responses). Claude-Session: https://claude.ai/code/session_01QaaK546yMRs9xgyGrnu7Vx
Contributor
There was a problem hiding this comment.
0 issues found across 3 files (changes from recent commits).
Auto-approved: Adds a self-service endpoint for claimants to cancel their own pending claims, scoped to the claimant and pending status. The change is bounded, well-tested, and clearly beneficial.
Re-trigger cubic
admdly
added a commit
that referenced
this pull request
Jul 30, 2026
main gained "Let claimants withdraw their own pending developer-profile claim" (#165) after this branch diverged, touching the same three files rewritten here for Drizzle. Auto-merge pasted the old raw db.prepare().bind().run() implementation in verbatim (git can't know it needs rewriting), so cancelClaim() is reimplemented against the Drizzle query builder to match rejectClaim()'s pattern, and its route handler now goes through getExtensionsDb() like every other v2 route. Also resolves a modify/delete conflict on the now-deleted mock-db.ts (kept deleted) and rewrites the three ported tests to use the db-fixtures helpers instead of the removed tables.* Map-mock API.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
POST /developers/claims/{id}/cancel, scoped to the caller's own claim andstatus = 'pending', so a claimant can withdraw a claim without waiting on a moderator to reject it.extensionsrepo that blocks "Create" on the account pages while a pending claim is outstanding — a user can only ever own one developer profile, so letting a create happen alongside a pending claim just sets up a future conflict at approval time.