Fix webpack build dependency cell creation order (#100597)
## Summary Fix the `no-map-async-cell` violation in webpack loader build-dependency tracking so `ast-grep scan --format github` passes again. Prepare resolver options concurrently, then create their cells synchronously in request order before resolving modules concurrently. This prevents async completion order from determining Turbo Tasks cell order. CI context: bc37b30d (#100569) aligned the CI ast-grep version with the repository (0.31.0 → 0.42.0), restoring enforcement of lint failures. #100562 fixed the analyzer occurrence, but #99549 subsequently introduced this occurrence in `build_module_requests_changed`. Tradeoff: the two phases add an intermediate vector allocation and a synchronization barrier: all options must be prepared before any module resolution starts. This may reduce overlap; the performance impact has not been measured. There may be a better approach, such as reading the shared resolver options once and synchronously cloning/customizing them before creating cells, avoiding the extra preparation join. ## Verification - `pnpm exec ast-grep scan --format github` - `ast-grep test` (7 passed) - `cargo fmt --all -- --check` - `cargo check -p turbopack-node --offline` - `pnpm build-all` <!-- NEXT_JS_LLM -->
Showing
Please
register
or
sign in
to comment