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

walkImportChain: Maximum call stack size exceeded #438

Closed
nym21 opened this issue Jun 23, 2020 · 2 comments
Closed

walkImportChain: Maximum call stack size exceeded #438

nym21 opened this issue Jun 23, 2020 · 2 comments

Comments

@nym21
Copy link

nym21 commented Jun 23, 2020

Describe the bug

When I save a js file that is being imported in a lot of places the HMR breaks

Reproduction

I'm trying to do a much simpler repository but I'm having a hard time reproducing it with a simple one

But here's one where it breaks: https://github.com/quickbookio/app

Just:

git clone
yarn
yarn dev

then go to http://localhost:3000/#/app and in your editor go to the src/js/store.js file for example and save

Also I checked there is no import loop (would be cool if it could detected and notified though 👍, rollup does it)

System Info

  • required vite version: latest
  • required Operating System: Mac OS 10.15.5
  • required Node version: v14.4

Logs (Optional if provided reproduction)

(node:19651) UnhandledPromiseRejectionWarning: RangeError: Maximum call stack size exceeded
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:144:25)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
    at walkImportChain (/Users/k/code/quickbook/app/node_modules/vite/dist/server/serverPluginHmr.js:169:22)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:19651) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:19651) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
@yyx990803
Copy link
Member

I noticed the load speed issue of the project is largely due to slow style insertion because of the huge tailwind css file, but that's a separate issue...

@nym21
Copy link
Author

nym21 commented Jun 23, 2020

It's a bit slow indeed but still faster than my previous setup with rollup !

Hope that you guys will find a solution to make it faster 👍

Thank you for the quick fix by the way !

@github-actions github-actions bot locked and limited conversation to collaborators Jul 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants