Skip to content

fix(cli): a gateway model while signed out prints source lines and a stack trace #1905

Todo

Description

@sahrizvi

Found in the end-to-end check of the published v0.12.13 npm package. Also in v0.12.12, but more users now reach it: since #1835 fix(provider): a blank Altimate key is not a sign-in a blank-field user gets this instead of a 403, and it is the usual state after /logout from the gateway when the config pins the gateway model.

Repro: with no ~/.altimate/altimate.json (or one with a blank field), run altimate run --model altimate-backend/altimate-default "reply ok". A project config with "model": "altimate-backend/altimate-default" and no --model does the same.

Observed: exit 1 with

Error: UnknownError: Model not found: altimate-backend/altimate-default.
2304 | if (!provider) { ...
ProviderModelNotFoundError: ... providerMissing: true
    at getModel (src/provider/provider.ts:2309:13)

Expected: a short message like other providers give (--model foo/bar, or Anthropic with no key): Error: Model not found: … and Try: altimate models, ideally with the gateway sign-in command.

Cause: altimate-backend is in provider.list().all with its models, so the early check in run.ts (around line 691) passes, and the server's getModel throw reaches the user as UnknownError with its stack.

Activity

  1. self-assigned this
    on Dec 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions