Closed njtierney closed 5 years ago
Hi @njtierney! How are you? I hope everything's going well. Unfortunately, I don't really have any helpful solutions. At the moment, all of the tests in prioritizr which rely Gurobi are skipped on Travis (using skip_if_not_installed("gurobi")
). Unfortunately, this means that we have to run tests locally in order to test if prioritizr is using Gurobi correctly, but I find the benefit of having access to Gurobi outweighs this cost. Perhaps one approach would be to try installing Gurobi on Travis and activating its 2-week demo mode automatically? It looks like you can download the Gurobi tarball from a static link on its website, but you might need some clever coding in order to automatically find the filename for the latest version.
Hey @jeffreyhanson !
So nice to hear from you! I'm good mate, hope things are going well in Porto, Portugal :)
Thanks for your advice!
I would definitely run skip_if_not_installed("gurobi")
, but I don't even use it in my tests. This was because I was worried I would trigger Travis errors. But I guess I can now use that.
But the confusing thing is that:
I'm not quite sure how to solve this issue - the only thing I can think of right now is to clear the package cache on Travis. I'll see how that goes.
OK so I went on a bit of a journey and found your thread, Jeff, on how travis builds on success: https://github.com/prioritizr/prioritizr/blob/master/.travis.yml
And then I have now shamelessly copied most of your travis YAML code here: https://github.com/prioritizr/prioritizr/blob/master/.travis.yml
Hopefully this helps solve the problem!
Newly simplified way to express that stuff in travis; see osmdata
for demo - all done via addons
, rather than explicit before_install
calls. addons
are in this case ubuntu-explicit, and the other stuff you can put in the matrix for oxs. In case that helps ...
Thanks, I it is solved now!
I had to include this line: https://github.com/njtierney/maxcovr/blob/master/.travis.yml#L38
Suggested by Rich FitzJohn and Bryce Mecum.
Awesome! Glad to see you got it working. Just a heads up in case this causes issues for you later on, I sometimes find that R Ubuntu packages (e.g. r-cran-rsymphony
and r-cran-rglpk
) on Travis can sometimes fail to install when new versions of R get released or when testing developmental versions of R, so I just manually install/apt-get
the Ubuntu system packages manually (e.g. coinor-libcgl-dev coinor-libclp-dev coinor-libcoinutils-dev coinor-libosi-dev coinor-libsymphony-dev coinor-libsymphony3
for SYMPHONY).
It looks like the package is breaking on installation of Rglpk and gurobi for Travis:
Which is stopping progress for #50.
It looks like
prioritizr
gets around the gurobi problem, they even have an awesome vignette that explains how to install itI'm not sure how to get around this problem - I'm going to tag @jeffreyhanson in to see if he might have some wise words of wisdom here