-
-
Notifications
You must be signed in to change notification settings - Fork 48
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
TypeError: Cannot read properties of undefined (reading 'createReview') #166
Comments
I'm also seeing this in my projects, again, without changes on my side.
|
Same here |
I can confirm the problem. |
I can confirm as well. I've tried downgrading down to 2.5.x, with no effect. Still seeing the error. |
Same here |
Another one here. |
For anybody looking for a solution for this problem. Here is how my workflow looked before (using this action): name: Merge me!
on:
pull_request_target:
jobs:
merge-me:
name: Merge me!
if: github.actor == 'dependabot[bot]'
runs-on: ubuntu-latest
steps:
- name: Merge me!
uses: ahmadnassri/action-dependabot-auto-merge@v2
with:
target: minor
github-token: ${{ secrets.SWAGGER_BOT_GITHUB_TOKEN }}
command: squash and merge Here is the replacement workflow which works exactly the same: name: Merge me!
on:
pull_request_target:
jobs:
merge-me:
name: Merge me!
runs-on: ubuntu-latest
# Checking the actor will prevent your Action run failing on non-Dependabot
# PRs but also ensures that it only does work for Dependabot PRs.
if: github.actor == 'dependabot[bot]'
steps:
# This first step will fail if there's no metadata and so the approval
# will not occur.
- name: Dependabot metadata
id: dependabot-metadata
uses: dependabot/[email protected]
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
# Finally, tell dependabot to merge the PR if all checks are successful
- name: Instruct dependabot to squash & merge
if: ${{ steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major' }}
uses: mshick/add-pr-comment@v2
with:
repo-token: ${{ secrets.SWAGGER_BOT_GITHUB_TOKEN }}
allow-repeats: true
message: |
@dependabot squash and merge
env:
GITHUB_TOKEN: ${{ secrets.SWAGGER_BOT_GITHUB_TOKEN }} |
Nice, thanks for sharing @char0n! 👍 |
Fairly certain you need to use I can open a PR in a bit to update this. |
Thank you for the quick turnaround on this @leezumstein and @ahmadnassri! I updated to I'm still trying to understand though how this broke without any visible changes? Or was Octokit somehow updated at the time when it broke without it being visible in the code changes in this repo? I don't see any new releases of Octokit here either (or is that not the package this GH action is using?): |
I believe this action still ends up pulling the updated docker image irregardless of which version of the action you're targeting. Dependencies we're updated with the recent docker image push which caused the breaking change. |
Can you please clarify @leezumstein: What is the Docker image you are referring to? Is it this one? I believe that's governed by this Dockerfile: With that, shouldn't the octokit dependencies be governed by what's in the There was only one change to dependencies in this repo when things broke (#162) and that didn't appear to touch on anything Github action or Octokit related. I don't see at all when the change to have to use As far as I can see, it should have been Again, just trying to understand what happened here for future reference and also as a learning experience for me. |
Same, thanks! |
@mknepprath looking at your PR (mknepprath/mknepprath-next#976), you probably want to go back to Alternatively, you can also set up Dependabot to update your Github Actions too. |
I am still in the process of further investigating what could have changed, but I thought I am going to post here in case anyone else has an idea.
As far as we know, nothing changed in the configuration of the token itself or the secret, but suddenly (around 12-24h ago) the setup that we had successfully working for months started failing with:
The line in question is this:
Which appears to mean that
octokit.pulls
isundefined
, but also that it does not appear to be a permission issue as such with the token since it got that far.At first I thought that something might have changed on the latest
2.6.1
release from earlier today, but I confirmed that the issue is also still happening with2.6.0
which as I said before we've been using fine for months.I am also sending this to Github support, but I was wondering whether anyone else has seen this and if yes, whether they found a solution for it.
Thanks in advance.
The text was updated successfully, but these errors were encountered: