nautechsystems/nautilus_trader · error

order notional `{notional}` below Lighter min_quote_amount `

Error message

order notional `{notional}` below Lighter min_quote_amount `{}` for {}

What it means

The adapter validates that the order notional (quantity × limit price, computed from price_ticks) meets the instrument's minimum quote amount (min_notional). Lighter rejects orders below this threshold, so the adapter pre-validates and raises this error instead.

Source

Thrown at crates/adapters/lighter/src/execution.rs:5645

fn validate_order_amount(
    instrument: &InstrumentAny,
    quantity: Quantity,
    price_ticks: u32,
    price_precision: u8,
) -> anyhow::Result<()> {
    if let Some(min_quantity) = instrument.min_quantity() {
        anyhow::ensure!(
            quantity >= min_quantity,
            "quantity `{quantity}` below Lighter min_base_amount `{min_quantity}` for {}",
            instrument.id(),
        );
    }

    if let Some(min_notional) = instrument.min_notional() {
        let price = decimal_from_ticks(price_ticks, price_precision);
        let notional = quantity.as_decimal() * price;
        anyhow::ensure!(
            notional >= min_notional.as_decimal(),
            "order notional `{notional}` below Lighter min_quote_amount `{}` for {}",
            min_notional.as_decimal(),
            instrument.id(),
        );
    }

    Ok(())
}

fn decimal_from_ticks(ticks: u32, decimals: u8) -> Decimal {
    Decimal::from(ticks) / Decimal::from(10_i64.pow(u32::from(decimals)))
}

/// Route a venue `account_orders` payload through the tracked-event path
/// when the cloid is known, otherwise fall back to the existing
/// [`OrderStatusReport`] flow used for externally-managed orders.
fn dispatch_lighter_order(

View on GitHub (pinned to 18893faf8b)

Solutions

  1. Increase order size or price so quantity × price meets min_notional before submission.
  2. Verify price_ticks/price_precision conversion — a scaling bug often produces an undersized notional.
  3. Consult instrument.min_notional() in strategy sizing logic and enforce it pre-trade.
  4. Skip or aggregate sub-minimum orders instead of submitting them.

Example fix

// before
let price = decimal_from_ticks(price_ticks, price_precision);
submit(quantity, price);
// after
let price = decimal_from_ticks(price_ticks, price_precision);
if let Some(min_notional) = instrument.min_notional() {
    if quantity.as_decimal() * price < min_notional.as_decimal() {
        tracing::warn!("order notional below min_quote_amount; skipping");
        return Ok(());
    }
}
submit(quantity, price);
Defensive patterns

Strategy: validation

Validate before calling

let price = decimal_from_ticks(price_ticks, price_precision);
if let Some(min_n) = instrument.min_notional() {
    assert!(quantity.as_decimal() * price >= min_n.as_decimal(), "notional below minimum");
}

Type guard

fn meets_min_notional(instrument: &InstrumentAny, qty: Quantity, price_ticks: u32, precision: u8) -> bool {
    instrument.min_notional().map_or(true, |min| {
        qty.as_decimal() * decimal_from_ticks(price_ticks, precision) >= min.as_decimal()
    })
}

Try / catch

match submit_result {
    Err(e) if e.to_string().contains("below Lighter min_quote_amount") => {
        // increase size or skip; log for sizing review
    }
    other => other,
}

Prevention

When it happens

Trigger: Submitting a limit order where quantity × price (from price_ticks and price_precision) is less than instrument.min_notional() — small quantity at a low price, or a mis-scaled price (wrong tick precision).

Common situations: Small test orders on high-priced markets, price tick conversion errors making notional appear tiny, risk engine clipping size below notional minimums.

Understand the failure class

Background: "value must be between 0 and 1" / "out of range" / "must not be negative" errors: fixing range-validation failures across open-source libraries — this error's family across 42 libraries.

Related errors


AI-assisted analysis of nautechsystems/nautilus_trader@18893faf8b (2026-09-08). Data as JSON: /api/errors/7181f35fccfa6f19. Report an issue: GitHub.