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

Updated dependency crashes server #27

Open
jamesgpearce opened this issue Dec 29, 2023 · 2 comments
Open

Updated dependency crashes server #27

jamesgpearce opened this issue Dec 29, 2023 · 2 comments

Comments

@jamesgpearce
Copy link
Contributor

jamesgpearce commented Dec 29, 2023

When I update vite-express to 0.12.0, the server crashes.

 @types/react                      ^18.0.28  →  ^18.2.46
 @types/react-dom                  ^18.0.11  →  ^18.2.18
 @typescript-eslint/eslint-plugin   ^5.57.1  →   ^6.16.0
 @typescript-eslint/parser          ^5.57.1  →   ^6.16.0
 @vitejs/plugin-react                ^4.0.0  →    ^4.2.1
 eslint                             ^8.38.0  →   ^8.56.0
 eslint-plugin-react-refresh         ^0.3.4  →    ^0.4.5
 typescript                          ^5.0.2  →    ^5.3.3
 vite                                ^4.3.9  →   ^5.0.10
 vite-express                        ^0.9.2  →   ^0.12.0
 vite-plugin-pwa                    ^0.16.4  →   ^0.17.4

👇

> vlcn-vite-starter@0.0.0 dev
> node ./server.js

No logger set! Using default logger.
info: Watching ./dbs/* for changes using polling: false {"service":"ws-server"}
10:06:15 AM [vite-express] Running in development mode
info listening on http://localhost:8080!
10:06:16 AM [vite-express] Using Vite to resolve the config file
Re-optimizing dependencies because lockfile has changed
info: upgrading to ws connection {"service":"ws-server"}

node:buffer:1322
      throw lazyDOMException('Invalid character', 'InvalidCharacterError');
      ^
DOMException [InvalidCharacterError]: Invalid character
    at atob (node:buffer:1322:13)
    at parseSecHeader (file:///Users/james/code/scratch/a/node_modules/@vlcn.io/ws-server/dist/index.js:80:21)
    at pullSecHeaders (file:///Users/james/code/scratch/a/node_modules/@vlcn.io/ws-server/dist/index.js:77:12)
    at Server.<anonymous> (file:///Users/james/code/scratch/a/node_modules/@vlcn.io/ws-server/dist/index.js:35:25)
    at Server.emit (node:events:531:35)
    at onParserExecuteCommon (node:_http_server:942:14)
    at onParserExecute (node:_http_server:836:3)

Node.js v21.2.0
@tantaman
Copy link
Contributor

tantaman commented Jan 4, 2024

Thanks for the report. Looks like something is being tossed into the auth header that is invalid base64

@Gobbo89
Copy link

Gobbo89 commented Feb 5, 2024

Hello, I also run into this issue, and had to stick to vite-express 0.11.
It's probably related to changes introduced in Make Vite middleware use current server for HMR WebSocket #100

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants