Error with PyQt5

All questions about installation
Forum rules
Please read the forum usage recommendations before posting.
marvin
Posts: 4
Joined: Wed Jul 01, 2020 5:04 pm

Error with PyQt5

Post by marvin »

Hello,

I am currently trying to install code-saturne 6.0.4 with the automated install but I am facing to an issue.

- code-saturne : 6.0.4
- Kubuntu 20.04 LTS
- Log file attached

When I start install_saturne.py, I get the message below :

Code: Select all

configure: error: cannot find PyQt5 support (>= 5.0) or PyQt4 support (>= 4.5), Graphical User Interface cannot be installed
I tried to install PyQt5 and PyQt4 with apt-get but the issue still present.

Thank you in advance.

BR
Attachments
install_saturne.log
(9.07 KiB) Downloaded 195 times
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error with PyQt5

Post by Yvan Fournier »

Hello,

You might also need PyQt5 dev tools. We recently posted a list of packages which you may need for various distributions on the wiki, so you might want to check that: https://github.com/code-saturne/code_sa ... n-packages.

Best regards,

Yvan
marvin
Posts: 4
Joined: Wed Jul 01, 2020 5:04 pm

Re: Error with PyQt5

Post by marvin »

Merci Yvan.

I already installed the required packages indicated in your link but no luck...
I installed too PyQt5 from source but that was not better.

Best regards,
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error with PyQt5

Post by Yvan Fournier »

Hello,

If you run Python in a terminal and type "import PyQt5" do you have an error ?

Do you have environment modules ore a secondary packaging system such as Conda which might interfere ? What does the config.log file contain ? Also, if using the automatic installer, be careful to set PYTHON=python3 (instead of python) if that is the version PyQt5 is installed with.

Best regards,

Yvan
marvin
Posts: 4
Joined: Wed Jul 01, 2020 5:04 pm

Re: Error with PyQt5

Post by marvin »

Hi,

Thanks, PYTHON=python3 was the solution. The installation completed well.
I am facing to a new issue when I try to start code-saturne. Please see the message below :

Code: Select all

bash: /home/jy/Code_Saturne/6.0.4/code_saturne-6.0.4/arch/Linux_x86_64/bin/code_saturne: python3: bad interpreter: No such file or directory
If you have any idea what could be the reason of this failure?

Thank you in advance.

Best regards,
marvin
Posts: 4
Joined: Wed Jul 01, 2020 5:04 pm

Re: Error with PyQt5

Post by marvin »

Ok, I finally found the solution.
I modified the shebang from :

Code: Select all

#!python3
to

Code: Select all

#!/usr/bin/python3
Thanks again for your help !
bmehra
Posts: 4
Joined: Thu Oct 01, 2020 3:07 pm

Re: Error with PyQt5

Post by bmehra »

marvin wrote: Thu Jul 02, 2020 9:51 pm Hi,

Thanks, PYTHON=python3 was the solution. The installation completed well.
I am facing to a new issue when I try to start code-saturne. Please see the message below :

Code: Select all

bash: /home/jy/Code_Saturne/6.0.4/code_saturne-6.0.4/arch/Linux_x86_64/bin/code_saturne: python3: bad interpreter: No such file or directory
If you have any idea what could be the reason of this failure?

Thank you in advance.

Best regards,
Hii Marvin, I aam facing the same issues. Can you please let me know where do you set PYTHON=python3 ?, i did not get completely. Thanks for your help. Regards Bineet
bmehra
Posts: 4
Joined: Thu Oct 01, 2020 3:07 pm

Re: Error with PyQt5

Post by bmehra »

in the bashrc you meant ?
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error with PyQt5

Post by Yvan Fournier »

Hello,

No, code_saturne stores the PYTHON value given at "configure" (before make && make install) time, so whatever is in .bashrc will not change anything.

If necessary, force "PYTHON=/usr/bin/python3" at the end of the "configure" options, or for an existing install, edit the <install-prefix>/bin/code_saturne script (but if you reinstall, it will be overwritten, so doing this at "configure" time is slower but cleaner.

Best regards,

Yvan
bmehra
Posts: 4
Joined: Thu Oct 01, 2020 3:07 pm

Re: Error with PyQt5

Post by bmehra »

Thank you Yvan

python3 folder and its packages are stored in /usr/lib/ in my case and not in /usr/bin/. I have provided the correct path in setup file, ran the install_saturne.py however got the error
configure: error: Python interpreter is too old even though the version is 3.8.2

Also i am doing all this using windows subsystem for linux in windows10


Thanks for you help

Regards

Bineet
Post Reply