[GRASS-dev] r67535: pygrass: change dirname in set_path()

Vaclav Petras wenzeslaus at gmail.com
Mon Jan 25 12:05:54 PST 2016


In r67669 I moved the functions to grass.script.utils to avoid ctypes
dependency. Backwards compatibility is kept. Documentation says
depreciated. Old functions can be removed in 8.0.

https://trac.osgeo.org/grass/changeset/67669

On Mon, Jan 25, 2016 at 5:31 AM, Pietro <peter.zamb at gmail.com> wrote:

> Hi Martin,
>
> Sorry for the delay.
>
> On Tue, Jan 12, 2016 at 7:11 PM, Martin Landa <landa.martin at gmail.com>
> wrote:
> > hm, what means `dirname`? I got impression that it's used for
> >
> > $GRASS_ADDON_BASE/etc/r.mymodule
> >
> > is find by set_path('r.mymodule')
> >
> > $GRASS_ADDON_BASE/etc/r.mymodule/lib1
> >
> > is find by set_path('r.mymodule', 'lib1'). From this logic I don't
> > understand why dirname must be set. Martin
>
> dirname must be set to check if the directory is available when using
> the code locally, if dirname is available in the local specified path
> then add the path to sys.path, otherwise try to find the correct path
> within the GRASS standard paths.
> I've added some more documentation to clarify this point.
>
> Let me know if you think is still not clear. :-)
>
> all the best
>
> Pietro
> _______________________________________________
> grass-dev mailing list
> grass-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20160125/083a449e/attachment.html>


More information about the grass-dev mailing list