Skip to content

Critical dependency warning with require-in-the-middle after upgrading to Sentry 8.52.0 in Next.js app #15209

Open
@danielkoller

Description

@danielkoller

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/nextjs

SDK Version

8.52.0

Framework Version

React 19.0.0 & Next.js 15.1.6

Link to Sentry event

No response

Reproduction Example/SDK Setup

No response

Steps to Reproduce

  1. Create a Next.js application
  2. Install latest @sentry/nextjs (8.52.0)
  3. Run the development server
  4. Observe the critical dependency warning

Expected Result

No critical dependency warnings during development server startup.

Actual Result

 ⚠ ./node_modules/.pnpm/[email protected]/node_modules/require-in-the-middle/index.js
Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Import trace for requested module:
./node_modules/.pnpm/[email protected]/node_modules/require-in-the-middle/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]/node_modules/@opentelemetry/instrumentation/build/esm/platform/node/instrumentation.js
./node_modules/.pnpm/@[email protected]_@[email protected]/node_modules/@opentelemetry/instrumentation/build/esm/platform/node/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]/node_modules/@opentelemetry/instrumentation/build/esm/platform/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]/node_modules/@opentelemetry/instrumentation/build/esm/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemet_usgluomwp3va5k3mad5pbwdxfm/node_modules/@sentry/opentelemetry/build/cjs/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]__@opentelemetry+ins_fvm7vkuyikfkbj6gbt6uu4g4sq/node_modules/@sentry/nextjs/build/cjs/server/index.js
./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]__@opentelemetry+ins_fvm7vkuyikfkbj6gbt6uu4g4sq/node_modules/@sentry/nextjs/build/cjs/index.server.js

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions