Skip to content

Commit

Permalink
Add FE part sentry error monitoring
Browse files Browse the repository at this point in the history
  • Loading branch information
petrvecera committed Feb 15, 2024
1 parent d888581 commit 33e6167
Show file tree
Hide file tree
Showing 3 changed files with 98 additions and 1 deletion.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"@mantine/core": "6.0.21",
"@mantine/hooks": "6.0.21",
"@mantine/notifications": "6.0.21",
"@sentry/react": "^7.101.1",
"@tabler/icons-react": "2.47.0",
"@tauri-apps/api": "1.5.3",
"axios": "1.6.3",
Expand Down
14 changes: 14 additions & 0 deletions src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,23 @@ import events from "./mixpanel/mixpanel"
import { listen } from "@tauri-apps/api/event"
import { info } from "tauri-plugin-log-api"
import { UploadNotifications } from "./components/UploadNotifications"
import * as Sentry from "@sentry/react";


info("Start frontend")


Sentry.init({
dsn: "https://88e8a309f91b8b5bb9a41dd14ff775b9@o4504995920543744.ingest.sentry.io/4506752563019776",
integrations: [
Sentry.browserTracingIntegration(),
],
// Performance Monitoring
tracesSampleRate: 0.1, // Capture 100% of the transactions
// Set 'tracePropagationTargets' to control for which URLs distributed tracing should be enabled
tracePropagationTargets: ["localhost"],
});

events.init()

// make sure an html file exists
Expand Down
84 changes: 83 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,88 @@
resolved "https://registry.yarnpkg.com/@remix-run/router/-/router-1.15.0.tgz#461a952c2872dd82c8b2e9b74c4dfaff569123e2"
integrity sha512-HOil5aFtme37dVQTB6M34G95kPM3MMuqSmIRVCC52eKV+Y/tGSqw9P3rWhlAx6A+mz+MoX+XxsGsNJbaI5qCgQ==

"@sentry-internal/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry-internal/feedback/-/feedback-7.101.1.tgz#d7e27ebcc46bd7306cfaa89b591293a394d75672"
integrity sha512-fOKDMVvLX+FuJHJszKBvRg1m7+fd4hchqRnZ9DDfitT6P5Ppl0gbEt/LStqu8Wq5M0tna+hpdwHlVEt7gZVKzw==
dependencies:
"@sentry/core" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry-internal/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry-internal/replay-canvas/-/replay-canvas-7.101.1.tgz#6856431a6360dd456c693d0510410dcd46f28150"
integrity sha512-09l6nD+lxWvwkpXLlIZuzj/z79Llbo6mcH33TJvxrUTjAqSGF/i3Pd5bTLWro9atippOyQgIV/yTGG4Bc5FhyQ==
dependencies:
"@sentry/core" "7.101.1"
"@sentry/replay" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry-internal/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry-internal/tracing/-/tracing-7.101.1.tgz#9504e29c3c2c3ef5f652777e487b596cf8f78e1a"
integrity sha512-ihjWG8x4x0ozx6t+EHoXLKbsPrgzYLCpeBLWyS+M6n3hn6cmHM76c8nZw3ldhUQi5UYL3LFC/JZ50b4oSxtlrg==
dependencies:
"@sentry/core" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-7.101.1.tgz#bab1257de499ed0e928bb4264a2e64d16cecccb5"
integrity sha512-+rIFoWPdO29AHVYsAwq8QEl2Ihv17Xh9Bt2aPFvLTGDA0caHjnx98g2jSOvLIOah6HI7Nwp3Njg2zBEzDtHkNw==
dependencies:
"@sentry-internal/feedback" "7.101.1"
"@sentry-internal/replay-canvas" "7.101.1"
"@sentry-internal/tracing" "7.101.1"
"@sentry/core" "7.101.1"
"@sentry/replay" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-7.101.1.tgz#929841b7734129803b6dcd4d16bf0d3f53af4657"
integrity sha512-XSmXXeYT1d4O14eDF3OXPJFUgaN2qYEeIGUztqPX9nBs9/ij8y/kZOayFqlIMnfGvjOUM+63sy/2xDBOpFn6ug==
dependencies:
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry/react@^7.101.1":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/react/-/react-7.101.1.tgz#678781d477bb4ff5b24444508168dd899472c1b2"
integrity sha512-CwaBXntX2e3XHZQZVuv/tcfm5H+UHcS6aVChGfUiBHIBi2JpAqdnLdQIFGTkE8BSnKyolKgIsnvIU3BQ//QTig==
dependencies:
"@sentry/browser" "7.101.1"
"@sentry/core" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"
hoist-non-react-statics "^3.3.2"

"@sentry/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/replay/-/replay-7.101.1.tgz#129ca5ac70690e78468b037a71a9b756bc3d965f"
integrity sha512-l4jmj2Rf/myzk3TA83PdMiomassG8okdBh1b2Hp1+ycBRVZFDmsR81gKPvnefSXwGwGNGKEmp6Q2bdGzekpp3Q==
dependencies:
"@sentry-internal/tracing" "7.101.1"
"@sentry/core" "7.101.1"
"@sentry/types" "7.101.1"
"@sentry/utils" "7.101.1"

"@sentry/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-7.101.1.tgz#7f936022d9b373f85ebf357634bf03a9e433a3d0"
integrity sha512-bwtkQvrCZ6JGc7vqX7TEAKBgkbQFORt84FFS3JQQb8G3efTt9fZd2ReY4buteKQdlALl8h1QWVngTLmI+kyUuw==

"@sentry/[email protected]":
version "7.101.1"
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-7.101.1.tgz#97399b1e6a63a15e8f9fec5112ac4834239f1db6"
integrity sha512-Nrg0nrEI3nrOCd9SLJ/WGzxS5KMQE4cryLOvrDcHJRWpsSyGBF1hLLerk84Nsw/0myMsn7zTYU+xoq7idNsX5A==
dependencies:
"@sentry/types" "7.101.1"

"@tabler/[email protected]":
version "2.47.0"
resolved "https://registry.yarnpkg.com/@tabler/icons-react/-/icons-react-2.47.0.tgz#b704e7ae98f95be8bd6e938b4b2e84cd20b0cf31"
Expand Down Expand Up @@ -1110,7 +1192,7 @@ has@^1.0.3:
dependencies:
function-bind "^1.1.1"

hoist-non-react-statics@^3.3.1:
hoist-non-react-statics@^3.3.1, hoist-non-react-statics@^3.3.2:
version "3.3.2"
resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45"
integrity sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==
Expand Down

0 comments on commit 33e6167

Please sign in to comment.