[Bug] i.landsat.download: add PyYAML as requirements in doc
Name of the addon
i.landsat.download
Describe the bug
Installation of i.landsat.download fails if yaml package is missing.
Compiling...
Traceback (most recent call last):
File "/var/folders/41/b45_b8253jn3rxtr4cd0bd7c0000gn/T/grass8-nicklas-17844/tmpdmiu8grk/i.landsat/grass_addons/src/imagery/i.landsat/scripts/i.landsat.download", line 159, in <module>
import yaml
ModuleNotFoundError: No module named 'yaml'
make[1]: *** [i.landsat.download.tmp.html] Error 1
It should be added to the documentation that PyYAML is required package.
Another related issue: EODAG python package is listed as requirement, but I see in the code that the i.eodag addon is also required.
How about adding requirements.txt files, at least for Python?
See e.g. our v.out.geojson addon which contains a python-requirements: target to run pip:
https://github.com/mundialis/v.out.geojson/blob/main/Makefile
Likewise an GRASS addon target could be added.
How about adding
requirements.txtfiles, at least for Python?See e.g. our
v.out.geojsonaddon which contains apython-requirements:target to runpip:https://github.com/mundialis/v.out.geojson/blob/main/Makefile
Likewise an GRASS addon target could be added.
I would prefer adding the info in the documentation, under requirements, which is perfectly fine; and perhaps a more graceful error message if a package is missing. Pip is not always the preferred way to install python modules, this is for example the case in a MacPorts system. That is probably not even possible with a code signed, notarised app bundle. Stealth installations like that is nothing I'd support for public code anyway.
Side note: I came across this while working on CMake installation of Addons. I have the concept ready with functional implementation, there remain some fine-tuning and cleaning up / refactoring of code. Stay tuned...