Merged in feature/IO-3162-sentry-improvements (pull request #2136)
feature/IO-3162-sentry-improvements Approved-by: Patrick Fic
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import { onError } from "@apollo/client/link/error";
|
||||
//https://stackoverflow.com/questions/57163454/refreshing-a-token-with-apollo-client-firebase-auth
|
||||
import * as Sentry from "@sentry/react";
|
||||
|
||||
const errorLink = onError(({ graphQLErrors, networkError, operation, forward }) => {
|
||||
if (graphQLErrors) {
|
||||
|
||||
@@ -7,9 +7,9 @@ import { getMainDefinition } from "@apollo/client/utilities";
|
||||
//import { split } from "apollo-link";
|
||||
import apolloLogger from "apollo-link-logger";
|
||||
//import axios from "axios";
|
||||
import { SentryLink } from "apollo-link-sentry";
|
||||
import { auth } from "../firebase/firebase.utils";
|
||||
import errorLink from "../graphql/apollo-error-handling";
|
||||
import { SentryLink } from "apollo-link-sentry";
|
||||
|
||||
//import { store } from "../redux/store";
|
||||
const httpLink = new HttpLink({
|
||||
|
||||
@@ -17,7 +17,7 @@ const currentDatePST = new Date()
|
||||
const sentryRelease =
|
||||
`${import.meta.env.VITE_APP_IS_TEST ? "test" : "production"}-${currentDatePST}-${process.env.VITE_GIT_COMMIT_HASH}`.trim();
|
||||
|
||||
//if (import.meta.env.PROD) {
|
||||
if (!import.meta.env.DEV) {
|
||||
Sentry.init({
|
||||
dsn: InstanceRenderManager({
|
||||
imex: "https://fd7e89369b6b4bdc9c6c4c9f22fa4ee4@o492140.ingest.sentry.io/5651027",
|
||||
@@ -60,4 +60,4 @@ Sentry.init({
|
||||
environment: import.meta.env.MODE,
|
||||
beforeBreadcrumb: excludeGraphQLFetch
|
||||
});
|
||||
//}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user