@hachej/boring-execution 0.3.1 → 0.4.0

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/README.md +5 -5
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -40,7 +40,7 @@ Errors are bounded in one place (`boundedMessage` in `src/bounded-error.ts`, als
40
40
 
41
41
  The command supports local `init`, matrix `status`, single-path `add`, index-only `rm --cached`, `commit -m`, bounded `log`, `branch`, `checkout`, and binary-content JSON `diff` or `diff --cached`. Other argument forms return exit 126. [The files guide](../files/README.md) owns authorization, serialization and diff semantics. No remote transport, durable recovery or publication transaction is claimed. Raw `.git` writes remain subject to the selected filesystem's host policy.
42
42
 
43
- Run `node examples/virtual-workspace.mjs` after building for a fictional shared native/Bash/Git example. `test/packages/execution.test.mjs` exercises public output and actual native ToolTasks. `npm run test:virtual-consumer` installs the tarball and exact registry dependency closure outside the repository, checks declarations and repeats those tests. Set `npm_config_cache` to a writable cache containing the pinned archives.
43
+ Run `node fixtures/virtual-workspace.mjs` after building for a fictional shared native/Bash/Git example. `test/packages/execution.test.mjs` exercises public output and actual native ToolTasks. `npm run test:virtual-consumer` installs the tarball and exact registry dependency closure outside the repository, checks declarations and repeats those tests. Set `npm_config_cache` to a writable cache containing the pinned archives.
44
44
 
45
45
  ## Borrowed remote Shell
46
46
 
@@ -52,7 +52,7 @@ Command strings, cwd, environment and native exit/error results pass through (pr
52
52
 
53
53
  Transport defaults are 64 KiB per request, 1 MiB per frame and 4 MiB of queued server frames. Oversized output or an overfull queue interrupts observation rather than reporting truncated success. These bounds do not cap native output production or Fetch/provider peak memory. Host native execution limits remain necessary. Local cancellation, callback failure or lease release requests remote cancellation and reports unconfirmed termination; prior effects can remain. Each borrowed lease owns only its active transports, and never calls the shared provider's cleanup.
54
54
 
55
- Run `node examples/remote-shell.mjs` for an actual native command through in-process Request/Response streaming. `npm run test:remote-shell-consumer` installs only the execution tarball and pinned native registry closure, checks strict declarations and repeats public native tests without the virtual/Git/Boring UI/agent peers. The handler reads request bodies through `@hachej/boring-files/request-guard`, so install `@hachej/boring-files` (an optional peer) with this subpath; the consumer installs its archive. This establishes the paired Fetch protocol and selected native behavior. Socket deployment, vendor provisioning/reattachment, durable command admission/recovery, independent file grants, protected builds and process-tree termination remain separate qualifications.
55
+ Run `node fixtures/remote-shell.mjs` for an actual native command through in-process Request/Response streaming. `npm run test:remote-shell-consumer` installs only the execution tarball and pinned native registry closure, checks strict declarations and repeats public native tests without the virtual/Git/Boring UI/agent peers. The handler reads request bodies through `@hachej/boring-files/request-guard`, so install `@hachej/boring-files` (an optional peer) with this subpath; the consumer installs its archive. This establishes the paired Fetch protocol and selected native behavior. Socket deployment, vendor provisioning/reattachment, durable command admission/recovery, independent file grants, protected builds and process-tree termination remain separate qualifications.
56
56
 
57
57
  ## Borrowed remote FileSystem
58
58
 
@@ -74,7 +74,7 @@ Known deviations from Pi's reader contract: a reader holds no handle, so renamin
74
74
 
75
75
  Defaults are 1 MiB per request, 4 MiB per normal JSON response and 1 MiB per stream frame. Binary values travel as canonical base64 text (protocol version 3; older peers are refused, so upgrade both ends together). Server backpressure queues at most one frame and reads on demand, with a read possibly in flight. These limits bound accepted transport data, not native reader allocation, JSON expansion, Fetch allocation or provider production. Oversized data refuses instead of reporting truncated success.
76
76
 
77
- Run `node examples/remote-files.mjs` after building to write and stream a fictional native file without a shell capability. `npm run test:remote-files-consumer` installs the execution and files tarballs (this subpath reads bodies through `@hachej/boring-files/request-guard`) and pinned registry dependencies, checks strict declarations and exercises actual native files, a native ToolTask and reader lifetime races. Its pinned `buffer` fixture dependency keeps undici's bare type import inside the isolated installation when the temporary directory has a parent workspace. In-process Fetch evidence does not qualify deployed sockets, vendor lifecycle, acquisition recovery, protected builds or complete exposure policy.
77
+ Run `node fixtures/remote-files.mjs` after building to write and stream a fictional native file without a shell capability. `npm run test:remote-files-consumer` installs the execution and files tarballs (this subpath reads bodies through `@hachej/boring-files/request-guard`) and pinned registry dependencies, checks strict declarations and exercises actual native files, a native ToolTask and reader lifetime races. Its pinned `buffer` fixture dependency keeps undici's bare type import inside the isolated installation when the temporary directory has a parent workspace. In-process Fetch evidence does not qualify deployed sockets, vendor lifecycle, acquisition recovery, protected builds or complete exposure policy.
78
78
 
79
79
  ## Virtual repository saved in SQLite
80
80
 
@@ -84,7 +84,7 @@ Run `node examples/remote-files.mjs` after building to write and stream a fictio
84
84
 
85
85
  ## AWS Code Interpreter environment
86
86
 
87
- `@hachej/boring-execution/aws-code-interpreter` needs the exact optional peer `@aws-sdk/client-bedrock-agentcore@3.1146.0`; the host passes its own `BedrockAgentCoreClient` (region, credentials, retries). It makes no AWS call except the session start, the command tools and `stop()`, and creates no AWS resource. The recipe that uses it is [examples/aws](../../examples/aws/README.md); the decisions are in [HOST-RECIPE-AWS.md](../../docs/architecture/HOST-RECIPE-AWS.md).
87
+ `@hachej/boring-execution/aws-code-interpreter` needs the exact optional peer `@aws-sdk/client-bedrock-agentcore@3.1146.0`; the host passes its own `BedrockAgentCoreClient` (region, credentials, retries). It makes no AWS call except the session start, the command tools and `stop()`, and creates no AWS resource. The recipe that uses it is [examples/hosts/aws](../../examples/hosts/aws/README.md); the decisions are in [HOST-RECIPE-AWS.md](../../docs/architecture/HOST-RECIPE-AWS.md).
88
88
 
89
89
  `createCodeInterpreterEnv({ client, codeInterpreterIdentifier, session, id, mount, cwd?, umask?, pollIntervalMs?, renew?, rotateMarginSeconds? })` returns `{ env, owned, sessionId(), lost(), renew(), stop(context) }`. `env` is one native Pi `ExecutionEnv` over one folder that both this host and the Code Interpreter session mount (an EFS access point): `mount.path` is where the session sees it (`/mnt/<name>`), `mount.root` where this host does. Tool paths are session paths, so commands and file tools name the same file.
90
90
 
@@ -94,5 +94,5 @@ Run `node examples/remote-files.mjs` after building to write and stream a fictio
94
94
 
95
95
  `efsUserLayout({ userId, uid, gid?, runtimeMountPath?, runtimeAccessPointRoot?, interpreterMountPath? })` is pure: for a user id (`[a-z0-9][a-z0-9_-]{0,63}`, never a path) and a host-allocated uid it returns the access point to create (root `/boring/users/<id>`, POSIX user `uid:1000`, setgid `2770`, a `boring:user` tag), the session mount (`/mnt/workspace`), this host's folder (`/mnt/efs/users/<id>`), the state directory outside it (`/mnt/efs/state/<id>`, with `journal.sqlite` and `harnessFile(key)`), the namespace id and the `filesystemConfigurations` entry.
96
96
 
97
- `test/packages/execution.test.mjs` drives the real SDK client against `examples/aws/fake-code-interpreter.mjs` (the wire format, without AWS): shared files, output, exit codes, cwd and environment, timeout and abort through `stopTask`, a lost session (auto renewal mid-turn and under concurrent commands, rotation before the time to live without stopping the old session, a stop that fails once and is retried, manual mode, borrowed sessions), borrowed versus owned stop, and two users who never see each other's folders (`..`, absolute paths, links and dangling links made by a command). The full deployment journey has not run against AWS (the session-ended error shapes are verified against the real service, owner 2026-10-12); see the open questions in HOST-RECIPE-AWS.md.
97
+ `test/packages/execution.test.mjs` drives the real SDK client against `examples/hosts/aws/fake-code-interpreter.mjs` (the wire format, without AWS): shared files, output, exit codes, cwd and environment, timeout and abort through `stopTask`, a lost session (auto renewal mid-turn and under concurrent commands, rotation before the time to live without stopping the old session, a stop that fails once and is retried, manual mode, borrowed sessions), borrowed versus owned stop, and two users who never see each other's folders (`..`, absolute paths, links and dangling links made by a command). The full deployment journey has not run against AWS (the session-ended error shapes are verified against the real service, owner 2026-10-12); see the open questions in HOST-RECIPE-AWS.md.
98
98
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hachej/boring-execution",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "type": "module",
@@ -56,7 +56,7 @@
56
56
  "@earendil-works/chord": "~1.2.0",
57
57
  "just-bash": "^3.6.0",
58
58
  "isomorphic-git": "^1.42.6",
59
- "@hachej/boring-files": "^0.3.1",
59
+ "@hachej/boring-files": "^0.4.0",
60
60
  "zod": "^4.6.5",
61
61
  "@aws-sdk/client-bedrock-agentcore": "^3.1146.0"
62
62
  },