Skip to content

Releases

v0.57.0

Choose a tag to compare

@baronunread baronunread released this 17 Nov 17:39
eb810e9

Built on @sproutboat/toolchain 0.28.0 (Porffor alpha 25), with @sproutboat/runtime 0.47.0 and @sproutboat/wire 0.22.7 kept as in 0.56.1. This is the runtime generation bb0aefe9 that Sproutboat Cloud runs. Every app is recompiled on its next build. Breaking for standalone builds: Porffor alpha 25 is now the only compiler; alpha 24 is no longer supported.

Changed

  • Porffor alpha 25 replaces alpha 24. Alpha 25 brings faster string and Buffer handling, crypto.subtle AES-GCM, stream/consumers and two compiler fixes. SPROUTBOAT_PORFFOR_CHANNEL accepts alpha-25; alpha-24 is refused like the older channels.
  • @sproutboat/runtime stays on 0.47.0 and @sproutboat/wire on exactly 0.22.7. Runtime 0.48.0 carries the storage capture code (switched off), which changes the code every app with bindings compiles, so it ships with its own runtime generation later.
  • CI runs Bun 1.4.4, the version Sproutboat Cloud runs.

v0.56.1

Choose a tag to compare

@baronunread baronunread released this 16 Nov 20:25
4d18d96

[0.56.1] - 2026-11-16

Built on @sproutboat/runtime 0.47.0 and @sproutboat/wire 0.22.7 (the rest unchanged from 0.56.0). No generation change: apps that build today build to the same bytes.

Fixed

  • Bundles that merely mention node:async_hooks (or another node: module) in a string are no longer refused. The check now looks only at real imports and require calls, so libraries such as Effect build; a genuine unsupported import is still refused.
  • Dynamic import("cloudflare:workers") works like the static import (it resolves to env, WorkerEntrypoint, DurableObject and RpcTarget).
  • import.meta compiles in every form, with workerd's values: url is file:///bundle/index.js, main is true, resolve() works, env, dirname and filename are undefined. Before, forms other than url, filename, dirname and main failed the native build, and those four carried the build machine's path.
  • The repository moved to sproutboat/cli.

v0.56.0

Choose a tag to compare

@baronunread baronunread released this 16 Nov 07:33
8bdbd1a

[0.56.0] - 2026-11-16

Built on @sproutboat/runtime 0.46.0, @sproutboat/wire 0.22.6, @sproutboat/assets 0.3.1 and @sproutboat/toolchain 0.27.0 (config 0.6.0 and artifact 0.3.0 unchanged). This is the runtime generation b147117c that Sproutboat Cloud runs. Every app is recompiled on its next build, since the runtime prelude changed. Breaking for standalone builds: Porffor alpha 24 is the only compiler, and --with-restore is gone.

Added

  • sproutboat domains add <host>, verify <host> and delete <host> on a Cloud. A custom domain belongs to the team. add claims the hostname and prints the TXT record to publish; verify has the Cloud look the record up through two public resolvers and says whether the claim is now verified; delete releases the claim (refused while an app still routes it). Once a domain is verified, route it from the project (routes in the config; it needs the domain:write permission, so an Owner or Admin) and its certificate is ordered at the first visit. domains list shows the app's routes and the team's claims, each with its state (pending, verified or lost). Before, these three verbs answered that an operator adds custom domains.
  • sproutboat deploy --prepare-out <dir>. Does everything a Cloud deploy does before its first network call and writes it to <dir> instead of uploading: sprout.generated.js (the bundled, wrapped source the Cloud compiles), build.json, spec.json (bindings, crons, queue consumers, and service bindings by name), assets/manifest.json and assets/blobs/<sha256>. No login, no network, no secrets. It is what the Cloud's builder runs in its sandbox for a Git deploy.

Removed

  • sproutboat build --standalone --with-restore, and with it Porffor alpha 19. The flag (the APP ltx-restore --generation DIR --output NEW_DB [--txid N] startup command) is gone; using it fails with a message that says so. Offline LTX restore will come back later as a plain CLI command, sproutboat restore, rather than as something every standalone binary carries (docs/native-ltx-restore.md says where it went). If you built with --with-restore, drop the flag; a binary built without it behaves as before. The flag was the only reason the CLI still built with alpha 19: its restore objects were compiled against alpha 19's native-fetch C API. The CLI no longer acquires, patches or compiles with an alpha 19 tree. Removed with it: vendor/ltx-restore/ (the native restore codec and its notices), src/native-restore*.ts, the alpha 19 native compile path, porfforArgs, and SPROUTBOAT_COMPILE_TIMEOUT_MS (it only reached the alpha 19 compile; the default build never read it).

