{"record":{"id":"5135b63694f52147","repo":"deepseek-ai/deepseek-harness","slug":"feedback-text-must-not-be-empty","errorCode":null,"errorMessage":"feedback text must not be empty","messagePattern":"feedback text must not be empty","errorType":"validation","errorClass":"TypeError","httpStatus":null,"severity":"error","filePath":"packages/feedback/command-feedback/src/index.ts","lineNumber":74,"sourceCode":"declare module '@deepseek-ai/dsh-session/types' {\n  interface SessionEventMap {\n    /**\n     * One recorded human remark about this session. Log-only and independent\n     * of its trigger; it never enters model context or derived history.\n     */\n    'feedback/record': { text: string }\n  }\n}\n\n/**\n * Record feedback independently of any UI trigger.\n * @param session - session the feedback describes.\n * @param text - human-authored feedback; surrounding whitespace is discarded.\n * @throws {TypeError} when the normalized text is empty.\n */\nexport function recordFeedback(session: Session, text: string): void {\n  const normalized = text.trim()\n  if (normalized.length === 0) throw new TypeError('feedback text must not be empty')\n  session.append('feedback/record', { text: normalized })\n}\n\n/**\n * Validate, record, and acknowledge one feedback entry. Returning an error\n * leaves no `feedback/record` event.\n * @param invocation - receiving agent, raw command input, and UI cancellation.\n * @param ctx - plugin context used to read the optional telemetry service.\n * @returns an acknowledgement containing the receiving session and anonymous\n * user ids plus the session-sharing disclosure, or a usage error when no\n * feedback text was supplied.\n */\nfunction executeFeedbackCommand(invocation: CommandInvocation, ctx: Context): CommandResult {\n  if (invocation.rawInput.trim().length === 0) {\n    return { kind: 'error', text: `Feedback text is required. ${USAGE}` }\n  }\n  recordFeedback(invocation.agent.session, invocation.rawInput)\n  const telemetry = ctx.get('sessionTelemetry')","sourceCodeStart":56,"sourceCodeEnd":92,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/feedback/command-feedback/src/index.ts#L56-L92","documentation":"Error \"feedback text must not be empty\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/feedback/command-feedback/src/index.ts:74 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}