Describe the bug
I am experiencing authentication problems from an Action which tries to trigger automated activities against a Pull Request or repo while using the @Actions/github v3.0.0 package.
To Reproduce
Steps to reproduce the behavior:
- Set your package to version 3.0.0 of actions/github
"dependencies": {
"@actions/core": "^1.2.4",
"@actions/github": "^3.0.0",
"js-yaml": "^3.14.0"
},
- Try and list the Pull Requests in the repo within an action
const myToken = core.getInput('repo-token');
const octokit = github.getOctokit(myToken)
console.log('octokit.pulls.list()');
const { data: pullRequestList } = await octokit.pulls.list({
...github.context.repo,
});
console.log('pullRequestList: ' + JSON.stringify(pullRequestList));
- Trigger the action to run
- Results in Bad Credentials error. From my logs
octokit.pulls.list()
Error: Bad credentials
##[error]Bad credentials
I have tried both the GitHub Token secret and a PAT. Both had the same outcome.
Expected behavior
I would expect this to authenticate and list the PRs as per all documentation I have read indicating this should work.
Additional context
Is this related to what looks to be some significant changes between v2.2.0 and 3.0.0.
I'm going back to v2.2.0 for now as a workaround.
Describe the bug
I am experiencing authentication problems from an Action which tries to trigger automated activities against a Pull Request or repo while using the @Actions/github v3.0.0 package.
To Reproduce
Steps to reproduce the behavior:
I have tried both the GitHub Token secret and a PAT. Both had the same outcome.
Expected behavior
I would expect this to authenticate and list the PRs as per all documentation I have read indicating this should work.
Additional context
Is this related to what looks to be some significant changes between v2.2.0 and 3.0.0.
I'm going back to v2.2.0 for now as a workaround.