Headless mode now backs off from re-fetching the model catalog after a recent failure instead of retrying every time
When Claude Code starts in headless (non-interactive, scripted) mode, it fetches a catalog of available models over the network. Now, before doing that fetch, it checks a saved marker recording whether a recent headless fetch failed. If a failure was recorded recently, it skips the network call entirely and falls back to the built-in model list, recording the reason as headless_held_off.
Success and failure are tracked in a new .headless-failed.json marker file, and repeated failures make Claude Code wait longer before trying again (exponential backoff).
This avoids repeatedly hitting a failing network endpoint on every headless run, which previously could slow down or delay each invocation. If the model catalog can't be reached, headless runs now fail fast and fall back to a known-good default list instead of retrying every time.