Skip to content

Running the hosted relay locally on macOS fails: Node 22 is unstated and the build hook reads /proc/pressure/io #2529

Closed

Description

@AbirAbbas

What happened

On dev@b5b7dead1, running the hosted relay locally on macOS, as relay/hosted/README.md "Run it locally" describes, fails in two ways before the relay starts.

  1. wrangler refuses Node below 22, and the README names no Node version:
Wrangler requires at least Node.js v22.0.0. You are using v20.19.5
  1. The [build] hook in relay/hosted/wrangler.toml runs scripts/raft-hosted-build.sh, which waits on Linux-only /proc/pressure/io through scripts/raft-proof-footprint.sh:
awk: can't open file /proc/pressure/io
...
Running custom build ... failed

A third, smaller one: with Node 24's npm, npm ci in relay/hosted skipped the esbuild and workerd install scripts, and wrangler dev then could not start. Installing with Node 20's npm and running with Node 24 worked.

Replication

Deterministic (no model). On a Mac with Node 20 as the default:

cd relay/hosted && npm ci && npm run dev

It fails with the first message above. Switching to Node 22 or newer then fails on the build hook with the second message.

Where

scripts/raft-proof-footprint.sh (the /proc/pressure/io loop), which scripts/raft-hosted-build.sh calls; relay/hosted/wrangler.toml [build]; the "Run it locally" section of relay/hosted/README.md.

The fix

  • The pressure check. Skip it, with no error, where /proc/pressure/io does not exist (macOS, or Linux without PSI), so the hook builds core.wasm everywhere. The wait stays exactly as it is where the file exists.
  • The Node version. The README's local-run section names the version CI uses, Node 22, and says how to check it.
  • The install scripts. Name the workaround in the README until it is understood.

Acceptance

  • e2e: on macOS, cd relay/hosted && npm ci && npm run dev with Node 22 builds core.wasm through the hook and serves on 127.0.0.1:8787.
  • Unit: scripts/raft-proof-footprint.sh with no /proc/pressure/io runs its command at once and exits with the command's status; with the file present it waits as before. A script test that covers this belongs in make test-tooling.

Activity

  1. added a commit that references this issue on Nov 9, 2026
    35d38c5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions