From 7cacd97961af20e0b3562f01d9668786fad6b733 Mon Sep 17 00:00:00 2001 From: Charly Gomez Date: Mon, 13 Oct 2025 14:54:46 +0200 Subject: [PATCH 1/3] rm ppr --- .../nextjs-15/app/ppr-error/[param]/page.tsx | 17 -------------- .../nextjs-15/next.config.js | 6 +---- .../test-applications/nextjs-15/package.json | 15 +++++-------- .../nextjs-15/tests/ppr-error.test.ts | 22 ------------------- 4 files changed, 6 insertions(+), 54 deletions(-) delete mode 100644 dev-packages/e2e-tests/test-applications/nextjs-15/app/ppr-error/[param]/page.tsx delete mode 100644 dev-packages/e2e-tests/test-applications/nextjs-15/tests/ppr-error.test.ts diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15/app/ppr-error/[param]/page.tsx b/dev-packages/e2e-tests/test-applications/nextjs-15/app/ppr-error/[param]/page.tsx deleted file mode 100644 index f2e096164d04..000000000000 --- a/dev-packages/e2e-tests/test-applications/nextjs-15/app/ppr-error/[param]/page.tsx +++ /dev/null @@ -1,17 +0,0 @@ -import * as Sentry from '@sentry/nextjs'; - -export default async function Page({ searchParams }: { searchParams: any }) { - // We need to dynamically check for this because Next.js made the API async for Next.js 15 and we use this test in canary tests - const normalizedSearchParams = await searchParams; - - try { - console.log(normalizedSearchParams.id); // Accessing a field on searchParams will throw the PPR error - } catch (e) { - Sentry.captureException(e); // This error should not be reported - await new Promise(resolve => setTimeout(resolve, 1000)); // Wait for any async event processors to run - await Sentry.flush(); - throw e; - } - - return
This server component will throw a PPR error that we do not want to catch.
; -} diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15/next.config.js b/dev-packages/e2e-tests/test-applications/nextjs-15/next.config.js index 2be749fde774..1098c2ce5a4f 100644 --- a/dev-packages/e2e-tests/test-applications/nextjs-15/next.config.js +++ b/dev-packages/e2e-tests/test-applications/nextjs-15/next.config.js @@ -1,11 +1,7 @@ const { withSentryConfig } = require('@sentry/nextjs'); /** @type {import('next').NextConfig} */ -const nextConfig = { - experimental: { - ppr: true, - }, -}; +const nextConfig = {}; module.exports = withSentryConfig(nextConfig, { silent: true, diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15/package.json b/dev-packages/e2e-tests/test-applications/nextjs-15/package.json index 7f9b3e822628..3e8e5f2af69f 100644 --- a/dev-packages/e2e-tests/test-applications/nextjs-15/package.json +++ b/dev-packages/e2e-tests/test-applications/nextjs-15/package.json @@ -11,9 +11,8 @@ "test:dev-turbo": "TEST_ENV=dev-turbopack playwright test", "test:build": "pnpm install && pnpm build", "test:build-canary": "pnpm install && pnpm add next@canary && pnpm add react@beta && pnpm add react-dom@beta && pnpm build", - "//": "15.0.0-canary.194 is the canary release attached to Next.js RC 1. We need to use the canary version instead of the RC because PPR will not work without. The specific react version is also attached to RC 1.", - "test:build-latest": "pnpm install && pnpm add next@15.0.0-canary.194 && pnpm add react@19.0.0-rc-cd22717c-20241013 && pnpm add react-dom@19.0.0-rc-cd22717c-20241013 && pnpm build", - "test:build-turbo": "pnpm install && pnpm add next@15.4.2-canary.1 && next build --turbopack", + "test:build-latest": "pnpm install && pnpm add next@next-15 && pnpm build", + "test:build-turbo": "pnpm install && next build --turbopack", "test:assert": "pnpm test:prod && pnpm test:dev" }, "dependencies": { @@ -22,9 +21,9 @@ "@types/react": "18.0.26", "@types/react-dom": "18.0.9", "ai": "^3.0.0", - "next": "15.4.2-canary.1", - "react": "beta", - "react-dom": "beta", + "next": "15.5.4", + "react": "latest", + "react-dom": "latest", "typescript": "~5.0.0", "zod": "^3.22.4" }, @@ -37,10 +36,6 @@ }, "sentryTest": { "optionalVariants": [ - { - "build-command": "pnpm test:build-canary", - "label": "nextjs-15 (canary)" - }, { "build-command": "pnpm test:build-latest", "label": "nextjs-15 (latest)" diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15/tests/ppr-error.test.ts b/dev-packages/e2e-tests/test-applications/nextjs-15/tests/ppr-error.test.ts deleted file mode 100644 index 7c7c0b91eed2..000000000000 --- a/dev-packages/e2e-tests/test-applications/nextjs-15/tests/ppr-error.test.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { expect, test } from '@playwright/test'; -import { waitForError, waitForTransaction } from '@sentry-internal/test-utils'; - -test('should not capture React-internal errors for PPR rendering', async ({ page }) => { - const pageServerComponentTransactionPromise = waitForTransaction('nextjs-15', async transactionEvent => { - return transactionEvent?.transaction === 'GET /ppr-error/[param]'; - }); - - let errorEventReceived = false; - waitForError('nextjs-15', async errorEvent => { - return errorEvent?.transaction === 'Page Server Component (/ppr-error/[param])'; - }).then(() => { - errorEventReceived = true; - }); - - await page.goto(`/ppr-error/foobar?id=1`); - - const pageServerComponentTransaction = await pageServerComponentTransactionPromise; - expect(pageServerComponentTransaction).toBeDefined(); - - expect(errorEventReceived).toBe(false); -}); From a89ce7b47b2752fd858b0255bf5740c622aee969 Mon Sep 17 00:00:00 2001 From: Charly Gomez Date: Mon, 13 Oct 2025 16:08:55 +0200 Subject: [PATCH 2/3] install latest 15 --- .../e2e-tests/test-applications/nextjs-15/package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15/package.json b/dev-packages/e2e-tests/test-applications/nextjs-15/package.json index 3e8e5f2af69f..9d56bf6c3df5 100644 --- a/dev-packages/e2e-tests/test-applications/nextjs-15/package.json +++ b/dev-packages/e2e-tests/test-applications/nextjs-15/package.json @@ -10,8 +10,7 @@ "test:dev": "TEST_ENV=development playwright test", "test:dev-turbo": "TEST_ENV=dev-turbopack playwright test", "test:build": "pnpm install && pnpm build", - "test:build-canary": "pnpm install && pnpm add next@canary && pnpm add react@beta && pnpm add react-dom@beta && pnpm build", - "test:build-latest": "pnpm install && pnpm add next@next-15 && pnpm build", + "test:build-latest": "pnpm install && pnpm add next@15 && pnpm build", "test:build-turbo": "pnpm install && next build --turbopack", "test:assert": "pnpm test:prod && pnpm test:dev" }, From f0e14bbc2faebca718790ad861c68740c0b4f8a9 Mon Sep 17 00:00:00 2001 From: Charly Gomez Date: Mon, 13 Oct 2025 16:12:28 +0200 Subject: [PATCH 3/3] test 15-basetest also on latest --- .../test-applications/nextjs-15-basepath/package.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dev-packages/e2e-tests/test-applications/nextjs-15-basepath/package.json b/dev-packages/e2e-tests/test-applications/nextjs-15-basepath/package.json index 48a0c69ae38a..7481ea0fca7a 100644 --- a/dev-packages/e2e-tests/test-applications/nextjs-15-basepath/package.json +++ b/dev-packages/e2e-tests/test-applications/nextjs-15-basepath/package.json @@ -15,9 +15,9 @@ "@types/node": "^18.19.1", "@types/react": "18.0.26", "@types/react-dom": "18.0.9", - "next": "15.4.2-canary.1", - "react": "beta", - "react-dom": "beta", + "next": "^15", + "react": "latest", + "react-dom": "latest", "typescript": "~5.0.0" }, "devDependencies": {