Skip to content

Shopify Hydrogen Server Instrumentation Error #15612

Closed
@allenjiang17

Description

@allenjiang17

Environment

SaaS (https://sentry.io/)

Steps to Reproduce

I've followed this guide to set up Sentry for Shopify Hydrogen:
https://docs.sentry.io/platforms/javascript/guides/remix/frameworks/hydrogen/

Specifically, instrumenting the server build

const instrumentedBuild = instrumentBuild(remixBuild)

causes an error in my server build. When I make a request to any of my server actions, I get the error

TypeError: Cannot read properties of undefined (reading 'sendDefaultPii')
at /Users/.../fp_storefront_hydrogen/node_modules/@sentry/remix/build/esm/server/errors.js:132:21

I've confirmed that it's specifically this step of instrumenting the server build that causes the problem, as when I comment it out and make requests to my server actions, it works fine.

Expected Result

No errors upon making requests to server actions after instrumenting the server build.

Actual Result

TypeError: Cannot read properties of undefined (reading 'sendDefaultPii')
at /Users/.../fp_storefront_hydrogen/node_modules/@sentry/remix/build/esm/server/errors.js:132:21

Product Area

Unknown

Link

No response

DSN

No response

Version

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

Waiting for: Product Owner

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions