Files
codex/codex-rs/core/tests/common
Rasmus Rygaard 44cb66e4ed Allow injecting model catalog caches (#36992)
## What changed

- Add the public asynchronous `ModelsCache` contract and cache entry/error types.
- Let model providers and `OpenAiModelsManager` accept caller-provided cache implementations while retaining the existing file-backed cache by default.
- Treat cache read failures as misses, keep cache write failures non-fatal, and support refreshing an entry's TTL after ETag revalidation.
- Continue to prefer an explicitly configured static model catalog over an injected cache.

## Testing

- Cover injected cache hits, read and write failures, TTL refreshes, and end-to-end model selection.
- Verify that the file-backed implementation satisfies the new cache contract and does not serve expired entries before revalidation.

GitOrigin-RevId: eef957a317910b8502a0c20f8fc112f689d5e389
2026-08-04 23:04:11 +00:00
..