r-hub / rhub

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

{ps} fails to build on Solaris #526

Closed jameslamb closed 2 years ago

jameslamb commented 2 years ago

I attempted to build {lightgbm} (https://github.com/microsoft/LightGBM) on solaris-x86-patched-ods tonight, using the following code.

rhub::check(
    path = "lightgbm_3.3.2.99.tar.gz"
    , email = Sys.getenv("EMAIL_FOR_RHUB")
    , check_args = "--as-cran"
    , platform = "solaris-x86-patched-ods"
    , env_vars = c(
        "R_COMPILE_AND_INSTALL_PACKAGES" = "always"
         , "_R_CHECK_SYSTEM_CLOCK_" = 0L
         , "_R_CHECK_CRAN_INCOMING_REMOTE_" = 0L
         , "_R_CHECK_PKG_SIZES_THRESHOLD_" = 60L
         , "_R_CHECK_TOPLEVEL_FILES_" = 0L
    )
    , show_status = TRUE
)

That build failed when building {lightgbm}'s dependencies. (build link)

{ps} fails to build, with the following error:

Error: package or namespace load failed for ‘ps’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/export/home/XeR9Yyk/R/00LOCK-ps/00new/ps/libs/ps.so':
ld.so.1: R: fatal: relocation error: file /export/home/XeR9Yyk/R/00LOCK-ps/00new/ps/libs/ps.so: symbol psll_memory_uss: referenced symbol not found
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/export/home/XeR9Yyk/R/ps’

Can you help me understand which of these outcomes this failure indicates?

  1. The R Hub Solaris environments are no longer supported, and should be considered deprecated.
  2. CRAN no longer requires Solaris builds, so releases of packages which don't work on Solaris can make it onto CRAN.
  3. There's a mistake in the way I used rhub::check()
  4. This is a bug in {ps}, and should be reported in https://github.com/r-lib/ps instead of here.
  5. Something else

Thank you so much for your time, and for maintaining R Hub!

Debugging Information

From logs like this:

ERROR: dependencies ‘callr’, ‘processx’, ‘ps’ are not available for package ‘testthat’

I can see that {ps} is required through a chain that starts with {testthat}

lightgbm
|_testthat
   |_callr
     |_processx
       |_ps

So I suspect that any builds on this environment for packages which use {testthat} might be affected.

I can see at https://cran.r-project.org/web/packages/ps/index.html that there was a new CRAN release of {ps} about 3 weeks ago (April 23, 2022), and at https://cran.r-project.org/web/checks/check_results_ps.html that CRAN did not check that package on Solaris.

I also do not see the Solaris checks listed at https://cran.r-project.org/web/checks/check_summary.html or https://cran.r-project.org/web/checks/check_flavors.html.

So maybe CRAN is no longer requiring Solaris checks, and therefore a {ps} release that isn't compatible with Solaris made it to CRAN? If you believe that's the case, then I apologize for taking up your time and attention will consider raising a separate issue with the {ps} maintainers.

References

Build link: https://builder.r-hub.io/status/lightgbm_3.3.2.99.tar.gz-e003453fa4744e8b8d9ac584dfa4cdb7

gaborcsardi commented 2 years ago

I think this was fixed already.

jameslamb commented 2 years ago

I think this was fixed already.

I don't believe so, sorry. I just triggered a new build about 30 minutes ago, and see the same error there.

Error: package or namespace load failed for ‘ps’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/export/home/X4DnfLS/R/00LOCK-ps/00new/ps/libs/ps.so':
ld.so.1: R: fatal: relocation error: file /export/home/X4DnfLS/R/00LOCK-ps/00new/ps/libs/ps.so: symbol psll_memory_uss: referenced symbol not found
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/export/home/X4DnfLS/R/ps’

Build link: https://builder.r-hub.io/status/lightgbm_3.3.2.99.tar.gz-426a3164aece4ae6b1a5eb5af17334ab

gaborcsardi commented 2 years ago

It is fixed in this repository, so it will be fixed in the next ps release.

jameslamb commented 2 years ago

in this repository

Ha, oh! I think maybe you mean https://github.com/r-lib/ps, not this {rhub} repo?

Ok then that answers my question, "this is a bug in {ps}". I guess this issue can be closed, and we'll wait on a new {ps} release to be able to test {lightgbm} on Solaris.

Thanks for the help.

gaborcsardi commented 2 years ago

Oh, right, sorry, didn't notice the repo.

FWIW CRAN do not check on Solaris, so you don't need to, either.

jameslamb commented 2 years ago

Thanks very much for that!

I have noticed that I don't see Solaris CRAN checks any more at https://cran.r-project.org/web/checks/check_summary.html or https://cran.r-project.org/web/checks/check_flavors.html, but just wasn't sure if I could trust that that requirement was truly gone, you know?

I think the fact that the most recent {ps} made it onto CRAN even though it doesn't build on Solaris is good evidence that that requirement is gone.


Thanks again for all your help, and for maintaining the R Hub project. It's been invaluable in testing {lightgbm} and other projects I've worked on. I'd be happy to help out if there's ever any work that can be done by outside contributors here.

gaborcsardi commented 2 years ago

but just wasn't sure if I could trust that that requirement was truly gone, you know?

Yes, it is apparently gone.