Error with Python command

robertavarela
robertavarela New Altair Community Member
edited October 2020 in Community Q&A

Hello,

 

When I load the Python command window in v2019.2 of Compose, I get the following error when typing help('modules'):

image.png.26f47a54ae1b746ada7077273b494250.png

Although this error pops up, I am able to see the installed modules when I hit OK. But why is this error happening? How to avoid it?

 

Thanks,

 

Roberta

Tagged:

Answers

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited July 2019

    Syntax errors, also known as parsing errors, are perhaps the most common kind of complaint you get while you are still learning Python:

     

    >>> while True print('Hello world')

    File '<stdin>', line 1

    while True print('Hello world')

                     ^

    SyntaxError: invalid syntax

     

     

    The parser repeats the offending line and displays a little ‘arrow’ pointing at the earliest point in the line where the error was detected. The error is caused by (or at least detected at) the token preceding the arrow: in the example, the error is detected at the function <span>print()</span>, since a colon (<span>':'</span>) is missing before it. File name and line number are printed so you know where to look in case the input came from a script.

    thanks

  • robertavarela
    robertavarela New Altair Community Member
    edited July 2019

    The error message does not have any ^ operator pointing to the exact position where the command fails. It seems like some kind of installation issue, since I didn't even spontaneously call this function, but I'd like help to understand what exactly it is.

     

    On top of that, the line 575 that the error mentions in file default.cfg does not it even exist, because this file only has 431 lines:

    <?xml version="1.0" encoding="UTF-8"?>image.thumb.png.a5bf478ec47f40279e5075dc539d6a7d.png

     

    Regards,

     

    Roberta

  • Anetlam
    Anetlam Altair Community Member
    edited August 2019

    Solved : you have to start cluster channels in order to issue this command

    Quite weird, but true

    Maybe there is something wrong with my installation ...