如何在Travis中指定生物导体包的包装版本?

时间:2018-03-08 10:34:00

标签: r travis-ci bioconductor rhdf5

我正在尝试使用travis作为我的R包。

检查适用于R 3.4,结果为here

对于R 3.3,Travis是KO,因为Travis安装了包rhdf5,但它不是正确的版本。结果为here

我在我的描述文件中有以下几行

Imports:
data.table,
methods,
stats
Suggests:
rhdf5 (>= 2.20.0),
parallel,
testthat,
knitr,
rmarkdown,
covr

对于R 3.4,travis就是这样做

Installing R packages: rhdf5, zlibbioc
108.31s$ Rscript -e 'install.packages(c("rhdf5", "zlibbioc"));if   (!all(c("rhdf5", "zlibbioc") %in% installed.packages())) { q(status = 1, save = "no")}'
Installing packages into ‘/home/travis/R/Library’
(as ‘lib’ is unspecified)
trying URL 'https://bioconductor.org/packages/3.6/bioc/src/contrib  /rhdf5_2.22.0.tar.gz'
Content type 'application/x-gzip' length 5475293 bytes (5.2 MB)

对于R 3.3,travis就是这样做

Installing R packages: rhdf5, zlibbioc
7.09s$ Rscript -e 'install.packages(c("rhdf5", "zlibbioc"));if   (!all(c("rhdf5", "zlibbioc") %in% installed.packages())) { q(status = 1, save = "no")}'
Installing packages into ‘/Users/travis/R/Library’
(as ‘lib’ is unspecified)
trying URL 'https://bioconductor.org/packages/3.4/bioc/bin/macosx/mavericks /contrib/3.3/rhdf5_2.18.0.tgz'
Content type 'application/x-gzip' length 1557714 bytes (1.5 MB) 

因此对于R 3.3,Travis安装rhdf5 2.18但在我的描述文件中我指定了2.20。

检查R 3.3的结果

* checking package dependencies ... ERROR
Package required and available but unsuitable version: ‘rhdf5’

如何告诉Travis安装rhdf5但仅当版本2.20可用时?

我没有在travis Doc here

中找到这些信息

我必须将_R_CHECK_FORCE_SUGGESTS设置为FALSE吗?

目前这是我的yaml文件

language: R
sudo: true
cache: packages


bioc_required: true
bioc_use_devel: true

os:
 - linux
 - osx

r:
 - oldrel
 - release
 - devel


r_github_packages:
 - hadley/devtools#1263
 - rte-antares-rpackage/antares-rpackageRead@develop
#before - Bioconductor-mirror/zlibbioc
# - Bioconductor-mirror/rhdf5
#after
bioc_packages:
  - rhdf5
  - zlibbioc


r_packages:
  - covr
  - devtools
  - data.table
  - lubridate
  - plyr
  - stringr
  - shiny
  - knitr
  - testthat
  - rmarkdown

after_success:
  - Rscript -e 'library(covr); codecov()'

0 个答案:

没有答案