You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It appears that things like ~/my_esmvaltool_diagnostics/my_diagnostic.py will expand to a valid location.
Absolute paths are not portable...
We are currently developing some material to teach people how to develop their diagnostics.
We would like to be able to ship a recipe.yml and a diagnostic.py together, with the recipe referencing the diagnostic using a relative path.
I propose to check for a local diagnostic script before appending the esmvaltool diagnostic root to the path.
PR coming.
The text was updated successfully, but these errors were encountered:
location of esmvaltool/recipes (if a relative path to a recipe is provided)
location of esmvaltool/interface_scripts (only for NCL diagnostics)
Maybe the best solution would be to add a new configuration option diagnostic_package_dir or something similar to the configuration file/command line and make that point to the installed esmvaltool package by default with a fallback to the current working directory.
See #826 for some previous, slightly outdated, discussion.
Hi everyone,
Currently, in the diagnostic section of a recipe, the script must be either:
Looking at the code here, there is a third option (not sure that one is very useful though):
https://github.com/ESMValGroup/ESMValCore/blob/6f879cfbff20568ca6b9e2ea4667793a44bef2e5/esmvalcore/_task.py#L350C1-L358C70
It appears that things like
~/my_esmvaltool_diagnostics/my_diagnostic.py
will expand to a valid location.Absolute paths are not portable...
We are currently developing some material to teach people how to develop their diagnostics.
We would like to be able to ship a
recipe.yml
and adiagnostic.py
together, with the recipe referencing the diagnostic using a relative path.I propose to check for a local diagnostic script before appending the esmvaltool diagnostic root to the path.
PR coming.
The text was updated successfully, but these errors were encountered: