Distribution-fitting is done using optim_safe() (in https://github.com/spatial-ews/spatialwarnings/blob/master/R/fitpsd.R#L24), which is there to catch errors when the optimization goes into undefined ranges, among other things. However, it tends to hide errors that are meaningful and are not due to convergence issues, e.g. today after an upgrade:
Error in dyn.load(file, DLLpath = DLLpath, ...) : \n unable to load shared object '/home/alex/R/x86_64-pc-linux-gnu-library/4.1/gsl/libs/gsl.so':\n libgsl.so.25: cannot open shared object file: No such file or directory\n
In those cases, it will return NA/NaN-like objects for no good reason. There should be a way to stop when those errors occur (or at least show a warning), and not hide them as if they were convergence-related.
Distribution-fitting is done using
optim_safe()(in https://github.com/spatial-ews/spatialwarnings/blob/master/R/fitpsd.R#L24), which is there to catch errors when the optimization goes into undefined ranges, among other things. However, it tends to hide errors that are meaningful and are not due to convergence issues, e.g. today after an upgrade:In those cases, it will return NA/NaN-like objects for no good reason. There should be a way to stop when those errors occur (or at least show a warning), and not hide them as if they were convergence-related.