Remove `octokit` README updates for v7 by joshmgross · Pull Request #557 · actions/github-script
I dont understand why #508 was a breaking change if it didnt remove any functionality and didnt change existing, it only added to the api surface. Can someone elaborate?
If users are defining a variable named octokit in their scripts (which I suspect some are), then these scripts would fail with the changes introduced by #508
For example:
- uses: actions/github-script@main with: script: | const octokit = github await octokit.rest.issues.createComment({ owner: context.repo.owner, repo: context.repo.repo, issue_number: ${{ github.event.issue.number }}, body: "Hello Again!" })
That will fail with the error
Unhandled error: SyntaxError: Identifier 'octokit' has already been declared
https://github.com/joshmgross/actions-testing/actions/runs/13551951964