-
Notifications
You must be signed in to change notification settings - Fork 261
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve release workflows #1913
Conversation
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
|
||
- name: Find changed workspaces | ||
id: find-changed-workspaces | ||
run: node ./scripts/ci/list-workspaces-to-be-released.js |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here we compute the list of workspaces that have changesets and the list of workspaces containing packages that haven't been published on npm
fail-fast: false | ||
matrix: | ||
workspace: ${{ fromJSON(needs.find-changed-workspaces.outputs.workspaces_with_changesets) }} | ||
uses: ./.github/workflows/create_changeset_pr_for_workspace.yml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here we make sure we create new "Version packages" PRs
fail-fast: false | ||
matrix: | ||
workspace: ${{ fromJSON(needs.find-changed-workspaces.outputs.workspaces_to_be_published) }} | ||
uses: ./.github/workflows/release_workspace.yml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here we release workspaces
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ inputs.workspace }} | ||
|
||
jobs: | ||
changesets-pr: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all of these have been moved to the create_changeset_pr_for_workspace
workflow
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
|
||
jobs: | ||
changesets-pr: | ||
name: Update Version Packages PR for ${{ inputs.workspace }} on branch main |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible that we run this workflow on branches besides main
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not at the moment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't yet looked in detail at the logic. But, I just want to query if this would break the workflow described in #1175? Losing the capability to patch older versions of plugins (for security releases/compatibility where needed with older Backstage versions) would be a difficult regression for us.
Happy to help with a different approach to patching older releases that aligns with this PR, but would prefer not to lose the capability in the interim.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah it makes sense, I can add the feature. I've DM you with more details 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just until we figure out how to retain the ability to release older plugin patch versions
This PR has been automatically marked as stale because it has not had recent activity from the author. It will be closed if no further activity occurs. If the PR was closed and you want it re-opened, let us know and we'll re-open the PR so that you can continue the contribution! |
Hey, I just made a Pull Request!
The current release workflow heavily relies on git to understand which workspaces need to be published, by computing a diff of the changed files and the state of the main branch before a PR was merged. However, this won't work if the changes that are already in the main branch haven't been released.
This PR attempts to address the issue by comparing the versions of the packages that are in the main branch with the versions of the respective packages published on npm.
release_all.yaml
: computes a list of packages that have new changesets and a list of packages that need to be published.These two lists are used to invoke the
create_changeset_pr_for_workspace
workflow for packages with changesets and therelease_workspace
workflow for workspaces with plugins that need to be published.✔️ Checklist
Signed-off-by
line in the message. (more info)