Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'Re-optimizing dependencies because vite config has changed’ causes a crash #7060

Open
johnnydecimal opened this issue Feb 25, 2025 · 0 comments
Labels
type: bug code to address defects in shipped code

Comments

@johnnydecimal
Copy link

Describe the bug

This often happens when I refactor CSS. I’m using Astro.

15:55:27 [vite] Re-optimizing dependencies because vite config has changed
TypeError: res.writeHead is not a function
    at ProxyServer.<anonymous> (file:///Users/john/.nvm/versions/node/v22.11.0/lib/node_modules/netlify-cli/dist/utils/proxy.js:392:13)
    at ProxyServer.emit (/Users/john/.nvm/versions/node/v22.11.0/lib/node_modules/netlify-cli/node_modules/eventemitter3/index.js:204:33)
    at ClientRequest.onOutgoingError (/Users/john/.nvm/versions/node/v22.11.0/lib/node_modules/netlify-cli/node_modules/http-proxy/lib/http-proxy/passes/ws-incoming.js:157:16)
    at ClientRequest.emit (node:events:518:28)
    at ClientRequest.emit (node:domain:489:12)
    at emitErrorEvent (node:_http_client:103:11)
    at Socket.socketErrorListener (node:_http_client:506:5)
    at Socket.emit (node:events:518:28)
    at Socket.emit (node:domain:489:12)
    at emitErrorNT (node:internal/streams/destroy:170:8)

  System:
    OS: macOS 15.3.1
    CPU: (8) arm64 Apple M1
  Binaries:
    Node: 22.11.0 - ~/.nvm/versions/node/v22.11.0/bin/node
    npm: 11.0.0 - ~/.nvm/versions/node/v22.11.0/bin/npm
  Browsers:
    Safari: 18.3
  npmGlobalPackages:
    netlify-cli: 19.0.0

Steps to reproduce

  1. Run netlify dev on an Astro project.
  2. Significantly change the structure of CSS.
  3. 💣

Configuration

[dev]
targetPort = 3011
port = 3012

Environment

System:
OS: macOS 15.3.1
CPU: (8) arm64 Apple M1
Memory: 107.61 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.11.0 - ~/.nvm/versions/node/v22.11.0/bin/node
npm: 11.0.0 - ~/.nvm/versions/node/v22.11.0/bin/npm
pnpm: 9.12.3 - /opt/homebrew/bin/pnpm
npmGlobalPackages:
netlify-cli: 19.0.0

@johnnydecimal johnnydecimal added the type: bug code to address defects in shipped code label Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug code to address defects in shipped code
Projects
None yet
Development

No branches or pull requests

1 participant