Ryven icon indicating copy to clipboard operation
Ryven copied to clipboard

Unable to Run M1 Apple Laptop

Open gsilvers opened this issue 4 years ago • 8 comments

Hello,

I have a new Mac M1 laptop. I've cloned the repo and pip installed the requirements but when executing Ryven.py I get the following:

========================================================================================== ;python3 Ryven.py (base) objc[21131]: Class RunLoopModeTracker is implemented in both /opt/anaconda3/lib/python3.8/site-packages/PySide2/Qt/lib/QtCore.framework/Versions/5/QtCore (0x15951b288) and /opt/anaconda3/lib/libQt5Core.5.9.7.dylib (0x163b48a80). One of the two will be used. Which one is undefined. QObject::moveToThread: Current thread (0x7fea9767a1c0) is not the object's thread (0x7fea9744de10). Cannot move to target thread (0x7fea9767a1c0)

You might be loading two sets of Qt binaries into the same process. Check that all plugins are compiled against the right Qt binaries. Export DYLD_PRINT_LIBRARIES=1 and check that only one set of binaries are being loaded. qt.qpa.plugin: Could not load the Qt platform plugin "cocoa" in "" even though it was found. This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: cocoa, minimal, offscreen.

fish: 'python3 Ryven.py' terminated by signal SIGABRT (Abort)

==========================================================================================

I've read issues for other projects that the version of cv was bad, I tried opencv-python==4.2.0.32 to no avail. I do have QT installed assuming this may be some sort of issue specific to the new M1 Macs?

Reproduction CD /Ryven python3 Ryven.py

System, version

  • OS: macOS
  • Version 11.2.1

gsilvers avatar Feb 25 '21 23:02 gsilvers

I am having the same issues on my M1 as well. I've tried the usual opencv uninstall, but with no luck. Did you find a solution?

dmsmiley avatar Mar 30 '21 17:03 dmsmiley

I don't have access to an M1 machine rn unfortunately. Ryven does not move any objects between threads, and the application doesn't use OpenCV, so this seems to be a PySide internal thing. While I couldn't find a bugreport describing the same errors, there have been issues reported with Big Sur recently. Maybe this might help.

leon-thomm avatar Mar 31 '21 06:03 leon-thomm

Yeah, this is no bueno. I downgraded to PySide 5.13, which fixes this issue, but now I'm getting the TypeError:'Shiboken.ObjectType' object is not iterable, which can only be solved by upgrading to PySide 5.14, which gives me the original problem. C'est la vie.

dmsmiley avatar Mar 31 '21 19:03 dmsmiley

I created a new conda x86 env with Python 3.8.8 and only installed the requirements on my M1 MacBook Air. This at least fixed the shown error, although afterwards Ryven stopped loading and got stuck on an empty white window. Also no error message in the console.

malteschade avatar May 18 '21 20:05 malteschade

Same issues , fix it by using :

 export QT_MAC_WANTS_LAYER=1

https://github.com/leon-thomm/Ryven/issues/40#issuecomment-799384371

V1ki avatar Jun 11 '21 07:06 V1ki

export QT_MAC_WANTS_LAYER=1

I tried this command but the same error happend.

Is it neccessary to install qt5 seperatly?

winglight avatar Aug 01 '21 03:08 winglight

I'm having similar difficulties on an Intel Mac:

(base) williamadams@MacBook-Pro ~ % ryven objc[82758]: Class RunLoopModeTracker is implemented in both /Users/williamadams/opt/anaconda3/lib/python3.8/site-packages/PySide2/Qt/lib/QtCore.framework/Versions/5/QtCore (0x11e54d288) and /Users/williamadams/opt/anaconda3/lib/libQt5Core.5.9.7.dylib (0x1279dca80). One of the two will be used. Which one is undefined. QObject::moveToThread: Current thread (0x7f96912a6c60) is not the object's thread (0x7f9691122650). Cannot move to target thread (0x7f96912a6c60)

You might be loading two sets of Qt binaries into the same process. Check that all plugins are compiled against the right Qt binaries. Export DYLD_PRINT_LIBRARIES=1 and check that only one set of binaries are being loaded. qt.qpa.plugin: Could not load the Qt platform plugin "cocoa" in "" even though it was found. This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: cocoa, minimal, offscreen.

WillAdams avatar Jan 31 '22 14:01 WillAdams

@WillAdams I'm having the same issue

tristanryerparke avatar Aug 27 '22 20:08 tristanryerparke