Skip to content

Commit a67e024

Browse files
committed
fix(web): make provider deletion stick in the settings panel and model picker
Deleting a provider from the Providers panel looked like a no-op, and the provider's models stayed in the model picker even after removing it from config.toml by hand. Four defects lined up: - The daemon answers DELETE /providers/{id} with 204 and no body, and the web transport parsed every response as JSON, so the delete always rejected client-side after the server had already applied it. - The redesigned panel called the raw API without a catch and skipped the client facade, so the failure was silent and the model picker's providers+models were never reloaded. - The background catalog refresh took one config snapshot, fetched over the network, then wrote the whole providers/models tables back, which resurrected any provider deleted in between. The write-back now reconciles against the live user config: providers removed meanwhile stay removed (their models too), providers added meanwhile are kept. - Deletion filtered model rows on 'provider' only while resolution honours 'provider_id' as well, so rows keyed that way outlived their provider. Every provider-scoped model filter now uses the same resolution. The web client also reloads providers and models when the daemon reports a config change that touches them, so an external config.toml edit is reflected in the picker without a page reload.
1 parent 30f8e2d commit a67e024

109 files changed

Lines changed: 420 additions & 257 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@pymodel/pythinker-code": patch
3+
---
4+
5+
Fix deleting a provider in the web and desktop settings: the provider and its models now disappear from the model picker, a failed delete shows an error, and a background catalog refresh no longer brings a deleted provider back.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
2-
"sourceHash": "135af31b82e0a89e3644936171b91c29d9880f1112d9b9046c4871da90618387",
2+
"sourceHash": "f73a79a727e58eba289d63e39ddc3f5569567bbfcbec2b363d586b2efd8c27ff",
33
"sourceFileCount": 422
44
}

apps/pythinker-code/dist-web/assets/CodeBlockNode-BLRXfA23.js renamed to apps/pythinker-code/dist-web/assets/CodeBlockNode-Bbs0JMVX.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/pythinker-code/dist-web/assets/DesignSystemView-Dwl_jD3y.js renamed to apps/pythinker-code/dist-web/assets/DesignSystemView-BH6uOcCV.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/pythinker-code/dist-web/assets/Tooltip-BzUUO29Z.js renamed to apps/pythinker-code/dist-web/assets/Tooltip-ByauZ1Sh.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/pythinker-code/dist-web/assets/abnfDiagram-VCTEODGH-2EOqIk1O.js renamed to apps/pythinker-code/dist-web/assets/abnfDiagram-VCTEODGH-DR8VhsuM.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/pythinker-code/dist-web/assets/arc-CE2HyL6e.js renamed to apps/pythinker-code/dist-web/assets/arc-BSs1lldA.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/pythinker-code/dist-web/assets/architectureDiagram-5GKGNRK7-CHbzcUpr.js renamed to apps/pythinker-code/dist-web/assets/architectureDiagram-5GKGNRK7-C0JzAuGB.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)