Goal
Raise the monorepo Bun floor from 1.3.7 to 1.4.0. Measure what 1.4 changes on this repo. Then keep only the test and runtime APIs that win on our machines.
Facts (2026-08-21)
- Latest stable is Bun 1.4.0, published 20 August 2026. No
1.4.x patch yet. Release · Blog
- Root
engines.bun is >=1.3.7. README and docs/self-hosting/README.md say the same.
- CI
setup-bun defaults to latest. Docker uses oven/bun:1-slim. Those may already pull 1.4 once Oven publishes the tag.
bun-types is still ^1.3.13 / ^1.3.14.
bun test runs on hocuspocus, email-templates, floating-popover, and hyperlink units. Jest and Cypress stay on Node or the browser.
- Official Bun 1.4 claims (quote only; not our numbers): idle CPU down 5×; memory down up to 35%; Linux start 50% faster;
Bun.serve peak 45 MB → 36 MB (−20%). Source: bun.com/blog/bun-v1.4
--parallel, --isolate, --shard, and --changed landed in 1.3.13. 1.4 adds --timings and isolate bug fixes. Test parallel docs
- Keep the metascraper
5.50.6 pin until bun -e "await import('metascraper')" succeeds on 1.4.0. The 1.4 post does not claim a require(esm) fix for mime@4.
- Do not
export default a Hono app. Bun still auto-serves that on :3000.
- Do not treat 1.4 as unlocking
@hocuspocus v4. The v4 Node crossws adapter still throws when "Bun" in globalThis.
- Do not replace Prisma, BullMQ, or ioredis with
Bun.SQL, Bun.cron, or Bun.redis on this ticket.
What to build
A measured upgrade. Not a rewrite.
- Soak 1.4.0 locally and in CI. Confirm Docker
1-slim is 1.4.
- Smoke: REST, WS, and worker start;
import('metascraper'); Prisma engines (NODE_MODULE_VERSION 147); Redis TLS names; pad persist (document:saved).
- Raise
engines.bun, bun-types, README, self-hosting, and AGENTS.md floors in the same change.
- On the
bun test suites only: try --isolate, then --parallel, then --timings plus --shard if CI time drops.
- Profile hocuspocus with
--cpu-prof-md / --heap-prof-md only if RSS or idle CPU improves versus 1.3.14. Consider process.on("memoryPressure") only after that profile.
- Re-check
idleTimeout default and the ws maxPayload ignore. Keep explicit idleTimeout: 60 unless 1.4 changes the hazard.
Out of scope
- Moving Jest or Cypress onto
bun test.
- Experimental HTTP/3 on
Bun.serve.
- Isolated linker or
lockfileVersion: 2 unless bun install forces it. Existing bun.lock stays hoisted.
@hocuspocus v4.
Acceptance criteria
Blocked by
None. Can wait for the product v2.0.0 tag if the maintainer wants that first. Does not depend on the Next 16 ticket.
Goal
Raise the monorepo Bun floor from
1.3.7to1.4.0. Measure what 1.4 changes on this repo. Then keep only the test and runtime APIs that win on our machines.Facts (2026-08-21)
1.4.xpatch yet. Release · Blogengines.bunis>=1.3.7. README anddocs/self-hosting/README.mdsay the same.setup-bundefaults tolatest. Docker usesoven/bun:1-slim. Those may already pull 1.4 once Oven publishes the tag.bun-typesis still^1.3.13/^1.3.14.bun testruns on hocuspocus, email-templates, floating-popover, and hyperlink units. Jest and Cypress stay on Node or the browser.Bun.servepeak 45 MB → 36 MB (−20%). Source: bun.com/blog/bun-v1.4--parallel,--isolate,--shard, and--changedlanded in 1.3.13. 1.4 adds--timingsand isolate bug fixes. Test parallel docs5.50.6pin untilbun -e "await import('metascraper')"succeeds on 1.4.0. The 1.4 post does not claim arequire(esm)fix formime@4.export defaulta Hono app. Bun still auto-serves that on:3000.@hocuspocusv4. The v4 Nodecrosswsadapter still throws when"Bun" in globalThis.Bun.SQL,Bun.cron, orBun.redison this ticket.What to build
A measured upgrade. Not a rewrite.
1-slimis 1.4.import('metascraper'); Prisma engines (NODE_MODULE_VERSION147); Redis TLS names; pad persist (document:saved).engines.bun,bun-types, README, self-hosting, andAGENTS.mdfloors in the same change.bun testsuites only: try--isolate, then--parallel, then--timingsplus--shardif CI time drops.--cpu-prof-md/--heap-prof-mdonly if RSS or idle CPU improves versus 1.3.14. Considerprocess.on("memoryPressure")only after that profile.idleTimeoutdefault and thewsmaxPayloadignore. Keep explicitidleTimeout: 60unless 1.4 changes the hazard.Out of scope
bun test.Bun.serve.lockfileVersion: 2unlessbun installforces it. Existingbun.lockstays hoisted.@hocuspocusv4.Acceptance criteria
bun --versionis 1.4.0 or newer.make dest-localstarts REST on:4000with no second listener on:3000.cd apps/hocuspocus.server && bun -e "await import('metascraper')"is recorded. Keep or drop the5.50.6overrides from that result, not from the blog.ERR_TLS_CERT_ALTNAME_INVALIDand the fix (servername).engines.bun, catalogbun-types, README,docs/self-hosting/README.md, andAGENTS.mdname the new floor.bun testis green on 1.4. The PR records whether--parallel,--isolate, or--timingsstayed.bun testwall-clock. Official Bun numbers are not a substitute.Blocked by
None. Can wait for the product
v2.0.0tag if the maintainer wants that first. Does not depend on the Next 16 ticket.