8be4ef47cd
The static import of @sentry/nextjs at module level triggered worker thread creation even when withSentryConfig was only called in production. This caused recurring "Cannot find module vendor-chunks/lib/worker.js" crashes that killed the dev server mid-request. Fix: replaced static import with dynamic require() inside a NODE_ENV === "production" block. In dev mode, the Sentry module is never loaded at all. Co-Authored-By: claude-flow <ruv@ruv.net>