Closed
Description
Describe the bug
If you run vite dev
then introduce a syntax error in vite.config.js
, the dev server tries and fails to restart, and the process crashes.
Ideally the process would stay alive, and gracefully recover once the error is fixed. Even better would be if the server survived, if only to report the error, though that's probably somewhat trickier.
Reproduction
https://github.com/Rich-Harris/vite-dev-server-crashes
Steps to reproduce
Instructions in the repro README
System Info
System:
OS: macOS 13.2.1
CPU: (10) arm64 Apple M1 Pro
Memory: 144.45 MB / 32.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 18.15.0 - ~/Library/pnpm/node
npm: 9.5.0 - ~/Library/pnpm/npm
Browsers:
Chrome: 111.0.5563.64
Firefox: 110.0.1
Safari: 16.3
npmPackages:
vite: ^4.1.4 => 4.1.4
Used Package Manager
pnpm
Logs
No response
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.