Join our discord community

Please or Register to create posts and topics.

PySide and PySide2 problems on Linux

Hi Richard, I'm here again

Last week I had some problems using Prism on Linux with Blender due to some PySide2 problems. Today I had more problems, this time with the Installation itself

I've annexed a screenshot with the errors I'm having trying to install it on my machine. Sometimes the install script try to use PySide2 modules, sometimes it calls PySide, but even with all the libs encapsulated in the scripts folder, it can't proceed

I've tested it in multiple Python environments, one with 3.9 version, another with 3.7, and even in another Linux machine, with a different distro in distinct Python versions too

PySide2 is working fine in my machine, regarding the Python environment used. I did several tests here, with other Qt applications, and everything seems to work fine

Dunno what to do tbh

In the ss: Green arrows shows PySide calls, and red ones PySide2 calls

Uploaded files:
  • You need to login to have access to uploads.

Prism tries to load PySide2 first and if that fails it will try to load PySide. That's why you see both versions in the terminal.

It might be that PySide2 can't be loaded because the version included in Prism conflicts with your Python version or your PySide2 version.

Try to delete this folder in your Prism installation: \PythonLibs\Python37\PySide and also \PythonLibs\Python27\PySide and try again to run the installer script.

Deleted these folders. Slightly different errors, but still related to PySide and PySide2

Uploaded files:
  • You need to login to have access to uploads.

There must be any problem with your environment so that the script doesn't find the location of your system PySide2. The PrismInstaller.py is called from here: https://github.com/RichardFrangenberg/Prism/blob/a620c875fc9e11b06415a00dff65a880e7959a26/Prism/Linux_Setup_Integrations.sh#L6

Maybe the "python" command is calling a wrong python version on your system?

If you can import PySide2 from a new python shell in your terminal then you can step by step replicate the process how the PrismInstaller.py is called (e.g. running it as sudo, importing Pyside2 from a file on disk, running it from a .sh file...) and see at which point it breaks.

You can also modify the PrismInstaller.py and print the sys.path to see which paths are in there. Maybe that gives any hint why it's not finding PySide2

Cheers,

Richard

Not sure if it has anything to do with it, but I was having a very similar problem with a fresh install of PopOS and after a lot of trials and errors I made it work by simply running in the terminal:

pip install PySide2

And then deleting the "PySide" folder in "Prism/PythonLibs/Python37"

 

 

Hello there I am running into a similar problem during the installation on Ubuntu 20.04 LTS

 

Traceback (most recent call last):
File "Scripts/PrismInstaller.py", line 83, in <module>
import PrismInstaller_ui
File "Scripts/UserInterfacesPrism/PrismInstaller_ui.py", line 10, in <module>
from PySide import QtCore, QtGui
ImportError: No module named PySide
Traceback (most recent call last):
File "Scripts/PrismCore.py", line 101, in <module>
from PySide.QtCore import *
ImportError: No module named PySide.QtCore

I installed Pyside2 and I removed the the folders mentioned above and still same error,

 

 

Hi, I know this thread is old but I had the same Problems.

For me the error was solved by not only installing pyside2 as user but also using "sudo pip install PySide2"

I dont know if you also have to install it as user. Try "sudo pip install PySide2" first and then pip install PySide2 if you need to.

Hi, I have spent a couple of hours trying to get this installed but I have arrived at a roadblock.

First, I had to avoid the problem with detecting the wrong version of Python, that causes the PySide(2) import errors. After what felt like days of trial and error, I found that "sudo apt-get install python-is-python3" would make the installer happier.

I also had to replace the files inside the Qt5 libraries and also the plugins "imageformats", "platforms" and "platformthemes" with updated versions from my local Qt5 install, as the supplied ones were causing errors.

The default "imageformats" folder does not contain all the .so libraries that Prism has, so I had to download a debian package with the rest:
https://packages.debian.org/sid/amd64/qt5-image-formats-plugins/download

Now the installer OPENS, which feels like a small victory, and asks to be launched with root permissions. When I do that, I get the error that stops me from installing (image attached)

Uploaded files:
  • You need to login to have access to uploads.