bcoe / conventional-release-labels

Apply labels for automatically generated release notes, based on conventionalcommits.org
Apache License 2.0
322 stars 14 forks source link

Error: Resource not accessible by integration #38

Open JobaDiniz opened 1 year ago

JobaDiniz commented 1 year ago

I get this error in pull-requests made by @dependabot

Run bcoe/conventional-release-labels@v1
  with:
    token: ***
    type_labels: {"feat": "feature", "fix": "fix", "breaking": "breaking"}
    ignored_types: ["chore"]
    ignore_label: ignore-for-release
Error: Resource not accessible by integration
boyum commented 1 year ago

Which event triggers the workflow? pull_request or pull_request_target?

JobaDiniz commented 1 year ago
pull_request
boyum commented 1 year ago

pull_request_target is a little safer and GH will allow forks and bots to do more stuff.

If you need to use pull_request, you could add the correct permissions to the job. I think this should work:

permissions:
  contents: read
  pull_requests: write
ElNgatia commented 1 month ago

I've encountered the same error using pull_request_target.