-
Notifications
You must be signed in to change notification settings - Fork 448
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: sentry integration (#1420)
Closes #1404 # Changes - Refactored Sentry Implementation: - Use single global instantiation, fixes previous global state pollution - Sentry now uses recommended React integrations (e.g. react dom router) - Error handling logic centralized in Report Error Machine - Errors are now asynchronously fed into our error Indexed DB from every source (i.e. Service Worker, setup page, extension) - Error Machine watches errors indexedDB for changes and automatically updates its own state - Extension no longer completely reloads when dismissing/ignoring errors, now gracefully recovers from the error state. - Audit check now ignores vulnerabilities with no known patched version - Fixed broken links to `@fuels/react` in docs after it migrated to Connectors # Features - New error review screen - User can dismiss individual errors before sending them to Sentry - User can review the Error's contents and identify if any private information is being sent - Error data is automatically sanitized for keys and other obviously private information - Aside from protected/required properties (i.e. message & stack), other properties can be deleted by the user to avoid leaking private information # Evidence ## Error Review Screen ![CleanShot 2024-08-15 at 18 57 14](https://github.com/user-attachments/assets/4bf43afa-2616-4fb2-90ff-ee75d5141d1f) ## Error Review Flow (Outdated) - Required error properties protection disabled: https://github.com/user-attachments/assets/d54f80b4-3da4-4aa8-be0d-60399c1d92b8 ## Example Sentry error with proper stack trace and source mapping: ![image](https://github.com/user-attachments/assets/701a3ed6-1b2c-4962-a6be-cb047facd4de) --------- Co-authored-by: Luiz Gomes <[email protected]>
- Loading branch information
1 parent
3486bee
commit 737652b
Showing
44 changed files
with
6,235 additions
and
8,793 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@fuel-wallet/connections": patch | ||
--- | ||
|
||
Fixed broken links to `@fuels/react` in docs |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@fuel-wallet/types": minor | ||
"fuels-wallet": minor | ||
--- | ||
|
||
Refactored Sentry implementation, error handling, and report logic |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"fuels-wallet": patch | ||
--- | ||
|
||
Include "Error Review" screen allowing the user to review and report screens |
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,3 +29,6 @@ dist-ssr | |
*.sw? | ||
|
||
cypress/videos | ||
|
||
# Sentry Config File | ||
.env.sentry-build-plugin |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.