vercel / vercel/workflow

Cannot find module '@workflow/world-postgres'

Open
#689 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
2.4k
Forks
365
Avg merge
2d 11h
Merged PRs (30d)
169

Description

I followed the instructions in https://useworkflow.dev/docs/deploying/world/postgres-world. I'm using Next.js 16.1.1. Deployed to Vercel (Node 24). got this error when I called the end point:

2025-12-26 09:20:40.395 [info] Starting Postgres World...
2025-12-26 09:20:40.395 [info] Failed to prepare server Error: An error occurred while loading instrumentation hook: Cannot find module '@workflow/world-postgres'
Require stack:
- /var/task/index.js
    at <unknown> (../../opt/rust/nodejs.js:2:13529)
    at Module.dn (../../opt/rust/nodejs.js:2:13907)
    at Je.e.<computed>.ze._load (../../opt/rust/nodejs.js:2:13499) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [Array]
}
2025-12-26 09:20:40.395 [info] Failed to prepare server Error: An error occurred while loading instrumentation hook: Cannot find module '@workflow/world-postgres'
Require stack:
- /var/task/index.js
    at <unknown> (../../opt/rust/nodejs.js:2:13529)
    at Module.dn (../../opt/rust/nodejs.js:2:13907)
    at Je.e.<computed>.ze._load (../../opt/rust/nodejs.js:2:13499) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [Array]
}
2025-12-26 09:20:40.400 [error] Error: An error occurred while loading instrumentation hook: Cannot find module '@workflow/world-postgres'
Require stack:
- /var/task/index.js
    at <unknown> (../../opt/rust/nodejs.js:2:13529)
    at Module.dn (../../opt/rust/nodejs.js:2:13907)
    at Je.e.<computed>.ze._load (../../opt/rust/nodejs.js:2:13499) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [Array]
}

Same thing with Redis world. The only way I can use workflow is with Vercel World in Pro plan. Hobby plan doesn't work which is annoying.

The packages:

npm list
my-workflow-next-app@0.1.0 
├── @emnapi/core@1.7.1 extraneous
├── @emnapi/runtime@1.7.1 extraneous
├── @emnapi/wasi-threads@1.1.0 extraneous
├── @napi-rs/wasm-runtime@0.2.12 extraneous
├── @tailwindcss/postcss@4.1.18
├── @tybys/wasm-util@0.10.1 extraneous
├── @types/node@20.19.27
├── @types/react-dom@19.2.3
├── @types/react@19.2.7
├── @workflow/world-postgres@4.1.0-beta.23
├── eslint-config-next@16.1.1
├── eslint@9.39.2
├── next@16.1.1
├── react-dom@19.2.3
├── react@19.2.3
├── tailwindcss@4.1.18
├── typescript@5.9.3
└── workflow@4.0.1-beta.36

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the documented Postgres World setup in a Next.js 16.1.1 app deployed to Vercel on Node 24, then inspect how the instrumentation hook loads @workflow/world-postgres and the Redis world. Done means the documented worlds work on the reported deployment plan without the MODULE_NOT_FOUND error.

Written by the indexing model from the issue text.

Assessment

Tech stack
next.js, node.js, postgresql, redis, typescript
Domain
backend, cloud, databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.