postmortem.io
Menu

802 entries newest

Browse

Incident

Incident Report: Invalid model cost map on main

Read the original on the company blog (external)
Contents · 4 sections

Incident Report: Invalid model cost map on main

LiteLLM incident report. Published 2026-02-10.

Date: January 27, 2026 Duration: ~20 minutes Severity: Low Status: Resolved

Summary

A malformed JSON entry in model_prices_and_context_window.json was merged to main (562f0a0). This caused LiteLLM to silently fall back to a stale local copy of the model cost map. Users on older package versions lost cost tracking for newer models only (e.g. azure/gpt-5.2). No LLM calls were blocked.

  • LLM calls and proxy routing: No impact.
  • Cost tracking: Impacted for newer models not present in the local backup. Older models were unaffected. The incident lasted ~20 minutes until the commit was reverted.

Background

The model cost map is not in the request path. It is used after the LLM response comes back, inside a try/catch, to calculate spend. A missing entry never blocks a call.

Both paths return a response to the caller. When the cost map lookup fails, the only difference is cost=0 on that request.

Root cause

LiteLLM fetches the model cost map from GitHub main at import time. If the fetch fails, it falls back to a local backup bundled with the package. Before this incident, the fallback was completely silent — no warning was logged.

A contributor PR introduced an extra { bracket, producing invalid JSON. The remote fetch failed with JSONDecodeError, triggering the silent fallback. Users on older package versions had backup files missing newer models.

Timeline:

  1. Malformed JSON merged to main
  2. LiteLLM installations fall back to local backup on next import
  3. Users report "This model isn't mapped yet" for newer models
  4. Bad commit identified and reverted (~20 minutes)

Remediation

Original source · company blog

Incident Report: Invalid model cost map on main

https://docs.litellm.ai/blog/model-cost-map-incident

This page is an extract. Cite the original; link here for the indexed copy.

LiteLLM. "Incident Report: Invalid model cost map on main." LiteLLM blog, 27 Jan 2026. https://docs.litellm.ai/blog/model-cost-map-incident (retrieved 2026-10-22 via postmortem.io)