Fix Execute Notebooks CI for fork PRs#67
Conversation
Repo secrets are not exposed to pull_request workflow runs triggered from forks, so QBRAID_API_KEY is empty and every notebook that instantiates QbraidProvider fails with a 401. Skip those notebooks when the key is absent; internal PRs still execute them fully. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Fork contributions land in staging first (API notebooks skipped without the secret), then an internal staging -> main PR executes the full suite with credentials. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
@rryoung98 if we allow skipping the remote execution on PRs from forks, how will the CI pass before we merge the changes? Maybe I'm missing something here |
|
Ideally we want some sort of guardrail which allows us (maintainers) to approve fork PRs to be run with creds |
Summary
Fork PRs (e.g. #65) fail the Execute Notebooks checks with
401 Unauthorizedbecause GitHub does not expose repository secrets topull_requestworkflow runs triggered from forks —QBRAID_API_KEYarrives empty regardless of the repo secret configuration.This adds a skip rule: when
QBRAID_API_KEYis empty, notebooks that authenticate with the qBraid API (QbraidProvider/QbraidClient) are skipped and reported asSKIPPED (no API key on fork PRs)in the job summary. PRs from branches in this repo still execute them fully since the secret is available there.Once merged, re-running the failed checks on #65 will pick up the updated workflow (pull_request runs use the merge commit's workflow file).
🤖 Generated with Claude Code