Welcome, Guest
Username: Password: Remember me

TOPIC: Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8

Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8 3 years 6 months ago #38439

  • theogd
  • theogd's Avatar
Hi everyone,

I've just installed the V8P2R0 version of telemac. I also had to install python 3.8 because I was running older versions of telemac with python 2.7. I would like to keep older versions so I didn't change the PATH for python and I have to use the commande 'py -3.8 telemac2d.py file.cas' to run the compilation.

I tried running several exemple cases, it is compilling but when arriving at 'Running your simulation" it stops with the error UnicodDecodeError: 'utf-8' codec can't decode byte 0xe8 in position 97: invalide continuation type.

I don't know if this is linked to the telemac version or the fact that I have several versions of python.

Hopefully python 2.7 is still working with the V8P1R0.

Thanks in advance !
Attachments:
The administrator has disabled public write access.

Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8 3 years 6 months ago #38446

  • PMV
  • PMV's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 149
  • Thank you received: 42
Hi,

You can create a seperate shortcut to a command window and set the PATH to python 3. Are you able to run scalar exemples? Maybe it's a MPI issue.

Hope that helps,
Patrick
The administrator has disabled public write access.

Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8 3 years 6 months ago #38447

  • theogd
  • theogd's Avatar
Thank you for your quick answer
I tried both scalar and parallel exemples with the same issue.
If I set the path to python 3 in a command window isn't it going to set it for the whole system ?
I'm currently trying to creat a virtual environnement for python 3 but with some issues with python modules.
The administrator has disabled public write access.

Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8 3 years 6 months ago #38448

  • PMV
  • PMV's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 149
  • Thank you received: 42
Create a shortcut on your desktop and right click to set the properties (target and start location). These will be for that session only.
The administrator has disabled public write access.

Python error while changing from V8P1RO with py2.7 to V8P2R0 py3.8 3 years 6 months ago #38450

  • theogd
  • theogd's Avatar
So I did it, and when I type 'python --version' I got the 3.8 only for the session but when I try to compile it looks like he doesn't compile with the 3.8 because I get the error 'from urllib.request import urlopen ImportError: No module named request' wich is a module existing in python 3.8 but not in 2.7.

I tried changing the path to python for the whole system, don't change anything, exept the fact that 'python --version' tells me the version I wrote in the path.

It is not even compiling that way, in the contrary to the commande 'py -3.8 telemac2d.py file.cas'
The administrator has disabled public write access.
Moderators: borisb

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.