feat(App): add Sentry for error reporting - #338
Merged
Conversation
Integrate Sentry SDK for error reporting with automatic source map uploads via Vite plugin. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
Confidence Score: 2/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant App as Application Startup
participant Sentry as Sentry SDK
participant React as React Router
participant User as User Interaction
participant SentryIO as Sentry.io Server
App->>Sentry: Initialize Sentry.init()
Note over Sentry: DSN: hardcoded<br/>sendDefaultPii: true<br/>enableLogs: true
Sentry->>SentryIO: Establish connection
App->>React: Import routeTree
App->>React: Create router instance
App->>React: Render RouterProvider
User->>React: Interact with application
alt Error occurs
React->>Sentry: Capture error automatically
Sentry->>SentryIO: Send error + PII + logs
Note over SentryIO: Store with source maps<br/>(if auth configured)
end
Note over App: Build Time
participant Vite as Vite Build
participant Plugin as Sentry Vite Plugin
Vite->>Plugin: Build with sourcemap: true
Plugin->>SentryIO: Upload source maps<br/>(requires auth token)
|
|
|
||
| // Initialize Sentry for error tracking | ||
| Sentry.init({ | ||
| dsn: "https://9d87ba0a2f4279c02f059509b276419d@o4510748532342784.ingest.us.sentry.io/4510748533194752", |
There was a problem hiding this comment.
logic: hardcoded DSN should be moved to environment variable
Suggested change
| dsn: "https://9d87ba0a2f4279c02f059509b276419d@o4510748532342784.ingest.us.sentry.io/4510748533194752", | |
| dsn: import.meta.env.VITE_SENTRY_DSN, |
Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/app/src/main.tsx
Line: 9:9
Comment:
**logic:** hardcoded DSN should be moved to environment variable
```suggestion
dsn: import.meta.env.VITE_SENTRY_DSN,
```
How can I resolve this? If you propose a fix, please make it concise.| // Initialize Sentry for error tracking | ||
| Sentry.init({ | ||
| dsn: "https://9d87ba0a2f4279c02f059509b276419d@o4510748532342784.ingest.us.sentry.io/4510748533194752", | ||
| sendDefaultPii: true, |
There was a problem hiding this comment.
style: sendDefaultPii: true sends personally identifiable information (email, username, IP) to Sentry - ensure this complies with privacy policy
Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/app/src/main.tsx
Line: 10:10
Comment:
**style:** `sendDefaultPii: true` sends personally identifiable information (email, username, IP) to Sentry - ensure this complies with privacy policy
How can I resolve this? If you propose a fix, please make it concise.
Comment on lines
+19
to
+22
| }), sentryVitePlugin({ | ||
| org: "sixhuman-es", | ||
| project: "web-app" | ||
| })], |
There was a problem hiding this comment.
logic: missing authentication configuration - source maps won't upload without auth token set via SENTRY_AUTH_TOKEN environment variable or in .env.sentry-build-plugin file
Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/app/vite.config.ts
Line: 19:22
Comment:
**logic:** missing authentication configuration - source maps won't upload without auth token set via `SENTRY_AUTH_TOKEN` environment variable or in `.env.sentry-build-plugin` file
How can I resolve this? If you propose a fix, please make it concise.
Advait1306
added a commit
that referenced
this pull request
Jan 21, 2026
#339) Integrate Sentry SDK for error reporting with automatic source map uploads via Vite plugin. Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
@sentry/react) for error tracking and logging@sentry/vite-plugin) for automatic source map uploadssendDefaultPiiandenableLogsenabledCloses #337
Test plan
🤖 Generated with Claude Code