r-lib / pak

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

pak does not find binary packages for R 4.3 on intel mac #487

Closed heavywatal closed 1 year ago

heavywatal commented 1 year ago
> pak::meta_clean()
? Do you want to delete all package metadata (Y/n) y
β„Ή Cleaning up cache directory /Users/watal/Library/Caches/org.R-project.R/R/pkgcache/_metadata.
> pak::cache_clean()
> pak::cache_delete()
> pak::pkg_install("rlang")

β†’ Will install 1 package.
β†’ Will download 1 CRAN package (761.99 kB).
+ rlang   1.1.0 πŸ‘· πŸΎβ€β™‚οΈπŸ”§ (761.99 kB)
β„Ή Getting 1 pkg (761.99 kB)
βœ” Got rlang 1.1.0 (source) (761.99 kB)                             
βœ” Downloaded 1 package (761.99 kB)in 446ms                         
β„Ή Building rlang 1.1.0
βœ” Built rlang 1.1.0 (10.5s)                                 
βœ” Installed rlang 1.1.0  (37ms)                               
βœ” 1 pkg: added 1, dld 1 (761.99 kB) [11.3s] 

while utils::install.packages() does

> install.packages("rlang")
Installing package into β€˜/Users/watal/.R/library/4.3’
(as β€˜lib’ is unspecified)
trying URL 'https://cloud.r-project.org/bin/macosx/big-sur-x86_64/contrib/4.3/rlang_1.1.0.tgz'
Content type 'application/x-gzip' length 1889157 bytes (1.8 MB)
==================================================
downloaded 1.8 MB

The downloaded binary packages are in
        /var/folders/xr/721w1dc555xgjz3kx35bsx900000gn/T//RtmpLuGuQ5/downloaded_packages
gaborcsardi commented 1 year ago

What version of pak is this? How did you install it?

heavywatal commented 1 year ago

pak 0.5 was installed with install.packages("pak"). This is the only one in my R_LIBS_USER so far.

heavywatal commented 1 year ago

Embedded packages look old: pkgcache is 2.0.4 and pkgdepends is 0.4.0.

gaborcsardi commented 1 year ago

Probably because CRAN does not have binaries for pak (and pkgcache and pkgdepends) yet. We can probably improve this in the future.

For now, you can install it like this: https://pak.r-lib.org/#arrow_down-installation

This also works:

source("https://pak.r-lib.org/install.R")
heavywatal commented 1 year ago

Confirmed binary pak from GitHub has correct pkgcache and pkgdepends, and they work as expected. Thank you.

CRAN seems to be providing binary packages already: https://cran.r-project.org/bin/macosx/big-sur-x86_64/contrib/4.3/. I guess CRAN built pak binary with old pkgcache and pkgdepends slightly before the new ones become available.

gaborcsardi commented 1 year ago

Yes, that is unfortunate. I'll submit a dummy update to get it rebuilt, and add some safeguard to install dependencies from source, it the source versions are newer, when building the pak binary.

gaborcsardi commented 1 year ago

I need to wait one more day, it seems, to make it the required seven days between updates.

gaborcsardi commented 1 year ago

New version submitted: https://github.com/r-lib/pak/issues/488