You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 12, 2021. It is now read-only.
Repository navigation
This repository was archived by the owner on May 12, 2021. It is now read-only.
upgrade to electron v3 to fix crash with some linux GPU configurations #844
I started using Patchwork in Patchwork-3.10.0-linux-x86_64.AppImage. Works perfectly. Says that there is an update... If I run 3.10.0 works, but if I run 3.10.1 no.
Some days ago everything worked smooth. Now trying to run it with npm start just exit silently, I removed node_modules and ran npm install with no change.
So I downloaded the AppImage and when execute I got:
Arch has been having a ton of issues with Electron as a Node module, so I've been using the system Electron instead. Could you try that for now? There are two packages on the AUR for the normal release and for staying up-to-date with master on GitHub:
If you're building from source, you'll need to pacman -S electron and rm -rf node_modules/electron so that you're using the system Electron rather than the Node module. You should be able to follow the issue as electron/electron#13972, which is causing Patchwork issues as a symptom.
Please let me know if there's anything I can do to help!
Reacted by Fabián Heredia Montiel and Daniel Aristizabal
I'm not sure why that would be -- any chance you've been able to build from source? Sorry, I wish I knew how to debug more extensively but I'm not even sure where to start. Debian is usually great about logging errors, so since you've checked in the usual spots I'm not sure where else to look other than having you fire up gdb or something silly.
same problem with git checkout v3.10.0 (but remember that app image of v3.10.0 works!)
git checkout v3.9.0 works! This line is also appearing in v3.10.0 AppImage (not in my source build) ATTENTION: option value of option force_s3tc_enable ignored..
@cronopio I don't get the nvm part. I don't know how to change my electron version (seems that is bundled in AppImage). Is this going to clear the issue.
What is unacceptable (italic confirmed) is that is not working in a vanilla debian stable that is a very common distribution for linux users, right?
@pedro-nonfree Could you try downloading Electron and verifying that it runs fine for you locally? Your console output shows that the SSB-specific code seems to be running fine, but it looks like Electron just isn't opening. Here are my steps:
Thanks for the screenshot! Here's what it should look like:
I have my own Electron woes (electron/electron#12820) so I know how frustrating they can be, but I'll admit I'm unsure how to debug this. You can use that Electron binary on Patchwork with ./electron /path/to/patchwork-source/index.js to see if it works, but my intuition is that the best case scenario is another black screen.
Hey, any chance ./electron --disable-gpu has a different result? If not, I'd also be curious whether Chromium works on your system.
but gets too much time like this, is it normal? it was because of a first start. Everything is fine!
extra note: my graphic card should be really compatible, is an intel ! No problems with any other application (including chromium, if you want me to test a specific WebGL or something I'm fine with it. But looks the problem is very related exclusively to electron )
Nice! I'm happy to see that Patchwork is opening correctly.
You can run npm start -- --disable-gpu to pass it to Electron, or you can edit package.json to hardcode the command in scripts.start. That "scuttling" message really means "reindexing database" and should only take a few minutes, but you can check the progress manually: while that runs, you canopen another terminal, navigate to the same directory, and run npx sbot progress. It should show something like this:
When indexes.current reaches index.target it should stop scuttling. I like to use watch npx sbot progress when I'm feeling paranoid. If it says anything like "couldn't connect to sbot" you can just close Patchwork and restart it. Hopefully you won't need to do that, but every once in a while it's nice to know the workaround.
Totally agree about the graphics driver. Electron should have the same GPU support as the underlying Chromium, but I've had trouble with their graphics support too. It's very frustrating, but I'm glad we found a workaround!
I'd recommend opening an issue with Electron, since that's where the bug is, but if you open a pull request with your change we can close this issue and discuss the workaround in your PR.
My only concern is that disabling GPU acceleration for everyone seems a bit overkill when only you and I are the only people who have this issue, but maybe the compatibility is worth it? I'm not sure, but it's worth discussing.
Wow, great solution! I never would've thought of that. My personal preference would be to wait for the bug to be fixed upstream, but you're welcome to open a PR if you think this should be merged into master.
changed the title [-]3.10.1 and 3.11 (AppImage) not working[/-][+]upgrade to electron v3 to fix crash with some linux GPU configurations[/+]on Nov 28, 2018
Activity
fabianhjr commentedon Aug 15, 2018
Antergos (Arch) 4.17.14-arch1-1-ARCH #1 SMP PREEMPT will SIGSEGV
cronopio commentedon Aug 16, 2018
Some days ago everything worked smooth. Now trying to run it with
npm startjust exit silently, I removednode_modulesand rannpm installwith no change.So I downloaded the AppImage and when execute I got:
Archlinux 4.17.14-arch1-1-ARCH
christianbundy commentedon Aug 21, 2018
@pedro-nonfree
Can you give some more info on what's going on? I'm not sure how to troubleshoot, but your output looks correct.
@fabianhjr @cronopio
Arch has been having a ton of issues with Electron as a Node module, so I've been using the system Electron instead. Could you try that for now? There are two packages on the AUR for the normal release and for staying up-to-date with
masteron GitHub:If you're building from source, you'll need to
pacman -S electronandrm -rf node_modules/electronso that you're using the system Electron rather than the Node module. You should be able to follow the issue as electron/electron#13972, which is causing Patchwork issues as a symptom.Please let me know if there's anything I can do to help!
pedro-nonfree commentedon Aug 21, 2018
@christianbundy that's all output I get trying to run AppImage. There are no logs in /var/log/daemon.log and/or /var/log/syslog
christianbundy commentedon Aug 21, 2018
Thanks @pedro-nonfree!
I'm not sure why that would be -- any chance you've been able to build from source? Sorry, I wish I knew how to debug more extensively but I'm not even sure where to start. Debian is usually great about logging errors, so since you've checked in the usual spots I'm not sure where else to look other than having you fire up
gdbor something silly.pedro-nonfree commentedon Aug 22, 2018
built from source
and:
same problem with
git checkout v3.10.0(but remember that app image of v3.10.0 works!)git checkout v3.9.0works! This line is also appearing in v3.10.0 AppImage (not in my source build)ATTENTION: option value of option force_s3tc_enable ignored..what seems clear is that is missing a more verbose output of what's happening, something is failing silently
cronopio commentedon Aug 23, 2018
@christianbundy Thanks man! I'll try using electron from system and let you know.
UPDATE: I had to remove
nvmand installed the AUR package that require to install arch'snodejsandnpmand is working now. Thanks!I guess then that the main problem with @pedro-nonfree needs a different version of electron
[-]3.10.1 (AppImage) not working[/-][+]3.10.1 and 3.11 (AppImage) not working[/+]pedro-nonfree commentedon Oct 3, 2018
@cronopio I don't get the
nvmpart. I don't know how to change my electron version (seems that is bundled in AppImage). Is this going to clear the issue.What is unacceptable (italic confirmed) is that is not working in a vanilla debian stable that is a very common distribution for linux users, right?
christianbundy commentedon Oct 3, 2018
@pedro-nonfree Could you try downloading Electron and verifying that it runs fine for you locally? Your console output shows that the SSB-specific code seems to be running fine, but it looks like Electron just isn't opening. Here are my steps:
electronbinary by double-clicking or from the CLIIt may also be worth testing Electron 2.0.3 (or previous), as I believe that were used when 3.10.1 was published. Hope this helps!
pedro-nonfree commentedon Oct 3, 2018
@christianbundy
Thanks for the detailed steps, I feel something is missing
(I already moved to the latest stable version as I detailed here)
Then, I did:
it did not work, same problem
christianbundy commentedon Oct 3, 2018
Sorry for the confusion, I'm only asking you to verify that Electron works on your system. For me, that looks like:
wget https://github.com/electron/electron/releases/download/v2.0.10/electron-v2.0.10-linux-x64.zip unzip -d . electron-v2.0.10-linux-x64.zip ./electronThis should produce two outputs:
My goal is to rule out an upstream Electron problem as the source of your issue.
pedro-nonfree commentedon Oct 3, 2018
Aha.
It opens a window, but without any content on it
christianbundy commentedon Oct 3, 2018
Thanks for the screenshot! Here's what it should look like:
I have my own Electron woes (electron/electron#12820) so I know how frustrating they can be, but I'll admit I'm unsure how to debug this. You can use that Electron binary on Patchwork with
./electron /path/to/patchwork-source/index.jsto see if it works, but my intuition is that the best case scenario is another black screen.Hey, any chance
./electron --disable-gpuhas a different result? If not, I'd also be curious whether Chromium works on your system.pedro-nonfree commentedon Oct 3, 2018
No! Thanks to you for your amazing follow up!
Disabling gpu works!
now patchwork shows something!!
would be nice to pass
--disable-gpuargument to patchwork that forwards it to electron, no?but gets too much time like this, is it normal?it was because of a first start. Everything is fine!extra note: my graphic card should be really compatible, is an intel ! No problems with any other application (including chromium, if you want me to test a specific WebGL or something I'm fine with it. But looks the problem is very related exclusively to electron )
pedro-nonfree commentedon Oct 3, 2018
editor /path/to/patchwork-source/package.json
then
npm startworksthese seems would have a very reasonable bugfix
christianbundy commentedon Oct 3, 2018
Nice! I'm happy to see that Patchwork is opening correctly.
You can run
npm start -- --disable-gputo pass it to Electron, or you can editpackage.jsonto hardcode the command inscripts.start. That "scuttling" message really means "reindexing database" and should only take a few minutes, but you can check the progress manually: while that runs, you canopen another terminal, navigate to the same directory, and runnpx sbot progress. It should show something like this:When
indexes.currentreachesindex.targetit should stop scuttling. I like to usewatch npx sbot progresswhen I'm feeling paranoid. If it says anything like "couldn't connect to sbot" you can just close Patchwork and restart it. Hopefully you won't need to do that, but every once in a while it's nice to know the workaround.Totally agree about the graphics driver. Electron should have the same GPU support as the underlying Chromium, but I've had trouble with their graphics support too. It's very frustrating, but I'm glad we found a workaround!
pedro-nonfree commentedon Oct 3, 2018
Yay! Thanks!!
What about adding this argument to AppImage? :]
christianbundy commentedon Oct 3, 2018
I'd recommend opening an issue with Electron, since that's where the bug is, but if you open a pull request with your change we can close this issue and discuss the workaround in your PR.
My only concern is that disabling GPU acceleration for everyone seems a bit overkill when only you and I are the only people who have this issue, but maybe the compatibility is worth it? I'm not sure, but it's worth discussing.
pedro-nonfree commentedon Nov 6, 2018
@christianbundy hey!
That works to (without the need to disable gpu):
editor /path/to/patchwork-source/package.json
would be that a good default thing to improve compatibility?
thanks to electron/electron#14954 (comment)
here seems there is the appropriate bugfix work in progress electron/electron#15555
christianbundy commentedon Nov 6, 2018
@pedro-nonfree
Wow, great solution! I never would've thought of that. My personal preference would be to wait for the bug to be fixed upstream, but you're welcome to open a PR if you think this should be merged into master.
mmckegg commentedon Nov 28, 2018
Looks like this has been fixed in the latest version of electron
3.x, but unfortunately due to some dependency issues, we can't yet upgrade past2.x.We need to get prebuilds of all of the dependencies for the latest abi (64).
[-]3.10.1 and 3.11 (AppImage) not working[/-][+]upgrade to electron v3 to fix crash with some linux GPU configurations[/+]christianbundy commentedon Apr 26, 2019
Upgraded to Electron 4 (see #964)! 🎉