@ai-ecoverse/slicc-bios 1.74.1 → 1.74.3

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.
package/README.md CHANGED
@@ -5,7 +5,7 @@ A slim loader for [SLICC](https://github.com/ai-ecoverse/slicc), from the boot-p
5
5
  The page shows six boot steps as they run:
6
6
 
7
7
  1. **Acquire OPFS** – open the origin private file system and ask for persistent storage.
8
- 2. **Create installer worker** – start `installer.js`, a shared worker that does all of the BIOS's OPFS writes and is shared by every tab. On a shared origin it first disarms SLICC 6's service worker, which would otherwise answer every npm download (see [SLICC 6's proxy worker](#slicc-6s-proxy-worker)). The installer has 30 s to answer. One that an earlier client started (connection #2 or later) can be stuck, so it also says how it reaches the network: it fetches modern-tar from jsDelivr (10 s at most) and checks who answered, and it lists the calls it is running, with how long each has been quiet. The BIOS replaces it when a service worker answered (`a service worker answered its downloads`), nothing answered (`its downloads got no answer in 10 s`), or a packages run has had no progress and no download data for 2 minutes (`its packages run made no progress for 121 s at node_modules/pako`, naming the packages it was writing). Replacing means the `reset` call: the old installer ends every other call it runs with `the installer stopped: seven's BIOS replaced it: <why>`, which releases their Web Locks, and closes itself; the BIOS then connects again until a new installer answers (10 tries). The step reads `connection #3: <why>, starting a new installer`, then `connection #1, replaced the installer (<why>)`. An installer that can't reach npm at all (offline) isn't replaced.
8
+ 2. **Create installer worker** – start `installer.js`, a shared worker that does all of the BIOS's OPFS writes and is shared by every tab. On a shared origin it first disarms SLICC 6's service worker, which would otherwise answer every npm download (see [SLICC 6's proxy worker](#slicc-6s-proxy-worker)). The installer has 30 s to answer. One that an earlier client started (connection #2 or later) can be stuck, so it also says how it reaches the network: it fetches modern-tar from jsDelivr (10 s at most) and checks who answered, and it lists the calls it is running, with how long each has been quiet. The BIOS replaces it when a service worker answered (`a service worker answered its downloads`), nothing answered (`its downloads got no answer in 10 s`, unless a packages run is going and the installer got data from npm in the last 30 s, so a probe slowed by another tab's downloads stops nothing that still makes progress), or a packages run has had no progress and no download data for 2 minutes (`its packages run made no progress for 121 s at node_modules/pako`, naming the packages it was writing). Replacing means the `reset` call: the old installer ends every other call it runs with `the installer stopped: seven's BIOS replaced it: <why>`, which releases their Web Locks, and closes itself; the BIOS then connects again until a new installer answers (10 tries). The step reads `connection #3: <why>, starting a new installer`, then `connection #1, replaced the installer (<why>)`. An installer that can't reach npm at all (offline) isn't replaced.
9
9
  3. **Install packages from npm into OPFS** – the installer reads [`src/packages/package-lock.json`](src/packages/package-lock.json), the lockfile the BIOS ships with. It pins only what UI boot and the agent install need (Lars, 2026-10-21): slicc-kernel, slicc-spectrum, slicc-browsers (the guard's catalog), slicc-capture and slicc-audio (the page's capture and audio), slicc-devices (the page's serial ports, with esptool-js and the pako and atob-lite it depends on, for `esptool`), wasi-pnpm, bash, coreutils, findutils, the TLS engine (the kernel's HTTPS) and fnox (the agent's secrets). Every other tool comes after boot, at npm's `latest` (see [Seven's tools](#sevens-tools)). It skips packages that name an `os` or `cpu` (native binaries such as esbuild's, which can't run in a browser). For every other locked package it downloads the tarball from `registry.npmjs.org` and checks its `integrity`, then unpacks it with the built-in `DecompressionStream` and [`modern-tar`](https://github.com/ayuhito/modern-tar) into OPFS at its lockfile path (`node_modules/…`), dropping `.` segments from entry names and skipping any entry with `..`. A package that is already there is rewritten in place, never emptied first: every file is overwritten whole (an OPFS write commits on close), the entry points come last: a command's wasm (and its variants), then its glue or script with `bin`, `main` and `exports` targets, then `package.json`, and only then do the files the new version no longer has go, so a running kernel or another tab never finds the package missing. Each package's overwrite, sweep and hashes run inside the installed kernel's `replacing()` (`@ai-ecoverse/slicc-kernel/meta`, kernel 1.168.0 and later, loaded once per run like `writeMetadata` below). It holds the package directory's Web Lock `slicc-kernel-replacing:v1:slicc-kernel:/<path>` until the package is written and the running kernels have been told to drop what they cached of it, and every kernel loads a program's files under that lock. So an exec that starts meanwhile waits, then loads the new version whole, never the new wasm with the old glue ([#663](https://github.com/ai-ecoverse/slicc-bios/issues/663)). A kernel without `replacing()` gets its packages written as before. While it unpacks, it hashes every file (SHA-256) and records the hashes in IndexedDB (see [Integrity](#integrity)). It also keeps each file's mode from the tarball, owned by root: once a package's files are in, it hands their paths and modes to the kernel's `writeMetadata` (`@ai-ecoverse/slicc-kernel/meta`, read from the installed kernel), in one batch per run, so an executable outside `bin/`, such as pnpm's `shims/i`, stays executable when the kernel checks modes. The seed's files are recorded as root's `0644`. A kernel without `/meta` skips this. A package installed before the kernel had `/meta` gets its modes once, on the first run with it: the installer fetches its tarball again, checks its integrity, reads the modes from the headers without unpacking, and marks the receipt (`modes: true`). A package installed or replaced later is marked when it's stamped. It also records a receipt in `var/lib/bios/`. A package whose recorded integrity matches the lockfile's and whose files are still there isn't downloaded again, so pinning a new version replaces just that package. Replacing a package keeps its nested `node_modules`, and packages the lockfile no longer lists are deleted along with their receipts and hashes. A package without recorded hashes is downloaded again, even with a receipt, so the first boot after integrity checks arrived downloads the base set once. Last, the installer copies the deployment's `package.json` and `pnpm-lock.yaml` to the OPFS root for pnpm, and the lockfile once more to `var/lib/slicc/pnpm-lock.yaml`, which records what is installed (see [Updates](#updates)).
10
10
 
11
11
  The step says what it waits for. The run takes the Web Lock `slicc-packages`; when another run holds it, the step reads `waiting 30 s for another install of the packages (held by another seven tab)`, or `(held by this installer's other run, 612 s in, at node_modules/pako)`, updated every 30 s, with how many more wait. Then it reads `reading the lockfile`, `downloading <path>` as each package starts, and `3/15 <path>` as each one is in. Its network waits are bounded: a download gets two 30 s windows without data, modern-tar's and the integrity ledger's imports 60 s each, and the `tools.json` fetch 30 s. Whatever else stalls a run (an OPFS write, a kernel's `replacing()` lock) is what the 2-minute check at **Create installer worker** catches. Every boot step that reports nothing for 15 s adds `, nothing new for 15 s` to its last line, once every 15 s, so a stalled boot names the step and the line it stalled at.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-ecoverse/slicc-bios",
3
- "version": "1.74.1",
3
+ "version": "1.74.3",
4
4
  "description": "Slim loader that boots SLICC into OPFS and serves the UI from there",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
@@ -52,7 +52,7 @@
52
52
  "@ai-ecoverse/slicc": "1.67.12",
53
53
  "@ai-ecoverse/slicc-browsers": "1.23.0",
54
54
  "@ai-ecoverse/slicc-cdp": "1.50.1",
55
- "@ai-ecoverse/slicc-kernel": "1.186.0",
55
+ "@ai-ecoverse/slicc-kernel": "1.187.0",
56
56
  "@ai-ecoverse/slicc-shared-web": "2.14.4",
57
57
  "@ai-ecoverse/slicc-spectrum": "2.16.1",
58
58
  "@ai-ecoverse/slicc-vault": "1.26.1",
@@ -4,6 +4,6 @@
4
4
  "description": "SLICC's agent, which the UI installs with pnpm in the background into /opt/agent in OPFS",
5
5
  "dependencies": {
6
6
  "@ai-ecoverse/slicc-agent": "7.34.0",
7
- "@ai-ecoverse/slicc-kernel": "1.186.0"
7
+ "@ai-ecoverse/slicc-kernel": "1.187.0"
8
8
  }
9
9
  }
@@ -15,10 +15,10 @@ importers:
15
15
  dependencies:
16
16
  '@ai-ecoverse/slicc-agent':
17
17
  specifier: 7.34.0
18
- version: 7.34.0(@ai-ecoverse/slicc-kernel@1.186.0)(@aws-sdk/credential-provider-node@3.972.84)(@smithy/signature-v4@5.7.4)
18
+ version: 7.34.0(@ai-ecoverse/slicc-kernel@1.187.0)(@aws-sdk/credential-provider-node@3.972.84)(@smithy/signature-v4@5.7.4)
19
19
  '@ai-ecoverse/slicc-kernel':
20
- specifier: 1.186.0
21
- version: 1.186.0
20
+ specifier: 1.187.0
21
+ version: 1.187.0
22
22
 
23
23
  packages:
24
24
 
@@ -32,8 +32,8 @@ packages:
32
32
  '@ai-ecoverse/slicc-spectrum':
33
33
  optional: true
34
34
 
35
- '@ai-ecoverse/slicc-kernel@1.186.0':
36
- resolution: {integrity: sha512-f9FAPjfz9IWB7ZaRRpH/HEZry1DocFxPRJKhBcn2ufnShI9Kwv4XEw8jHyRTZu6G3R7g9lpuO4NNWprz6OHIcA==}
35
+ '@ai-ecoverse/slicc-kernel@1.187.0':
36
+ resolution: {integrity: sha512-t3w75tbm9GfxScJij5Tny5QmZ2w/b2scikNXHXBCHpr89xfCg6cC8Vn3L+ERDtzpPOu5dbsLhbOGug0Eo7jNTQ==}
37
37
  engines: {node: '>=26'}
38
38
 
39
39
  '@anthropic-ai/sdk@0.129.0':
@@ -338,9 +338,9 @@ packages:
338
338
 
339
339
  snapshots:
340
340
 
341
- '@ai-ecoverse/slicc-agent@7.34.0(@ai-ecoverse/slicc-kernel@1.186.0)(@aws-sdk/credential-provider-node@3.972.84)(@smithy/signature-v4@5.7.4)':
341
+ '@ai-ecoverse/slicc-agent@7.34.0(@ai-ecoverse/slicc-kernel@1.187.0)(@aws-sdk/credential-provider-node@3.972.84)(@smithy/signature-v4@5.7.4)':
342
342
  dependencies:
343
- '@ai-ecoverse/slicc-kernel': 1.186.0
343
+ '@ai-ecoverse/slicc-kernel': 1.187.0
344
344
  '@aws-sdk/middleware-websocket': 3.972.54
345
345
  '@earendil-works/chord': 1.5.0
346
346
  '@earendil-works/pi-ai': 1.5.0(@aws-sdk/credential-provider-node@3.972.84)(@smithy/signature-v4@5.7.4)
@@ -363,7 +363,7 @@ snapshots:
363
363
  - ws
364
364
  - zod
365
365
 
366
- '@ai-ecoverse/slicc-kernel@1.186.0': {}
366
+ '@ai-ecoverse/slicc-kernel@1.187.0': {}
367
367
 
368
368
  '@anthropic-ai/sdk@0.129.0':
369
369
  dependencies:
@@ -10,7 +10,7 @@
10
10
  "@ai-ecoverse/slicc-browsers": "1.23.0",
11
11
  "@ai-ecoverse/slicc-capture": "1.5.0",
12
12
  "@ai-ecoverse/slicc-devices": "1.2.1",
13
- "@ai-ecoverse/slicc-kernel": "1.186.0",
13
+ "@ai-ecoverse/slicc-kernel": "1.187.0",
14
14
  "@ai-ecoverse/slicc-spectrum": "2.16.1",
15
15
  "@ai-ecoverse/wasi-fnox": "1.47.0-1",
16
16
  "@ai-ecoverse/wasi-pnpm": "12.9.1-21",
@@ -75,9 +75,9 @@
75
75
  }
76
76
  },
77
77
  "node_modules/@ai-ecoverse/slicc-kernel": {
78
- "version": "1.186.0",
79
- "resolved": "https://registry.npmjs.org/@ai-ecoverse/slicc-kernel/-/slicc-kernel-1.186.0.tgz",
80
- "integrity": "sha512-f9FAPjfz9IWB7ZaRRpH/HEZry1DocFxPRJKhBcn2ufnShI9Kwv4XEw8jHyRTZu6G3R7g9lpuO4NNWprz6OHIcA==",
78
+ "version": "1.187.0",
79
+ "resolved": "https://registry.npmjs.org/@ai-ecoverse/slicc-kernel/-/slicc-kernel-1.187.0.tgz",
80
+ "integrity": "sha512-t3w75tbm9GfxScJij5Tny5QmZ2w/b2scikNXHXBCHpr89xfCg6cC8Vn3L+ERDtzpPOu5dbsLhbOGug0Eo7jNTQ==",
81
81
  "license": "Apache-2.0",
82
82
  "engines": {
83
83
  "node": ">=26"
@@ -7,7 +7,7 @@
7
7
  "@ai-ecoverse/slicc-browsers": "1.23.0",
8
8
  "@ai-ecoverse/slicc-capture": "1.5.0",
9
9
  "@ai-ecoverse/slicc-devices": "1.2.1",
10
- "@ai-ecoverse/slicc-kernel": "1.186.0",
10
+ "@ai-ecoverse/slicc-kernel": "1.187.0",
11
11
  "@ai-ecoverse/slicc-spectrum": "2.16.1",
12
12
  "@ai-ecoverse/wasi-fnox": "1.47.0-1",
13
13
  "@ai-ecoverse/wasi-pnpm": "12.9.1-21",
@@ -21,8 +21,8 @@ importers:
21
21
  specifier: 1.2.1
22
22
  version: 1.2.1
23
23
  '@ai-ecoverse/slicc-kernel':
24
- specifier: 1.186.0
25
- version: 1.186.0
24
+ specifier: 1.187.0
25
+ version: 1.187.0
26
26
  '@ai-ecoverse/slicc-spectrum':
27
27
  specifier: 2.16.1
28
28
  version: 2.16.1
@@ -65,8 +65,8 @@ packages:
65
65
  resolution: {integrity: sha512-7Ihkpq8b5ruq0gtB6HUJJbwZKFVgqRZjSxd4nsYk2VyszdUCLf2lEvsmb9MIqHOEPEI94ZOZHEOj7ExLU7A1LA==}
66
66
  engines: {node: '>=24', slicc-kernel: '>=1.183.0'}
67
67
 
68
- '@ai-ecoverse/slicc-kernel@1.186.0':
69
- resolution: {integrity: sha512-f9FAPjfz9IWB7ZaRRpH/HEZry1DocFxPRJKhBcn2ufnShI9Kwv4XEw8jHyRTZu6G3R7g9lpuO4NNWprz6OHIcA==}
68
+ '@ai-ecoverse/slicc-kernel@1.187.0':
69
+ resolution: {integrity: sha512-t3w75tbm9GfxScJij5Tny5QmZ2w/b2scikNXHXBCHpr89xfCg6cC8Vn3L+ERDtzpPOu5dbsLhbOGug0Eo7jNTQ==}
70
70
  engines: {node: '>=26'}
71
71
 
72
72
  '@ai-ecoverse/slicc-ortllama@1.28.0':
@@ -272,7 +272,7 @@ snapshots:
272
272
  dependencies:
273
273
  esptool-js: 0.7.1
274
274
 
275
- '@ai-ecoverse/slicc-kernel@1.186.0': {}
275
+ '@ai-ecoverse/slicc-kernel@1.187.0': {}
276
276
 
277
277
  '@ai-ecoverse/slicc-ortllama@1.28.0':
278
278
  dependencies: