#10513 Structured JSON logs with Error object show as empty object on dashboard
Confirmed Cloudflare production runtime limitation (not wrangler). Maintainer confirmed with observability team. Reporter accepted workaround (stringify errors).
Close with comment explaining platform limitation
Analysis Report
Issue Review: cloudflare/workers-sdk#10513
Summary
Structured JSON logs with Error objects appear as empty {} on Cloudflare dashboard despite showing data in local wrangler dev.
Findings
- Created: 2025-09-01
- Updated: 2025-09-02
- Version: Wrangler 4.33.1, Node 22.19.0, macOS 15.6.1
- Component: Cloudflare observability/logging (not workers-sdk)
- Labels: bug
- Comments: 2
Key Evidence
- Not a workers-sdk issue: A Cloudflare team member (@edmundhung) confirmed with the observability team that this is a "limitation in the production runtime when processing error objects" - meaning this is a Cloudflare platform limitation, not a wrangler/workers-sdk bug.
- Reporter accepted workaround: The reporter acknowledged the explanation and stated the workaround (stringifying Error objects) works for them.
- Issue is misplaced: This should be tracked in a Cloudflare platform/observability tracker if it needs to be tracked at all, not in workers-sdk.
Recommendation
Status: CLOSE
Reasoning: This is a confirmed limitation in the Cloudflare production runtime's observability system, not a bug in wrangler or workers-sdk. The Cloudflare team confirmed this, and the reporter has accepted the workaround. The workers-sdk repository is not the correct place for this issue.
Action: Close the issue with a comment explaining this is a platform limitation that has been acknowledged.
Suggested Comment
Closing this issue as it has been confirmed by the observability team that this is a known limitation in the Cloudflare production runtime when processing Error objects in structured logs.
The workaround is to stringify Error objects before passing them to console methods:
console.error('Message', { error: error.message, stack: error.stack }); // or console.error('Message', { error: JSON.stringify(error) });If you'd like to see this limitation addressed in the platform, please file feedback through the Cloudflare dashboard or community forums.
Thank you for reporting this!
Notes & Feedback (0)
No notes yet.