r-lib / pak

A fresh approach to package installation
https://pak.r-lib.org
677 stars 63 forks source link

Cannot install pak 0.8.0 on Linux #680

Open jameslairdsmith opened 2 months ago

jameslairdsmith commented 2 months ago

I'm trying to install pak on Red Hat Enterprise Linux 7 (CPE OS Name: cpe:/o:redhat:enterprise_linux:7.9:GA:server"). I'm getting an error when pak tries to build its own HTML documentation. The error occurs when it reaches pkg_sysreqs.

pkg_search                              html  
pkg_status                              html  
pkg_sysreqs                             html  
Error:  attempt to apply non-function
* removing ‘/home/333573/R/x86_64-pc-linux-gnu-library/4.0/pak’
* restoring previous ‘/home/333573/R/x86_64-pc-linux-gnu-library/4.0/pak’
Warning in install.packages :
  installation of package ‘pak’ had non-zero exit status

It works fine on 0.7.2, so it must be something that happened in 0.8.0. Looking through the commit history, it seems like #666 is the most likely time it broke.

gaborcsardi commented 2 months ago

Can you install a binary? As in https://pak.r-lib.org/reference/install.html#pre-built-binaries

jameslairdsmith commented 2 months ago

Can you install a binary? As in https://pak.r-lib.org/reference/install.html#pre-built-binaries

Yes that file works. (Although the corporate nature of the network I'm on means I'm not able to install it directly from the URL.)

gaborcsardi commented 2 months ago

You can also try

install.packages("pak", INSTALL_opts = "--no-html")

to avoid pre-building the HTML.

jameslairdsmith commented 2 months ago

You can also try

install.packages("pak", INSTALL_opts = "--no-html")

to avoid pre-building the HTML.

I didn't know this was an option, but of course it makes complete sense that it's there. Thanks!