From 06667f399d0f3d5289447052635860bc37e52158 Mon Sep 17 00:00:00 2001 From: betegon Date: Fri, 2 Oct 2026 13:04:21 +0200 Subject: [PATCH] test(e2e): Skip commit association in sourcemap fixtures Keep sourcemap fixtures within the release and upload flows supported by their local API mocks. Disable CLI telemetry for E2E builds while preserving the SDK telemetry under test. Co-Authored-By: GPT-6 (OpenAI) --- .github/workflows/build.yml | 2 ++ dev-packages/e2e-tests/run.ts | 1 + .../test-applications/nextjs-sourcemaps/next.config.js | 1 + .../test-applications/nuxt-4-sourcemaps/nuxt.config.ts | 2 +- .../test-applications/react-router-sourcemaps/vite.config.ts | 1 + .../e2e-tests/test-applications/remix-sourcemaps/vite.config.ts | 1 + 6 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f680c6c3c630..b5424d7b242d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1038,6 +1038,7 @@ jobs: REACT_APP_E2E_TEST_DSN: 'https://username@domain/123' E2E_TEST_SENTRY_ORG_SLUG: 'sentry-javascript-sdks' E2E_TEST_SENTRY_PROJECT: 'sentry-javascript-e2e-tests' + SENTRY_CLI_NO_TELEMETRY: '1' strategy: fail-fast: false matrix: ${{ fromJson(needs.job_build.outputs.e2e-matrix) }} @@ -1173,6 +1174,7 @@ jobs: REACT_APP_E2E_TEST_DSN: ${{ secrets.E2E_TEST_DSN }} E2E_TEST_SENTRY_ORG_SLUG: 'sentry-javascript-sdks' E2E_TEST_SENTRY_PROJECT: 'sentry-javascript-e2e-tests' + SENTRY_CLI_NO_TELEMETRY: '1' E2E_OPENROUTER_API_KEY: ${{ secrets.E2E_OPENROUTER_API_KEY }} # Used by test apps that deploy a real Cloudflare Worker, e.g. cloudflare-workers-send-to-sentry CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} diff --git a/dev-packages/e2e-tests/run.ts b/dev-packages/e2e-tests/run.ts index 317aa42a3a64..3b931861354c 100644 --- a/dev-packages/e2e-tests/run.ts +++ b/dev-packages/e2e-tests/run.ts @@ -191,6 +191,7 @@ async function run(): Promise { const env = { ...process.env, ...envVarsToInject, + SENTRY_CLI_NO_TELEMETRY: '1', // Volta applies a project's node pin only to commands it manages, and it // manages pnpm only when this is set. Without it, the `volta run pnpm` // calls below build each app on whatever node is already on PATH rather diff --git a/dev-packages/e2e-tests/test-applications/nextjs-sourcemaps/next.config.js b/dev-packages/e2e-tests/test-applications/nextjs-sourcemaps/next.config.js index 69a0a61a9388..a4a9634c262e 100644 --- a/dev-packages/e2e-tests/test-applications/nextjs-sourcemaps/next.config.js +++ b/dev-packages/e2e-tests/test-applications/nextjs-sourcemaps/next.config.js @@ -10,6 +10,7 @@ module.exports = withSentryConfig(nextConfig, { project: 'test-project', release: { name: 'test-release', + setCommits: false, }, sourcemaps: { deleteSourcemapsAfterUpload: false, diff --git a/dev-packages/e2e-tests/test-applications/nuxt-4-sourcemaps/nuxt.config.ts b/dev-packages/e2e-tests/test-applications/nuxt-4-sourcemaps/nuxt.config.ts index ae2e95194fa7..a1a67689df1c 100644 --- a/dev-packages/e2e-tests/test-applications/nuxt-4-sourcemaps/nuxt.config.ts +++ b/dev-packages/e2e-tests/test-applications/nuxt-4-sourcemaps/nuxt.config.ts @@ -24,7 +24,7 @@ export default defineNuxtConfig({ authToken: 'fake-auth-token', org: 'test-org', project: 'test-project', - release: { name: 'test-release' }, + release: { name: 'test-release', setCommits: false }, // Dropping `filesToDeleteAfterUpload` is the whole point of the "kept" variant: Sentry should // upload the maps and leave the emitted files alone. sourcemaps: keepClientSourceMaps ? {} : { filesToDeleteAfterUpload: ['.output/public/**/*.map'] }, diff --git a/dev-packages/e2e-tests/test-applications/react-router-sourcemaps/vite.config.ts b/dev-packages/e2e-tests/test-applications/react-router-sourcemaps/vite.config.ts index 7ecda171a055..1ef9fea07178 100644 --- a/dev-packages/e2e-tests/test-applications/react-router-sourcemaps/vite.config.ts +++ b/dev-packages/e2e-tests/test-applications/react-router-sourcemaps/vite.config.ts @@ -12,6 +12,7 @@ export const sentryConfig: SentryReactRouterBuildOptions = { sentryUrl: 'http://localhost:3032', release: { name: 'test-release', + setCommits: false, }, sourcemaps: { // The maps have to survive until `sentryOnBuildEnd` uploads them, so this asserts the option is diff --git a/dev-packages/e2e-tests/test-applications/remix-sourcemaps/vite.config.ts b/dev-packages/e2e-tests/test-applications/remix-sourcemaps/vite.config.ts index 0229581eda4f..d2dd2ee288b4 100644 --- a/dev-packages/e2e-tests/test-applications/remix-sourcemaps/vite.config.ts +++ b/dev-packages/e2e-tests/test-applications/remix-sourcemaps/vite.config.ts @@ -14,6 +14,7 @@ export default defineConfig({ sentryUrl: 'http://localhost:3033', release: { name: 'test-release', + setCommits: false, }, debug: true, }),