More Notification Options for EAS Workflow failures
Stanisław Chmiela
Hey David Jebing!
How are you using Workflows?
I think the most common (and convenient) way to integrate Workflows into development process is to connect your Expo project to GitHub and run Workflows on push/pull request events. Then when the workflow fails (or succeeds) you get these little ✅❌ marks on the commit or pull request automatically.
Sometimes it makes sense to opt-in to Workflows in only parts of CI, then you'd usually run
npx eas-cli workflow:run --wait ...
from within workflow and, again, the outer CI job would fail which would show in Azure, Buildkite, GitLab, etc.What do you think about that?
Cheers,
Stanley
PS. Telegram would be easier than e-mail, maybe we could do Telegram…
David Jebing
Stanisław Chmiela
What you‘re suggesting is almost how we‘re already using EAS Workflows and for builds it is mostly fine (1), but for (2) I would really appreciate this feature.
Use Case 1:
Our Jenkins CI trigger does not wait for builds to succeed to not delay other things in our CI pipeline that should run in parallel. We can partly subscribe to notifications for build and submission failures in EAS, but failed updates or fingerprint could probably go unnoticed.
Use Case 2:
We are considering a scheduled trigger within EAS Workflows to run E2E Tests or nightly builds. There is no other system than EAS Workflows to look for failures and building a trigger from another CI system just to get notified of the result seems redundant.
There has be a way to configure notifications for individual Workflows when it is used as a full replacement of other CI solutions.
Stanisław Chmiela
David Jebing I'm not familiar with Jenkins so probably this is going to sound stupid, but… can't other things in the CI pipeline be made run in parallel? So that you _could_ await the workflow result? This sounds like a better experience overall.
Does Jenkins have any API that you could trigger at the end of a workflow? Think:
fingerprint -> get_build -> maestro_tests -> jenkins_hook
?You could also do your own
email_results
job and send the email with any email provider you want.This is the first time I hear this request so I'm hesitant to commit to delivering it this instant and trying to think of ways to let you handle that "in userland".
David Jebing
Stanisław Chmiela
Yes this is totally doable in Jenkins and it is a tradeoff we decided to make - although our pipeline is a bit more complicated and you cannot nest parallel execution where it just made it sense not to waiting for builds to complete.
A custom notify job would solve it in userland, but looking at the documentation (https://docs.expo.dev/eas/workflows/syntax/#custom-jobs) it seems rather complicated to do while custom builds already supports typescript functions (https://docs.expo.dev/custom-builds/functions/)
Maybe eas workflows should also support custom typescript functions to allow such things being build in userland more easily?
Otherwise I'm just suggesting a pre-packaged job for basic email notifications which seems similar to the existing slack job while being more universal.