Skip to content
Source
Sign inSign up
TanStack/schemas

Keep the Fireworks poll when one model's metadata is forbidden #359

Mergedtombeckenhammerged 2 commits intomain fromfix/358-fireworks-metadata-403merged by tombeckenham View on GitHub

tombeckenhamcommented

Closes #358

Problem

Since 2026-10-19 15:48 UTC every Fireworks poll fails with ingest_failed:

fetch failed: https://api.fireworks.ai/v1/accounts/fireworks/models/minimax-m3p1-flash → 403 Forbidden

Fireworks now lists minimax-m3p1-flash but returns 403 for its native metadata. I reproduced this with our key: minimax-m3 and deepseek-v4p1-flash return 200. fireworksHostedReasoning loaded that metadata outside tryDocs. One model's failure therefore failed the whole provider poll, and all 21 Fireworks rows stopped updating.

Fix

fireworksHostedReasoning now takes the adapter's DocsRun and loads through tryDocs, as CLAUDE.md requires for docs loads. When a load fails:

  • That row gets absent: { capabilities: 'unavailable' }, so the poller keeps the stored capabilities map.
  • The failure is counted in docsFailures. It still emits ingest_failed and sets docsFailing on /v1/status.

No value is filled in. The parser stays strict, and the listing itself is still unwrapped.

Test

host-native-reasoning.test.ts covers one model whose metadata returns 403:

  • That row comes back marked unavailable and the run records the failure.
  • The next model is still read.

The test fails on main. bun run test (2061 passed), lint, typecheck and check all pass.

Review notes (non-critical, not changed here)

  • The whole map is frozen, not just one flag. absent works per fact, not per flag. On a failed load the row keeps its whole stored capabilities map, so this poll's listing flags (e.g. tools) are dropped for that row. A row first seen while it 403s (as minimax-m3p1-flash is now) is stored with capabilities: null until the 403 clears. The documented unavailable contract says exactly this. The alternative is to treat a 403 as "states nothing" and return the row unchanged. That would decide that a 403 means no statement, which is a judgement for the owner.
  • A 403 that never clears keeps the alarm on. Failures are not cached, so every poll re-fetches. docs-failing:fireworks and ingest_failed stay on until Fireworks opens the endpoint or drops the id. That is visible on purpose.
  • No adapter-level test. Nothing asserts that listModels survives the 403. The new run parameter is required, so the wiring is checked by types, and docsReport reads the same run.

🤖 Generated with Claude Code

https://claude.ai/code/session_01BRZxK4ijRmVpp7BtBRfs19

    1. Triage summary

      What it solvesOne listed Fireworks id (minimax-m3p1-flash) returns 403 on its native metadata. That failed the whole Fireworks poll every 15 minutes, and all 21 rows had been frozen since 15:31 UTC.
      Does it matterYes. A whole provider stopped updating: prices, context, new rows and deprecations.
      Added complexityLow: one extra parameter and a tryDocs wrap around an existing load (+~20 lines in src).
      Fallbacks that should be errorsNone. No value is invented. The failure is still ingest_failed + docsFailing, and the row keeps its stored capabilities per the unavailable contract.
      Public type/API changesNone. fireworksHostedReasoning is internal and its only caller is updated.
      Users helped / hurtHelped: all Fireworks catalog consumers. Hurt: the new row's capabilities stay null while the 403 lasts (by contract).
      Standards complianceFollows CLAUDE.md: docs loads go through tryDocs, the listing stays unwrapped, parsers stay strict, a focused test sits outside src/routes, and the full checks pass.
      VerdictApprove: smallest fix that puts the per-model docs load under the repo's documented failure path without hiding the error.

      Generated by Claude Code

    2. tombeckenham merged thisb52e5d2

    3. tombeckenham closed this

Sign in to join this conversation.