Re: [Gimp-developer] Python plugin debugging and workflow

On 3 April 2012 08:01, Jon Decker <jondecker76 gmail com> wrote:
> Hello
> I have a lot of work into my first large plugin.  One thing that really
> slows my progress is the lack of any kind of debugging or work flow.  For
> example, if I make a syntax error, the plugin will just silently fail, or
> fail to appear in the menu.  I receive no erros or hints as to where the
> error occured.  I normally have to commentoput code line-by-line and rerun
> the plugin until I find the offending line of code.  I've wasted hours at a
> time finding small little bugs like this.

to detect syntax errors, just try to run your plug-ina s a normal
Python program -
Syntax errors will be flagged normally - i the program is well formed,
it will fail with an import error
when trying to import gimp or gimpfu

As fro runtime erros, just watch the normal error output of GIMP on
the terminal.
(the good news is taht for fixing these errors, you just have to
re-run the plugin from inside GIMP<
no need to reinstall or relaod anything).


> Is there a way to have gimp relay python errors?
> I have also noticed that the python plugins will not run outside of gimp
> with the standard python interpreter (can't find the gimp imports).
> Is there something I'm missing?  Is this the workflow that everybody uses?
> Any hints or tips?
> thanks!
> _______________________________________________
> gimp-developer-list mailing list
> gimp-developer-list gnome org

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]