From c36f4d4a65760932b73bb38e04e097c326b8ea6d Mon Sep 17 00:00:00 2001 From: Volnei Munhoz Date: Mon, 12 Jan 2026 09:16:08 -0300 Subject: [PATCH] =?UTF-8?q?Revert=20"fix:=20add=20withSentryConfig=20to=20?= =?UTF-8?q?enable=20Sentry=20tracing=20in=20production=20(#26=E2=80=A6"=20?= =?UTF-8?q?(#26744)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit dd4e8344c95a6f2f2772a49d683b801772876dcb. --- apps/web/next.config.ts | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/apps/web/next.config.ts b/apps/web/next.config.ts index 25028749eb..b02ebd2916 100644 --- a/apps/web/next.config.ts +++ b/apps/web/next.config.ts @@ -1,17 +1,16 @@ -import process from "node:process"; -import { withSentryConfig } from "@sentry/nextjs"; import { withBotId } from "botid/next/config"; import { config as dotenvConfig } from "dotenv"; import type { NextConfig } from "next"; import type { RouteHas } from "next/dist/lib/load-custom-routes"; import { withAxiom } from "next-axiom"; + import i18nConfig from "./next-i18next.config"; import packageJson from "./package.json"; import { nextJsOrgRewriteConfig, orgUserRoutePath, - orgUserTypeEmbedRoutePath, orgUserTypeRoutePath, + orgUserTypeEmbedRoutePath, } from "./pagesAndRewritePaths"; dotenvConfig({ path: "../../.env" }); @@ -140,25 +139,6 @@ if (process.env.NEXT_PUBLIC_VERCEL_USE_BOTID_IN_BOOKER === "1") { plugins.push(withBotId); } -const sentryTracesSampleRate = parseFloat(process.env.SENTRY_TRACES_SAMPLE_RATE ?? "0.0") || 0.0; -const isSentryEnabled = - process.env.NODE_ENV === "production" && - process.env.NEXT_PUBLIC_SENTRY_DSN && - sentryTracesSampleRate > 0; - -if (isSentryEnabled) { - plugins.push((config) => - withSentryConfig(config, { - silent: !process.env.SENTRY_DEBUG, - org: process.env.SENTRY_ORG, - project: process.env.SENTRY_PROJECT, - authToken: process.env.SENTRY_AUTH_TOKEN, - widenClientFileUpload: true, - disableLogger: true, - }) - ); -} - interface OrgDomainMatcher { has: RouteHas[]; source: string;