Can I rely on setup.py to retrieve the version of basix?

Hello,

To package Basix from the git repo as a PKGBUILD, I am using the version shown in python/setup.py, because git describe, git rev-list, git rev-parse do not give me a v#.#.# tag (e.g. v0.5.1; only get something like joss-62-g888e38ce). Is it safe to assume that pyhton/setup.py will hold the correct version? Thanks!

I would recommend using something extending the below:

curl -sL https://api.github.com/repos/FEniCS/basix/releases/latest | grep “tag_name”

Because we make the GitHub Releases when we are fully satisfied with the tags.

I will investigate the git describe issue, it’s unexpected.

For git describe you need to checkout the release branch first:

git checkout release
git describe --tags

returns v0.5.0.post0 as expected.

1 Like