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

Better error message for Did not receive an init message from worker after 60000ms #426

Closed
linonetwo opened this issue Apr 9, 2022 · 2 comments

Comments

@linonetwo
Copy link

Error: Timeout: Did not receive an init message from worker after 60000ms. Make sure the worker calls expose().
    at Timeout._onTimeout (/Applications/TidGi.app/Contents/Resources/app.asar/.webpack/main/file:/Users/runner/work/TidGi-Desktop/TidGi-Desktop/node_modules/threads/dist/master/spawn.js:35:53)
    at listOnTimeout (node:internal/timers:557:17)
    at processTimers (node:internal/timers:500:7)

But its hard to tell which one causes the error (I have multiple workers)

And this only happen on electron startup sometimes, not always, maybe listener registered too late? Can I delay the expose so the listener gets the message always?

@andywer
Copy link
Owner

andywer commented Apr 9, 2022

Good point. Might be a duplicate of #420, though.

linonetwo added a commit to tiddly-gittly/TidGi-Desktop that referenced this issue May 9, 2022
@linonetwo
Copy link
Author

This usually happened when a import xxx failed.

And import maybe good in dev env, but bad after electron packaged. So this will happened in electron production mode.

I found it by moving some of import to dynamic import, and it never say Did not receive an init message from worker after #478

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

No branches or pull requests

2 participants