raidionics / Raidionics

Software for automatic segmentation and generation of standardized clinical reports of brain tumors from MRI volumes

Home Page:https://raidionics.github.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bug: Launching latest artifact fails on macOS

andreped opened this issue · comments

Describe the bug
Tried to download the latest artifact, install it, and run. The icon popped up but closed immediantly.

Computer settings (please complete the following information):

  • Operating System : [e.g., Windows 10] macOS 12 Monterey
  • Processor (CPU) type: [e.g., Intel i5] Intel Core i7

To Reproduce
Install the latest artifact, and go to /Applications/Raidionics.app/Contents/MacOS/ and then launch with ./Raidionics.

Error messages

andreped@thomasl-MBP /Applications % cd Raidionics.app/
andreped@thomasl-MBP /Applications % open -a Raidionics.app 
andreped@thomasl-MBP /Applications % cd Raidionics.app/Contents/MacOS 
andreped@thomasl-MBP MacOS % ./Raidionics 
Traceback (most recent call last):
  File "main.py", line 8, in <module>
ImportError: could not import module 'PySide6.QtGui'
[14837] Failed to execute script 'main' due to unhandled exception!

Tried using a newer PyInstaller version (v5.13.2) did not resolve the issue.

@dbouget Could you test the latest artifact on Windows. Apparently, this was also an issue with PySide6 on windows:
https://bugreports.qt.io/browse/PYSIDE-1891

Not sure if it has been resolved.

Could also be an issue with this specific release. Upgrading to the latest PySide6 (v6.5.2), still compatible with Python 3.7, might resolve the issue: https://pypi.org/project/PySide6/

This seems like a bug with PySide6 (not PyInstaller):
https://stackoverflow.com/questions/71919812/after-upgrading-pyside6-gives-error-no-module-named-pyside6-qtwidgets

I can try building with latest to see if it resolves the issue.

Just managed to reproduce the issue on macOS.

I got the same issue after simply making the virtualenv + installing deps and running main.py. So this is not a PyInstaller issue, but rather a PySide6 bug, as I thought! Will try to upgrade PySide6 to see if it resolves the issue.

I tried to simply upgrade the PySide6 version, but this did not resolve the issue. These were the versions installed:

PySide6-6.5.2 PySide6-Addons-6.5.2 PySide6-Essentials-6.5.2 shiboken6-6.5.2

Or maybe it did, because now I get this error:

from PySide6.QtWidgets import QApplication

As suggested in this thread, I managed to resolve the issue by simply reinstalling PySide6 after install.

Will make a PR.

In the future, this bug will likely be resolved, but for now, we will need this workaround.