Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[disablebot] Fix workflow when run on PR #6096

Merged
merged 1 commit into from
Jan 15, 2025
Merged

Conversation

clee2000
Copy link
Contributor

@clee2000 clee2000 commented Dec 20, 2024

We don't have access to the environment at PR time, so we don't have the GH_PYTORCHBOT_TOKEN. Instead we can fallback to GITHUB_TOKEN, but this doesn't have the necessary permissions for getting the correct unstable + disable jobs. However, being able to test the overall workflow on PR and the disable tests generator is better than nothing

Copy link

vercel bot commented Dec 20, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Updated (UTC)
torchci ⬜️ Ignored (Inspect) Visit Preview Jan 9, 2025 7:15pm

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Dec 20, 2024
@clee2000 clee2000 marked this pull request as ready for review December 20, 2024 18:35
@clee2000 clee2000 requested a review from a team December 20, 2024 18:35
@clee2000 clee2000 force-pushed the csl/update_disabled_tests branch from 16bb3e0 to 9e78265 Compare January 9, 2025 19:01
# PyTorch bot token is the most obvious choice. Outside of the
# environment, we do not have access to this token so fall back to the
# GITHUB_TOKEN.
GITHUB_TOKEN: ${{ github.ref == 'refs/heads/main' && secrets.GH_MERGEBOT_TOKEN || secrets.GITHUB_TOKEN }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wait lol what is the diff between GH_MERGEBOT_TOKEN and GH_PYTORCHBOT_TOKEN

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume one is from pytorchmergebot and the other from pytorchbot but I don't actually know

I renamed here to GITHUB_TOKEN because I thought most people have a personal token saved as GITHUB_TOKEN and no mergebot token so when running locally they wouldn't have to remap. Also I guess the name would be misleading when the workflow is just using github token

Copy link
Contributor

@atalman atalman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@clee2000 clee2000 merged commit d1728a4 into main Jan 15, 2025
9 checks passed
@clee2000 clee2000 deleted the csl/update_disabled_tests branch January 15, 2025 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants