[Eric] auto-compile forms, check syntax

Detlev Offenbach detlev at die-offenbachs.de
Sun Jan 14 17:01:25 GMT 2007


On Sunday 14 January 2007 16:33, Carles Pina i Estany wrote:
> Hello,
>
> On Jan/14/2007, Detlev Offenbach wrote:
> > On Sunday 14 January 2007 15:35, Carles Pina i Estany wrote:
> > > Hello,
> > >
> > > I am using Eric 3.9.1. I wanted to use 4.x but I didn't have time
> > > because pyqt from Debian is too old (at least when I checked it some
> > > weeks ago, maybe now is already updated.
> > >
> > > I have two questions (my project is Qt4):
> > > -After change a form, forms are not automatically compiled. But in
> > > project settings I have marked "Automatically copmile changed forms".
> > > Any other hint? (of course, I change the form using designerqt called
> > > from Eric)
> >
> > The forms are compiled the next time they are needed, which is for a
> > debug session or a run session or any one of the others. They are not
> > compiled, if you do not invoke any of the run/debug/... actions.
>
> Stupid of me! Until some time ago (one hour, just until after I sent the
> mail) I was executing the project going to my "main.py" and then F2.
> This way doesn't compile the forms, if I press Shift+F2 then forms are
> compiled.
> Don't trust any user, we can do unexpected things!

Forgot to say, that Autocompile Forms is a project related setting and only 
works for the project run/debug/... actions.

>
> > > -Sometimes (often :-) ) there is some syntax error in my programs. I
> > > have seen that "Right click" - "check" - "Syntax" tells me it. I would
> > > like that when I close the document or when I execute the project this
> > > thing is checked.  I have seen in preferences (but I cannot find now)
> > > something related on it and was enabled, but was not working. Any tip?
> >
> > That setting may be found in the configuration dialog Editor->General
> > page. It should work (at least it does over here with eric 3.9.4).
>
> Ok, I have "Automatic Syntax check". If I type a mistake the "bug" (left
> of the line) appears if I save or I execute (Shift+F2, at least). But I
> would expect that, when I press Shift+F2 if there is any error it asks
> me to show the errors (there is 3 errors in this file-lines, etc.). I
> even would expect a short description of the error...
>

When you save a script or run/debug/... a project, which causes all unsaved 
scripts to be saved first, the syntax check is performed, if the a.m. setting 
is switched on. However, Python's syntax checker stops at the first one found 
and that one is reported back to the IDE and marked with the little bug 
symbol. The message reported by Python is accessible via the margin context 
menu "Show syntax error message". This is on a per file basis. If all your 
errors are one per file, all will be flagged. If you have more than one per 
file, only the first one will be flagged.

> Is it possible with 3.9.4? Or for next versions?
>

I don't know of a way to change this behavior.

Regards,
Detlev
-- 
Detlev Offenbach
detlev at die-offenbachs.de


More information about the Eric mailing list