Skip to main content

lifecycle

Function lifecycle 

Source
pub async fn lifecycle(repo: &Path, pr_url: &str) -> Result<PrLifecycle>
Expand description

Read just a pull request’s lifecycle state - open, merged, or closed - with none of the checks/reviews/comments land itself needs to decide what to do next.

For a caller that only ever wants one fact and must not risk anything else: magi fold --merged uses this to confirm a URL the operator hands it is actually a merged pull request before touching a run’s state, so a typo or a still-open PR fails loudly instead of quietly recording a merge that never happened.