paul-buerkner / brms

brms R package for Bayesian generalized multivariate non-linear multilevel models using Stan
https://paul-buerkner.github.io/brms/
GNU General Public License v2.0
1.25k stars 177 forks source link

Fix creating stanfit from csv when rstan not loaded #1663

Closed andrjohns closed 1 month ago

andrjohns commented 1 month ago

Reported by @ave, using cmdstanr backend is giving error in some cases:

Error in getClass(Class, where = topenv(parent.frame())) : 
  “cxxdso” is not a defined class

Which is caused by the CSV processing attempting to use a class from the rstan package when it's not loaded. This PR updates the class lookup to specify that it should be found in rstan

paul-buerkner commented 1 month ago

Thanks! Merging now :-)