#11095 Cross-Process Communication breaks when specifying environment
Not a bug - expected behavior. Worker name becomes worker-name-environment with -e flag, so service bindings must use full name. Reporter confirmed fix works. Documentation improvement should go to cloudflare-docs repo.
Close with redirect to cloudflare-docs for documentation improvement
Analysis Report
Issue Review: cloudflare/workers-sdk#11095
Summary
Cross-process communication fails when using wrangler dev -e <environment> because environment suffix changes worker name used in service bindings.
Findings
- Created: 2025-10-24
- Updated: 2025-11-04
- Version: wrangler 4.45.0, @cloudflare/vite-plugin 1.13.15
- Component: wrangler, vite-plugin
- Labels: bug, documentation, error-messaging
- Comments: 4
Key Evidence
Root cause identified by maintainer: @petebacondarwin explained that running
wrangler dev --env developmentchanges the worker name fromworker-btoworker-b-development. Service bindings must reference the full name including environment suffix.Reporter confirmed resolution: @tenpaiyomi stated "absolutely brilliant, that works, thank you so much!" after updating service binding configuration to use the environment-suffixed name.
Converted to documentation improvement: @petebacondarwin moved to backlog stating "Moving to backlog to track improving the documentation around this."
Documentation gap identified: Reporter noted the behavior is only documented in the wrangler environments page, not in the main service bindings documentation.
Recommendation
Status: CLOSE
Reasoning: The original bug report has been fully resolved - it was not a bug but expected behavior that wasn't well documented. The user's issue is fixed, and the remaining work (documentation improvement) belongs in the cloudflare-docs repository, not workers-sdk. Documentation issues for Cloudflare products are tracked in cloudflare/cloudflare-docs.
Action: Close with comment redirecting documentation improvement to cloudflare-docs repo.
Suggested Comment
This issue has been resolved - the behavior is working as intended. When using
wrangler dev --env <environment>, the worker name becomes<worker-name>-<environment>, and service bindings must reference this full name.For the documentation improvement request (adding this information to the service bindings docs), please open an issue in cloudflare/cloudflare-docs where the Workers documentation is maintained.
Closing as the underlying functionality is working correctly. Thank you for the detailed report and for helping identify the documentation gap!
Notes & Feedback (0)
No notes yet.