OpenBB-finance/OpenBB · error · ValueError

Invalid Deribit symbol. Supported symbols are: {', '.join(DE

Error message

Invalid Deribit symbol. Supported symbols are: {', '.join(DERIBIT_FUTURES_CURVE_SYMBOLS)}

What it means

ValueError from get_futures_symbols when the (uppercased) symbol is not in DERIBIT_FUTURES_CURVE_SYMBOLS = [BTC, ETH, PAXG]. Stricter than the options allow-list: the futures curve only supports these three underlyings. Used by the futures curve model, whose query params also enforce the same list.

Source

Thrown at openbb_platform/providers/deribit/openbb_deribit/utils/helpers.py:168


async def get_futures_curve_symbols(symbol: FuturesCurveSymbols = "BTC") -> list[str]:
    """
    Get a list of futures symbols for a given symbol.

    Parameters
    ----------
    symbol : FuturesCurveSymbols
        The symbol to get futures symbols for.

    Returns
    -------
    list[str]
        A list of futures symbols.
    """
    symbol = symbol.upper()  # type: ignore
    if symbol not in DERIBIT_FUTURES_CURVE_SYMBOLS:
        raise ValueError(
            f"Invalid Deribit symbol. Supported symbols are: {', '.join(DERIBIT_FUTURES_CURVE_SYMBOLS)}",
        )

    currency = "USDC" if symbol == "PAXG" else symbol
    instruments = await get_instruments(currency, "future")

    symbols: list = []
    for d in instruments:
        ins_name = d.get("instrument_name", "")
        if ins_name.startswith(symbol):
            symbols.append(ins_name)

    return symbols


async def get_ticker_data(symbol: str) -> dict:
    """
    Get ticker data.

View on GitHub (pinned to 3e071fcc2c)

Solutions

  1. Use BTC, ETH, or PAXG for the futures curve.
  2. For SOL/XRP/BNB futures data, use the futures historical/info endpoints with full instrument names instead.
  3. Check the query param's __json_schema_extra__ choices for the authoritative per-endpoint list.

Example fix

# before
obb.derivatives.futures.curve(symbol="SOL", provider="deribit")

# after
obb.derivatives.futures.curve(symbol="BTC", provider="deribit")
Defensive patterns

Strategy: validation

Validate before calling

CURVE_SYMBOLS = {"BTC", "ETH", "PAXG"}
assert symbol.strip().upper() in CURVE_SYMBOLS, f"futures curve supports only {sorted(CURVE_SYMBOLS)}"

Type guard

from typing import Literal, TypeGuard
CurveSymbol = Literal["BTC", "ETH", "PAXG"]

def is_curve_symbol(s: str) -> TypeGuard[CurveSymbol]:
    return s.strip().upper() in {"BTC", "ETH", "PAXG"}

Prevention

When it happens

Trigger: Calling the futures curve (or get_futures_symbols directly) with SOL, XRP, BNB — valid options underlyings but not curve-supported — or with BTCUSDT-style pairs.

Common situations: Assuming option underlyings and futures-curve underlyings coincide; they do not (6 vs 3). Copying symbols between endpoints without checking each model's choices.

Related errors


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