Closed Token00 closed 3 years ago
Added some infos here stracktrace sent to developer...
https://www.reddit.com/r/Electrum/comments/i6j3nr/macos_big_sur_wont_start/
Is there any work in progress with this issues?
Also encountering this issue. Please let me know if I can be of assistance in providing any logs etc.
I suspect this is most likely due to problems upstream, with PyInstaller, or maybe even Python itself.
For the time being, consider running from source.
I paste a log from the console, maybe it will help:
I suspect this is most likely due to problems upstream, with PyInstaller, or maybe even Python itself.
For the time being, consider running from source.
Happy to report that building from source alleviates the issue.
probably related: https://github.com/pyinstaller/pyinstaller/issues/5107
EDIT: actually this is only about building on macOS 11
I suspect this is most likely due to problems upstream, with PyInstaller, or maybe even Python itself. For the time being, consider running from source.
Happy to report that building from source alleviates the issue.
did not work for me. Did you only run ./make_osx
?
@SimonHausdorf I think they meant "running" from source, instead of bulding/creating a binary. See the README, though the instructions there need to be adapted a bit for MacOS.
Happy to report that building from source alleviates the issue.
sorry could you explain the process ? thanks!!
Happy to report that building from source alleviates the issue.
sorry could you explain the process ? thanks!!
git clone https://github.com/spesmilo/electrum.git cd electrum brew install automake libtool pyqt pip3 install cryptography ./contrib/make_libsecp256k1.sh pip3 install --user -e . ./run_electrum
denis2342
reported on IRC that it is only the GUI that does not open; many things actually seem to properly start (see logs).
Based on this, I now think it might not be a pyinstaller issue - either of Qt/PyQt/pyinstaller might be the cause.
related https://tickets.metabrainz.org/browse/PICARD-1950
builds with any PyQt version >= 5.13.2 (with the latest version tested being current 5.15.1) do not run on macOS 11 Big Sur.
On macOS Big Sur the application stops responding after start without showing the UI. Actually even a very minimalistic Qt5 app with only an empty window will stop responding as soon as the app's mainloop gets executed. The exact reason is unknown, but it happens with PyQt >= 5.13.2 (tested up to 5.15.1).
This actually only happens when running from the packaged app. Running from Picard from source works fine. For now I can't say whether the core problem lies within PyQt5 or PyInstaller.
This is what the PyQt lead maintainer says: https://www.riverbankcomputing.com/pipermail/pyqt/2020-September/043131.html
Could you tell me how to settle the problem? When will PyQt5 support macOS 11.0?
Not before it is released. Not before it is supported by Python. Not before it is supported by Qt.
I gather macOS 11 got released today. I was hoping this would get fixed in pyinstaller/qt/pyqt.
Alas, we shall try to have a workaround.
We can try to build with PyQt 5.13.1 as Picard does.
@cculianu assuming this affects Electron Cash too, I'm just curious if maybe you have looked into it (?)
I've built a test release for ElectrumSV with PyQt5 pinned to 5.13.1 and had a Bug Sur user who already experienced the 5.15 lock ups try it and they reported it works fine.
4.0.2 was the one that still did the onefile thing and unarchived itself into a temp dir right? I suspect macOS hates that now since it "looks" a lot like a rootkit. EDIT: Yeah I see reports that 4.0.4 doesn't work for people either. Jesus.
4.0.4 has the proper .app? @rt121212121 is electrumsv a .app with real files in it or is it sort of a glorified "onefile"?
Anyway I'll try it.
@SomberNight: No, I haven't looked into it but I'll install Big Sur in a VM and check it out and let you know.
Rant: Jesus Christ every darned release Apple breaks something or makes developer life hell. They keep locking down their platform with more restrictions. They are trying to turn (what was) a perfectly decent desktop OS into a glorified iPad. :(
I''l look into it. Thanks for the heads-up.
"Big Sur" .. more like "Bugs, Sir!", amirite?
"Big Sur"prise -- your stuff stopped working.
I don't know exactly what PyInstaller does on MacOS to make it work, but it is the dmg file that is produced. You should be familiar with it, since it's what Electron Cash and Electrum were doing when we forked. MacOS treats it as second class because it is not signed, but otherwise beyond the Big Sur issue, it seems like it works based on very limited testing. I expect the earlier version of PyQt5 will be sufficient to give Big Sur users a working build.
It's hard to get away from PyInstaller given how much it reduces the build sizes.
Option B here fixed the issue for me:
https://github.com/biolab/orange3/issues/4878#issuecomment-659443190
I've reproduced the hang on a VM. Indeed bundling older PyQt, namely 5.13.1, fixes it. Done in https://github.com/spesmilo/electrum/commit/77f75f102b14cebe315df63c2343e48999d6692e. The next release of Electrum should hence work properly.
I'll close this issue as we have a workaround, however the root cause is still unknown.
@sod1684 what command did you run exactly?
so when is the next release?
What's the workaround?
we have released Electrum 4.0.5 now, with the workaround of using old PyQt5
FYI -- a workaround that seems to work also is to set the env var:QT_MAC_WANTS_LAYER=1
(which can be done before the QApplication
is created).
See: https://bugreports.qt.io/browse/QTBUG-87014 And: https://stackoverflow.com/questions/64818879/is-there-any-solution-regarding-to-pyqt-library-doesnt-work-in-mac-os-big-sur
@cculianu Oh nice. One of the comments on stackoverflow also says
PyQt5 5.15.2 was released on Nov 24 and it supposedly integrates this fix
we should instead consider bumping to that then
Oh nice. Note I was unable to reproduce this issue at all in a Big Sur VM with PyQt 5.14.2 or 5.15.1 -- I presume it may only happen sometimes depending on graphics driver or something (I'm using VMWare Fusion).
Do let me know if you can if that works!
@cculianu I confirm that 5.15.2 seems to be working on my Big Sur VM (virtualbox) (and I was able to reproduce the hang on other versions on this same VM in the past).
Thanks @SomberNight -- I still couldn't reproduce it but knowing it works regardless on 5.15.2 is good to know, thanks for the follow-up.
Tried running Electrum 4.0.2 on MacOS Big Sur Beta 3 today.
If you start it, it's in the dock but no window opens. Right-click on the dock icon reveals "Application not responding". It's also permanently at 100% CPU in Activity Monitor. But even after an hour of waiting nothing happens.