Skip to content

Conversation

@choldgraf
Copy link
Member

@choldgraf choldgraf commented Sep 29, 2025

This cleans up some of our token reading code and un-breaks tests in the process. Here's what this does:

  • Adds a TOKEN_READONLY so that we don't hit rate limits as quickly.
  • This adds the constraint that this token will only be used on a PR from a non-fork, so it's only a short-term fix. But it confirms that our test suite now passes.

runs-on: ubuntu-24.04
env:
# This is a private access token for @choldgraf that has public read-only access.
# WARNING: This only works for PRs from non-forked repositories.
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is not great then, IMO fork based workflow should be encouraged for everyone in general so to remove the "us and them" distinctions between contributors and the core team.

Copy link
Collaborator

Choose a reason for hiding this comment

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

(I don't necessarily say that for this repo as it should be a low traffic utility; but in general for JB)

Copy link
Member Author

@choldgraf choldgraf Sep 29, 2025

Choose a reason for hiding this comment

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

I agree, I am just trying to get this un-stuck here! The other option would be to re-configure out test suite so that it doesn't hit API rate limits as quickly but that feels like something I don't have the bandwidth to fix right now

@choldgraf choldgraf changed the title Change token to readonly Add a token to avoid rate limits on tests Sep 29, 2025
@choldgraf
Copy link
Member Author

I've updated this PR so that it will revert to the old behavior if the PR is from a forked repository, that way we'll use the PAT's rate limit for non-forked calls (like releases etc) and we'll use the default github limit for all others.

@choldgraf
Copy link
Member Author

superceded by #134

@choldgraf choldgraf closed this Sep 30, 2025
@bsipocz bsipocz deleted the action-2 branch December 1, 2025 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants