1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

Bump all @sentry related packages

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton 2022-03-31 09:07:41 -04:00
parent 3a26ea7b7f
commit 797c6487bf
5 changed files with 95 additions and 111 deletions

View File

@ -205,8 +205,8 @@
"@ogre-tools/injectable": "5.2.0",
"@ogre-tools/injectable-react": "5.2.0",
"@ogre-tools/fp": "5.2.0",
"@sentry/electron": "^2.5.4",
"@sentry/integrations": "^6.19.2",
"@sentry/electron": "^3.0.6",
"@sentry/integrations": "^6.19.3",
"@types/circular-dependency-plugin": "5.0.5",
"abort-controller": "^3.0.0",
"auto-bind": "^4.0.0",
@ -280,7 +280,7 @@
"@material-ui/icons": "^4.11.2",
"@material-ui/lab": "^4.0.0-alpha.60",
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.4",
"@sentry/types": "^6.19.2",
"@sentry/types": "^6.19.3",
"@testing-library/jest-dom": "^5.16.3",
"@testing-library/react": "^11.2.7",
"@testing-library/user-event": "^13.5.0",
@ -339,7 +339,6 @@
"@typescript-eslint/eslint-plugin": "^5.15.0",
"@typescript-eslint/parser": "^5.16.0",
"ansi_up": "^5.1.0",
"mock-http": "^1.1.0",
"chart.js": "^2.9.4",
"circular-dependency-plugin": "^5.2.2",
"cli-progress": "^3.10.0",
@ -372,6 +371,7 @@
"jest-mock-extended": "^1.0.18",
"make-plural": "^6.2.2",
"mini-css-extract-plugin": "^2.5.2",
"mock-http": "^1.1.0",
"node-gyp": "7.1.2",
"node-loader": "^2.0.0",
"nodemon": "^2.0.15",

View File

