Tencent/WeKnora · error
http list-engines status %d: %s
Error message
http list-engines status %d: %s
What it means
Protocol error in HTTPDocumentReader.ListEngines: the docreader answered the list-engines request with a non-200 status. The response body is read and included (%d status, %s body) so the docreader's error detail is visible; fires when the service is up but rejects the call (auth, bad overrides, internal error).
Source
Thrown at internal/infrastructure/docparser/http_parser.go:156
jsonBody, err := json.Marshal(body)
if err != nil {
return nil, fmt.Errorf("http marshal list-engines request: %w", err)
}
httpReq, err := http.NewRequestWithContext(ctx, http.MethodPost, base+PathListEngines, bytes.NewReader(jsonBody))
if err != nil {
return nil, fmt.Errorf("http new request: %w", err)
}
httpReq.Header.Set("Content-Type", "application/json")
resp, err := p.client.Do(httpReq)
if err != nil {
return nil, fmt.Errorf("http list-engines failed: %w", err)
}
defer resp.Body.Close()
if resp.StatusCode != http.StatusOK {
respBytes, _ := io.ReadAll(resp.Body)
return nil, fmt.Errorf("http list-engines status %d: %s", resp.StatusCode, string(respBytes))
}
var out httpListEnginesResponse
if err := json.NewDecoder(resp.Body).Decode(&out); err != nil {
return nil, fmt.Errorf("http decode list-engines response: %w", err)
}
result := make([]types.ParserEngineInfo, 0, len(out.Engines))
for _, e := range out.Engines {
result = append(result, types.ParserEngineInfo{
Name: e.Name,
Description: e.Description,
FileTypes: e.FileTypes,
Available: e.Available,
UnavailableReason: e.UnavailableReason,
})
}
return result, nilView on GitHub (pinned to 988cbb0330)
Solutions
- Read the embedded response body for the server's reason
- Check request overrides against supported engine options
- Retry for 5xx; fix the request for 4xx
Defensive patterns
Strategy: retry
When it happens
Trigger: Thrown at internal/infrastructure/docparser/http_parser.go:156 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Tencent/WeKnora@988cbb0330 (2026-09-02).
Data as JSON: /api/errors/c0a3a15aea9a58e7.
Report an issue: GitHub.