[GRASS-user] not able to import and use pygrass

Vaclav Petras wenzeslaus at gmail.com
Mon Jun 29 09:08:32 PDT 2015


On Mon, Jun 29, 2015 at 11:42 AM, Moritz Lennert <
mlennert at club.worldonline.be> wrote:

> On 29/06/15 16:57, Gra wrote:
>
>> Hi I compiled Grass 7.0 (with OpenMP) on a CENTOS 7 OS.
>>
>> everything works properly, but I'm not able to use PYGRASS
>>
>> here is my first part of the codes if I add import pygrass I have the
>> error:
>> *
>>      import pygrass
>>
>> ImportError: No module named pygrass
>>
>
> try
>
> import grass.pygrass
>
> pygrass is on the same level as script which you seem to be able to import
> successfully.
>

I fixed the documentation in:

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

When backported and updated online, it will be visible at:

http://grass.osgeo.org/grass70/manuals/libpython/pygrass_modules.html

The source code and its layout (which influences resulting package layout)
can be browsed here (lib/python directory becomes `grass` package):

https://trac.osgeo.org/grass/browser/grass/trunk/lib/python/

Reviews of documentation are welcome, patches accepted.

Vaclav
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20150629/4c190f62/attachment.html>


More information about the grass-user mailing list