Skip to content

fix(nextjs): Fix version detection and option insertion logic for clientTraceMetadata option #12323

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

Merged
merged 2 commits into from
Jun 3, 2024
Merged

fix(nextjs): Fix version detection and option insertion logic for clientTraceMetadata option #12323

merged 2 commits into from
Jun 3, 2024

Conversation

ykzts
Copy link
Contributor

@ykzts ykzts commented Jun 2, 2024

Before submitting a pull request, please take a look at our
Contributing guidelines and verify:

  • If you've added code that should be tested, please add tests.
  • Ensure your code lints and the test suite passes (yarn lint) & (yarn test).

When using Next.js v15.0.0-rc.0 or v15.0.0-canary.6, withSentryConfig does not add clientTraceMetadata to experimental. This is because both rc and canary releases have a minor version of 0 and are always treated as false.

Copy link
Contributor

@lforst lforst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! We had the same thought 😂 #12324

@lforst
Copy link
Contributor

lforst commented Jun 3, 2024

Added functionality to merge clientTraceMetadata in case it is already present.

@lforst lforst changed the title fix(nextjs): Add clientTraceMetadata for Next.js v15.0 fix(nextjs): Fix version detection and option insertion logic for clientTraceMetadata option Jun 3, 2024
@lforst lforst merged commit 4172e16 into getsentry:develop Jun 3, 2024
39 checks passed
@ykzts ykzts deleted the fix/client-trace-metadata branch June 3, 2024 05:58
c298lee pushed a commit that referenced this pull request Jun 4, 2024
@AbhiPrasad
Copy link
Member

Released with https://github.com/getsentry/sentry-javascript/releases/tag/8.8.0 - thanks for the PR @ykzts!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants