Skip to content
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

[No QA] Create triggerWorkflowAndWait action #2495

Merged
merged 29 commits into from
May 11, 2021
Merged

Conversation

roryabraham
Copy link
Contributor

@roryabraham roryabraham commented Apr 20, 2021

Details

Creates a new GitHub Action to trigger another workflow and wait for its execution to complete. The other workflow must be triggerable by the workflow_dispatch event. Similar to this action, except better because:

  1. Uses a while loop to wait for the workflow to start, then another to wait for it to finish. https://github.com/convictional/trigger-workflow-and-wait sort of assumes that the workflow will start immediately, which is not always a safe assumption.
  2. Is written in JS so will work on any runner, not just linux runners.
  3. Uses more emojis, and is therefore objectively better. 🙃

Fixed Issues

Related to #2329

Tests

Manually tested using another repo:

QA Steps

No QA

Tested On

GitHub :)

@roryabraham
Copy link
Contributor Author

Took some tweeking (and has some hardcoded params to work in Public-Test-Repo atm), but here's a pretty successful POC test run:

https://github.com/Andrew-Test-Org/Public-Test-Repo/runs/2415274704?check_suite_focus=true

Next I need to test it with a couple inputs

@roryabraham
Copy link
Contributor Author

Okay, got inputs working, and by happy accident confirmed that error propagation is working as expected: https://github.com/Andrew-Test-Org/Public-Test-Repo/runs/2422716796?check_suite_focus=true

@roryabraham
Copy link
Contributor Author

@roryabraham roryabraham requested a review from deetergp May 7, 2021 20:22
@roryabraham roryabraham requested review from AndrewGable and Jag96 May 7, 2021 20:22
@roryabraham roryabraham changed the title Create triggerWorkflowAndWait action [No QA] Create triggerWorkflowAndWait action May 7, 2021
@roryabraham roryabraham marked this pull request as ready for review May 7, 2021 20:22
@roryabraham roryabraham requested a review from a team as a code owner May 7, 2021 20:22
@MelvinBot MelvinBot requested review from pecanoro and removed request for a team May 7, 2021 20:23
@roryabraham
Copy link
Contributor Author

Okay, sorry for the delay on this one, ready for review!

@roryabraham
Copy link
Contributor Author

@pecanoro In case you do end up reviewing this, just know that all the index.js are compiled files, so you don't need to look at them 🙂

Copy link
Contributor

@Jag96 Jag96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a few questions

pecanoro
pecanoro previously approved these changes May 10, 2021
@AndrewGable
Copy link
Contributor

I'm heading OOO and might have a chance to review this but don't block on my reivew 👍

@roryabraham
Copy link
Contributor Author

Updated and ready for re-review 👍

@Jag96 Jag96 merged commit c5e66e4 into main May 11, 2021
@Jag96 Jag96 deleted the Rory-TriggerWorkflowAndWait branch May 11, 2021 20:00
@OSBotify
Copy link
Contributor

✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

@OSBotify
Copy link
Contributor

🚀 Deployed to staging in version: 1.0.42-1🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

@OSBotify
Copy link
Contributor

🚀 Deployed to production in version: 1.0.44-0🚀

platform result
🤖 android 🤖 failure ❌
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants