Skip to content
pi-c View Ticket
Login

View Ticket

A remote command tool for the build with no operating system

Opend909e0fe55c1cc2bcead0392510f004ed0312b49Created 11.2 days agoUpdated 11.1 days ago
Description2026-11-19 19:05:47
An option, not the way pic runs: in a build with no operating system (pic alone in a microVM, its workspace as SQLite rows through cowoco and onefile, ticket ff1a4dc200) there is no bash. pic offers a separate tool there, available only in that build, that runs a command on a runner machine. Not to be built yet.

How a call works: (1) pic checks in the working copy if it has changes, as a private scratch check-in; (2) pushes it to the runner with Fossil sync; (3) sends the effect id, the check-in, the command and a time limit; (4) the runner, an ordinary machine with fossil and the toolchain, moves its long-lived checkout to that check-in and runs the command (build outputs stay there, so builds stay incremental); (5) if tracked files changed, it checks them in as a child and returns the output and that check-in; (6) pic pulls it and updates its rows. Fossil carries changes both ways; rows are never shown as files and no disk is scanned. Requests are keyed by effect id, so after a crash pic asks the runner what happened instead of marking the call unknown.

Fits pic_executor (src/pic.h): file operations stay on the rows; only run goes to the runner.

Needs: the database workspace and the BearSSL sync channel (ticket ff1a4dc200); the runner service; the check-in step before a call; a rule for files added on either side (cowoco needs an explicit add; the runner needs ignore globs).

Decision taken: scratch check-ins are private and pushed only to the runner, if libfossil can make private check-ins (to verify first; its sync has privateContent). Otherwise a clone only the runner holds.

Rejected: no command tool at all (the agent cannot build or test); a userland in the VM over the rows; serving the rows as a network filesystem; WASI toolchains inside pic; CI as the runner (minutes per call, cannot return formatter edits).

2026-11-19 19:05:55
Correction: where scratch check-ins live is not decided yet. Proposed: private, pushed only to the runner, if libfossil can make private check-ins; otherwise a clone only the runner holds. Ordinary branches would be simplest but keep every command in project history. To decide when this is built.