-
-
Notifications
You must be signed in to change notification settings - Fork 131
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
Error when using fine-grained PAT #208
Comments
Are you using a fine-grained PAT? They are in beta and may not work for all GitHub APIs yet. Please try with a "classic" PAT. (The deprecation warning is not the cause of the error) |
I have the same issue.
PAT is not used because the target workflow in the same repo. |
Hi @Sicness Your case is different. When using the default |
Hi @peter-evans , thanks for the response. The initial workflow is triggered by a push into the repo. My goal is to build the app on new commits in a branch and trigger deployment workflow from the first workflow. Looks like in that case I'll have to specify token? It's not obvious from the README :) |
@Sicness It's difficult to say without seeing your workflow. Are you specifying permissions:
contents: write e.g. https://github.com/peter-evans/repository-dispatch/blob/main/.github/workflows/ci.yml#LL14C1-L16C18 |
@peter-evans , So, I created the token with contents: write and now it works. Thank you. The only comment from my side that it would be good to add a comment that in some cases it will be required to specify a token even if the target workflow in the same repo. For example when the initial workflow is triggered by on.push.branches. |
Thanks adding content write fixed my fine grained token issue too |
@peter-evans Yes, I'm using a fine-grained PAT. |
Just to make it crystal clear: using a fine-grained PAT to notify a different repository works. |
@BrunoJuchli Thank you for confirming and raising a PR to update the readme. Fine-grained PAT usage is now documented here: https://github.com/peter-evans/repository-dispatch#token |
Hi,
first of all, diclaimer, I'm new to github actions. I'm trying to use your action to trigger some other action on some other repository. Not withstanding the fact that I have a
PAT
error, I'm getting a warning of deprecation.The text was updated successfully, but these errors were encountered: