What happened?
Model openai-codex/gpt-6.1-terra intermittently disappears from pi --list-models, apparently after system sleep or VPN connectivity issues (or wrong country selection).
❯ pi --list-models | Select-String -Pattern "terra"
openai gpt-5.6-terra 272K 128K yes yes
openai-codex gpt-5.6-terra 272K 128K yes yesThe model is still present in ~/.pi/agent/models-store.json, but its catalog metadata changes:
| Field | Before | After |
|---|---|---|
| lastModified | 1793193879000 | 0 |
| checkedAt | 1793240351635 | 1793295007994 |
| etag | Present | Missing |
| gpt-6.1-terra in cached models | Yes | Yes |
| Model visible in Pi | Yes | No |
Even with PI_OFFLINE=1, the model remains hidden.
Running pi update --models restores it immediately. This has happened repeatedly.
Suspected cause
In withRemoteCatalog(), HTTP 404/501 responses reset lastModified to 0 and clear etag, while preserving stored.models.
remoteModels() then rejects the cached models because their timestamp is older than the built-in catalog.
A successful response missing the Last-Modified header is another possible cause.
Source: remote-catalog-provider.ts (v1.4.0)
- Pi 1.4.0
- Node.js 26
- Windows 11
Steps to reproduce
- Run pi update --models and verify gpt-6.1-terra is listed.
- Allow a periodic catalog refresh, potentially during unstable VPN connectivity.
- Observe that the model disappears while remaining in the stored model array.
- Run pi update --models again. The model reappears.
The network trigger is intermittent; the exact HTTP response has not been captured.
Expected behavior
A transient catalog endpoint failure should not invalidate a previously valid cached catalog or hide working models. The last known good catalog should remain available until a valid replacement is received.
❯ pi --list-models | Select-String -Pattern "terra"
openai gpt-5.6-terra 272K 128K yes yes
openai-codex gpt-5.6-terra 272K 128K yes yes
openai-codex gpt-6.1-terra 500K 128K yes yesVersion
1.4.0
Activity
0No activity yet.