Changed

  • Porffor alpha 24 is the only compiler. SPROUTBOAT_PORFFOR_CHANNEL accepts alpha-24; alpha-19, alpha-21, alpha-22 and alpha-23 are errors that say they are no longer supported. Alpha 24 compiles TypeScript namespaces, enums and parameter properties, and decorators, which earlier channels rejected. sproutboat toolchain doctor and the artifact manifest name alpha 24 and the patched tree the toolchain ships. A standalone build's server (the uWebSockets shim, the web classes and the HTTP/1.0 edit) comes from sources vendored in @sproutboat/toolchain 0.27.0, byte for byte the ones the alpha 19 chain produced.
  • _redirects follows Cloudflare's matching (@sproutboat/assets 0.3.1, @sproutboat/wire 0.22.6). The whole request path must match, so a trailing slash is significant: /compare /compare/ 308 redirects /compare once and /compare/ is then served instead of redirecting to itself forever. :name matches up to the next / and may sit inside a segment, * matches anything including / and is :splat in the target, a static rule beats a dynamic one, and among rules of one kind the first in the file wins. Paths that differ only by a trailing slash match differently from before, with no compatibility date, because the edge serves assets before any app code runs.
  • Durable Objects leave memory when idle (@sproutboat/runtime 0.46.0), from compatibility date 2026-11-21; earlier dates are unchanged. An idle object is evicted and constructed again by its next event, with its storage, alarm and SQLite file kept. A pending timer, an unawaited fetch, an open WebSocket or connect() socket, or a streamed response keeps an object in memory. SB_DO_IDLE_MS, SB_DO_MAX, SB_DO_WAIT_MS and SB_DO_QUEUE_MAX tune it; a standalone binary keeps every object with an open socket in memory. Runtime 0.46.0 also makes SQLite page caches start at 256 KiB and grow on evidence (up to 2 MiB or the database's share of SB_MEMORY_LIMIT), which lowers the memory of an app with many databases.

v0.55.0

Choose a tag to compare

@baronunread baronunread released this 13 Nov 16:44
ab09748

Added

  • sproutboat init --template <name> writes a starter, with the shape of npm create cloudflare. Four starters, each standard Workers TypeScript that runs unchanged on workerd, with a README, tests (Node's own test runner, npm test), a tsconfig.json and a current worker-configuration.d.ts: realtime-room (a chat room on a Durable Object with hibernating WebSockets: acceptWebSocket, tags, serializeAttachment, presence, history), api-d1 (a JSON API on D1 with a migration, validation and keyset pagination), site-api (static assets plus /api/* routes and KV in one Worker) and jobs (a cron trigger that enqueues, a queue consumer with retries and idempotence, KV for state). --list-templates prints them. In a terminal init asks for the template, the directory, whether to install dependencies and whether to use git (both default to yes); -y (--yes, --accept-defaults) takes every default, --install / --no-install and --git / --no-git decide the two steps, and without a terminal nothing runs that a flag did not ask for. --git makes a first commit and does nothing inside an existing repository. init without --template is the hello starter it always was. The starters are embedded in the CLI as text (src/templates-embedded.ts, about 90 KiB, rewritten by bun run templates:embed), so the compiled executable needs no network or files beside it.
  • sproutboat dev --ip <address>. dev listens on 127.0.0.1 as before; --ip 0.0.0.0 makes it reachable from other machines, as wrangler dev --ip does.
  • A project with assets and no main is a Worker with only static assets, as in Wrangler. check, dev, build and deploy write a small entry into .sproutboat/assets-only.js that answers any request no file matched with env.<binding>.fetch(request), so not_found_handling (the single-page app shell, the nearest 404 page, or a plain 404) applies as it does on Cloudflare. The assets binding is assets.binding, or ASSETS when the config names none. Nothing else in the config changes: a project with a main is untouched, and one with neither still gets main must be a relative entry point under src/.
  • domains list works against a Cloud. It prints the app's routes from its record, marked built-in (under sproutboat.app) or custom. domains add, verify and delete on a Cloud say that custom domains are added by an operator for now and that deploys keep them, instead of calling Community's /api/projects/<name>/domains, which a Cloud does not have. domains takes --account <team>.

Changed

  • examples/ holds only what a person reads. The conformance, stress, runtime-comparison, workers-verbatim and workers-contract fixtures, the Cloudflare pattern ports (cf-*), request, upload and the harness library moved to test/fixtures/; kitchen-sink and quote-service, which are deployed on Sproutboat Cloud and check every generation swap, moved to dogfood/. Their deployed names and the bun run kitchen-sink scripts are unchanged.

  • sproutboat types writes worker-configuration.d.ts, like wrangler types. The file declares interface Env (and Cloudflare.Env, which import { env } from "cloudflare:workers" reads) with a type per binding, so a handler is typed as export default { ... } satisfies ExportedHandler<Env> and env.KV, env.DB and the rest autocomplete and are checked. Vars are literal types (--strict-vars=false makes them string); a Durable Object binding is typed with its class when the entry is TypeScript, so await env.COUNTER.getByName("a").increment() is checked. The command takes Wrangler's positional (the file to write), --env-interface, --strict-vars, --include-runtime, --include-env and --check, which exits 1 when the file is missing or out of date by the hash in its header. --include-runtime references the runtime types the CLI ships instead of copying them in, and there is no --include-main-module. The ambient types gain the Workers shapes the runtime already had: ExportedHandler, ScheduledController, DurableObjectNamespaceAsync with RPC stubs and getByName, DurableObjectStorageAsync with sql, FetcherAsync, R2ObjectBodyAsync.writeHttpMetadata, and a cloudflare:workers module (DurableObject, WorkerEntrypoint, RpcTarget, env). A project at or after compatibility date 2026-09-28 gets no global env; earlier ones still do. dev and deploy refresh the default file when a plain sproutboat types wrote it and the config has moved on, and leave one made with other flags alone.

  • deploy to a Cloud sends every binding. KV, D1, R2, queues, Analytics Engine, Durable Objects, rate limiters, the secret names, the assets binding and triggers.crons now go to the Cloud in the app record, in a build deploy and a module deploy alike, so examples/kitchen-sink runs there with all its bindings. The warning that they were "not sent to the Cloud by the CLI yet" is gone. Each app's Cloud storage is private to it, so the record's resource id is the binding name in lowercase (DB is db; a queue's is its queue name), and d1 execute --remote and r2 object address the binding name as before. Every queue is also a queue consumer (max_batch_size, max_batch_timeout in milliseconds, max_retries, dead_letter_queue, with Cloudflare's defaults). An account-level id in a binding is ignored with a warning. Before anything is uploaded the deploy refuses more than 16 crons, 16 queue consumers or 64 bindings (service bindings included), a cron or resource name the Cloud would refuse, and a durable_objects class the entry module does not export. --dry-run prints every binding, consumer and cron. A queue's retry_delay rides in the binding's config; the record has no field for it yet.

  • sproutboat dev relays WebSockets. The stable port now forwards an upgrade to the sprout and passes frames both ways, so a browser can use a WebSocket or a Durable Object chat under dev. Before, the upgrade went through a plain fetch and the client got a protocol error. Stopping dev closes open sockets instead of waiting for them.

  • examples/kitchen-sink is a dashboard. Every tile calls its real binding: a KV counter, a D1 guestbook that shows the SQL it ran, R2 upload and list, a Durable Object chat over WebSocket (hibernation API), a queue and cron feed read from D1, a service binding to quote-service, and secret names. Latency is measured in the worker with performance.now() and returned in Server-Timing; sizes are measured at build time. The Astro UI is gone; sproutboat.standalone.jsonc builds the same app as a standalone binary.

  • Every example is a standard Cloudflare Worker, and CI says so. examples/* are rewritten as TypeScript in the Workers style: export default { async fetch(request, env, ctx) } satisfies ExportedHandler<Env>, scheduled(controller, env, ctx), queue(batch, env, ctx), Durable Objects that extend DurableObject and are called over RPC (env.COUNTERS.getByName(name).increment()), a WorkerEntrypoint with an RPC method, every binding call awaited, await request.json(), Response.json(), and a schema created once instead of on every request. All are at compatibility date 2026-11-18, and each has a README (what it shows, run, deploy, curl lines) and a generated worker-configuration.d.ts. bun run examples:workerd translates each sproutboat.jsonc into a wrangler.jsonc, typechecks the entry against the runtime types wrangler types generates (no Sproutboat declaration in the program), runs it under workerd with wrangler dev and sends the same requests bun run examples sends the standalone binary; bun test runs it (so the CI check job does), and bun run examples:types verifies every worker-configuration.d.ts is current and typechecks, also under bun test. What is skipped is printed with its reason: analytics (query() is a Sproutboat extension) and outbound-fetch (the private-address refusal is Sproutboat policy) send only the requests Workers can answer. examples/README.md states the two rules the examples follow: standard Workers style, and no test-only code in examples.

  • examples/conformance: the binding conformance suite has its own fixture. The routes and vectors that existed only for tests (login and notes, the crypto vectors with crypto.scryptVerify, the async echo, the egress refusals, /admin/stats, the direct-transfer tickets, the service-binding probe) moved out of examples/kitchen-sink/src/index.js into a worker of their own, with its own checks on both backends (bun run conformance, bun run conformance:standalone: 34 and 37 checks). kitchen-sink is the demo only: the dashboard's API, its limits, the chat room and its cron jobs (77 and 75 checks), no binary-fixture.bin in the deployed site, no ViewCounter or QUOTE_URL. Its routes under /api, /healthz and the chat (/api/chat, the ?probe=1 probe, the 96 KiB history cap) are unchanged. bun run kitchen-sink and kitchen-sink:standalone still exist and run the demo's checks and then the conformance fixture's. Both harness pairs now share examples/lib/backends.ts.

  • kitchen-sink is Workers-style and runs on workerd. Its entry points take env as an argument (fetch(request, env), scheduled(controller, env), queue(batch, env)), ChatRoom extends DurableObject, and its tables are created once per process instead of on every request. Running it under workerd found two bugs that Sproutboat's runtime had hidden, both fixed: env.SESSIONS.list("") (the pre-2026-10-25 argument, which throws on Workers) and a chat broadcast that sent to a socket already closing. It has a worker-configuration.d.ts and JSDoc types for env; the entry stays JavaScript because the Code panels excerpt it and the harness compiles it as it is.

Fixed

  • **deploy to a Cloud no longer un...
Read more

v0.54.0

Choose a tag to compare

@baronunread baronunread released this 11 Nov 08:40
03b0e5d

Built on @sproutboat/runtime 0.44.0, @sproutboat/wire 0.22.4 and @sproutboat/toolchain 0.24.2 (runtime and wire from 0.43.0 and 0.22.3). Runtime 0.44.0 adds service bindings between Cloud apps from compatibility date 2026-11-18; every app is recompiled on its next build, since the runtime prelude changed. The Cloud-only features below need a Cloud control plane with sproutboat-cloud#42, #45 and #49; remote D1 and R2 also need a host whose agent serves the data routes (sproutd#93).

Added

  • Profiles: --profile <name> and SPROUTBOAT_PROFILE. A profile is an endpoint, its stored credential and a default team, so one machine can hold a Community login and a Cloud login side by side and say which one a command uses. login --profile <name> makes one (it fixes the endpoint, so --api-url must match when the profile exists), logout and whoami act on the profile in use, profile list shows them and profile use <name> changes the default. whoami and deploy now start with two lines, profile and endpoint, so a deploy never goes somewhere unannounced. A profile and an endpoint that name different places (--profile cloud --api-url <community>, or the same pair in the environment) are an error. Precedence: --api-url and --profile, then SPROUTBOAT_API_URL and SPROUTBOAT_PROFILE, then the default profile, then https://dash.sproutboat.com; --profile beats SPROUTBOAT_API_URL and --api-url beats SPROUTBOAT_PROFILE.

  • Global flags with Wrangler's meanings, accepted before or after the command: -c, --config <file> (the project's config file; its directory is the project), --cwd <dir>, -e, --env <name>, --env-file <file> (repeat it; later files override earlier ones) and -v, --version. dev and run still take --env and --env-file as before, now through the same parser, and --flag=value works. A flag a command cannot honour is refused (deploy --env staging exits 2 instead of deploying), a repeated single-value flag takes its last value, and everything after -- is left alone.

  • r2 object get | put | delete <bucket>/<key>, with Wrangler's flags. get takes --file <path> or --pipe (bytes to stdout) and, with neither, writes ./<key> like Wrangler; put takes --file or --pipe plus --content-type, --content-disposition, --content-encoding, --content-language, --cache-control (short forms --ct --cd --ce --cl --cc) and --expires, and uses the file's type when no content type is given; delete is idempotent. On a Cloud endpoint <bucket> is a binding from r2_buckets and the objects live in the app's bucket on its host, 64 MiB each. A key follows the Cloud's rules (1 to 1024 bytes of UTF-8, no control character, no backslash, no empty, . or .. segment) and a bad one is refused with the reason before anything is sent. A download is an inert attachment (application/octet-stream, nosniff, CSP: sandbox), so the object's own type is read from x-object-content-type (only when it was stored) and shown in the note; a PUT always declares its length. data:read (get) and data:write (put, delete) are the grants: a key without one is told which, and how to get it (the "Deploy and data" or "Read data" key preset). A rate limit and a busy host say when to retry; a backup capture, a full quota (507) and a failed audit each have their own message; a 502 or 503 from a Cloud host that does not serve R2 yet says "remote D1/R2 isn't available on this Cloud host yet". --profile, -c and --cwd work as everywhere, and an unknown option is refused. Unlike Wrangler there is no local mode yet (--local is refused with the reason, and remote is the default), since dev keeps R2 objects in its broker store. On self-hosted Community get reads through the existing route by bucket name, and put and delete report that they are not supported yet. Follows sproutboat-cloud#49 (docs/host-data.md); real data needs a host agent that serves the R2 routes.

  • deployments list | status | tail <id>. list shows the 10 most recent deployments of the project in this directory, newest first, with the live one marked; status shows what is live and whether a host applied it; both take --json. On a Cloud endpoint a deployment is a build (GET /v1/apps/<app>/builds): tail <id> follows it server-side, from its first log line to its end state, so a deploy that was detached with Ctrl-C can be picked up again; it exits 1 when the build failed or was cancelled, and Ctrl-C only stops following (exit 130, the build keeps running). On self-hosted Community a deployment is a version, list and status read /api/projects/<app>/deployments, and tail says there is nothing to follow. Needs sproutboat-cloud#49 for the build list.

  • secret is secrets, and secrets bulk [file] takes Wrangler's bulk file. secret bulk reads JSON {"NAME": "value", "OLD": null} (a null deletes) or a .env file (no deletes), from the file or stdin, at most 100 entries, and refuses a bad name or value by name before sending anything. On a Cloud endpoint it is one PATCH /v1/apps/<app>/secrets, so one new version. secrets put, delete and bulk now wait for a host to apply that version, as wrangler secret put deploys at once (the Cloud already re-ships the same module with the new sealed secrets as a new record generation); --no-deploy returns as soon as the change is stored, which is what they did before. A host that fails to apply it is an error with the host's reason. Self-hosted Community still applies secrets on the next deploy or restart of the app (it has no redeploy route), so --no-deploy changes nothing there and bulk is one call per name.

  • d1 execute and d1 migrations create | list | apply, with Wrangler's semantics. d1 execute <database> --command <sql> | --file <path> runs every statement of the script in order, in one transaction, against the local dev database (.sproutboat/dev/d1/<BINDING>.sqlite) unless --remote is given, as Wrangler does; it prints JSON ([{ results, success, meta }]) when --json is passed or stdout is not a terminal. <database> is a binding from d1_databases. --persist-to <dir> moves the local state, --yes skips the remote --file confirmation. Migrations are migrations/NNNN_<name>.sql (the top-level migrations_dir in sproutboat.jsonc changes the folder; create starts at 0001 and goes one past the highest), applied in order, each in one transaction with its row in the d1_migrations table (id, name, applied_at, Wrangler's schema); the first failing migration is rolled back, the earlier ones stay applied, and the command exits 1. A terminal asks before applying; CI does not. --remote needs a Sproutboat Cloud endpoint and its POST /v1/apps/<app>/d1/<BINDING>/query (data:write to change data, data:read to SELECT only; a key without the grant is told which one and how to get it). A busy host, a rate limit, a refused statement (refused), a SQL error (with its statement number), a paused backup capture, a memory limit and a full quota each get their own message; a 502 or 503 from a Cloud host that does not serve D1 yet says "remote D1/R2 isn't available on this Cloud host yet". On self-hosted Community it says it is not supported yet. Follows sproutboat-cloud#49 (docs/host-data.md); --profile, -c and --cwd work as everywhere.

  • login on a Sproutboat Cloud endpoint is the device-code flow (RFC 8628). It prints a code and a link, opens the browser when it can, and stores an account API key (CLI on <hostname>, Developer at most) for the team you approve. logout revokes that key on the server and then forgets it; whoami shows the team, the key and its access, and exits 1 when not logged in. --account <team> preselects a team.

  • deploy to the Cloud builds from source. It bundles the project, uploads the generated source by sha256 (skipped when the Cloud has it), asks the Cloud to build it, streams the build log ( | per line), then prints ✓ Built in 4.1 s · peak memory 742 MB (cap 1200 MB) and waits for a host to apply the generation the build wrote. Assets go up by hash first. A dropped log stream resumes from the last line and then falls back to polling; Ctrl-C cancels the build (exit 130); --no-wait returns once the build is accepted and prints /v1/builds/<id>; --dry-run says it would build in the Cloud. A queued build the builder is holding back shows why (for example waiting for memory (1172 MB available, a build needs 1600 MB)) and keeps waiting. A failed build prints its reason, its peak memory when known, and exits 1; a Cloud with builds off or no builder says so, and a 429 shows the Cloud's message. Then it prints https://<app>.<team>.sproutboat.app. --module app.so and --sproutd with --generation stay as operator paths; a team key's module upload is refused with "modules are built by the Cloud; run `sproutboat deploy` without --module". Logged out in a terminal it logs in first; with no terminal it fails naming SPROUTBOAT_API_TOKEN. Other bindings and crons in sproutboat.jsonc are not sent yet and the deploy warns.

  • SPROUTBOAT_API_TOKEN always wins over a stored login (SPROUTBOAT_TOKEN stays as the older name). SPROUTBOAT_ACCOUNT and an account field in sproutboat.jsonc choose the team, like Wrangler's account_id. Several teams can be stored per endpoint.

  • The deploy target is the endpoint you are logged in to. The CLI asks it what it is (GET /v1/config) and deploys the Cloud way or the Community way. There is no --cloud flag, since Wrangler also has one target chosen by credentials.

  • secrets put, list and delete work on a Sproutboat Cloud app, by name through /v1/apps/<app>/secrets, independent of deploys like wrangler secret. An app that is not deployed says to deploy first or pass --secrets-file on the first deploy; a 403 names secret:write or `secret:li...

Read more

v0.53.1

Choose a tag to compare

@baronunread baronunread released this 09 Nov 17:10
5c89d96

Built on @sproutboat/runtime 0.43.0, @sproutboat/wire 0.22.3 and @sproutboat/toolchain 0.24.2, unchanged from 0.53.0. No runtime or wire change, so there is no new compatibility date and no recompile.

Changed

  • init adds sproutboat to the project's devDependencies and the dev, deploy and check scripts, the way Cloudflare's templates do for Wrangler, so a project pins the CLI version that compiles it and npm run deploy works after npm install. The range is a caret on the running CLI's version. A missing package.json is created (private, version 0.0.0); an existing one keeps its fields and indentation, a script with the same name is never overwritten (init prints a warning naming it), and a sproutboat already declared in any dependency section is left as is. An unreadable package.json stops init before any file is written. The next step it prints follows the project's package manager (a lockfile, then the launching tool, then npm), for example cd hello && pnpm install && pnpm run dev (pnpm run, because pnpm deploy is pnpm's own command).

v0.53.0

Choose a tag to compare

@baronunread baronunread released this 09 Nov 03:14
a8e2239

Built on @sproutboat/runtime 0.43.0, @sproutboat/wire 0.22.3 and @sproutboat/toolchain 0.24.2. The runtime change is the opt-in SB_LOG=json log below; without it nothing an app can observe changes, so there is no new compatibility date. Every app is recompiled on its next build, since the runtime prelude changed.

Added

  • sproutboat tail --file <log|-> follows a standalone binary's request and error records (#268). Run the binary with SB_LOG=json (runtime 0.43.0 writes them) and tail --file prints the last 10 matching records, then new ones as they are written, in pretty lines or one JSON record per line (--format json). --status, --method and --search filter; --lines sets the snapshot size and --no-follow prints it and exits; --file - reads a pipe such as journalctl -f -o cat. An error follows its request's filters, and errors from background work always show. A missing file is waited for, a rotated or truncated file is reread from its start, a line over 64 KiB is skipped and counted, control characters are replaced before printing, and only known fields are written, so output stays bounded and parseable. It needs no login or network and ends with exit 0 on Ctrl-C. The existing control plane tail (live stream, --format json, filters, --recent, --sprout) is unchanged. See "Logs" in docs/standalone.md.
  • sproutboat run launches a standalone binary with its settings supplied at launch (#275). sproutboat run [project-dir] --env-file prod.env --port 80 --data-dir /var/lib/app starts dist/<name> (or --binary) with an environment built from three layers, highest first: --port and --data-dir, the --env-file files (repeat the flag; a later file overrides an earlier one), then the inherited environment. Like wrangler deploy, it fails before the binary starts when a declared secret (the config's secrets plus --require) is unset or empty; --check validates and prints a summary without starting it. The summary names each secret and the layer it came from, never a value, nothing is written to disk, and the binary and its artifact metadata are untouched, so the identical binary moves between development and production. SIGINT, SIGTERM and SIGHUP are passed to the binary and its exit status is returned. examples/vars-secrets walks through it.

Changed

  • init scaffolds the Workers-style handler. New projects get compatibility date 2026-09-28 and fetch(request, env, ctx), so env and ctx are available without a date bump. Existing sproutboat.jsonc files are never rewritten, and projects on older dates keep their behavior.
  • sproutboat dev takes local secrets the way Wrangler does (#275). .dev.vars or the .env files, never both (a warning names the ignored ones); --env <name> selects .dev.vars.<name> and the .env.<name> files; the .env files layer .env.<name>.local, .env.local, .env.<name>, .env; CLOUDFLARE_LOAD_DEV_VARS_FROM_DOT_ENV=false turns them off; --env-file <file> (repeatable, later overrides earlier) replaces the default set. The process environment is not passed to the app, except for declared secret names when CLOUDFLARE_INCLUDE_PROCESS_ENV=true and no .dev.vars is in use, and files win over it. A declared secret with no value is a warning and dev still starts. Files use dotenv syntax; a line that is not an assignment is skipped with a file:line warning that never repeats the line.
  • .dev.vars is now parsed with dotenv syntax. It used to be a simpler format. The differences that can matter: an unquoted value ends at a # (it used to keep it), quotes may be single, double or backtick, double quotes expand \n, and the last of a repeated name wins. A line that is not an assignment is skipped with a warning instead of silently.
  • docs/standalone.md no longer lists <data>/secrets.json: a standalone binary has only ever read secrets from the environment.

Fixed

  • The native conformance harnesses no longer hang on a stalled response (#276). The broker and standalone kitchen-sink harnesses and the small-example smoke runner give every HTTP and raw-socket request a deadline (SB_HARNESS_REQUEST_TIMEOUT_MS, default 30 s) that covers the whole body, and bound readiness (SB_HARNESS_READY_TIMEOUT_MS) and compilation (SB_HARNESS_BUILD_TIMEOUT_MS) separately, so a slow build cannot look like a hung handler. A timeout, or a child that exits during a request, reports the step, backend, runtime and toolchain versions and the child's recent stderr with secret values removed. Only the run's own children are stopped and its temp dir removed, on failure and on SIGINT or SIGTERM. Fault-injection tests cover a server that never completes a body and a child that exits mid-request. This is repository tooling; the shipped CLI does not change.

v0.52.1

Choose a tag to compare

@baronunread baronunread released this 08 Nov 22:12
94caba1

Built on @sproutboat/toolchain 0.24.2, @sproutboat/runtime 0.42.2 and @sproutboat/wire 0.22.2. The compiler output changes (four Porffor alpha 22 miscompile fixes in the toolchain), so every app is recompiled on its next build. Nothing else an app can observe changes, so there is no new compatibility date.

Fixed

  • Four Porffor alpha 22 miscompiles are fixed (toolchain 0.24.2), found with postgres.js and drizzle-orm. A method call on a receiver of unknown type evaluated its arguments in C's unspecified order, so buf.toString("utf8", i, i += n) returned "". A class declaration that is assigned to, such as TypeScript's (SQL || (SQL = {})) namespace merge, never stored the class in its binding and died with "Cannot get property of null". The right operand of ||, && and ?? retyped a local at compile time as if it always ran, so the same pattern inside a function still failed. new Date(s) returned NaN for +HH and +HHmm offsets such as Postgres' 2026-11-08 14:48:19.097+00; they now parse, together with +HH:mm.
  • A warm standalone build no longer recompiles every C unit. The alpha 22 build cleared the units directory, object cache included, before each render, so every build paid the full C compile (about 13 s for hello on an M1). It now clears only the previous render and keeps obj/; a unit whose text and flags are unchanged is not compiled again.
  • build --standalone --target host uses the compile cache. An unchanged host build returns in about 0.2 s (was about 39 s for hello). The key includes the host compiler's name and --version banner. Dev builds still bypass it.

v0.52.0

Choose a tag to compare

@baronunread baronunread released this 06 Nov 20:32
35a3d16

[0.52.0] - 2026-11-06

Built on @sproutboat/toolchain 0.24.1, @sproutboat/runtime 0.42.2 and @sproutboat/wire 0.22.2. The compiler changes, so every app is recompiled on its next build. Nothing an app can observe changes apart from the two fixes below, so there is no new compatibility date.

Changed

  • Standalone binaries and deploys now build with Porffor alpha 22 (was alpha 19). Binaries are about 5% smaller (hello 6.58 to 6.27 MB, stress 6.62 to 6.30 MB, linux-x64). Apps using jose, yaml, supabase-js and Neon (HTTP, and Pool over WebSocket) are checked route by route and give the same results as on alpha 19 and on Bun. Measured against alpha 19 on the same box: idle memory is 3 to 7% lower, requests per second are 5 to 15% lower, p50 latency is 3 to 8% higher, and p95 is up to about 30% (5 to 8 µs) higher on a request-heavy app. The module is composed the way sproutd's workers are, so no Node runtime module is linked, and it is served by the same uWebSockets server as before (WebSockets, streaming, graceful restart). LTO is on for optimized builds.
  • Fallback: SPROUTBOAT_PORFFOR_CHANNEL=alpha-19 builds with the previous alpha 19 compiler for this release only; it will be removed in the next one. The compile cache is keyed by channel, so switching back and forth does not reuse the wrong binary. The artifact manifest and sproutboat versions view now report the Porffor release a build actually used (alpha-22 (a081ebd)).
  • build --standalone --with-restore stays on alpha 19 for now. Its offline ltx-restore command is built against alpha 19's native C API, which alpha 22 does not provide yet, so such a build uses the alpha 19 compiler. Setting SPROUTBOAT_PORFFOR_CHANNEL=alpha-22 together with --with-restore is an error, not a link failure.

Fixed

  • A Uint8Array or ArrayBuffer response body is sent with its real length. On the alpha 22 server the bridge read the length from the buffer's flags word, so such a response went out with Content-Length: 2147483647. Found while qualifying alpha 22. No release ever shipped it, since alpha 19 was the default until now.
  • Neon's Pool over WebSocket no longer hangs. Alpha 22 linked its Node runtime's process, setImmediate, clearImmediate and global for any app that named them. pg-pool then queued on process.nextTick, and a standalone binary never drains that queue. These four names are now absent, as on alpha 19, so libraries no longer take their Node code paths.

v0.51.1

Choose a tag to compare

@baronunread baronunread released this 05 Nov 04:17
8949107

[0.51.1] - 2026-11-05

Built on @sproutboat/runtime 0.42.2, @sproutboat/toolchain 0.23.1 and @sproutboat/wire 0.22.2. Nothing an app can observe changes except latency, the refused address ranges below and the startTls() write order, so there is no new compatibility date.

Fixed

  • Bytes written right after socket.startTls() no longer go out unencrypted. On a connect() socket, the I/O thread took the start-TLS request and the app's queued writes in the same pass, and flushed all of them in plaintext before switching to TLS. Any write queued before the thread picked up the upgrade could leave in the clear. Only the bytes written before startTls() now go out in plaintext. Everything after waits until the TLS engine owns the socket, and new writes on the old plaintext socket reject, as in workerd. A failed plaintext flush is now a connection error. The egress tunnel also no longer stays paused on the discarded plain socket after an upgrade under backpressure.

  • The BearSSL source ships in the package (vendor/bearssl, 867 KB) and is read first, hash-verified, so builds no longer depend on bearssl.org being up. bearssl.org stays as the fallback, with bounded retry on 5xx. Every source, vendored or downloaded, is checked against the pinned sha256, so a bad file cannot change what gets built.

  • A malformed connect() tunnel opening frame no longer ends the egress process. A tcp.open head whose JSON did not parse used to throw out of the egress service's socket handler before the token was checked, which took egress down for every app. It now gets an expected tcp.open error frame and only that connection closes; the broker answers it as a bad request, and a refused head stops buffering whatever the client keeps sending.

Changed

  • fetch() and connect() refuse more reserved address space that carries no public service: AS112 and the old IPv4 anycast blocks (192.31.196.0/24, 192.52.193.0/24, 192.88.99.0/24, 192.175.48.0/24), SIIT (::ffff:0:0:0/96), IETF protocol assignments including Teredo (2001::/23), 3fff::/20 and SRv6 (5f00::/16). This applies to the broker, the egress service and a standalone binary alike, and SB_EGRESS_ALLOW still overrides it.

Performance

  • Outbound TCP sockets set TCP_NODELAY. Nagle's algorithm and the peer's delayed ACK stalled every fresh HTTPS fetch() by about 44 ms on Linux, because each small TLS handshake flight waited for an ACK; a fresh fetch now takes about 1.4 ms. This covers fetch(), outbound WebSockets and connect() on a standalone binary, including sockets handed over by SB_EGRESS_FD, and the egress tunnel's connections to origins.