OpenMV IDE always crashing

Hello, I don’t understand why OpenMV IDE always crashes while editing a script.
I’m using Windows 10 or Windows Seven.

Hi, this is a bug we’ve noticed when inputting keyword arguments.

It should have been fixed with v 1.5.1 but still survived somehow.

It will be fixed… again… With the next IDE release. Until then, I can tell you how disable keyword arguments highlighting.

Go to the IDE install dir, share/QtCreator/generic-highlighter/python.xml file.

Comment out line this line.

This will disable argument highlighting which causes an infinite loop.

I fixed this script previously to stop the infinite loop from happening but something else is going on that I have to debug.

Hi kwagyeman, thank you for that reply. It now perfectly works.
Best regards

Found the problem…

<RegExpr attribute="OpenMVArguments" String="[a-zA-Z_][a-zA-Z_0-9]" context="#pop"/>

Should be:

<RegExpr attribute="OpenMVArguments" String="[a-zA-Z_][a-zA-Z_0-9]*" context="#pop"/>

Why this fixes it is hard to explain. But, basically it boils down to the parser being okay with even length keyword string and not odd length ones. I thought I fixed the issue since the test case string was even in length.

I’ll put some more improvements into the text highlighter while I’m at this.

Try this new file.
python.xml (30.1 KB)