@ -4,7 +4,6 @@
*/
import { Dedupe, Offline } from "@sentry/integrations";
import * as Sentry from "@sentry/electron";
import { sentryDsn, isProduction } from "./vars";
import { UserStore } from "./user-store";
import { inspect } from "util";
@ -23,10 +22,14 @@ function mapProcessName(processType: string) {
/**
* Initialize Sentry for the current process so to send errors for debugging.
*/
export function SentryInit() {
export async function SentryInit() {
const processName = mapProcessName(process.type);
Sentry.init({
const { init } = process.type === "browser"
? await import("@sentry/electron/main")
: await import("@sentry/electron/renderer");
init({
beforeSend: (event) => {
// default to false, in case instance of UserStore is not created (yet)
const allowErrorReporting = UserStore.getInstance(false)?.allowErrorReporting ?? false;

View File

@ -60,21 +60,23 @@ import navigateToPreferencesInjectable from "../common/front-end-routing/routes/
import syncGeneralCatalogEntitiesInjectable from "./catalog-sources/sync-general-catalog-entities.injectable";
import hotbarStoreInjectable from "../common/hotbar-store.injectable";
import applicationMenuItemsInjectable from "./menu/application-menu-items.injectable";
import type { DiContainer } from "@ogre-tools/injectable";
const di = getDi();
async function main(di: DiContainer) {
app.setName(appName);
app.setName(appName);
app.on("ready", async () => {
/**
* Note: this MUST be called before electron's "ready" event has been emitted.
*/
await SentryInit();
await di.runSetups();
await app.whenReady();
injectSystemCAs();
const onCloseCleanup = disposer();
const onQuitCleanup = disposer();
SentryInit();
logger.info(`📟 Setting ${productName} as protocol client for lens://`);
if (app.setAsDefaultProtocolClient("lens")) {
@ -187,8 +189,6 @@ app.on("ready", async () => {
lensProtocolRouterMain.route(rawUrl);
});
logger.debug("[APP-MAIN] waiting for 'ready' and other messages");
const directoryForExes = di.inject(directoryForExesInjectable);
logger.info(`🚀 Starting ${productName} from "${directoryForExes}"`);
@ -357,7 +357,9 @@ app.on("ready", async () => {
setTimeout(() => {
appEventBus.emit({ name: "service", action: "start" });
}, 1000);
});
}
main(getDi());
/**
* Exports for virtual package "@k8slens/extensions" for main-process.

View File

@ -44,10 +44,6 @@ import { bindEvents } from "./navigation/events";
import deleteClusterDialogModelInjectable
from "./components/delete-cluster-dialog/delete-cluster-dialog-model/delete-cluster-dialog-model.injectable";
if (process.isMainFrame) {
SentryInit();
}
configurePackages(); // global packages
registerCustomThemes(); // monaco editor themes
@ -63,6 +59,9 @@ async function attachChromeDebugger() {
}
export async function bootstrap(di: DiContainer) {
if (process.isMainFrame) {
await SentryInit();
}
await di.runSetups();
// TODO: Consolidate import time side-effect to setup time

162
yarn.lock
View File

@ -1000,103 +1000,91 @@
schema-utils "^3.0.0"
source-map "^0.7.3"
"@sentry/browser@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-6.7.1.tgz#e01144a08984a486ecc91d7922cc457e9c9bd6b7"
integrity sha512-R5PYx4TTvifcU790XkK6JVGwavKaXwycDU0MaAwfc4Vf7BLm5KCNJCsDySu1RPAap/017MVYf54p6dWvKiRviA==
dependencies:
"@sentry/core" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
tslib "^1.9.3"
"@sentry/core@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-6.7.1.tgz#c3aaa6415d06bec65ac446b13b84f073805633e3"
integrity sha512-VAv8OR/7INn2JfiLcuop4hfDcyC7mfL9fdPndQEhlacjmw8gRrgXjR7qyhnCTgzFLkHI7V5bcdIzA83TRPYQpA==
dependencies:
"@sentry/hub" "6.7.1"
"@sentry/minimal" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
tslib "^1.9.3"
"@sentry/electron@^2.5.4":
version "2.5.4"
resolved "https://registry.yarnpkg.com/@sentry/electron/-/electron-2.5.4.tgz#337b2f7e228e805a3e4eb3611c7b12c6cf87c618"
integrity sha512-tCCK+P581TmdjsDpHBQz7qYcldzGdUk1Fd6FPxPy1JKGzeY4uf/uSLKzR80Lzs5kTpEZFOwiMHSA8yjwFp5qoA==
dependencies:
"@sentry/browser" "6.7.1"
"@sentry/core" "6.7.1"
"@sentry/minimal" "6.7.1"
"@sentry/node" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
tslib "^2.2.0"
"@sentry/hub@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-6.7.1.tgz#d46d24deec67f0731a808ca16796e6765b371bc1"
integrity sha512-eVCTWvvcp6xa0A5GGNHMQEWslmKPlisE5rGmsV/kjvSUv3zSrI0eIDfb51ikdnCiBjHpK2NBWP8Vy8cZOEJegg==
dependencies:
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
tslib "^1.9.3"
"@sentry/integrations@^6.19.2":
"@sentry/browser@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/integrations/-/integrations-6.19.2.tgz#d5abcab94ae23ada097eb454c269e9ab573e14bb"
integrity sha512-RjkZXPrtrM+lJVEa4OpZ9CYjJdkpPoWslEQzLMvbaRpURpHFqmABGtXRAnJRYKmy6h7/9q9sABcDgCD4OZw11g==
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-6.19.2.tgz#c0f6df07584f3b36fa037067aea20b2c8c2095a3"
integrity sha512-5VC44p5Vu2eJhVT39nLAJFgha5MjHDYCyZRR1ieeZt3a++otojPGBBAKNAtrEMGV+A2Z9AoneD6ZnDVlyb3GKg==
dependencies:
"@sentry/core" "6.19.2"
"@sentry/types" "6.19.2"
"@sentry/utils" "6.19.2"
tslib "^1.9.3"
"@sentry/core@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/core/-/core-6.19.2.tgz#dd35ba6ca41a2dd011c43f732bcdadbb52c06376"
integrity sha512-yu1R3ewBT4udmB4v7sc4biQZ0Z0rfB9+TzB5ZKoCftbe6kqXjFMMaFRYNUF9HicVldKAsBktgkWw3+yfqGkw/A==
dependencies:
"@sentry/hub" "6.19.2"
"@sentry/minimal" "6.19.2"
"@sentry/types" "6.19.2"
"@sentry/utils" "6.19.2"
tslib "^1.9.3"
"@sentry/electron@^3.0.6":
version "3.0.6"
resolved "https://registry.yarnpkg.com/@sentry/electron/-/electron-3.0.6.tgz#02ec5c78bc604d6cc1a12b6ccd1bd995b00af737"
integrity sha512-8ITIVSz4+ISZODIKPCtKN79RhU4scIDxgqEMvygwOnaAyB9nv/bJoOWK+pnXfUjSPYczB5GKxu99EyCfdOC3qA==
dependencies:
"@sentry/browser" "6.19.2"
"@sentry/core" "6.19.2"
"@sentry/node" "6.19.2"
"@sentry/types" "6.19.2"
"@sentry/utils" "6.19.2"
deepmerge "^4.2.2"
tslib "^2.3.1"
"@sentry/hub@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/hub/-/hub-6.19.2.tgz#0e9f9c507e55d8396002f644b43ef27cc9ff1289"
integrity sha512-W7KCgNBgdBIMagOxy5J5KQPe+maYxSqfE8a5ncQ3R8BcZDQEKnkW/1FplNbfRLZqA/tL/ndKb7pTPqVtzsbARw==
dependencies:
"@sentry/types" "6.19.2"
"@sentry/utils" "6.19.2"
tslib "^1.9.3"
"@sentry/integrations@^6.19.3":
version "6.19.3"
resolved "https://registry.yarnpkg.com/@sentry/integrations/-/integrations-6.19.3.tgz#b5ac64591a9c7ae60f54c7d5ebd0d9152215c377"
integrity sha512-hOyX0UoH1ZyFtOjIazL2M9HfQMIjwukv0AtTX2W7sVfV1qxvISaV5lYZrAw1xB1lRoUwOJr/C0odddHWtBgdsA==
dependencies:
"@sentry/types" "6.19.3"
"@sentry/utils" "6.19.3"
localforage "^1.8.1"
tslib "^1.9.3"
"@sentry/minimal@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-6.7.1.tgz#babf85ee2f167e9dcf150d750d7a0b250c98449c"
integrity sha512-HDDPEnQRD6hC0qaHdqqKDStcdE1KhkFh0RCtJNMCDn0zpav8Dj9AteF70x6kLSlliAJ/JFwi6AmQrLz+FxPexw==
"@sentry/minimal@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/minimal/-/minimal-6.19.2.tgz#e748541e4adbc7e80a3b6ccaf01b631c17fc44b4"
integrity sha512-ClwxKm77iDHET7kpzv1JvzDx1er5DoNu+EUjst0kQzARIrXvu9xuZuE2/CnBWycQWqw8o3HoGoKz65uIhsUCzQ==
dependencies:
"@sentry/hub" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/hub" "6.19.2"
"@sentry/types" "6.19.2"
tslib "^1.9.3"
"@sentry/node@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/node/-/node-6.7.1.tgz#b09e2eca8e187168feba7bd865a23935bf0f5cc0"
integrity sha512-rtZo1O8ROv4lZwuljQz3iFZW89oXSlgXCG2VqkxQyRspPWu89abROpxLjYzsWwQ8djnur1XjFv51kOLDUTS6Qw==
"@sentry/node@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/node/-/node-6.19.2.tgz#cad621ad319f555826110f4d6c972a2fc95800fc"
integrity sha512-Z1qREpTpYHxaeWjc1zMUk8ZTAp1WbxMiI2TVNc+a14DVT19Z2xNXb06MiRfeLgNc9lVGdmzR62dPmMBjVgPJYg==
dependencies:
"@sentry/core" "6.7.1"
"@sentry/hub" "6.7.1"
"@sentry/tracing" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
"@sentry/core" "6.19.2"
"@sentry/hub" "6.19.2"
"@sentry/types" "6.19.2"
"@sentry/utils" "6.19.2"
cookie "^0.4.1"
https-proxy-agent "^5.0.0"
lru_map "^0.3.3"
tslib "^1.9.3"
"@sentry/tracing@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/tracing/-/tracing-6.7.1.tgz#b11f0c17a6c5dc14ef44733e5436afb686683268"
integrity sha512-wyS3nWNl5mzaC1qZ2AIp1hjXnfO9EERjMIJjCihs2LWBz1r3efxrHxJHs8wXlNWvrT3KLhq/7vvF5CdU82uPeQ==
dependencies:
"@sentry/hub" "6.7.1"
"@sentry/minimal" "6.7.1"
"@sentry/types" "6.7.1"
"@sentry/utils" "6.7.1"
tslib "^1.9.3"
"@sentry/types@6.19.2", "@sentry/types@^6.19.2":
"@sentry/types@6.19.2":
version "6.19.2"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-6.19.2.tgz#0219c9da21ed975951108b8541913b1966464435"
integrity sha512-XO5qmVBdTs+7PdCz7fAwn1afWxSnRE2KLBFg5/vOdKosPSSHsSHUURSkxiEZc2QsR+JpRB4AeQ26AkIRX38qTg==
"@sentry/types@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-6.7.1.tgz#c8263e1886df5e815570c4668eb40a1cfaa1c88b"
integrity sha512-9AO7HKoip2MBMNQJEd6+AKtjj2+q9Ze4ooWUdEvdOVSt5drg7BGpK221/p9JEOyJAZwEPEXdcMd3VAIMiOb4MA==
"@sentry/types@6.19.3", "@sentry/types@^6.19.3":
version "6.19.3"
resolved "https://registry.yarnpkg.com/@sentry/types/-/types-6.19.3.tgz#94b19da68d4d23561efb1014f72968bcea85cd0c"
integrity sha512-jHhqxp8MIWSfOc3krorirTGKTEaSFO6XrAvi+2AZhr6gvOChwOgzgrN2ZqesJcZmgCsqWV21u3usSwYeRrjOJA==
"@sentry/utils@6.19.2":
version "6.19.2"
@ -1106,12 +1094,12 @@
"@sentry/types" "6.19.2"
tslib "^1.9.3"
"@sentry/utils@6.7.1":
version "6.7.1"
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-6.7.1.tgz#909184ad580f0f6375e1e4d4a6ffd33dfe64a4d1"
integrity sha512-Tq2otdbWlHAkctD+EWTYKkEx6BL1Qn3Z/imkO06/PvzpWvVhJWQ5qHAzz5XnwwqNHyV03KVzYB6znq1Bea9HuA==
"@sentry/utils@6.19.3":
version "6.19.3"
resolved "https://registry.yarnpkg.com/@sentry/utils/-/utils-6.19.3.tgz#0c3a3f0b86c12e3b079e56e37a44e62a1226043d"
integrity sha512-GdC9B/FK7qd0zItY43135bYbhuVSawE18bIrQDNuno8gTpDJ5OgShpTN9zR53AmMh16/lwKNnV3ZZjlpKcxuNw==
dependencies:
"@sentry/types" "6.7.1"
"@sentry/types" "6.19.3"
tslib "^1.9.3"
"@sideway/address@^4.1.3":
@ -9735,7 +9723,6 @@ npm@^6.14.16:
cmd-shim "^3.0.3"
columnify "~1.5.4"
config-chain "^1.1.12"
debuglog "*"
detect-indent "~5.0.0"
detect-newline "^2.1.0"
dezalgo "~1.0.3"
@ -9750,7 +9737,6 @@ npm@^6.14.16:
has-unicode "~2.0.1"
hosted-git-info "^2.8.9"
iferr "^1.0.2"
imurmurhash "*"
infer-owner "^1.0.4"
inflight "~1.0.6"
inherits "^2.0.4"
@ -9769,14 +9755,8 @@ npm@^6.14.16:
libnpx "^10.2.4"
lock-verify "^2.1.0"
lockfile "^1.0.4"
lodash._baseindexof "*"
lodash._baseuniq "~4.6.0"
lodash._bindcallback "*"
lodash._cacheindexof "*"
lodash._createcache "*"
lodash._getnative "*"
lodash.clonedeep "~4.5.0"
lodash.restparam "*"
lodash.union "~4.6.0"
lodash.uniq "~4.5.0"
lodash.without "~4.4.0"
@ -13064,7 +13044,7 @@ tslib@^1.10.0, tslib@^1.8.1, tslib@^1.9.0, tslib@^1.9.3:
resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00"
integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==
tslib@^2.0.3, tslib@^2.1.0, tslib@^2.2.0:
tslib@^2.0.3, tslib@^2.1.0, tslib@^2.3.1:
version "2.3.1"
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01"
integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==