wtfutil/wtf · error
%s
Error message
%s
What it means
Raised in finnhubRequest when the Finnhub API returns a non-2xx status: the error is only the HTTP status string (e.g. '401 Unauthorized'), no body. Typical causes are an invalid/expired API token, exceeded rate limit, or an unsupported symbol.
Source
Thrown at modules/stocks/finnhub/client.go:76
url := finnhubURL.ResolveReference(&url.URL{RawQuery: params.Encode()})
req, err := http.NewRequest("GET", url.String(), http.NoBody)
req.Header.Add("Accept", "application/json")
req.Header.Add("Content-Type", "application/json")
if err != nil {
return nil, err
}
httpClient := &http.Client{}
resp, err := httpClient.Do(req)
if err != nil {
return nil, err
}
defer func() { _ = resp.Body.Close() }()
if resp.StatusCode < 200 || resp.StatusCode > 299 {
return nil, fmt.Errorf("%s", resp.Status)
}
return resp, nil
}
View on GitHub (pinned to bb838c1ccb)
Solutions
- Verify the Finnhub API token configured for the widget is valid
- Check the ticker/symbol passed to Getquote exists on Finnhub
- Back off and retry on 429 rate-limit responses
- Check Finnhub plan limits if requests are being rejected
Defensive patterns
Strategy: retry
When it happens
Trigger: Thrown at modules/stocks/finnhub/client.go:76 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of wtfutil/wtf@bb838c1ccb (2026-09-03).
Data as JSON: /api/errors/c57b293526868351.
Report an issue: GitHub.