Skip to content

feat(onboarding): Add logs to react router onboarding #97438

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AbhiPrasad
Copy link
Member

@AbhiPrasad AbhiPrasad requested a review from chargome August 7, 2025 21:16
@AbhiPrasad AbhiPrasad self-assigned this Aug 7, 2025
@AbhiPrasad AbhiPrasad requested a review from a team as a code owner August 7, 2025 21:17
Copy link

linear bot commented Aug 7, 2025

@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Aug 7, 2025
Comment on lines +214 to +216
Sentry.logger.info("User triggered test error", {
'action': SentryLogAttribute.string('test_loader_error'),
});`
Copy link
Contributor

Choose a reason for hiding this comment

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

Potential bug: The React Router onboarding doc uses an undefined `SentryLogAttribute`, which will cause a `ReferenceError` and crash the user's application during verification.
  • Description: The code in the React Router getting started documentation at Sentry.logger.info uses SentryLogAttribute.string('test_loader_error'). The SentryLogAttribute object is not defined in the Sentry JavaScript SDK or imported anywhere in the codebase. When a user copies and executes this code snippet during the onboarding verification step, their application will throw a ReferenceError: SentryLogAttribute is not defined. This crash prevents users from successfully verifying their Sentry setup for React Router when logs are enabled, breaking a key part of the onboarding flow.
  • Suggested fix: Remove the call to the undefined SentryLogAttribute.string() wrapper. The value for the action key should be a plain string, like 'test_loader_error', consistent with other JavaScript onboarding documentation and the Sentry SDK's API.
    severity: 0.8, confidence: 1.0

Did we get this right? 👍 / 👎 to inform future reviews.

Copy link
Member

@chargome chargome left a comment

Choose a reason for hiding this comment

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

🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: Frontend Automatically applied to PRs that change frontend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants