On Wed, Aug 1, 2018 at 11:03 AM, Pietro <[email protected]> wrote:

> Hi Yann,
>
> On Wed, Jul 25, 2018 at 9:34 AM, Yann Chemin <[email protected]>
> wrote:
>
>> v.import_(input=adminfile,output="admin",quiet=True,superquiet=True)
>>
>
> Why are you interested to execute "v.import_(" instead of "v.import(",
> what is it the purpose of this extra underscore in this case?
> It is quite easy to fix this issue but actually I'm not conviced should be
> fixed.
>

I think Yann is using shortcuts, not execution by providing module name as
a string, so than "import" is really a keyword:

>>> a = 1
>>> a.real
1
>>> a.xxx
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'int' object has no attribute 'xxx'
>>> a.import()
  File "<stdin>", line 1
    a.import()
           ^
SyntaxError: invalid syntax
_______________________________________________
grass-dev mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to