From 27ae85368a7d334ec4fed8ed39179dce3c4b9015 Mon Sep 17 00:00:00 2001 From: sethkfman <10342624+sethkfman@users.noreply.github.com> Date: Tue, 15 Oct 2024 20:15:02 +0000 Subject: [PATCH] chore(runway): cherry-pick chore: Update Sentry Performance Sampling utils.js (#11805) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## **Description** This PR reduces the sampling rate by 50% Sentry Performance. We are currently using too much of our allocation. ## **Related issues** Fixes: ## **Manual testing steps** 1. Go to this page... 2. 3. ## **Screenshots/Recordings** ### **Before** ### **After** ## **Pre-merge author checklist** - [ ] I’ve followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile Coding Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md). - [ ] I've completed the PR template to the best of my ability - [ ] I’ve included tests if applicable - [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots. --- app/util/sentry/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/util/sentry/utils.js b/app/util/sentry/utils.js index 26448b31041..024422616a6 100644 --- a/app/util/sentry/utils.js +++ b/app/util/sentry/utils.js @@ -503,7 +503,7 @@ export function setupSentry() { ] : integrations, // Set tracesSampleRate to 1.0, as that ensures that every transaction will be sent to Sentry for development builds. - tracesSampleRate: __DEV__ ? 1.0 : 0.08, + tracesSampleRate: __DEV__ ? 1.0 : 0.04, beforeSend: (report) => rewriteReport(report), beforeBreadcrumb: (breadcrumb) => rewriteBreadcrumb(breadcrumb), beforeSendTransaction: (event) => excludeEvents(event),