Repository navigation
fix(models): allow deleting synced/fetched models (e.g. llamacpp) via DELETE /api/provider-models - #3204
Conversation
Bump 3.8.9 → 3.8.10 across package.json, lockfile, electron, open-sse, and docs/reference/openapi.yaml; add the [3.8.10] CHANGELOG section (root + 41 i18n mirrors) as the integration target for the cycle. Entries land here as work merges into release/v3.8.10; finalized by the release flow.
Assign unique aliases to HuggingChat, Kimi Web, and Qwen Web so they no longer shadow primary providers or trigger startup warnings. Add a unit test to enforce provider alias uniqueness and prevent future collisions. Also expand local ignore and VS Code exclude rules for agent, build, and worktree artifacts.
Normalize image_url parts across all Responses input paths. Integrated into release/v3.8.10.
Preserve API key expiration local time + clear button. Integrated into release/v3.8.10.
Strip previous_response_id for stateless Responses upstreams (auto/strip/preserve). Integrated into release/v3.8.10.
…(#3138) Map caps.thinking to ModelV2.capabilities.interleaved for opencode-plugin. Integrated into release/v3.8.10.
Use synced models as authoritative local catalog for all providers (+regression test). Integrated into release/v3.8.10.
…I key→dashscope (#3149) Bifurcate Qoder validation by token type (PAT→Cosy, regular→dashscope) +regression test. Integrated into release/v3.8.10.
Dynamic antigravity MITM model resolution in the executor (+bug fix +regression test; DB import dropped from client-reachable config). Integrated into release/v3.8.10.
Podman deployment options + larger upload body-size limits (+CONTAINER_HOST docs). Integrated into release/v3.8.10.
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
Code Review SummaryStatus: 3 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)CRITICAL
WARNING
SUGGESTION
Files Reviewed (3 files)
Reviewed by step-3.7-flash-20260528 · 870,002 tokens |
… DELETE /api/provider-models Fixes #3199. ## Problem Models fetched from providers like llamacpp are stored in the 'syncedAvailableModels' namespace (key = providerId:connectionId). The DELETE /api/provider-models handler only called removeCustomModel(), which operates on the 'customModels' namespace. Since fetched models are never in customModels, removeCustomModel() returned false and the model remained visible after deletion. ## Fix 1. Added removeSyncedAvailableModel() in src/lib/db/models.ts that scans all connection-scoped synced model lists for a provider, removes the target model, and deletes the key if the list becomes empty. 2. Exported it through src/lib/localDb.ts. 3. Updated DELETE handler in src/app/api/provider-models/route.ts to call both removeCustomModel() and removeSyncedAvailableModel(), returning true if either succeeds. ## Tests Added tests/unit/llamacpp-model-delete.test.ts with 3 assertions: - removeSyncedAvailableModel deletes a model from multiple connections - removeSyncedAvailableModel deletes the key when a connection becomes empty - removeSyncedAvailableModel returns false when model does not exist All 3 pass.
ab8b014 to
1f6e1e3
Compare
# Conflicts: # docs/reference/openapi.yaml # open-sse/executors/antigravity.ts # package-lock.json # package.json
7b4bda1
into
cheaper-inference:release/v3.8.11
|
Merged into Good catch on #3199: fetched/synced models live in the Verified before merge: 4/4 |
…etch (#3199) (#3212) Follow-up to #3204: deleting a synced (fetched) model removed it from the synced set, but the DELETE route didn't mark it hidden and the re-import path didn't skip hidden ids, so the next auto-fetch re-added it. Now the route marks the id hidden on delete and replaceSyncedAvailableModelsForConnection filters hidden ids, so the deletion sticks. Co-authored-by: tjengbudi <tjengbudi@users.noreply.github.com>
…s + add contributor hall Consolidate the split [Unreleased]/[3.8.11] sections into one, add entries for every merged contributor PR that was missing credit (#3170/#3171/#3172 @pizzav-xyz, #3185/#3195 @zhiru, #3188 @xz-dev, #3189/#3203/#3204/#3241 @wilsonicdev, #3191 @bypanghu, #3206 @juandisay, #3217 @oyi77, #3226 @miracuves, #3187/#3200 maintainer), drop stale v3.8.8 leftovers (#2958/#2959 already shipped) and 3 empty v3.8.10 stub headers.
… DELETE /api/provider-models (cheaper-inference#3204) Integrated into release/v3.8.11
…etch (cheaper-inference#3199) (cheaper-inference#3212) Follow-up to cheaper-inference#3204: deleting a synced (fetched) model removed it from the synced set, but the DELETE route didn't mark it hidden and the re-import path didn't skip hidden ids, so the next auto-fetch re-added it. Now the route marks the id hidden on delete and replaceSyncedAvailableModelsForConnection filters hidden ids, so the deletion sticks. Co-authored-by: tjengbudi <tjengbudi@users.noreply.github.com>
…s + add contributor hall Consolidate the split [Unreleased]/[3.8.11] sections into one, add entries for every merged contributor PR that was missing credit (cheaper-inference#3170/cheaper-inference#3171/cheaper-inference#3172 @pizzav-xyz, cheaper-inference#3185/cheaper-inference#3195 @zhiru, cheaper-inference#3188 @xz-dev, cheaper-inference#3189/cheaper-inference#3203/cheaper-inference#3204/cheaper-inference#3241 @wilsonicdev, cheaper-inference#3191 @bypanghu, cheaper-inference#3206 @juandisay, cheaper-inference#3217 @oyi77, cheaper-inference#3226 @miracuves, cheaper-inference#3187/cheaper-inference#3200 maintainer), drop stale v3.8.8 leftovers (cheaper-inference#2958/cheaper-inference#2959 already shipped) and 3 empty v3.8.10 stub headers.
… DELETE /api/provider-models (cheaper-inference#3204) Integrated into release/v3.8.11
…etch (cheaper-inference#3199) (cheaper-inference#3212) Follow-up to cheaper-inference#3204: deleting a synced (fetched) model removed it from the synced set, but the DELETE route didn't mark it hidden and the re-import path didn't skip hidden ids, so the next auto-fetch re-added it. Now the route marks the id hidden on delete and replaceSyncedAvailableModelsForConnection filters hidden ids, so the deletion sticks. Co-authored-by: tjengbudi <tjengbudi@users.noreply.github.com>
…s + add contributor hall Consolidate the split [Unreleased]/[3.8.11] sections into one, add entries for every merged contributor PR that was missing credit (cheaper-inference#3170/cheaper-inference#3171/cheaper-inference#3172 @pizzav-xyz, cheaper-inference#3185/cheaper-inference#3195 @zhiru, cheaper-inference#3188 @xz-dev, cheaper-inference#3189/cheaper-inference#3203/cheaper-inference#3204/cheaper-inference#3241 @wilsonicdev, cheaper-inference#3191 @bypanghu, cheaper-inference#3206 @juandisay, cheaper-inference#3217 @oyi77, cheaper-inference#3226 @miracuves, cheaper-inference#3187/cheaper-inference#3200 maintainer), drop stale v3.8.8 leftovers (cheaper-inference#2958/cheaper-inference#2959 already shipped) and 3 empty v3.8.10 stub headers.
… DELETE /api/provider-models (cheaper-inference#3204) Integrated into release/v3.8.11
…etch (cheaper-inference#3199) (cheaper-inference#3212) Follow-up to cheaper-inference#3204: deleting a synced (fetched) model removed it from the synced set, but the DELETE route didn't mark it hidden and the re-import path didn't skip hidden ids, so the next auto-fetch re-added it. Now the route marks the id hidden on delete and replaceSyncedAvailableModelsForConnection filters hidden ids, so the deletion sticks. Co-authored-by: tjengbudi <tjengbudi@users.noreply.github.com>
…s + add contributor hall Consolidate the split [Unreleased]/[3.8.11] sections into one, add entries for every merged contributor PR that was missing credit (cheaper-inference#3170/cheaper-inference#3171/cheaper-inference#3172 @pizzav-xyz, cheaper-inference#3185/cheaper-inference#3195 @zhiru, cheaper-inference#3188 @xz-dev, cheaper-inference#3189/cheaper-inference#3203/cheaper-inference#3204/cheaper-inference#3241 @wilsonicdev, cheaper-inference#3191 @bypanghu, cheaper-inference#3206 @juandisay, cheaper-inference#3217 @oyi77, cheaper-inference#3226 @miracuves, cheaper-inference#3187/cheaper-inference#3200 maintainer), drop stale v3.8.8 leftovers (cheaper-inference#2958/cheaper-inference#2959 already shipped) and 3 empty v3.8.10 stub headers.
Fixes #3199.
Problem
Models fetched from providers like llamacpp are stored in the
'syncedAvailableModels' namespace (key = providerId:connectionId).
The DELETE /api/provider-models handler only called removeCustomModel(),
which operates on the 'customModels' namespace. Since fetched models are
never in customModels, removeCustomModel() returned false and the model
remained visible after deletion.
Fix
all connection-scoped synced model lists for a provider, removes the
target model, and deletes the key if the list becomes empty.
call both removeCustomModel() and removeSyncedAvailableModel(),
returning true if either succeeds.
Tests
Added tests/unit/llamacpp-model-delete.test.ts with 3 assertions:
All 3 pass.