A consequence of this is that is quite hard to properly define recipe state at a given time.
An alternative would be to create a proper Github App. Then we could manage the recipe state inside the API backend as a proper state machine, and post the appropriate updates to GitHub when needed.
This would be a major refactor but would probably make more sense in the long run.
Our current automation / orchestration setup is a janky mix of github workflows, github API calls, and prefect callbacks. (See https://github.com/pangeo-forge/flow-charts)
A consequence of this is that is quite hard to properly define recipe state at a given time.
An alternative would be to create a proper Github App. Then we could manage the recipe state inside the API backend as a proper state machine, and post the appropriate updates to GitHub when needed.
This would be a major refactor but would probably make more sense in the long run.