ci(app): update slackapi/slack-github-action version from v1 to v2#20950
ci(app): update slackapi/slack-github-action version from v1 to v2#20950
Conversation
update slackapi/slack-github-action version from v1 to v2 close AUTH-2780
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## edge #20950 +/- ##
=======================================
Coverage 56.94% 56.94%
=======================================
Files 3953 3953
Lines 326609 326609
Branches 46615 46615
=======================================
Hits 185988 185988
Misses 140403 140403
Partials 218 218
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
Updates the GitHub Actions workflow for app build/deploy notifications by migrating slackapi/slack-github-action from v1 (deprecated output commands) to v2, aligning with GitHub Actions deprecation guidance.
Changes:
- Bump
slackapi/slack-github-actionfromv1.14.0tov2.1.1. - Migrate Slack notification steps to v2 inputs (
webhook+webhook-type) and removeSLACK_WEBHOOK_URLenv usage.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| with: | ||
| webhook: ${{ secrets.OT_APP_OT3_SLACK_NOTIFICATION_WEBHOOK_URL }} | ||
| webhook-type: incoming-webhook | ||
| payload: '{"branch_or_tag":"${{ github.ref_name }}","build_type":"${{ needs.determine-build-type.outputs.type }}", "gh_linkback":"https://github.com/Opentrons/opentrons/tree/${{ github.ref_name }}", "windows_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.windows-release}}", "mac_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.mac-release}}", "linux_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.linux-release}}"}' | ||
| env: | ||
| SLACK_WEBHOOK_URL: ${{ secrets.OT_APP_ROBOTSTACK_SLACK_NOTIFICATION_WEBHOOK_URL }} | ||
| _ACCESS_URL: https://${{env._APP_DEPLOY_BUCKET_ROBOTSTACK}}/${{env._APP_DEPLOY_FOLDER_ROBOTSTACK}} |
There was a problem hiding this comment.
The slack notify release step now posts to secrets.OT_APP_OT3_SLACK_NOTIFICATION_WEBHOOK_URL, but previously it used a different webhook secret for release notifications. This changes where release notifications are delivered and seems outside the PR’s stated scope (action version bump). If release notifications should still go to the robotstack webhook/channel, switch this step back to the appropriate secret (or document the intentional change).
| webhook: ${{ secrets.OT_APP_OT3_SLACK_NOTIFICATION_WEBHOOK_URL }} | ||
| webhook-type: incoming-webhook | ||
| payload: '{"branch_or_tag":"${{ github.ref_name }}","build_type":"${{ needs.determine-build-type.outputs.type }}", "gh_linkback":"https://github.com/Opentrons/opentrons/tree/${{ github.ref_name }}", "windows_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.windows-internal-release}}", "mac_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.mac-internal-release}}", "linux_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.linux-internal-release}}"}' |
There was a problem hiding this comment.
The step outputs being interpolated here include hyphens (e.g. windows-internal-release from echo "windows-${variant}=..." >> $GITHUB_OUTPUT). In GitHub Actions expressions, keys with hyphens should be accessed with bracket notation (e.g. steps.names.outputs['windows-internal-release']) or the output names should be changed to use underscores. Otherwise the expression may be parsed as subtraction and not resolve correctly.
| with: | ||
| webhook: ${{ secrets.OT_APP_OT3_SLACK_NOTIFICATION_WEBHOOK_URL }} | ||
| webhook-type: incoming-webhook | ||
| payload: '{"branch_or_tag":"${{ github.ref_name }}","build_type":"${{ needs.determine-build-type.outputs.type }}", "gh_linkback":"https://github.com/Opentrons/opentrons/tree/${{ github.ref_name }}", "windows_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.windows-release}}", "mac_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.mac-release}}", "linux_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.linux-release}}"}' |
There was a problem hiding this comment.
Same issue as above: this payload references outputs like windows-release / mac-release / linux-release, which contain hyphens. These should be accessed via bracket notation (e.g. steps.names.outputs['windows-release']) or renamed to underscore-separated output names to ensure the expressions resolve reliably.
| payload: '{"branch_or_tag":"${{ github.ref_name }}","build_type":"${{ needs.determine-build-type.outputs.type }}", "gh_linkback":"https://github.com/Opentrons/opentrons/tree/${{ github.ref_name }}", "windows_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.windows-release}}", "mac_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.mac-release}}", "linux_build":"${{ env._ACCESS_URL }}/${{steps.names.outputs.linux-release}}"}' | |
| payload: '{"branch_or_tag":"${{ github.ref_name }}","build_type":"${{ needs.determine-build-type.outputs.type }}", "gh_linkback":"https://github.com/Opentrons/opentrons/tree/${{ github.ref_name }}", "windows_build":"${{ env._ACCESS_URL }}/${{ steps.names.outputs['windows-release'] }}", "mac_build":"${{ env._ACCESS_URL }}/${{ steps.names.outputs['mac-release'] }}", "linux_build":"${{ env._ACCESS_URL }}/${{ steps.names.outputs['linux-release'] }}"}' |
Overview
update slackapi/slack-github-action version from v1 to v2
close AUTH-2780
https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
v1 uses the deprecated command
Test Plan and Hands on Testing
Changelog
close AUTH-2780
Review requests
Risk assessment
low