Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
f0bf65f
computer: Hand host module factories the assets client
aron-cf Oct 8, 2026
e67eced
computer: Add ws:assets
aron-cf Oct 8, 2026
d25c354
computer: Mint tokens and clone URLs from ws:artifacts
aron-cf Oct 8, 2026
2bbd399
computer: Run a configured prelude before ws:container commands
aron-cf Oct 8, 2026
fe2c9a2
computer: Let ws:container limit output by lines
aron-cf Oct 8, 2026
8144eff
computer: Read host module descriptions when the backend is described
aron-cf Oct 8, 2026
d4f8b14
computer: Take exec output limits on the tool set options
aron-cf Oct 8, 2026
a749b2d
computer: Return each pi tool's own output as details
aron-cf Oct 8, 2026
0855b3c
computer: Export the exec tool definition on its own entry point
aron-cf Oct 8, 2026
1acb260
computer: Declare exec's input as an object
aron-cf Oct 8, 2026
6c30042
computer: Parse an exec input object sent as JSON text
aron-cf Oct 8, 2026
cd7936a
dofs: Prune the directory a trailing /** exclusion names
aron-cf Oct 8, 2026
a7316b9
dofs: Match brace alternatives in find and grep globs
aron-cf Oct 8, 2026
d12198d
computer: Take one glob or several in the grep and find tools
aron-cf Oct 8, 2026
b15ec04
computer: Bound the diff the edit tool computes and returns
aron-cf Oct 8, 2026
9ae73f2
computer: Confine the file tools to a root directory
aron-cf Oct 8, 2026
b42038d
docs: Document the new isolate host modules and their options
aron-cf Oct 8, 2026
9469bc1
docs: Document brace globs and /** pruning in find and grep
aron-cf Oct 8, 2026
9c0a37a
docs: Document the tool set's root, execOutput, details and edit bounds
aron-cf Oct 8, 2026
2d85e6d
computer, dofs: Add changesets for the module, tool and glob changes
aron-cf Oct 8, 2026
46e543a
computer: List the tools ws:tools exports in its description
aron-cf Oct 12, 2026
18513f7
computer: Do not start a ws:tools call that was cancelled while it wa…
aron-cf Oct 12, 2026
caea5cc
computer: Refuse ws:assets publish on a read-only backend
aron-cf Oct 12, 2026
714af3f
computer: Keep the end of ws:container output the runtime did not cut
aron-cf Oct 12, 2026
521091f
computer: Name the error each bare toThrow in the new tests expects
aron-cf Oct 13, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/edit-diff-bounds.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

The `edit` tool bounds its diff with `maxDiffLines` and `maxDiffBytes` and reports `diffTruncated`; see [`edit` tool documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#edit).
5 changes: 5 additions & 0 deletions .changeset/exec-input-object.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": minor
---

The `exec` tool's `input` is an object rather than any JSON value; see [`exec` tool documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#exec).
5 changes: 5 additions & 0 deletions .changeset/exec-input-repair.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

The `exec` tool parses an `input` object sent as a string of JSON; see [`exec` tool documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#exec).
5 changes: 5 additions & 0 deletions .changeset/exec-output-option.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

Tool sets take `execOutput: { maxLines, maxBytes }` for the `exec` tool's output limits; see [tool option documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#options).
5 changes: 5 additions & 0 deletions .changeset/find-brace-globs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/dofs": patch
---

`find` and `grep` globs match brace alternatives such as `**/*.{ts,tsx}`; see [`find` documentation](https://github.com/cloudflare/computer/blob/main/docs/04_filesystem_interface.md#find).
5 changes: 5 additions & 0 deletions .changeset/find-prune-trailing-globstar.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/dofs": minor
---

An exclusion ending in `/**` also prunes the directory it names in `find` and `grep`; see [`find` documentation](https://github.com/cloudflare/computer/blob/main/docs/04_filesystem_interface.md#find).
5 changes: 5 additions & 0 deletions .changeset/module-host-assets.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

Host module factories receive the Workspace's assets client as `host.assets`; see [host module documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#host-modules).
5 changes: 5 additions & 0 deletions .changeset/module-lazy-descriptions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`WorkerJavaScriptBackend` reads each host module's description whenever it describes itself, so a factory can describe something built later; see [module documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#modules).
5 changes: 5 additions & 0 deletions .changeset/pi-tool-details.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`createPiTools` results carry each tool's own output as `details`; see [pi documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#pi).
5 changes: 5 additions & 0 deletions .changeset/tool-glob-lists.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

The `grep` tool's `include` and `exclude`, and the `find` tool's `exclude`, take one glob or a list; see [`grep` tool documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#grep).
5 changes: 5 additions & 0 deletions .changeset/tools-core-entry-point.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

Add `@cloudflare/computer/tools/core`, which exports `defineExec` without an agent library; see [tool documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#what-ships).
5 changes: 5 additions & 0 deletions .changeset/tools-root-option.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

Tool sets take `root` to confine the file tools to one directory and refuse symbolic links; see [root documentation](https://github.com/cloudflare/computer/blob/main/docs/09_tool_interface.md#root).
5 changes: 5 additions & 0 deletions .changeset/ws-artifacts-tokens.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`ws:artifacts` adds `createToken` and `share` for minting git tokens and clone URLs; see [`ws:artifacts` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wsartifacts).
5 changes: 5 additions & 0 deletions .changeset/ws-assets-module.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

Add `ws:assets` so isolate JavaScript can publish a Workspace file to a time-limited URL; see [`ws:assets` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wsassets).
5 changes: 5 additions & 0 deletions .changeset/ws-container-max-lines.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`createContainerModule({ maxOutputLines })` limits each `ws:container` stream by lines as well as bytes; see [`ws:container` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wscontainer).
5 changes: 5 additions & 0 deletions .changeset/ws-container-prelude.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`createContainerModule({ prelude })` runs shell text such as `set -o pipefail` before each `ws:container` command; see [`ws:container` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wscontainer).
5 changes: 5 additions & 0 deletions .changeset/ws-container-tail-fallback.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`ws:container` keeps the end of each stream, up to `maxOutputLines` and `maxOutputBytes`, when a Workspace with `output: false` returns output whole, rather than its first `maxOutputBytes`; see [`ws:container` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wscontainer).
5 changes: 5 additions & 0 deletions .changeset/ws-tools-list-names.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudflare/computer": patch
---

`ws:tools` lists the tools code can import in its description; see [`ws:tools` documentation](https://github.com/cloudflare/computer/blob/main/docs/17_isolate_javascript.md#wstools).
21 changes: 12 additions & 9 deletions docs/04_filesystem_interface.md
Original file line number Diff line number Diff line change
Expand Up @@ -336,15 +336,19 @@ matched against each candidate's path **relative to `directory`**, not
its absolute path — so `**/*.ts` under `/workspace/src` matches
`a/b.ts`, not `/workspace/src/a/b.ts`.

The glob supports `*`, `**`, `**/`, and `?`. Character classes and
brace expansions are matched literally.
The glob supports `*`, `**`, `**/`, `?`, and brace alternatives:
`**/*.{ts,tsx}` matches either extension, and groups nest. A brace with
no comma, or with no closing brace, is matched literally, as in a
shell. Character classes are matched literally.

`exclude` takes globs of the same shape, matched against the same
relative path. An exclusion is decided before the inclusion glob, so it
always wins. When an excluded entry is a directory the walk prunes it:
neither the directory nor anything beneath it is read, which is what
makes skipping `node_modules` or `.git` cheap rather than merely quiet.
`limit` and `offset` then paginate whatever survives.
An exclusion ending in `/**` also excludes the directory it names, so
`node_modules/**` prunes `node_modules` itself; a file of that name is
kept. `limit` and `offset` then paginate whatever survives.

```ts
// Every TypeScript file in the project.
Expand All @@ -355,7 +359,7 @@ const all = await fs.find("/workspace/notes");

// Skip generated trees without descending into them.
const sources = await fs.find("/workspace", "**/*.ts", {
exclude: ["node_modules", "node_modules/**", ".git", ".git/**"],
exclude: ["{node_modules,.git}/**"],
});
```

Expand Down Expand Up @@ -424,9 +428,8 @@ paginate matching lines.
`exclude` takes globs of the same shape as `find`'s, matched against the same
directory-relative path and applied before `include`, so an exclusion always
wins. An excluded directory is pruned before its children are queried, so the
subtree costs nothing rather than being read and filtered. As with `find`, name
both the directory and its contents to skip a whole subtree: `node_modules/**`
matches what is below `node_modules`, not `node_modules` itself.
subtree costs nothing rather than being read and filtered. As with `find`,
`node_modules/**` skips the whole subtree, `node_modules` included.

`path` may be a directory or a single file. Directory searches return matches
in deterministic depth-first discovery order, then line order within each
Expand All @@ -437,7 +440,7 @@ traversal to prune, so `exclude` does not apply to it.
const hits = await fs.grep("TODO", "/workspace/src", {
ignoreCase: true,
include: "**/*.ts",
exclude: ["node_modules", "node_modules/**"],
exclude: ["node_modules/**"],
});
for (const hit of hits) {
console.log(`${hit.path}:${hit.line}: ${hit.text}`);
Expand Down Expand Up @@ -526,7 +529,7 @@ maps to `Workspace.fs`:
| `symlink` / `readlink` | `symlink` / `readlink` | Same argument order as Node. Targets are stored verbatim and may dangle. |
| `watch` | — | Low-level primitive in `fs/watch.ts` (`createWatcher`, `createWatchAsyncIterable`, `WatchHandle`, `WatchOptions`); not exposed on the `WorkspaceFilesystem` class. |
| `open` / `FileHandle` | — | Use streams instead. |
| `glob` | `find` | Limited glob support (`*`, `**`, `**/`, and `?`), plus `exclude` for pruning subtrees. |
| `glob` | `find` | Limited glob support (`*`, `**`, `**/`, `?`, and `{a,b}`), plus `exclude` for pruning subtrees. |
| — | `grep` | Not in `node:fs`; literal by default, with optional regular expressions. Shares `find`'s `include`/`exclude` globs. |
| — | `find` | Recursive directory walk with an optional glob, relative-rooted. |
| — | `ls` | Flat list of file paths under a directory (segment-aware). |
Expand Down
Loading
Loading