What
Enhance the detect-flaky-jobs workflow to discover and include the associated Pull Request link in the Slack notification message.
Why
When a flaky job is detected, knowing which PR triggered the workflow run helps engineers to:
- Quickly navigate to the PR that introduced or exposed the flaky behavior
- Correlate flaky jobs with specific code changes
- Prioritize fixes based on PR context
Currently, engineers need to manually trace the commit/branch back to find the associated PR.
How
Use the GitHub API to find the PR associated with the workflow run's head_sha.