Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sentry for Remix overwrites root loader data #5553

Closed
3 tasks done
mattrigg9 opened this issue Aug 9, 2022 · 4 comments
Closed
3 tasks done

Sentry for Remix overwrites root loader data #5553

mattrigg9 opened this issue Aug 9, 2022 · 4 comments
Labels
Package: remix Issues related to the Sentry Remix SDK Type: Bug

Comments

@mattrigg9
Copy link

mattrigg9 commented Aug 9, 2022

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which package are you using?

@sentry/remix

SDK Version

7.9.0

Framework Version

18.2.0

Link to Sentry event

No response

Steps to Reproduce

Since Sentry 7.9.0, any data returned by the root loader is overwritten with an object with only sentryTrace and sentryBaggage attributes. Looking at this PR, appears these attributes were meant to be merged alongside the original loader response.

Expected Result

The root loader should return an object with the user's returned attributes, merged with Sentry wrapped attributes.

Actual Result

Returned data:
Screen Shot 2022-08-09 at 2 58 28 PM

useLoaderData() response:
Screen Shot 2022-08-09 at 2 58 46 PM

@shirshendubhowmick
Copy link

Exact same issue

@Fenntasy
Copy link

Fenntasy commented Aug 10, 2022

I have the same bug and the issue here is the use of the json function.

in your example, replacing it with:

export async function loader({ request }) {
  return { test: "foo" };
}

Should make it work but that's not the way of fixing it. However, I see it has been fixed in the code already, just not published so I hope it should be good quickly.

EDIT: It's been fixed 14h ago 9d38065

@onurtemizkan
Copy link
Collaborator

Thanks for reporting this folks! Fix is merged (#5548) and will be published soon!

Duplicate: #5539 and #5549

@onurtemizkan onurtemizkan closed this as not planned Won't fix, can't repro, duplicate, stale Aug 10, 2022
@onurtemizkan onurtemizkan added Status: Duplicate Package: remix Issues related to the Sentry Remix SDK and removed Status: Untriaged labels Aug 10, 2022
@mattrigg9
Copy link
Author

Awesome, thanks for the quick response and patch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: remix Issues related to the Sentry Remix SDK Type: Bug
Projects
None yet
Development

No branches or pull requests

4 participants