marinebon / p2p

Pole to Pole website
https://marinebon.github.io/p2p
3 stars 1 forks source link

R package install bugs with make_pages_on_push Github Action #28

Closed eqmh closed 2 years ago

eqmh commented 2 years ago

Hey @7yl4r, @bbest,

I tried to add a name to the membership list and got a package 'sf' installation error when running GHA.

I think we've had similar bugs in the past. Please let me know how to fix.

Cheers, and thanks for looking into this!

7yl4r commented 2 years ago

looking at the build log it looks like the problem is with gdal not being installed:

checking for gdal-config... no
no
configure: error: gdal-config not found or not executable.

was a gdal install working on this machine before? gdal can be a tricky one to get working sometimes.

7yl4r commented 2 years ago

Since the commits between a last working build and the latest failing ones only changed the xlsx and the readme, I guess it must have been working before.

My only guess then is that a library version changed. We should consider adding version numbers to the DESCRIPTION file.

7yl4r commented 2 years ago

The last working build was ~2mo ago which would have been sf==1.0-2 instead of the current sf==1.0-3 [ref.]

7yl4r commented 2 years ago

sidenote: @bbest : is the renv.lock file used by gh-actions? I thought packages installed through the DESCRIPTION file?

7yl4r commented 2 years ago

Well.. my first guess didn't fix it. (same err in log). Is the sf package crucial? What is GDAL getting used for here? Seems like it could be overkill for this site.

eqmh commented 2 years ago

Hi @7yl4r , The 'sf' package is used at least in site_templates and the Index Rmd's to map sites and process OBIS records, so, yes, I think it is critical.

bbest commented 2 years ago

Hey @7yl4r,

Looks like using the newer version of sf (== 1.0-3) got it working per commit https://github.com/marinebon/p2p/commit/a1721c0cbc599b3bbff43e582d76cc1db656bf3f and successful Github Action 4183778751 (note: Installing sf [1.0-3] ... OK [installed binary]). This is based on noticing the binary version listed on CRAN:

7yl4r commented 2 years ago

That is pretty weird; 1.0-3 is the version that was being installed by default when this bug first popped up. I guess one of:

  1. there has been an unversioned bugfix to the sf package
  2. setting the version in DESCRIPTION causes the install to behave differently than if the default version is used (even if the default and set version numbers are the same)
  3. some other temporary issue with our setup not related to the sf package

Anyway. Glad it is working. Thanks for taking a look! 🥂

eqmh commented 2 years ago

Many thanks, @7yl4r and @bbest!