eslint / rewrite

Monorepo for the new version of ESLint
Apache License 2.0
65 stars 4 forks source link

Bug: release-please workflow runs release steps after merging a non-release PR #8

Closed mdjermanovic closed 1 month ago

mdjermanovic commented 1 month ago

Which packages are affected?

Environment

This is a CI/CD issue.

What did you do?

Yesterday, I merged https://github.com/eslint/rewrite/pull/6 and wanted to check the release-please workflow run.

Here's the run that was triggered by that merge:

https://github.com/eslint/rewrite/actions/runs/8967052291

In the release-please workflow, like in other our repos, some steps should be run only when we merge a release PR (i.e. when we want to publish a new version of the package):

https://github.com/eslint/rewrite/blob/e1257125614fd89979350a94d1a0cef742d74f9a/.github/workflows/release-please.yml#L22-L104

What did you expect to happen?

Since this was a "normal" (non-release) PR, I expected the above steps not to run.

What actually happened?

The run printed "A release was created." and proceeded to checkout the repo, install Node.js, and package dependencies.

It didn't proceed with further steps that would publish the packages, but it could be just because the PR wasn't changing any files in them.

Link to Minimal Reproducible Example

N/A

Participation

Additional comments

No response

nzakas commented 1 month ago

This doesn't appear to be happening any more: https://github.com/eslint/rewrite/actions/runs/8987072983/job/24684660538

However, there's another error. I think it's confused about the version numbers and needs a baseline to start from.

mdjermanovic commented 1 month ago

However, there's another error.

The new error seems to be fixed by https://github.com/eslint/rewrite/pull/9, but the error from the original post still exists in the latest run:

https://github.com/eslint/rewrite/actions/runs/8997389474

mdjermanovic commented 1 month ago

To clarify, my concern is less about running unnecessary installation steps, it's more than it might continue to the publish steps in case that the merged PR was changing files inside the packages.

mdjermanovic commented 1 month ago

Seems related: https://github.com/google-github-actions/release-please-action/issues/912