stan-dev / posterior

The posterior R package
https://mc-stan.org/posterior/
Other
168 stars 23 forks source link

Please use consistent signing in version numbers #323

Closed tillea closed 11 months ago

tillea commented 11 months ago

Hi, when I updated the Debian packaged version of posterior I realised that the versioned dependency from two packages was specified with different signs than the maintainer of these packages decided in their versioning. I'm perfectly aware that R is sorting '.' and '-' is sorting equally in version numbers. However, in other environments where this is not the case it is asking for trouble when using divergent spelling of the version strings. That's why I'd be happy if you could apply the following patch

--- a/DESCRIPTION
+++ b/DESCRIPTION
@@ -26,8 +26,8 @@ Depends: R (>= 3.2.0)
 Imports: methods, abind, checkmate, rlang (>= 1.0.6), stats, tibble (>=
         3.1.0), vctrs (>= 0.5.0), tensorA, pillar, distributional,
         parallel, matrixStats
-Suggests: testthat (>= 2.1.0), caret (>= 6.0.84), gbm (>= 2.1.8),
-        randomForest (>= 4.6.14), e1071 (>= 1.7.3), dplyr, tidyr,
+Suggests: testthat (>= 2.1.0), caret (>= 6.0-84), gbm (>= 2.1.8),
+        randomForest (>= 4.6.14), e1071 (>= 1.7-3), dplyr, tidyr,
         knitr, ggplot2, ggdist, rmarkdown
 License: BSD_3_clause + file LICENSE
 Encoding: UTF-8

inside the DESCRIPTION file. It would be great if you could apply this to the next release to have consistent versioning with the caret and e1071 authors. This would help downstream consumers of your package. Thanks a lot for considering, Andreas.

paul-buerkner commented 11 months ago

So you are suggesting to replace . with - or the other way round? I think it would be easiest if you submitted a PR. Happy to check it and merge it then if it looks good.

tillea commented 11 months ago

I confirm that I find the fact that '.' and '-' are playing the same role regarding sorting in version numbers. I hope the PR clarifies what I mean. Its just using the same spelling of the version number. Thanks a lot for considering the PR, Andreas.