Describe the solution
I requested #5918 be reopened for tracking however I did not hear back so decided to create a new issue.
Currently, accessing a Durable Object over RPC in multiple wrangler instances causes this error:
Cannot access `MyDurableObject#myMethod` as Durable Object RPC is not yet supported between multiple `wrangler dev` sessions.
To get around this, you can start all your workers/durable objects in one command (same Miniflare instance) by chaining -c however, this is not ideal for several reasons such as large monorepos with dozens of workers and durable objects depending on each other. Another workaround is to create a wrapper instance that extends WorkerEntrypoint which just proxies everything to the DO but this is an extra layer and a ton of duplication.
Describe the solution
I requested #5918 be reopened for tracking however I did not hear back so decided to create a new issue.
Currently, accessing a Durable Object over RPC in multiple wrangler instances causes this error:
To get around this, you can start all your workers/durable objects in one command (same Miniflare instance) by chaining
-chowever, this is not ideal for several reasons such as large monorepos with dozens of workers and durable objects depending on each other. Another workaround is to create a wrapper instance that extendsWorkerEntrypointwhich just proxies everything to the DO but this is an extra layer and a ton of duplication.