mjskay / tidybayes

Bayesian analysis + tidy data + geoms (R package)
http://mjskay.github.io/tidybayes
GNU General Public License v3.0
710 stars 59 forks source link

spread_draws() broken: Error: All list elements must be lists themselves. #289

Closed sponslerdb closed 2 years ago

sponslerdb commented 2 years ago

I just updated tidybayes to version 3.0.1. Now all spread_draws() calls throw this error: Error: All list elements must be lists themselves.

This error can be reproduced with the code in this vignette.

https://mjskay.github.io/tidybayes/articles/tidy-brms.html

sponslerdb commented 2 years ago

I just tried re-running the code with version 3.0.0, and it worked. So, the bug must be in the changes made in v. 3.0.1.

sponslerdb commented 2 years ago

Looks like the same issue was encountered by this user: https://stackoverflow.com/questions/69244923/error-all-list-elements-must-be-lists-themselves-error-in-using-spread-draws-f/69451184#69451184

mjskay commented 2 years ago

Hmmm weird. Can you post your sessionInfo()?

mjskay commented 2 years ago

Ah, I see the stackoverflow post has sessionInfo() output.

I have not been able to reproduce this problem on R 4.1 or R 4.0, and all the tests are currently passing on CRAN, which they would not be if spread_draws was broken. Looking at the stackoverflow session info, there are a number of out of date packages that are tidybayes dependencies that I could imagine causing this problem (particularly tibble, vctrs, and posterior), so I suspect it is a problem caused by some change in one of those packages that the newer version of tidybayes depends on and which I failed to add as a minimum version dependency.

Can you try updating your packages (e.g. update.packages(ask = FALSE)) and running the code again? Thanks!

mjskay commented 2 years ago

Hi --- I am closing this for now as I still cannot replicate this bug. If you have a chance to update all of your packages and check again and it is still broken, please do reopen this so I can investigate further. Thanks!

sponslerdb commented 2 years ago

Sorry, I haven't found a chance to try it yet, but I'm sure you're right about the problem involving an outdated version of some other package. I just need to finish something while the script works before I try to break it again :)

mjskay commented 2 years ago

Heh makes sense, I've certainly been there :)