We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
⚠ ./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/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]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js Error: An error occurred while loading instrumentation hook: Cannot find module 'os' at webpackEmptyContext (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:22:10) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:12687) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:29503) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:29991) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:30305) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:43728) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:60086) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:21:20565) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:20:832) at eval (webpack-internal:///(instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js:33:45327) at (instrument)/./node_modules/.pnpm/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq/node_modules/@vercel/otel/dist/node/index.js (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/vendor-chunks/@[email protected]_@[email protected]_@[email protected]_@opentelemetry+ins_afxcmrvzguz46bycbb3njvxqfq.js:20:1) at __webpack_require__ (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/webpack-runtime.js:33:42) at eval (webpack-internal:///(instrument)/./src/instrumentation.ts:5:70) at (instrument)/./src/instrumentation.ts (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:62:1) at __webpack_require__ (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/webpack-runtime.js:33:42) at __webpack_exec__ (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:72:39) at /Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:73:287 at __webpack_require__.X (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/webpack-runtime.js:116:21) at /Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:73:47 at Object.<anonymous> (/Users/aonsx/WebstormProjects/lobe-chat/.next/server/instrumentation.js:76:3) at Module._compile (node:internal/modules/cjs/loader:1358:14) at Module._extensions..js (node:internal/modules/cjs/loader:1416:10) at Module.load (node:internal/modules/cjs/loader:1208:32) at Module._load (node:internal/modules/cjs/loader:1024:12) at Module.require (node:internal/modules/cjs/loader:1233:19) at mod.require (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/require-hook.js:65:28) at require (node:internal/modules/helpers:179:18) at DevServer.runInstrumentationHookIfAvailable (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/dev/next-dev-server.js:436:51) at async Span.traceAsyncFn (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/trace/trace.js:154:20) at async DevServer.prepareImpl (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/dev/next-dev-server.js:214:9) at async NextServer.prepare (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/next.js:161:13) at async initializeImpl (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/lib/render-server.js:98:5) at async initialize (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/lib/router-server.js:423:22) at async Server.<anonymous> (/Users/aonsx/WebstormProjects/lobe-chat/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/lib/start-server.js:249:36) { code: 'MODULE_NOT_FOUND' }
The text was updated successfully, but these errors were encountered:
Same thing happening to me :-(
Sorry, something went wrong.
same issue for me :(
I had this problem, too. I resolved it by adding "@vercel/otel" to the serverComponentsExternalPackages list in Next.js configuration.
serverComponentsExternalPackages
In next.config.ts add:
next.config.ts
experimental: {, serverComponentsExternalPackages: [ "@vercel/otel" ] }
This change tells Next.js to treat @vercel/otel as an external package in server components, which should resolve the critical dependency warning.
@vercel/otel
No branches or pull requests
The text was updated successfully, but these errors were encountered: