r-hub / rhub

R-hub API client
https://r-hub.github.io/rhub/
Other
347 stars 49 forks source link

problem with ncdf4 #621

Open dankelley opened 3 weeks ago

dankelley commented 3 weeks ago

I have a package (github.com/dankelley/oce) that passes rhub tests on linux (R-devel) but fails on both windows and macos (R-devel).

The reported problem is as below. This has been the case for quite a while. I wonder if there is a way I can get around this, perhaps by telling it to use the CRAN version of ncdf4 (to circumvent compilation of an already trustworthy CRAN build).

Things are fine with the other test actions for the package. But I do like to include r-hub in my testing, because I reason that the more tests, the better.

I'm using the action code as downloaded a few months ago.

  ℹ Building ncdf4 1.22
  ✖ Failed to build ncdf4 1.22 (1m 18.3s)
  Error: 
  ! error in pak subprocess
  Caused by error in `stop_task_build(state, worker)`:
  ! Failed to build source package ncdf4.
gaborcsardi commented 3 weeks ago

I wonder if there is a way I can get around this, perhaps by telling it to use the CRAN version of ncdf4 (to circumvent compilation of an already trustworthy CRAN build).

CRAN does not have macOS package builds for R-devel. They also don't have one for ncdf4 on Windows R-devel, because it fails to build for them as well, see the CRAN check pages of the package.

I'm using the action code as downloaded a few months ago.

You are using an old version of the workflow, install/update the rhub package and run rhub::rhub_setup(overwrite = TRUE). That should solve the macos build issue.

The Windows issue is either with the ncdf4 package itself or Rtools, so that needs to be solved elsewhere.