Closed monholm closed 3 weeks ago
I have the same issues
Having an exact same issue. release-please is creating additional empty PR besides the actual package PR.
Also there is no autorelease:
tag attached to the PR.
release-please-config.json
{
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"bootstrap-sha": "942d93a2423b28394b427eabdae1b2cc7a174742",
"bump-minor-pre-major": true,
"bump-patch-for-minor-pre-major": false,
"include-v-in-tag": true,
"separate-pull-requests": true,
"sequential-calls": true,
"packages": {
".github": {
"package-name": "workflows",
"release-type": "simple"
},
"packages/my-package": {
"package-name": "my-package",
"release-type": "node"
}
},
"plugins": ["node-workspace"],
"changelog-sections": [
{ "type": "feat", "section": "Features", "hidden": false },
{ "type": "fix", "section": "Bug Fixes", "hidden": false },
{ "type": "chore", "section": "Miscellaneous", "hidden": false },
{ "type": "deps", "section": "Dependencies", "hidden": false },
{ "type": "docs", "section": "Documentation", "hidden": false },
{ "type": "ci", "section": "Continuous Integration", "hidden": false }
]
}
.release-please-manifest.json
{
".github": "2.3.1",
".github+FILLER": "0.0.0",
"packages/my-package": "2.3.0",
"packages/my-package+FILLER": "0.0.0"
}
Also facing the exact same issue.
Sad to see that it was reported a year ago and still hasn't been fixed 😕..
I was able to track down the issue to the merge plugin (used when enabling the node-workspace plugin).
@chingor13, I don't really understand the purpose of the code here, so I will let you decide what needs to be fixed. Thanks 😊
From manifest.ts#buildPullRequests()
the node-workspace
plugin is called:
https://github.com/googleapis/release-please/blob/08331fa555ed482f675fb3e9dd5b0a5296e200a3/src/manifest.ts#L798-L801
The node-workspace
plugin inherits from WorkspacePlugin
but does not overrides the run()
method.
So workspace.ts#run()
is called instead, and there, the merge
plugin is called:
https://github.com/googleapis/release-please/blob/08331fa555ed482f675fb3e9dd5b0a5296e200a3/src/plugins/workspace.ts#L169-L177
Here, the merge.ts#run()
will always return a PR for the root project merged with the candidates:
https://github.com/googleapis/release-please/blob/08331fa555ed482f675fb3e9dd5b0a5296e200a3/src/plugins/merge.ts#L129-L138
Resulting, for a mono-repo, to always have an empty chore: release main
even though there is no project at the root.
@chingor13 I might be wrong, but this does not seem to be resolved. The referenced PR above is not merged and has been inactive for ~two months. Has this been resolved elsewhere?
While trying to use
release-please
withseparate-pull-requests
and thenode-workspace
plugin enabled, I stumbled upon a couple of issues and some odd behaviour.When pushing a commit for a single (and at this point in the repro, the only) package, in addition to the
chore(main): release <package-name> x.y.z
pr,release-please
opens another pr (chore: release main
) with 0 files changed. Thechore: release main
pr is open constantly and contains 0 files changed.Is this expected behaviour? If so, how is one supposed to treat this PR? Leave it as is, merge it before or after the pr containing actual changes, or? I was unable to find any documentation regarding this, so I'm guessing this might be a bug? :)
Moving on from there, using the same setup, if one updates a package that's referenced in another package, the
chore: release main
pr is updated with the patch bump change for the package that references the updated package. But thechangelog
change is invalid and if one tries to merge the PR, no tag is created for the patch bump, causing the versioning to fail. I've created a repro, as this is quite difficult describing... 😅Environment details
release-please
version: v15.7.0Steps to reproduce
separate-pull-request
andnode-workspace
pluginAgain, I've created a repro that hopefully makes it easier to grasp. If not, let me know if I can help provide any other info :)