I have created package fenr
for Bioconductor. It contains functions downloading data from GO, Kegg, Reactome and WikiPathways. As per Bioconductor requirements, these functions have executable examples and are covered by tests. This is all fine until one of the online resources is down, even for a short time, and then the package fails CHECK. This happened recently and I have received a notification of failed CHECK. This is bound to happen from time to time and I'm not happy with my package failing checks because of online resource issues.
What is the best practice in such cases? Should I put dontrun
around examples for these functions and remove them from tests? This would be against Bioconductor guidelines. Should I catch download issues and instead of producing an error return a graceful NULL with a warning, or something similar?
gracefully exit is a good option. so would caching results See BiocFileCache. I think biomart has tried to do this sort of caching option too since it experiences similar downtime for online resource.