Closed danieltomasz closed 10 months ago
Commenting to say that I am having this same issue trying to install the rstan development version on my Mac.
R version: 4.3.0 Operating system: maxOS 12.6.7 Intel
Commenting to say that I am having this same issue trying to install the rstan development version on my Mac.
This can often be due to a firewall issue, are you working on a corporate/organisation network or computer? Can you try using a different network/internet connection?
I am using a personal computer and have tried using multiple network/internet connections, with the same issue.
Can you post the output from the following command (testing connection to the repo):
download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-arm64/contrib/4.3/PACKAGES", destfile = tempfile())
And then also the full output that you get when running the installation command:
install.packages("rstan", repos = c("https://mc-stan.org/r-packages/", getOption("repos")))
Here is the output when I test the connection using the code you specified (i.e., big-sur-arm64
):
> download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-arm64/contrib/4.3/PACKAGES", destfile = tempfile())
trying URL 'https://mc-stan.org/r-packages/bin/macosx/big-sur-arm64/contrib/4.3/PACKAGES'
Content type 'application/octet-stream' length 909 bytes
==================================================
downloaded 909 bytes
Here is the output when I test the connection but change the code from big-sur-arm64
to big-sur-x86_64
to reflect my operating system:
> download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES", destfile = tempfile())
trying URL 'https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES'
Error in download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES", :
cannot open URL 'https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES'
In addition: Warning messages:
1: In download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES", :
downloaded length 0 != reported length 0
2: In download.file("https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES", :
cannot open URL 'https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES': HTTP status was '404 Not Found'
And here is the output from second command (running the installation):
> install.packages("rstan", repos = c("https://mc-stan.org/r-packages/", getOption("repos")))
also installing the dependency ‘StanHeaders’
Warning in install.packages :
unable to access index for repository https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3:
cannot open URL 'https://mc-stan.org/r-packages/bin/macosx/big-sur-x86_64/contrib/4.3/PACKAGES'
trying URL 'https://cran.rstudio.com/bin/macosx/big-sur-x86_64/contrib/4.3/StanHeaders_2.26.27.tgz'
Content type 'application/x-gzip' length 2531198 bytes (2.4 MB)
==================================================
downloaded 2.4 MB
trying URL 'https://cran.rstudio.com/bin/macosx/big-sur-x86_64/contrib/4.3/rstan_2.21.8.tgz'
Content type 'application/x-gzip' length 20980241 bytes (20.0 MB)
==================================================
downloaded 20.0 MB
Ah yep, thought that might be the case. Our repo isn't properly configured for Intel MacOS, only Apple Silicon (my fault on that one!).
I'll push an update now so that binaries will be available in a few hours, but in the interim you should be able to install from source:
install.packages("rstan", repos = c("https://mc-stan.org/r-packages/", getOption("repos")),
type = "source")
I'll push an update now so that binaries will be available in a few hours
Thanks!
@jgabry Binaries are updating now, turns out it was actually a bug in the drat
package: https://github.com/eddelbuettel/drat/issues/138
The fix isn't on CRAN yet, so a heads up to use drat
from github if you have to update any binaries in the future
Summary:
Please provide a short summary (no more than a sentence or two).
Due to some bugs in the version on cran I tried to install 2.26 on my machine with R 4.3 arm64. I am unable to install the package from stan repo.
Description:
Output
RStan Version:
stan is uninstalled when trying to install from repo
R Version:
R 4.3.1
Operating System:
Macos 13.4 ARM