@try-works/dsh-model-as-tool 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/client/index.js +17 -0
  2. package/package.json +1 -1
package/client/index.js CHANGED
@@ -1526,6 +1526,23 @@ window.__ModuleLoader__.load({
1526
1526
  await dualWriteDisabledExtensions(id, 'disable')
1527
1527
  }
1528
1528
  setExtRemote({ kind: 'ready', namespace, ...(await describeExtensions(namespace)) })
1529
+ // A store write and the following describe can land in either order
1530
+ // under load. One bounded re-read after a successful action settles
1531
+ // the row's controls (the Enable switch appears on an install) without
1532
+ // asking the operator to reopen the page. mounted() gates a stale
1533
+ // update after the dialog closes.
1534
+ setTimeout(() => {
1535
+ void (async () => {
1536
+ try {
1537
+ const settled = modelToolsRemote(ctx, mounted())
1538
+ if (settled !== null) {
1539
+ setExtRemote({ kind: 'ready', namespace: settled, ...(await describeExtensions(settled)) })
1540
+ }
1541
+ } catch (settleError) {
1542
+ // The snapshot already rendered is the last known host truth.
1543
+ }
1544
+ })()
1545
+ }, 500)
1529
1546
  } catch (error) {
1530
1547
  setExtRowError({ id, text: remoteErrorText(error) })
1531
1548
  // The action may have changed host state before failing. Read it back,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@try-works/dsh-model-as-tool",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "Install Desert Ant Labs on-device models as DSH tools and skills, with per-platform capability gating",
5
5
  "keywords": [
6
6
  "dsh",