Welcome, Guest
Username: Password: Remember me

TOPIC: SyntaxError: Missing paretheses in call to 'print'.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44528

  • Laurie
  • Laurie's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 97
  • Thank you received: 5
Hieveryone,

I'm taking back an old V7P1 model.
It worked very well a few weeks ago.
In the meantime I have installed the V8P4. Since then, all my old versions of TELEMAC have crashed with this error message:
SyntaxError: Missing paretheses in call to 'print'. Did you mean print(' +> simulation en Francais')?

My CAS is written in French.
The model runs on another machine on which I have not installed V8P4.

My understanding is that it comes from using Python3 instead of Python2.7. But if that's the case, I don't know how to check or correct it?
And above all, without causing problems for Python V8P4 :blink:

Nice !

The Target identified in the shorcut use to open the cmd windows :
C:\Windows\SysWOW64\cmd.exe /E:ON /V:ON /K "C:\TELEMAC\V7P1.bat"


The BAT use to V7P1 :
echo off
set VTEL=V7P1
set SYSTELCFG=C:\TELEMAC\%VTEL%\configs
set PATH=%PATH%;c:\telemac\%vtel%\scripts\python27
set PATH=%PATH%;c:\telemac\mpi\bin
set PATH=%PATH%;c:\telemac\outils\matrub\bin
set PATH=%PATH%;c:\telemac\outils
set PATH=%PATH%;c:\python27
set PATH=C:\TELEMAC\TDM-GCC-64\bin;%PATH%
set PROMPT=V7P1_$P$G
echo on



Hoping you could help me,

Thanks,

Laurie
The administrator has disabled public write access.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44546

  • Renault
  • Renault's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 120
  • Thank you received: 33
Hi Laurie,

Your suspicions are correct, this seems like a Python 2 vs Python 3 error.

What files are contained in this project folder that end in .py? Would it be possible for you to uninstall v7p1 and Python 2.7 from your system?

André Renault
The administrator has disabled public write access.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44548

  • Laurie
  • Laurie's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 97
  • Thank you received: 5
Hi André,

Why uninstall v7p1 and Python 2.7 from my system ?
I have to use this version. And I have no *.exe install file to install the V7P1 if I firstly uninstall it.

If I can't use V8P4 AND V7P1 on my computer, I just will use an other computer for the V7P1 :)
The administrator has disabled public write access.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44550

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi
You have a python conflict on your computer...
Sounds that installing v8p4 leads to a kind of priority of python 3 which create the problem with v7p1 which requires python2.
If you plan to manage both version on your computer, you probably have to manage a python switch also to ensure python 2 will be use for v7p1

Regards
Christophe
The administrator has disabled public write access.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44551

  • Laurie
  • Laurie's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 97
  • Thank you received: 5
Thanks for your answer.

Have you an example about how to manage/script the switch version ? If not, I'll find by myself.

Kind regards,
The administrator has disabled public write access.

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44553

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
No exemple as this will be specific to your computer... and also because python could be use by other programs...
Christophe
The administrator has disabled public write access.
The following user(s) said Thank You: Laurie

SyntaxError: Missing paretheses in call to 'print'. 7 months 1 week ago #44555

  • Laurie
  • Laurie's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 97
  • Thank you received: 5
Ok. Thanks :)
The administrator has disabled public write access.
Moderators: pham

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