Integrate Sentry crash analytics#62
Open
Jim8y wants to merge 3 commits into
Open
Conversation
Add Sentry.Maui, which automatically captures unhandled managed exceptions and native crashes across platforms. The DSN is a configurable constant (SharedOptions.SentryDsn); an empty value leaves the SDK disabled until the team provides their Sentry endpoint. Privacy-conscious defaults for a wallet: SendDefaultPii=false, AttachScreenshot=false, no performance tracing. Builds for net10.0-android (0 errors).
There was a problem hiding this comment.
Pull request overview
This PR integrates Sentry crash analytics into the .NET MAUI app so unhandled managed exceptions and native crashes can be captured on supported platforms.
Changes:
- Add
Sentry.MauiNuGet dependency. - Introduce
SharedOptions.SentryDsnas the central DSN configuration value (empty by default). - Wire Sentry into
MauiProgram.CreateMauiApp()viabuilder.UseSentry(...)and configure privacy-oriented options.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| OneGateApp/Services/SharedOptions.cs | Adds a SentryDsn constant used to enable/disable Sentry via configuration. |
| OneGateApp/OneGateApp.csproj | Adds the Sentry.Maui package reference. |
| OneGateApp/MauiProgram.cs | Registers Sentry during app startup and sets Sentry options. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Contributor
Author
|
Latest review follow-up: addressed both Copilot comments in Changes:
Validation:
Screenshots: Screenshots are GitHub release assets only and are not committed to the repository. Ready for re-review. |
…analytics # Conflicts: # OneGateApp/Services/SharedOptions.cs
Contributor
Author
|
Base refresh validation update:
Screenshots are stored as GitHub release assets only, not committed to the repo: |
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.
What
Integrates Sentry (
Sentry.Maui6.6.0) as the third-party crash analytics service. Sentry automatically captures unhandled managed exceptions and native crashes across Android/iOS/maccatalyst — no manual exception handlers needed.Wired as
builder.UseSentry(ConfigureSentry)(early in the chain, right afterUseMauiApp).Configuration
SharedOptions.SentryDsn(currently empty). Set it to your Sentry DSN to enable — an empty value leaves the SDK disabled (no crash, no data sent), so this is safe to merge before the DSN is provisioned.SendDefaultPii = false,AttachScreenshot = false(avoid capturing on-screen balances/addresses),TracesSampleRate = 0(crash reporting only).Verified / notes
CrashReporter): you wanted a third-party service, so Capture unhandled exceptions and report crashes #61 can be closed in favor of this — don't run both (they'd double-capture). I left Capture unhandled exceptions and report crashes #61 open for you to decide.