Bouni / python-luxtronik

python-luxtronik is a library that allow you to interact with a Luxtronik heatpump controller.
MIT License
37 stars 20 forks source link

Release / Pre-Release strategy and versioning scheme #69

Open Bouni opened 1 year ago

Bouni commented 1 year ago

I never really used pre-releases before but with more than just me working on this codebase it seems like a good idea to use them.

I propose that we release pre-releases at a quite high frequency in order to test things and if we think we reached a solid state we release a "real" version.

As mentioned by @kbabioch here we could use test.pypi.org for pre-releases and the real pypi for real releases.

I did a quick test over in my dummy repo with that: https://github.com/Bouni/auto-version-bump/blob/main/.github/workflows/publish-to-pypi.yml#L8-L27

We alos need to agree on a versioning scheme, @kbabioch already said he would stick to semantic versioning (1.2.3), I was in favor of the HA versioning scheme (2023.01.01) but thats just personal preference and I'm flexble with that. @BenPru, any opinion on that matter?

For pre-releases i would just add a -rc1, -rc2 and so on.

BenPru commented 1 year ago

any opinion on that matter?

My favor is the ha versionig scheme.

kbabioch commented 1 year ago

So it's 2:1 regarding the versioning scheme then :-).

I'm fine with HA versioning scheme, although I want to make sure that we don't block ourselves in the future: Are we sure that there will always be one version of this project that will be released? I guess the HA versioning scheme only works when there is one release stream. If we're confident about it, then let's go with it ;-).

Bouni commented 1 year ago

@kbabioch what scenarios do you have in mind that force us to maintain multiple versions?

kbabioch commented 1 year ago

The typical scenario are serious bug fixes and/or security issues while keeping support for older versions of the code without breaking the API too much.

For instance, let's assume the following:

All of this is totally made up and will never occur in exactly this way, of course.

Still, that's why semantic versioning is used for many libraries. You can maintain bug and security fixes without breaking the API, but still make progress on features and API changes in another release stream.

Python, for instance, is working in the same way. Python 3.9.x is still being supported while work is done on Python 3.11. Any serious bugs will be addressed in both streams.

I totally get why it's different for Home Assistant and why they are essentially just bumping numbers and don't care about backwards compatibility. But I think for libraries and modules it should be different, since they are being consumed by other applications. For applications using libraries it's easy to not care, but for the underlying libraries its important to maintain API stability.

kbabioch commented 1 year ago

We need to conclude this and agree on a (new) versioning scheme. One more call to @Guzz-T, @Bouni, @gerw @BenPru.

The current proposals are:

1.) Home Assistant versioning scheme, i.e. encoding the date and/or increasing some number without any specific meaning. 2.) Semantic versioning, i.e. something with major and minor versions, etc.

Personally I would prefer 2.), but it seems like back then there was a (small) majority towards 1.). Is this still the case?

gerw commented 1 year ago

I think that semantic versioning is more useful. With this, we can backport (and release) bugfixes to old stable versions.

Guzz-T commented 1 year ago

I think that semantic versioning is more useful. With this, we can backport (and release) bugfixes to old stable versions.

I totally agree with @gerw