Turbopack panic: Dependency tracking disabled; invalidation blocked during Next.js 16 build

When running next build on Windows, Turbopack crashes with an internal panic that states: “Dependency tracking is disabled so invalidation is not allowed”. The crash happens during the optimized production build stage and immediately aborts the build. This began after local changes; previously the project built successfully with Turbopack. I confirmed versions and attempted multiple fixes locally without success.

Environment

  • OS: Windows 10/11 (local machine; specify exact Windows build if available)

  • Node: v24.11.1

  • npm: 10.8.2

  • Next.js: v16.0.9

  • Shell: Git Bash / PowerShell (both tried)

Reproduction steps

  1. Clone or use the project root.

  2. Ensure dependencies installed: npm ci (or npm install).

  3. Run: next build (or npm run build).

  4. Turbopack panics and a panic file is generated in the OS temp directory.

Observed behavior
Build aborts with this error message printed in the console:

thread 'tokio-runtime-worker' panicked:
Dependency tracking is disabled so invalidation is not allowed

A panic file appears at C:\Users\<USER>\AppData\Local\Temp\next-panic-*.log. Full panic log attached.

What I tried

  • Deleted .next and node_modules, cleared npm cache, reinstalled.

  • Enabled Turbopack persistent caching flags in next.config.ts.

  • Attempted builds with RUST_BACKTRACE=1 and NEXT_TURBOPACK_TRACING=1 to collect logs.

  • Forced build to Webpack (NEXT_USE_TURBOPACK=0) — that succeeds, so it appears specific to Turbopack runtime.

  • Verified Node architecture (x64) and checked for duplicate/case-conflicting filenames.

Files & logs attached

  • turbopack-debug.log — full traced build output (run with cross-env RUST_BACKTRACE=1 NEXT_TURBOPACK_TRACING=1 next build > turbopack-debug.log 2>&1).

  • next-panic-*.log — the panic log found in %TEMP% (attach the file).

  • next.config.ts — current config (paste below or attach).
    Please see attached files for exact backtrace and context.

Additional notes

  • I can provide a minimal reproduction repo if helpful. If there are any known Windows-specific Turbopack issues or recommended next.config flags to toggle for stability, I can try them and repost logs. Happy to run further diagnostics on command.

Next.config.ts (paste or attach here)

<paste your next.config.ts content here>

Thanks — please advise next steps or tell me if you want a minimal repro repository and I’ll prepare one.

Hey, happy to take a look but i don’t see the files you attached? did something go wrong?

A minimal repro would be great!

I was also running in this issue, until I switched this option in windows: Developer mode - ON