The question is as the title says.
I started using bump2version and then discovered setuptools_scm (fairly new to developing full-fledged python programs) and now I am confused.
https://setuptools.readthedocs.io/en/latest/history.html#v20-6-0 (ancient, I know, and I use v40-x-x) mentions the integration of bumpversion, however, there is no mention of ever dropping bumpversion support in subsequent changelogs.
Meanwhile, 1.4 Extending and Reusing Setuptools section of setuptools documentation mentions setuptools_scm (and setuptools_svn) for integration with git, Hg and svn.
So, the question is: Is bumpversion deprecated/obsolete?
To further clarify I will try and explain my use-case a bit more
I have a super-project that has multiple subprojects.
super
├───base/
├───core/
├───lib/
├───version/requirements.txt
└───modules/
├───module-1/
├───module-2/
├───module-3/
├───module-4/
└───module-5/
The super is a master git, with each subproject as a submodule (which have their own submodules) and of course, each of them maintains its own release versions (which is easy enough)
A release of the project is comprised of signed-off modules that are inter-compatible with everything else.
I am currently using a submodule called version that maintains a requirements.txt
+ pyproject.toml
and pulls the whole thing together into a distributable package. Following guidelines in https://github.com/pypa/pipfile/issues/27 and somewhat pulling from https://caremad.io/posts/2013/07/setup-vs-requirement/
The question remains: Is there a canonical approach to doing something like this?
If you use setuptools_scm
, you probably don't need bump2version
. And vice versa.
There is no 'canonical' way to bump a version in Python. Multiple tools exist, and you can use the one you like (or none at all).
The message in the setuptools
changelog is about what the setuptools authors use in their own Git repository. They still use bump2version, as seen in this config file.
The projects setuptools_scm
and setuptools
are similar in name but they're totally independent.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With