opentelemetry-network
opentelemetry-network copied to clipboard
[Proposal] When releasing, set patch number automatically
Describe the issue you're reporting
Background
Releases currently follow semantic versioning, i.e., the version has three numeric components {major}.{minor}.{patch}.
Those three components are set to constants in version.sh.
The Problem
The current setup requires a developer to bump the version manually after each release. This opens up the possibility of human error: a release could overwrite old artifacts with a newer version, if there hadn't been an intermediate version bump.
Proposal
To mitigate, we might auto-generate the patch number. Indeed, version.sh already computes a build number using the number of commits from a well known commit, which should be monotonically increasing if we only release from the main
branch.
So the proposal is to automatically set the patch number to be the build number. Major and minor versions would still be updated manually.
Drawbacks The drawback is that patch numbers would stop being contiguous, i.e., instead of having v0.10.0, v0.10.1, v0.10.2, ..., versions might be v.0.10.4001, v.0.10.4037, v.0.10.4099 etc.
cc @open-telemetry/network-maintainers @open-telemetry/network-approvers @open-telemetry/network-triagers
We used to do this, and then we abandoned it for a number of reasons:
- it produces meaningless version numbers (we're doing semver);
- doesn't work reliably across branches;
- it is not practiced by other OpenTelemetry projects.