Opened 6 years ago
Closed 4 years ago
#3691 closed defect (fixed)
addon r.connectivity.distance not working
Reported by: | cgarzon | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.8.3 |
Component: | Addons | Version: | 7.4.1 |
Keywords: | r.connectivity | Cc: | sbl |
CPU: | OSX/Intel | Platform: | MacOSX |
Description (last modified by )
I have installed the addon r.connectivity. But when I try to use r.connectivity.distance I get the following error:
GRASS 7.4.1 (nc_spm_08_grass7):~ > r.connectivity.distance Traceback (most recent call last): File "/Users/carolgarzon/Library/GRASS/7.4/Modules/scripts/r.connectivity.distance", line 242, in <module> TMP_PREFIX = grass.tempname(12) AttributeError: 'module' object has no attribute 'tempname' -------- There is no manual page for this command and when I tried reinstalling I got: ADVERTENCIA: Extension <r.connectivity> already installed. Re-installing... Fetching <r.connectivity> from GRASS GIS Addons repository (be patient)... Compiling... Traceback (most recent call last): File "/tmp/grass7-carolgarzon-7044/tmp_ooFcV/r.connectivity/scripts/r.connectivity.distance", line 242, in <module> TMP_PREFIX = grass.tempname(12) AttributeError: 'module' object has no attribute 'tempname' make[1]: *** [r.connectivity.distance.tmp.html] Error 1 Installing... install: /tmp/grass7-carolgarzon-7044/tmp_ooFcV/r.connectivity/docs/html/r.connectivity.distance.html: No such file or directory make[1]: *** [install] Error 71 Updating addons metadata file... Installation of <r.connectivity> successfully finished
What might be the problem?
Change History (11)
comment:1 by , 6 years ago
Description: | modified (diff) |
---|
comment:2 by , 6 years ago
follow-up: 5 comment:3 by , 6 years ago
Yes, the addon is developed against upcoming 7.6 and the tempname() function is not part of 7.4.
Options would be
a) to backport it to 7.4 (its a new feature but a minor change with little risk...) or
b) to (at least temporarily) add the function to the addon, together wih a check for GRASS version
What would be the prefered solution from the core-devs perspective? Option a) would solve the issue first with next point release (7.4.3), option b) would create some mess in the addon code (that could be removed later...).
comment:4 by , 6 years ago
Cc: | added |
---|---|
Keywords: | r.connectivity added |
Milestone: | → 7.4.3 |
comment:5 by , 6 years ago
Replying to sbl:
Yes, the addon is developed against upcoming 7.6 and the tempname() function is not part of 7.4.
Options would be
a) to backport it to 7.4 (its a new feature but a minor change with little risk...) or
b) to (at least temporarily) add the function to the addon, together wih a check for GRASS version
What would be the prefered solution from the core-devs perspective? Option a) would solve the issue first with next point release (7.4.3), option b) would create some mess in the addon code (that could be removed later...).
I'd go both ways: backport r73205 (found with trac - source code browser - "blame" function) to relbranch74 and also add it for now to the addon code. Then remove once 7.4.3 is out.
comment:10 by , 5 years ago
Milestone: | → 7.8.3 |
---|
comment:11 by , 4 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
After backport and with 7.8 being stable version this can be closed, I guess.
(minor wish: please use the "Code Block" button in the editor for citing terminal output for better readability)
Replying to cgarzon:
It seems that an import is missing to enable:
https://grass.osgeo.org/grass76/manuals/libpython/script.html?highlight=tempname#script.core.tempname
The author may know best...