diff --git a/node-src/errorMonitoring.ts b/node-src/errorMonitoring.ts index b31a66887..7c2f08714 100644 --- a/node-src/errorMonitoring.ts +++ b/node-src/errorMonitoring.ts @@ -49,6 +49,7 @@ export function filterBreadcrumb(breadcrumb: Sentry.Breadcrumb) { Sentry.init({ dsn: 'https://4fa173db2ef3fb073b8ea153a5466d28@o4504181686599680.ingest.us.sentry.io/4507930289373184', release: process.env.SENTRY_RELEASE || process.env.npm_package_version, + dist: process.env.SENTRY_DIST, sampleRate: 1, environment: process.env.SENTRY_ENVIRONMENT, enabled: @@ -58,7 +59,6 @@ Sentry.init({ integrations: [], initialScope: { tags: { - entrypoint: process.env.CI && process.env.GITHUB_RUN_ID ? 'action' : 'cli', version: process.env.npm_package_version, index_url: process.env.CHROMATIC_INDEX_URL, }, diff --git a/scripts/versionAndBuildForRelease.mjs b/scripts/versionAndBuildForRelease.mjs index 13eae72a9..2908aab72 100755 --- a/scripts/versionAndBuildForRelease.mjs +++ b/scripts/versionAndBuildForRelease.mjs @@ -27,12 +27,15 @@ async function main() { await $`git reset --hard`; console.info('🌐 Sending sourcemaps to Sentry'); - await $({ stdout: 'inherit', stderr: 'inherit' })`sentry-cli sourcemaps inject dist`; - await $({ stdout: 'inherit', stderr: 'inherit' })`sentry-cli sourcemaps inject action`; + await $({ stdout: 'inherit', stderr: 'inherit' })`sentry-cli sourcemaps inject dist action`; await $({ stdout: 'inherit', stderr: 'inherit', - })`sentry-cli sourcemaps upload --release ${nextVersion} dist action`; + })`sentry-cli sourcemaps upload --release=${nextVersion} --dist=cli dist`; + await $({ + stdout: 'inherit', + stderr: 'inherit', + })`sentry-cli sourcemaps upload --release=${nextVersion} --dist=action action`; console.info('🚀 Creating new release in Sentry'); await $({ stdout: 'inherit', stderr: 'inherit' })`sentry-cli releases new ${nextVersion}`; diff --git a/tsup.config.ts b/tsup.config.ts index 00bd010c0..17d8ca027 100644 --- a/tsup.config.ts +++ b/tsup.config.ts @@ -21,6 +21,7 @@ export default defineConfig((options) => [ env: { SENTRY_ENVIRONMENT: process.env.CI ? 'production' : 'development', SENTRY_RELEASE: process.env.SENTRY_RELEASE || 'development', + SENTRY_DIST: 'cli', }, }, { @@ -37,6 +38,7 @@ export default defineConfig((options) => [ env: { SENTRY_ENVIRONMENT: process.env.CI ? 'production' : 'development', SENTRY_RELEASE: process.env.SENTRY_RELEASE || 'development', + SENTRY_DIST: 'action', }, }, ]);