Closed asakiasako closed 4 years ago
@asakiasako my use case is similar as I used electron-react-boilerplate. In their docs, they mentioned something about some modules uses native code, i.e. C/C++, and those modules would be handled somewhat differently. zerorpc is the only one in this context. Also the npm page of zeromq mentions something about using prebuilt binary instead of build from source. Hope this can help you narrow it down a bit...
I managed to fix this by replacing the git url with the node version:
"dependencies": { "zerorpc": "^0.9.7" },
@fyears Is there any reason to use your custom version of zerorpc. The app seems to be fully functional with zerorpc 0.9.7.
@meowlz My conf just want to use the optimized versions of msgpack and zeromq that don't need c++ compilers for installing, nothing else.
It's quite strange that it doesn't work with other latest libraries. :-(
Thank you for your sharing.
After changing the dependencies as @meowlz suggested I also needed to use electron-rebuild vianpm install --save-dev electron-rebuild
and npx electron-rebuild
before I could get npx electron .
to work.
What's happened to git+https://github.com/fyears/zerorpc-node.git has it been deleted or made private?
This breaks your own https://github.com/fyears/electron-python-example, a few of my own projects plus anybody else replying on this repo. Seemed to be there yesterday...
Same issue as @abulka This is crucial for one of my projects.
@bvhpatel Turns out you can use the official zerorpc repo instead, but make sure you are using electron 3, not higher. See my article.
Thank you, @abulka! Would you know if there is any "loss" (in performance, functionalities, or else) by using electron 3 rather than 7?
A late update on Dec 31, 2019:
I am so sorry about the issues, @abulka @bvhpatel . Please allow me to explain what happened.
First of all, the post was written 3~4 years ago. I haven't maintained the repo for a long time, so I would not be surprised if anything breaks now, since the libraries/software (including Electron and Python) are evolving VERY VERY quickly.
The code was released under MIT license. You could change the code under the license. But remember, THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, ...
What happened to my repo fyears/zerorpc-node
? It was just because my changes were merged by upstream. So a few days ago I cleaned up my GitHub repos and just deleted it (without remembering to change my article words). Now I have changed the readme, pointing to the official repo without the need to use my own fork of zerorpc-node
. Notice that it doesn't mean that it would work, because like I said the post was written a few years before and haven't been updated or maintained for a long time!!
Would you know if there is any "loss" (in performance, functionalities, or else) by using electron 3 rather than 7?
I guess some APIs have been changed from Electron 3 to 7, so this situation prevents people from upgrading if not updating my code to adapt to the latest APIs. I am sure you will find a way to upgrade. :-)
I built my app just following the instruction. Thanks for the great work. It's really helpful. It works pretty well before I package the electron app, but when I finally package it, error comes (zerorpc module can not find). The resources/app/node_modules directory has all other modules except those imported by zerorpc. I don't know why it comes, but I guess the key point is it's imported by git link. Can you give me any suggestions? Thanks.