stan-dev / rstan

RStan, the R interface to Stan
https://mc-stan.org
1.02k stars 264 forks source link

Help Installing cmdstan using cmdstanr #1112

Closed Gabe-Inoshita closed 5 months ago

Gabe-Inoshita commented 5 months ago

Hello everyone,

I am having some issues getting Cmdstan to install using cmdstanr.

Description:

When I try to install cmdstan in R via rtools it fails due to a broken toolchain and when I attempt to fix the pathway it fails as well. I do not know how to fix the issue as I am a new user of cmdstan.

Reproducible Steps:

Here is the code I am attempting to input to get cmdstan installed

library(cmdstanr) install_cmdstan() cmdstanr::check_cmdstan_toolchain() cmdstanr::check_cmdstan_toolchain(fix = TRUE)

Current Output:

This is what I am getting

install_cmdstan() Error: Rtools43 installation found but the toolchain was not installed. Run cmdstanr::check_cmdstan_toolchain(fix = TRUE) to fix the issue. cmdstanr::check_cmdstan_toolchain() Error: Rtools43 installation found but the toolchain was not installed. Run cmdstanr::check_cmdstan_toolchain(fix = TRUE) to fix the issue. cmdstanr::check_cmdstan_toolchain(fix = TRUE) Installing mingw32-make and g++ with Rtools43 Error in processx::run("pacman", args = c("-Sy", install_pkgs, "--noconfirm"), …: ! System command 'pacman' failed

Exit status: 1 Stderr (last 10 lines, see $stderr for more): warning: too many errors from mirror.iscas.ac.cn, skipping for the remainder of this transaction error: failed retrieving file 'mingw32.db' from mirror.iscas.ac.cn : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed retrieving file 'clang32.db' from mirror.iscas.ac.cn : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed retrieving file 'clangarm64.db' from mirrors.cloud.tencent.com : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed retrieving file 'ucrt64.db' from mirrors.cloud.tencent.com : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed retrieving file 'mingw64.db' from mirrors.cloud.tencent.com : error setting certificate file: /usr/ssl/certs/ca-bundle.crt warning: too many errors from mirrors.cloud.tencent.com, skipping for the remainder of this transaction error: failed retrieving file 'mingw32.db' from mirrors.cloud.tencent.com : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed retrieving file 'clang32.db' from mirrors.cloud.tencent.com : error setting certificate file: /usr/ssl/certs/ca-bundle.crt error: failed to synchronize all databases (download library error)

Type .Last.error to see the more details.

RStan Version:

I am using cmdstanr version 0.7.1 which is the most recent version on github i believe.

R Version:

I am using R version 4.3.2 and Rtools version rtool43 (Most recent)

Operating System:

Windows 11 Home OS build 22621.3007