Skip to content

Commit 2dffa0e

Browse files
authored
Merge branch 'develop' into stream-responses-openai
2 parents ffcd2f7 + 68d7ee4 commit 2dffa0e

File tree

182 files changed

+2490
-3491
lines changed

Some content is hidden

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

182 files changed

+2490
-3491
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,6 @@ env:
4747
${{ github.workspace }}/packages/*/lib
4848
${{ github.workspace }}/packages/ember/*.d.ts
4949
${{ github.workspace }}/packages/gatsby/*.d.ts
50-
${{ github.workspace }}/packages/utils/cjs
51-
${{ github.workspace }}/packages/utils/esm
5250
5351
BUILD_CACHE_TARBALL_KEY: tarball-${{ github.event.inputs.commit || github.sha }}
5452

@@ -950,13 +948,13 @@ jobs:
950948
retention-days: 7
951949

952950
- name: Pre-process E2E Test Dumps
953-
if: always()
951+
if: failure()
954952
run: |
955953
node ./scripts/normalize-e2e-test-dump-transaction-events.js
956954
957955
- name: Upload E2E Test Event Dumps
958956
uses: actions/upload-artifact@v4
959-
if: always()
957+
if: failure()
960958
with:
961959
name: E2E Test Dump (${{ matrix.label || matrix.test-application }})
962960
path: ${{ runner.temp }}/test-application/event-dumps
@@ -1062,13 +1060,13 @@ jobs:
10621060
run: pnpm ${{ matrix.assert-command || 'test:assert' }}
10631061

10641062
- name: Pre-process E2E Test Dumps
1065-
if: always()
1063+
if: failure()
10661064
run: |
10671065
node ./scripts/normalize-e2e-test-dump-transaction-events.js
10681066
10691067
- name: Upload E2E Test Event Dumps
10701068
uses: actions/upload-artifact@v4
1071-
if: always()
1069+
if: failure()
10721070
with:
10731071
name: E2E Test Dump (${{ matrix.label || matrix.test-application }})
10741072
path: ${{ runner.temp }}/test-application/event-dumps

.size-limit.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ module.exports = [
233233
import: createImport('init'),
234234
ignore: [...builtinModules, ...nodePrefixedBuiltinModules],
235235
gzip: true,
236-
limit: '145 KB',
236+
limit: '146 KB',
237237
},
238238
{
239239
name: '@sentry/node - without tracing',

MIGRATION.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,23 @@ Sentry.init({
6161
});
6262
```
6363

64+
## 3. Behaviour Changes
65+
66+
### Removal of First Input Delay (FID) Web Vital Reporting
67+
68+
Affected SDKs: All SDKs running in browser applications (`@sentry/browser`, `@sentry/react`, `@sentry/nextjs`, etc.)
69+
70+
In v10, the SDK stopped reporting the First Input Delay (FID) web vital.
71+
This was done because FID has been replaced by Interaction to Next Paint (INP) and is therefore no longer relevant for assessing and tracking a website's performance.
72+
For reference, FID has long been deprecated by Google's official `web-vitals` library and was eventually removed in version `5.0.0`.
73+
Sentry now follows Google's lead by also removing it.
74+
75+
The removal entails **no breaking API changes**. However, in rare cases, you might need to adjust some of your Sentry SDK and product setup:
76+
77+
- Remove any logic in `beforeSend` or other filtering/event processing logic that depends on FID or replace it with INP logic.
78+
- If you set up Sentry Alerts that depend on FID, be aware that these could trigger once you upgrade the SDK, due to a lack of new values.
79+
To replace them, adjust your alerts (or dashbaords) to use INP.
80+
6481
## No Version Support Timeline
6582

6683
Version support timelines are stressful for everybody using the SDK, so we won't be defining one.

dev-packages/browser-integration-tests/suites/replay/customEvents/test.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {
44
expectedClickBreadcrumb,
55
expectedCLSPerformanceSpan,
66
expectedFCPPerformanceSpan,
7-
expectedFIDPerformanceSpan,
87
expectedFPPerformanceSpan,
98
expectedLCPPerformanceSpan,
109
expectedMemoryPerformanceSpan,
@@ -56,7 +55,6 @@ sentryTest(
5655
expectedNavigationPerformanceSpan,
5756
expectedLCPPerformanceSpan,
5857
expectedCLSPerformanceSpan,
59-
expectedFIDPerformanceSpan,
6058
expectedFPPerformanceSpan,
6159
expectedFCPPerformanceSpan,
6260
expectedMemoryPerformanceSpan, // two memory spans - once per flush

dev-packages/browser-integration-tests/suites/replay/multiple-pages/test.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {
44
expectedClickBreadcrumb,
55
expectedCLSPerformanceSpan,
66
expectedFCPPerformanceSpan,
7-
expectedFIDPerformanceSpan,
87
expectedFPPerformanceSpan,
98
expectedLCPPerformanceSpan,
109
expectedMemoryPerformanceSpan,
@@ -77,7 +76,6 @@ sentryTest(
7776
expectedNavigationPerformanceSpan,
7877
expectedLCPPerformanceSpan,
7978
expectedCLSPerformanceSpan,
80-
expectedFIDPerformanceSpan,
8179
expectedFPPerformanceSpan,
8280
expectedFCPPerformanceSpan,
8381
expectedMemoryPerformanceSpan, // two memory spans - once per flush
@@ -117,7 +115,6 @@ sentryTest(
117115
expectedReloadPerformanceSpan,
118116
expectedLCPPerformanceSpan,
119117
expectedCLSPerformanceSpan,
120-
expectedFIDPerformanceSpan,
121118
expectedFPPerformanceSpan,
122119
expectedFCPPerformanceSpan,
123120
expectedMemoryPerformanceSpan,
@@ -188,7 +185,6 @@ sentryTest(
188185
expectedNavigationPerformanceSpan,
189186
expectedLCPPerformanceSpan,
190187
expectedCLSPerformanceSpan,
191-
expectedFIDPerformanceSpan,
192188
expectedFPPerformanceSpan,
193189
expectedFCPPerformanceSpan,
194190
expectedMemoryPerformanceSpan,
@@ -326,7 +322,6 @@ sentryTest(
326322
expectedNavigationPerformanceSpan,
327323
expectedLCPPerformanceSpan,
328324
expectedCLSPerformanceSpan,
329-
expectedFIDPerformanceSpan,
330325
expectedFPPerformanceSpan,
331326
expectedFCPPerformanceSpan,
332327
expectedMemoryPerformanceSpan,

dev-packages/browser-integration-tests/suites/tracing/metrics/web-vitals-fid/template.html

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

dev-packages/browser-integration-tests/suites/tracing/metrics/web-vitals-fid/test.ts

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

dev-packages/browser-integration-tests/utils/replayEventTemplates.ts

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -148,19 +148,6 @@ export const expectedCLSPerformanceSpan = {
148148
},
149149
};
150150

151-
export const expectedFIDPerformanceSpan = {
152-
op: 'web-vital',
153-
description: 'first-input-delay',
154-
startTimestamp: expect.any(Number),
155-
endTimestamp: expect.any(Number),
156-
data: {
157-
value: expect.any(Number),
158-
rating: expect.any(String),
159-
size: expect.any(Number),
160-
nodeIds: expect.any(Array),
161-
},
162-
};
163-
164151
export const expectedINPPerformanceSpan = {
165152
op: 'web-vital',
166153
description: 'interaction-to-next-paint',

dev-packages/e2e-tests/lib/getTestMatrix.ts

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,27 @@ function getAffectedTestApplications(
143143
.map(line => line.trim())
144144
.filter(Boolean);
145145

146-
// If something in e2e tests themselves are changed, just run everything
146+
// If something in e2e tests themselves are changed, check if only test applications were changed
147147
if (affectedProjects.includes('@sentry-internal/e2e-tests')) {
148+
try {
149+
const changedTestApps = getChangedTestApps(base, head);
150+
151+
// Shared code was changed, run all tests
152+
if (changedTestApps === false) {
153+
return testApplications;
154+
}
155+
156+
// Only test applications that were changed, run selectively
157+
if (changedTestApps.size > 0) {
158+
return testApplications.filter(testApp => changedTestApps.has(testApp));
159+
}
160+
} catch (error) {
161+
// eslint-disable-next-line no-console
162+
console.error('Failed to get changed files, running all tests:', error);
163+
return testApplications;
164+
}
165+
166+
// Fall back to running all tests
148167
return testApplications;
149168
}
150169

@@ -153,3 +172,32 @@ function getAffectedTestApplications(
153172
return sentryDependencies.some(dep => affectedProjects.includes(dep));
154173
});
155174
}
175+
176+
function getChangedTestApps(base: string, head?: string): false | Set<string> {
177+
const changedFiles = execSync(`git diff --name-only ${base}${head ? `..${head}` : ''} -- dev-packages/e2e-tests/`, {
178+
encoding: 'utf-8',
179+
})
180+
.toString()
181+
.split('\n')
182+
.map(line => line.trim())
183+
.filter(Boolean);
184+
185+
const changedTestApps: Set<string> = new Set();
186+
const testAppsPrefix = 'dev-packages/e2e-tests/test-applications/';
187+
188+
for (const file of changedFiles) {
189+
if (!file.startsWith(testAppsPrefix)) {
190+
// Shared code change - need to run all tests
191+
return false;
192+
}
193+
194+
const pathAfterPrefix = file.slice(testAppsPrefix.length);
195+
const slashIndex = pathAfterPrefix.indexOf('/');
196+
197+
if (slashIndex > 0) {
198+
changedTestApps.add(pathAfterPrefix.slice(0, slashIndex));
199+
}
200+
}
201+
202+
return changedTestApps;
203+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
import Layout from '../../layouts/Layout.astro';
3+
4+
export const prerender = false;
5+
6+
---
7+
8+
<Layout title="User Settings">
9+
<h1>User Settings</h1>
10+
</Layout>

0 commit comments

Comments
 (0)