-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
Labels
feat: deps optimizerEsbuild Dependencies OptimizationEsbuild Dependencies Optimizationhas workaroundp3-downstream-blockerBlocking the downstream ecosystem to work properly (priority)Blocking the downstream ecosystem to work properly (priority)regressionThe issue only appears after a new releaseThe issue only appears after a new release
Description
Describe the bug
When upgrading from Vite 6 to Vite 7, I encounter this error only the first time I start the dev server:
Failed to run dependency scan. Skipping dependency pre-bundling. Error: failed to resolve rollupOptions.input value: "demo/entry.js".
- The error only appears on the first run after upgrading Vite and running
npm run dev. - The dev server still starts and works correctly even when the error appears.
- After making any change to the code (triggering HMR), the server continues to function and the error does not reappear.
- If I stop the server (Ctrl+C) and run
npm run devagain, the error does not show up anymore. - This behavior is not present in Vite 6; there are no errors in the same setup.
Reproduction
https://stackblitz.com/edit/vitejs-vite-rwztsg7q?file=vite.config.js
Steps to reproduce
- Go to this URL: https://stackblitz.com/edit/vitejs-vite-rwztsg7q?file=vite.config.js
The error appears the first time the dev server starts.
Note: You may need to scroll up in the terminal to see the error message, as it is above the visible area. - Stop the server.
- Run
npm run devagain.
The error does not appear anymore. - Alternatively, in the StackBlitz terminal, run
rm -rf node_modules && npm iand thennpm run dev.
The error appears again.
System Info
System:
OS: macOS 15.5
CPU: (8) arm64 Apple M3
Memory: 1.04 GB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.9.0 - ~/.nvm/versions/node/v22.9.0/bin/node
Yarn: 1.22.22 - ~/.nvm/versions/node/v22.9.0/bin/yarn
npm: 10.9.0 - ~/.nvm/versions/node/v22.9.0/bin/npm
pnpm: 9.15.4 - ~/.nvm/versions/node/v22.9.0/bin/pnpm
bun: 1.1.34 - ~/.bun/bin/bun
Browsers:
Chrome: 138.0.7204.93
Chrome Canary: 140.0.7280.0
Edge: 138.0.3351.65
Safari: 18.5
Safari Technology Preview: 26.0Used Package Manager
npm
Logs
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to vuejs/core instead.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.
ysgk, he3als, Jeto143 and hivokas
Metadata
Metadata
Assignees
Labels
feat: deps optimizerEsbuild Dependencies OptimizationEsbuild Dependencies Optimizationhas workaroundp3-downstream-blockerBlocking the downstream ecosystem to work properly (priority)Blocking the downstream ecosystem to work properly (priority)regressionThe issue only appears after a new releaseThe issue only appears after a new release