{"record":{"id":"dd386112e795089b","repo":"deepseek-ai/deepseek-harness","slug":"web-aborted-dd3861","errorCode":"WEB_ABORTED","errorMessage":"Perplexity search aborted","messagePattern":"Perplexity search aborted","errorType":"exception","errorClass":"WebError","httpStatus":null,"severity":"error","filePath":"packages/web/web-search-perplexity/src/provider.ts","lineNumber":122,"sourceCode":"      response = await fetch(`${this.options.baseURL}/chat/completions`, {\n        method: 'POST',\n        redirect: 'error',\n        headers: {\n          'authorization': `Bearer ${this.options.apiKey}`,\n          'content-type': 'application/json',\n          'accept': 'application/json',\n          'user-agent': USER_AGENT,\n        },\n        body: JSON.stringify({\n          model: this.options.model,\n          max_tokens: this.options.maxTokens,\n          messages: [{ role: 'user', content: request.query }],\n          ...this.options.searchRecency !== undefined ? { search_recency_filter: this.options.searchRecency } : {},\n        }),\n        ...signal !== undefined ? { signal } : {},\n      })\n    } catch (error: unknown) {\n      if (isAbortError(error)) throw new WebError('Perplexity search aborted', 'WEB_ABORTED', { cause: error })\n      throw new WebError(`Perplexity search request failed: ${String(error)}`, 'WEB_PROVIDER_ERROR', { cause: error })\n    }\n\n    if (!response.ok) {\n      const status = response.status\n      let message = `Perplexity API error (HTTP ${status})`\n      try {\n        const parsed = await response.json() as PerplexityError\n        const detail = typeof parsed.error === 'string' ? parsed.error : parsed.error?.message ?? parsed.message\n        if (detail !== undefined && detail.length > 0) message = detail\n      } catch (error: unknown) {\n        // An abort fired mid-body must surface as WEB_ABORTED, not be swallowed\n        // into a generic HTTP-error message — cancellation is not a provider\n        // error (the seam's cancellation contract).\n        if (isAbortError(error)) throw new WebError('Perplexity search aborted', 'WEB_ABORTED', { cause: error })\n        // Otherwise: the HTTP status is already captured in `message` above; a\n        // malformed/non-JSON error body (normal for gateway 5xx/429s) can only\n        // cost a richer provider message, never the real error.","sourceCodeStart":104,"sourceCodeEnd":140,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/web/web-search-perplexity/src/provider.ts#L104-L140","documentation":"Error \"Perplexity search aborted\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/web/web-search-perplexity/src/provider.ts:122 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Retry the Perplexity search without aborting, or handle the abort as a cancelled search."],"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"}