{"record":{"id":"6aebaab4e7966a3d","repo":"paperclipai/paperclip","slug":"missing-file-field-file-6aebaa","errorCode":null,"errorMessage":"Missing file field 'file'","messagePattern":"Missing file field 'file'","errorType":"http","errorClass":null,"httpStatus":400,"severity":"error","filePath":"server/src/routes/issues.ts","lineNumber":13677,"sourceCode":"  router.post(\"/issues/:id/comments\", validate(addIssueCommentSchema), 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\" && req.body.onBehalfOfUserId != null) {\n      await auditAgentIssueCommentAttributionSpoof({\n        db,\n        req,\n        issue,\n        surface: \"issue.comment.create\",\n        requestedValue: readNonEmptyString(req.body.onBehalfOfUserId),\n      });\n      await denyIssueWrite(req, res, issue, \"issue_write_attribution_spoof_rejected\");\n      return;\n    }\n    const commentAccessDecision = await assertAgentIssueCommentAllowed(req, res, issue);\n    if (!commentAccessDecision) return;\n    const commentAuthorizationReason = issueWriteAuthorizationReason(req, commentAccessDecision);\n    if (!assertStructuredCommentFieldsAllowed(req, res, {\n      presentation: req.body.presentation,\n      metadata: req.body.metadata,\n    })) return;\n    const closedExecutionWorkspace = await getClosedIssueExecutionWorkspace(issue);\n\n    const actor = getActorInfo(req);\n    const commentPresentation = req.body.presentation ??\n      await deriveRecoveryCommentPresentation(req, issue.companyId, req.body.body);\n    const reopenRequested = req.body.reopen === true;\n    const resumeRequested = req.body.resume === true;\n    const interruptRequested = req.body.interrupt === true;\n    const isClosed = isClosedIssueStatus(issue.status);\n    const isBlocked = issue.status === \"blocked\";\n    const crossIssueCommentOnlyGrant =\n      isClosed &&\n      (isDirectParentReportDecision(commentAccessDecision) ||\n        (req.actor.type === \"agent\" &&\n          issue.assigneeAgentId !== null &&","sourceCodeStart":13659,"sourceCodeEnd":13695,"githubUrl":"https://github.com/paperclipai/paperclip/blob/01ad8584922b5d85292b1723cae71fa0d9b07a19/server/src/routes/issues.ts#L13659-L13695","documentation":"400 from issue attachment upload. Fires when the multipart request completed but req.file is absent — no part was provided under the required field name 'file', so there is nothing to store.","triggerScenarios":"Thrown at server/src/routes/issues.ts:12658 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Include the required field(s) in the request path, query, or body as named by the error message, then retry.","Check the API contract in packages/shared validators for the exact required shape of this endpoint."],"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"}