OpenBB-finance/OpenBB · error · OpenBBError

Error: {error} -> {message}

Error message

Error: {error} -> {message}

What it means

Generic OpenBBError raised in the forward EPS estimates fetch callback when Intrinio returns a JSON body with a non-null 'error' key whose message does not mention 'api key'. It wraps the raw Intrinio error code and message, e.g. 'Error: 404 -> Not Found', covering anything the API reports besides authorization failures.

Source

Thrown at openbb_platform/providers/intrinio/openbb_intrinio/models/forward_eps_estimates.py:173

                new_data = data.get("estimates")  # type: ignore
                if new_data:
                    results.extend(new_data)

        if symbols:
            await asyncio.gather(*[get_one(symbol) for symbol in symbols])
            return results

        async def fetch_callback(response, session):
            """Use callback for pagination."""
            data = await response.json()
            error = data.get("error", None)
            if error:
                message = data.get("message", "")
                if "api key" in message.lower():
                    raise UnauthorizedError(
                        f"Unauthorized Intrinio request -> {message}"
                    )
                raise OpenBBError(f"Error: {error} -> {message}")

            if data.get("estimates") and len(data.get("estimates")) > 0:  # type: ignore
                results.extend(data.get("estimates"))  # type: ignore
                while data.get("next_page"):  # type: ignore
                    next_page = data["next_page"]  # type: ignore
                    next_url = f"{url}&next_page={next_page}"
                    data = await amake_request(next_url, session=session, **kwargs)
                    if "estimates" in data and len(data.get("estimates")) > 0:  # type: ignore
                        results.extend(data.get("estimates"))  # type: ignore
            return results

        url = f"{BASE_URL}&{query_str}&api_key={api_key}"

        results = await amake_request(url, response_callback=fetch_callback, **kwargs)  # type: ignore

        if not results:
            raise EmptyDataError("The request was successful but was returned empty.")

View on GitHub (pinned to 3e071fcc2c)

Solutions

  1. Read the embedded '{error} -> {message}' text - it is the verbatim Intrinio response and names the real cause.
  2. Validate the symbol exists (e.g. obb.equity.price.quote(symbol=..., provider='intrinio')).
  3. If rate-limited, throttle request frequency or raise your Intrinio plan tier.
  4. Retry once after correcting parameters; if the error persists, test the equivalent URL directly against api-v2.intrinio.com.
Defensive patterns

Strategy: try-catch

Validate before calling

import re
# validate tickers before batching
def is_plausible_ticker(s: str) -> bool:
    return bool(re.fullmatch(r'[A-Z.\-]{1,8}', s.strip().upper()))

Try / catch

from openbb_core.provider.exceptions import OpenBBError
try:
    res = obb.equity.estimates.forward_eps(symbol=sym, provider='intrinio')
except OpenBBError as e:
    msg = str(e)
    if 'api key' in msg.lower():
        fix_credentials()
    elif '429' in msg or 'limit' in msg.lower():
        backoff_and_retry()
    else:
        raise

Prevention

When it happens

Trigger: equity/estimates/forward_eps with provider=intrinio where the API responds with an error payload: unknown/invalid symbol, disallowed query parameter combination, rate limit (429) message returned in the body, or a malformed request URL built from the query string.

Common situations: Delisted or misspelled ticker passed in symbol; hitting Intrinio per-minute/per-day call limits; using parameters the endpoint no longer accepts after an Intrinio API change.

Related errors


AI-assisted analysis of OpenBB-finance/OpenBB@3e071fcc2c (2026-08-14). Data as JSON: /api/errors/62537228a0a18e0c. Report an issue: GitHub.