{"record":{"id":"166f5003f174694a","repo":"paperclipai/paperclip","slug":"queued-comment-can-no-longer-be-canceled","errorCode":null,"errorMessage":"Queued comment can no longer be canceled","messagePattern":"Queued comment can no longer be canceled","errorType":"http","errorClass":null,"httpStatus":409,"severity":"error","filePath":"server/src/routes/issues.ts","lineNumber":12583,"sourceCode":"    if (!issue) return;\n    if (!(await assertIssueReadAllowed(req, res, issue))) return;\n    const interactions = await issueThreadInteractionService(db).listForIssue(id);\n    res.json(interactions);\n  });\n\n  router.post(\"/issues/:id/interactions\", validate(createIssueThreadInteractionSchema), async (req, res) => {\n    const id = req.params.id as string;\n    const issue = await getAccessibleResource(req, res, svc.getById(id), \"Issue not found\");\n    if (!issue) return;\n    if (req.actor.type === \"agent\") {\n      if (!(await assertAgentIssueMutationAllowed(req, res, issue, { allowVisibleIssueWrite: true }))) return;\n      if (await assertLowTrustControlPlaneDenied(req, res, issue.companyId, issue)) return;\n    } else {\n      assertBoard(req);\n    }\n\n    const actor = getActorInfo(req);\n    const agentSourceRunId = req.actor.type === \"agent\" ? requireAgentRunId(req, res) : null;\n    if (req.actor.type === \"agent\" && !agentSourceRunId) return;\n    if (\n      req.body.kind === \"request_confirmation\"\n      && req.body.addresseeAgentId\n      && req.body.payload?.toolAction !== undefined\n    ) {\n      throw badRequest(\"Tool-action confirmations cannot be addressed to agents\");\n    }\n    if (req.body.kind === \"request_confirmation\" && req.body.payload?.toolAction !== undefined) {\n      throw unprocessable(\"payload.toolAction is server-owned metadata and cannot be supplied when creating an interaction\");\n    }\n    if (req.body.kind === \"request_confirmation\" && req.body.payload?.secretProposal !== undefined) {\n      throw unprocessable(\"payload.secretProposal is server-owned metadata and cannot be supplied when creating an interaction\");\n    }\n\n    // Plan-document confirmation targets are validated authoritatively inside\n    // issueThreadInteractionService.create, which re-reads the plan document's\n    // latest revision and rejects a stale/missing target under the same insert","sourceCodeStart":12565,"sourceCodeEnd":12601,"githubUrl":"https://github.com/paperclipai/paperclip/blob/01ad8584922b5d85292b1723cae71fa0d9b07a19/server/src/routes/issues.ts#L12565-L12601","documentation":"409 on queued-comment cancel. Fires when the comment is owned by the actor and a cancel was requested, but the comment is no longer queued for the active run (already delivered/flushed or the run has moved past it), so cancellation is too late.","triggerScenarios":"Thrown at server/src/routes/issues.ts:11579 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Wait for the conflicting state to clear (running job, hold, pause, or stale fingerprint), refresh the current state, then retry the operation."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"01ad8584922b5d85292b1723cae71fa0d9b07a19","analyzedAt":"2026-08-18T22:49:45.177Z","contentChangedAt":"2026-08-18T22:49:45.177Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}