question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

action-automatic-releases broken - UnhandledPromiseRejectionWarning: HttpError: Resource not accessible by integration

See original GitHub issue

This was working as expected until a few weeks ago, now when trying to use the action the following error occurs:

Generating changelog
  Error: Resource not accessible by integration
  (node:1865) UnhandledPromiseRejectionWarning: HttpError: Resource not accessible by integration
      at /home/runner/work/_actions/marvinpinto/action-automatic-releases/latest/dist/index.js:1:361954
      at processTicksAndRejections (internal/process/task_queues.js:93:5)
  (node:1865) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
  (node:1865) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Perhaps JS is trying to read from a variable or file that doesn’t exist?


This is being called in my workflow as follows:

  - name: Download Example Artifact
    uses: actions/download-artifact@v2
    with:
      name: "hello-world"

  - name: Create Github Release With Example Artifact
    uses: marvinpinto/action-automatic-releases@latest
    with:
      repo_token: "${{ secrets.GITHUB_TOKEN }}"
      prerelease: true
      automatic_release_tag: "${{ steps.calver.outputs.release }}-${{ github.run_id }}"
      files: |
        "hello-world.zip"

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
marvinpintocommented, Dec 1, 2021

Did you per chance enable permissions on your repo? I recently ran into something similar, this is what I use on another repo:

permissions:
  id-token: "write"
  contents: "write"
  packages: "write"
  pull-requests: "read"

You can probably ignore id-token unless you’re using GitHub OIDC auth. The permissions are not very well documented so I had to figure this out by trial and error.

1reaction
rtrad89commented, Nov 8, 2022

For anyone else coming along later, I had to go to Settings -> Actions -> General and give “Read and write permissions” to the Github Actions workflows.

It is not recommended to solve the problem on the repo level. I had to just specify the workflow’s permissions as per this comment, which is more secure I believe.

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Resource not accessible by integration" · Issue #10 - GitHub
This is clearly a github defect, and now its actively breaking otherwise working code. Edit: Rerunning the failed job with extra debugging enabled...
Read more >
"Resource not accessible by integration" on github post /repos ...
I explicitly assigned allowed all permissions in the workflow but it still doesn't work. Permissions for GH Token are also set to read/write....
Read more >
Debug "Resource not accessible by integration" error when ...
This error basically talks about a permission issue. When working with Github apps, you may not have set the necessary permission to access...
Read more >
Resource not accessible by integration - GoReleaser
Integrations that may cause this: Homebrew Tap; Krew Plugins. Fixing it¶. You have basically two options: 1. Use a Personal Access Token (PAT) ......
Read more >
Github action to auto comment on a new pull request seems to ...
... via a PR on github and I think the new-pull-request-comment-action is broken. ... HttpError: Resource not accessible by integration at ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found