googleapis / googleapis/release-please
Unwanted Major Version Bump Due to Historical Breaking Change
- Dominant language
- TypeScript
- Stars
- 7.5k
- Forks
- 588
- Avg merge
- 12h 16m
- Merged PRs (30d)
- 7
Description
Hi there, I hope this finds you well.
I'm implementing release-please in one of my projects, and I've been running into an issue that I'm hoping to get some clarity on.
The issue arises when the tool attempts to bump the major version number due to a breaking change commit that was introduced earlier in the project's history. Specifically, this breaking change was the reason for a previous bump from version 9.x.x to 10.x.x.
When I try to initialize release-please with a base version of 10.17.3, I'd expect the next proposed version to be 10.18.0 (given that there's only a new feature commit to consider, not a breaking change). However, the tool proposes 11.0.0 as the new version, seemingly because it's considering the historical breaking change that was introduced earlier.
From my understanding, release-please should only consider the commits since the last release when proposing the new version. Is this correct? If so, it seems like the tool is not behaving as expected in my case. I apologize if I missed a solution that's already been documented or discussed; I've tried to find relevant information but couldn't find a definitive answer.
On a related note, I'd also like to customize the PR title and remove the v prefix from the version number in the changelogs, but I couldn't find options to do so. Any advice on these points would be appreciated.
Thank you for your time and your work on this tool. I look forward to any insights you can provide on this matter.
So to wrap it up that is like a list of what is happening
1. I have a service running with version 10.17.3.
2. I have previously introduced a BREAKING CHANGE that led to a bump from 9.x.x to 10.x.x.
3. Now I'm implementing release-please with the base version of 10.17.3.
4. After the base version, I introduce only feat: commits, so I would expect the next version to be 10.18.0.
5. However, release-please is proposing to bump the version to 11.0.0 instead of 10.18.0. It seems to be considering the historical BREAKING CHANGE that was introduced for the 9.x.x to 10.x.x bump.
6. My goal is to have release-please consider only the commits made after the base version when proposing a new version, which is the expected behavior of the tool. Therefore, it should suggest 10.18.0, not 11.0.0, in this scenario.
Also things to consider, I'm running release please using the release-please-action with the manifest command, and I'm running it from a branch instead of master which is my base branch. Hopefully this is clear for you
My release-please-config.json file looks like and I have two packages to bump
```
{
"plugins": [
{
"type": "linked-versions",
"groupName": "my-project",
"components": ["my-project", "types"]
}
],
"group-pull-request-title-pattern": "chore: release my-project ${version}",
"packages": {
".": {
"component": "my-project",
"release-type": "node"
},
"types": {
"component": "types",
"release-type": "node"
}
}
}
```
and the release-please-manifest.json
```
{
".": "10.17.3",
"types": "10.17.3"
}
```
Contributor guide
Assessment
This issue has not been assessed yet.