[GRASS-dev] v.in.pygbif addon: Manual does not build

Vaclav Petras wenzeslaus at gmail.com
Tue Sep 13 08:16:08 PDT 2016


On Tue, Sep 13, 2016 at 10:52 AM, Helmut Kudrnovsky <hellik at web.de> wrote:

> the difference ist that in v.in.natura2000 it's done in def main(); in
> v.in.pygbif it's done before def main()
>


Right, this must be done only after calling grass.script.parser() function
but also in the right scope, so main is usually the right place for short
modules. There are other solutions with using another variable suitable for
more complicated modules (used e.g. in wxGUI), see m.printws:

https://trac.osgeo.org/grass/browser/grass-addons/grass7/misc/m.printws/m.printws.py?rev=69427#L177
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20160913/4208d88c/attachment.html>


More information about the grass-dev mailing list