Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

covr causing failed TravisCI builds? #334

Closed
billdenney opened this issue Sep 22, 2018 · 12 comments
Closed

covr causing failed TravisCI builds? #334

billdenney opened this issue Sep 22, 2018 · 12 comments

Comments

@billdenney
Copy link

In the past couple of days, I've had failed builds on TravisCI through what appears to be it waiting on covr() to return:

https://travis-ci.org/billdenney/pknca/jobs/431929216

The main package is here: https://github.com/billdenney/pknca

Is there a way to fire-and-forget the covr() call after a successful TravisCI build so that it becomes only the responsibility of codecov.io at that point?

@billdenney
Copy link
Author

billdenney commented Sep 22, 2018

A subsequent build yielded this message during the codecov() run:

Error: Failure in `/tmp/RtmpXtetLQ/R_LIBS30cf80d11a9/PKNCA/PKNCA-tests/testthat.Rout.fail`
Execution halted
Warning message:
system call failed: Cannot allocate memory 

https://travis-ci.org/billdenney/pknca/jobs/431938785

@jimhester
Copy link
Member

You will have to try and debug this locally first with package_coverage()

@billdenney
Copy link
Author

package_coverage() locally (Windows 10) gives no issues:

> library(covr)
> foo <- package_coverage()
> print(foo)
PKNCA Coverage: 94.19%
R/class-general.R: 73.81%
R/class-PKNCAresults.R: 79.63%
R/tss.stepwise.linear.R: 87.72%
R/class-PKNCAconc.R: 88.24%
R/tss.R: 88.68%
R/class-PKNCAdata.R: 89.15%
R/tss.monoexponential.R: 89.47%
R/pk.calc.all.R: 90.88%
R/exclude_nca.R: 92.41%
R/class-PKNCAdose.R: 93.80%
R/check.intervals.R: 95.88%
R/interpolate.conc.R: 96.55%
R/001-add.interval.col.R: 96.92%
R/superposition.R: 97.48%
R/parseFormula.R: 97.70%
R/pk.calc.simple.R: 97.93%
R/PKNCA.options.R: 98.84%
R/general.functions.R: 99.12%
R/002-pk.business.rules.R: 100.00%
R/AIC.list.R: 100.00%
R/auc.R: 100.00%
R/aucint.R: 100.00%
R/choose.intervals.R: 100.00%
R/cleaners.R: 100.00%
R/exclude.R: 100.00%
R/half.life.R: 100.00%
R/merge.R: 100.00%
R/pk.calc.c0.R: 100.00%
R/pk.calc.dn.R: 100.00%
R/pk.calc.urine.R: 100.00%
R/provenance.R: 100.00%
> 

@jimhester
Copy link
Member

From your error messages it seems to be caused by using too much memory, I am not sure there is a lot that can be done about it. You could try running package_coverage() on travis first, then pass the result to codecov to see if it is failing when calculating coverage (which is likely) or when uploading the reports to codecov.

Rscript -e 'cov <- covr::package_coverage()' -e 'print(cov)' -e 'covr::codecov(coverage = cov)'

billdenney added a commit to billdenney/pknca that referenced this issue Sep 24, 2018
@billdenney
Copy link
Author

I'm still having trouble: https://travis-ci.org/billdenney/pknca/jobs/432495895

When running locally, package_coverage() returns in about a minute.

@wlandau
Copy link

wlandau commented Sep 27, 2018

@wlandau
Copy link

wlandau commented Sep 27, 2018

Whatever the issue may be, it seems like these builds started failing right after the latest CRAN release of covr. Could something have changed in how covr uses memory resources? Could there be conflicts between processes forked by covr and those forked by the tests?

@jimhester
Copy link
Member

Please try with the current devel version of covr, it may be #335 which is now fixed.

@wlandau
Copy link

wlandau commented Sep 27, 2018

Works for drake, thanks!

billdenney added a commit to billdenney/pknca that referenced this issue Sep 27, 2018
@billdenney
Copy link
Author

Works for PKNCA, too. Thanks!

@wlandau
Copy link

wlandau commented Sep 27, 2018

In that case, shall we close?

@billdenney
Copy link
Author

I think yes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants