Skip to content

Commit 39f9e2a

Browse files
authored
Merge pull request #12987 from getsentry/prepare-release/8.19.0
meta(changelog): Update changelog for 8.19.0
2 parents ca99121 + 6e562ea commit 39f9e2a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+1429
-1425
lines changed

.github/workflows/build.yml

Lines changed: 12 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -519,7 +519,7 @@ jobs:
519519
strategy:
520520
fail-fast: false
521521
matrix:
522-
node: [14, 16, 18, 20, 22]
522+
node: [14, 16, 18, 20, 22.4]
523523
steps:
524524
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
525525
uses: actions/checkout@v4
@@ -579,7 +579,7 @@ jobs:
579579
strategy:
580580
fail-fast: false
581581
matrix:
582-
node: [14, 16, 18, 20, 22]
582+
node: [14, 16, 18, 20, 22.4]
583583
steps:
584584
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
585585
uses: actions/checkout@v4
@@ -779,33 +779,6 @@ jobs:
779779
name: playwright-traces
780780
path: dev-packages/browser-integration-tests/test-results
781781

782-
job_browser_build_tests:
783-
name: Browser Build Tests
784-
needs: [job_get_metadata, job_build]
785-
runs-on: ubuntu-20.04
786-
timeout-minutes: 5
787-
steps:
788-
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
789-
uses: actions/checkout@v4
790-
with:
791-
ref: ${{ env.HEAD_COMMIT }}
792-
- name: Set up Node
793-
uses: actions/setup-node@v4
794-
with:
795-
node-version-file: 'package.json'
796-
- name: Restore caches
797-
uses: ./.github/actions/restore-cache
798-
env:
799-
DEPENDENCY_CACHE_KEY: ${{ needs.job_build.outputs.dependency_cache_key }}
800-
- name: Run browser build tests
801-
run: |
802-
cd packages/browser
803-
yarn test:package
804-
- name: Run utils build tests
805-
run: |
806-
cd packages/utils
807-
yarn test:package
808-
809782
job_check_for_faulty_dts:
810783
name: Check for faulty .d.ts files
811784
needs: [job_get_metadata, job_build]
@@ -843,12 +816,12 @@ jobs:
843816
strategy:
844817
fail-fast: false
845818
matrix:
846-
node: [14, 16, 18, 20, 22]
819+
node: [14, 16, 18, 20, 22.4]
847820
typescript:
848821
- false
849822
include:
850823
# Only check typescript for latest version (to streamline CI)
851-
- node: 22
824+
- node: 22.4
852825
typescript: '3.8'
853826
steps:
854827
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
@@ -885,7 +858,7 @@ jobs:
885858
strategy:
886859
fail-fast: false
887860
matrix:
888-
node: [18, 20, 22]
861+
node: [18, 20, 22.4]
889862
remix: [1, 2]
890863
# Remix v2 only supports Node 18+, so run 16 tests separately
891864
include:
@@ -1317,7 +1290,6 @@ jobs:
13171290
[
13181291
job_build,
13191292
job_compile_bindings_profiling_node,
1320-
job_browser_build_tests,
13211293
job_browser_unit_tests,
13221294
job_bun_unit_tests,
13231295
job_deno_unit_tests,
@@ -1409,7 +1381,7 @@ jobs:
14091381
- os: ubuntu-20.04
14101382
node: 20
14111383
- os: ubuntu-20.04
1412-
node: 22
1384+
node: 22.4
14131385

14141386
# x64 musl
14151387
- os: ubuntu-20.04
@@ -1423,7 +1395,7 @@ jobs:
14231395
node: 20
14241396
- os: ubuntu-20.04
14251397
container: node:22-alpine3.18
1426-
node: 22
1398+
node: 22.4
14271399

14281400
# arm64 glibc
14291401
- os: ubuntu-20.04
@@ -1437,7 +1409,7 @@ jobs:
14371409
node: 20
14381410
- os: ubuntu-20.04
14391411
arch: arm64
1440-
node: 22
1412+
node: 22.4
14411413

14421414
# arm64 musl
14431415
- os: ubuntu-20.04
@@ -1455,7 +1427,7 @@ jobs:
14551427
- os: ubuntu-20.04
14561428
arch: arm64
14571429
container: node:22-alpine3.18
1458-
node: 22
1430+
node: 22.4
14591431

14601432
# macos x64
14611433
- os: macos-13
@@ -1468,7 +1440,7 @@ jobs:
14681440
node: 20
14691441
arch: x64
14701442
- os: macos-13
1471-
node: 22
1443+
node: 22.4
14721444
arch: x64
14731445

14741446
# macos arm64
@@ -1486,7 +1458,7 @@ jobs:
14861458
target_platform: darwin
14871459
- os: macos-13
14881460
arch: arm64
1489-
node: 22
1461+
node: 22.4
14901462
target_platform: darwin
14911463

14921464
# windows x64
@@ -1500,7 +1472,7 @@ jobs:
15001472
node: 20
15011473
arch: x64
15021474
- os: windows-2022
1503-
node: 22
1475+
node: 22.4
15041476
arch: x64
15051477

15061478
steps:

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@
1414
- fix(angular): Remove `afterSendEvent` listener once root injector is destroyed (#12786)
1515
- fix(browser): Fix bug causing unintentional dropping of transactions (#12933)
1616
- fix(feedback): Add a missing call of Actor.appendToDom method when DOMContentLoaded event is triggered (#12973)
17+
- feat(vercel-edge): Add dedupe as default integration (#12957)
18+
- fix(node): Pass inferred name & attributes to `tracesSampler` (#12945)
19+
- feat(express): Allow to pass options to `setupExpressErrorHandler` (#12952)
1720

1821
Work in this release was contributed by @jaspreet57 and @arturovt. Thank you for your contribution!
1922

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ package. Please refer to the README and instructions of those SDKs for more deta
5353
- [`@sentry/vue`](https://github.com/getsentry/sentry-javascript/tree/master/packages/vue): Browser SDK for Vue
5454
- [`@sentry/solid`](https://github.com/getsentry/sentry-javascript/tree/master/packages/solid): Browser SDK for Solid
5555
- [`@sentry/gatsby`](https://github.com/getsentry/sentry-javascript/tree/master/packages/gatsby): SDK for Gatsby
56+
- [`@sentry/nestjs`](https://github.com/getsentry/sentry-javascript/tree/master/packages/nestjs): SDK for NestJS
5657
- [`@sentry/nextjs`](https://github.com/getsentry/sentry-javascript/tree/master/packages/nextjs): SDK for Next.js
5758
- [`@sentry/remix`](https://github.com/getsentry/sentry-javascript/tree/master/packages/remix): SDK for Remix
5859
- [`@sentry/aws-serverless`](https://github.com/getsentry/sentry-javascript/tree/master/packages/aws-serverless): SDK

packages/browser/test/package/test-code.js renamed to dev-packages/browser-integration-tests/suites/public-api/init/built-pkg/subject.js

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,3 @@
1-
/* eslint-disable no-console */
2-
const Sentry = require('../../build/npm/cjs/index.js');
3-
4-
// Init
5-
Sentry.init({
6-
dsn: 'https://[email protected]/42',
7-
beforeSend(_event) {
8-
console.log('Got an event');
9-
return null;
10-
},
11-
beforeBreadcrumb(crumb) {
12-
console.log(`Got a breadcrumb: ${crumb.category}`);
13-
return crumb;
14-
},
15-
});
16-
17-
// Configure
181
const scope = Sentry.getCurrentScope();
192
scope.setExtra('foo', 'bar');
203
scope.setFingerprint('foo');
@@ -75,6 +58,5 @@ Sentry.withScope(scope => {
7558

7659
var xhr = new XMLHttpRequest();
7760
xhr.onload = () => console.log('loaded'); // This throws error
78-
// xhr.addEventListener("load", () => console.log('loaded')); This does not throw error
7961
xhr.open('GET', 'https://httpbin.org/get');
8062
xhr.send();
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import * as fs from 'node:fs';
2+
import * as path from 'node:path';
3+
4+
import { expect } from '@playwright/test';
5+
6+
import { sentryTest } from '../../../../utils/fixtures';
7+
8+
// Regression test against https://github.com/getsentry/sentry-javascript/pull/1896
9+
sentryTest('should not contain tslib_1__default', async ({ getLocalTestPath }) => {
10+
await getLocalTestPath({ testDir: __dirname });
11+
12+
const initBundle = fs.readFileSync(path.join(__dirname, 'dist', 'init.bundle.js'), 'utf-8');
13+
expect(initBundle.length).toBeGreaterThan(0);
14+
expect(initBundle).not.toContain('tslib_1__default');
15+
16+
const subjectBundle = fs.readFileSync(path.join(__dirname, 'dist', 'subject.bundle.js'), 'utf-8');
17+
expect(subjectBundle.length).toBeGreaterThan(0);
18+
expect(subjectBundle).not.toContain('tslib_1__default');
19+
});
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
const { loggingTransport } = require('@sentry-internal/node-integration-tests');
2+
const Sentry = require('@sentry/node');
3+
4+
Sentry.init({
5+
dsn: 'https://[email protected]/1337',
6+
release: '1.0',
7+
transport: loggingTransport,
8+
tracesSampler: samplingContext => {
9+
// The name we get here is inferred at span creation time
10+
// At this point, we sadly do not have a http.route attribute yet,
11+
// so we infer the name from the unparametrized route instead
12+
return (
13+
samplingContext.name === 'GET /test/123' &&
14+
samplingContext.attributes['sentry.op'] === 'http.server' &&
15+
samplingContext.attributes['http.method'] === 'GET'
16+
);
17+
},
18+
debug: true,
19+
});
20+
21+
// express must be required after Sentry is initialized
22+
const express = require('express');
23+
const cors = require('cors');
24+
const { startExpressServerAndSendPortToRunner } = require('@sentry-internal/node-integration-tests');
25+
26+
const app = express();
27+
28+
app.use(cors());
29+
30+
app.get('/test/:id', (_req, res) => {
31+
res.send('Success');
32+
});
33+
34+
app.get('/test2', (_req, res) => {
35+
res.send('Success');
36+
});
37+
38+
Sentry.setupExpressErrorHandler(app);
39+
40+
startExpressServerAndSendPortToRunner(app);
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
import { cleanupChildProcesses, createRunner } from '../../../../utils/runner';
2+
3+
describe('express tracesSampler', () => {
4+
afterAll(() => {
5+
cleanupChildProcesses();
6+
});
7+
8+
describe('CJS', () => {
9+
test('correctly samples & passes data to tracesSampler', done => {
10+
const runner = createRunner(__dirname, 'server.js')
11+
.expect({
12+
transaction: {
13+
transaction: 'GET /test/:id',
14+
},
15+
})
16+
.start(done);
17+
18+
// This is not sampled
19+
runner.makeRequest('get', '/test2?q=1');
20+
// This is sampled
21+
runner.makeRequest('get', '/test/123?q=1');
22+
});
23+
});
24+
});

docs/changelog/v7.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,15 @@
33
Support for Sentry SDK v7 will be dropped soon. We recommend migrating to the latest version of the SDK. You can migrate
44
from `v7` to `v8 of the SDK by following the [migration guide](../../MIGRATION.md).
55

6+
## 7.118.0
7+
8+
- fix(v7/bundle): Ensure CDN bundles do not overwrite `window.Sentry` (#12579)
9+
10+
## 7.117.0
11+
12+
- feat(browser/v7): Publish browserprofling CDN bundle (#12224)
13+
- fix(v7/publish): Add `v7` tag to `@sentry/replay` (#12304)
14+
615
## 7.116.0
716

817
- build(craft): Publish lambda layer under its own name for v7 (#12098) (#12099)

packages/astro/vite.config.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
1-
import type { UserConfig } from 'vitest';
2-
31
import baseConfig from '../../vite/vite.config';
42

53
export default {
64
...baseConfig,
75
test: {
8-
// test exists, no idea why TS doesn't recognize it
9-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
10-
...(baseConfig as UserConfig & { test: any }).test,
6+
...baseConfig.test,
117
environment: 'jsdom',
128
},
139
};

packages/browser/package.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,7 @@
4949
},
5050
"devDependencies": {
5151
"@sentry-internal/integration-shims": "8.18.0",
52-
"fake-indexeddb": "^4.0.1",
53-
"webpack": "^4.47.0"
52+
"fake-indexeddb": "^4.0.1"
5453
},
5554
"scripts": {
5655
"build": "run-p build:transpile build:bundle build:types",
@@ -73,7 +72,6 @@
7372
"size:check": "cat build/bundles/bundle.min.js | gzip -9 | wc -c | awk '{$1=$1/1024; print \"ES2017: \",$1,\"kB\";}'",
7473
"test": "yarn test:unit",
7574
"test:unit": "jest",
76-
"test:package": "node test/package/npm-build.js && rm test/package/tmp.js",
7775
"test:unit:watch": "jest --watch",
7876
"yalc:publish": "yalc publish --push --sig"
7977
},

packages/browser/test/package/npm-build.js

Lines changed: 0 additions & 69 deletions
This file was deleted.

0 commit comments

Comments
 (0)