Problem/Motivation
Since #1314180: Make dev release numbers useful the packaging script is adding nice version information into dev releases.
It seems it does not work with modules using semantic versions.
Having this information stored correctly is a requirement for other features, for example "Downloading translations for dev releases".
---
I know this feature is not so useful since using composer (as projects using composer do not have the version information in their dev modules), but there are some solutions for that also, like https://packagist.org/packages/drupal-composer/info-rewrite (which gets the version string from packages.drupal.org, and it gets it from the packaging script)
Steps to reproduce
https://www.drupal.org/project/ctools/releases/4.0.x-dev
have version info version: '4.0.x-dev'
when it should be like version: 4.0.1+0-dev
https://www.drupal.org/project/conditional_fields/releases/4.x-dev
have version info version: '4.x-dev'
when it should be like version: 4.0.0-alpha1+28-dev
Comments
Comment #2
PasqualleComment #5
drummThe 4.0.x-dev release would have packaged before the 4.0.1 tag existed, so there wasn’t a 4.0.1 tag to count commits from. Dev releases are not repackaged until a new commit is pushed to the branch.
It should have counted from 4.0.0. Part of the regular expression is matching an abbreviated Git commit hash. ctools has enough commits for the Git client to put in 8 characters of the commit hash. The second commit here allows longer abbreviated commit hashes.
Comment #6
drummThe first commit addresses the conditional_fields example. The
4.x
branch name is used in constructing the regular expression, but a pattern to match the minor version number needed to be added.
These fixes are deploying now. In general, this is not something we would trigger repackaging for, since dev releases are inherently unstable, so these should fill out as the maintainers make their next commit.