Comments (5)
I'm afraid that's expected behaviour. It's related to how GH handles actions for forked repositories.
For some more information you could have a look at this related issue from another action: pascalgn/automerge-action#46
I'm really sorry about that, but I'm afraid there's not much I can do about it. If you have any ideas on how to solve this problem, I would be happy to hear them!
from size-label-action.
Thanks @pascalgn, that's unfortunate. You might want to add it to the Action description.
I investigated a bit more:
After the first few failures, we changed from the normal GITHUB_TOKEN
to ours that we are using for other issue related Actions. That leads to this error:
https://github.com/fastlane/fastlane/runs/462203915?check_suite_focus=true
Run pascalgn/size-label-action@df7ad4303b35cbeb20937dbb12d5a050520e469e
/usr/bin/docker run --name e87b529cbecee79e0b47278e92af16f3767d94_b057d1 --label e87b52 --workdir /github/workspace --rm -e GITHUB_TOKEN -e HOME -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e GITHUB_ACTIONS=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/fastlane/fastlane":"/github/workspace" e87b52:9cbecee79e0b47278e92af16f3767d94
Error: Environment variable GITHUB_TOKEN not set!
at main (/usr/local/share/.config/yarn/global/node_modules/size-label-action/index.js:28:11)
at Object.<anonymous> (/usr/local/share/.config/yarn/global/node_modules/size-label-action/index.js:197:3)
at Module._compile (internal/modules/cjs/loader.js:816:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:827:10)
at Module.load (internal/modules/cjs/loader.js:685:32)
at Function.Module._load (internal/modules/cjs/loader.js:620:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:877:12)
at internal/main/run_main_module.js:21:11
This is of course can not work.
But before that, the error looks like that:
https://github.com/fastlane/fastlane/runs/451209007?check_suite_focus=true
Run pascalgn/size-label-action@df7ad4303b35cbeb20937dbb12d5a050520e469e
/usr/bin/docker run --name dfb1b5160b021ce4a27a8c524123950d4df_796cf0 --label 488dfb --workdir /github/workspace --rm -e GITHUB_TOKEN -e HOME -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e GITHUB_ACTIONS=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/fastlane/fastlane":"/github/workspace" 488dfb:1b5160b021ce4a27a8c524123950d4df
Changed lines: 26
Matching label: size/S
{ RequestError [HttpError]: Resource not accessible by integration
at response.text.then.message (/usr/local/share/.config/yarn/global/node_modules/@octokit/request/dist-node/index.js:66:23)
at processTicksAndRejections (internal/process/task_queues.js:86:5)
name: 'HttpError',
status: 403,
headers:
{ 'access-control-allow-origin': '*',
'access-control-expose-headers':
'ETag, Link, Location, Retry-After, X-GitHub-OTP, X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, X-GitHub-Media-Type',
connection: 'close',
'content-encoding': 'gzip',
'content-security-policy': "default-src 'none'",
'content-type': 'application/json; charset=utf-8',
date: 'Mon, 17 Feb 2020 18:43:40 GMT',
'referrer-policy': 'origin-when-cross-origin, strict-origin-when-cross-origin',
server: 'GitHub.com',
status: '403 Forbidden',
'strict-transport-security': 'max-age=31536000; includeSubdomains; preload',
'transfer-encoding': 'chunked',
vary: 'Accept-Encoding, Accept, X-Requested-With',
'x-content-type-options': 'nosniff',
'x-frame-options': 'deny',
Did you already investigate what exactly is throwing this error and why? I am not sure I found the exact thing that applies here in the linked thread.
from size-label-action.
Yeah, I'm not sure if that makes it better or worse. If I understand the docs correctly, the "default" GITHUB_TOKEN at least has read-only access to forked repositories in some cases. This is probably not true for personal access tokens.
I understand the reasoning behind some of the decisions around GH actions and forked repositories, but I think the current state makes a lot of common use cases impossible
from size-label-action.
Same issue here! Unfortunately just saw the problem after having installed the Action in my repo (which is an open source project where people create forks for their collaboration).
Agree with @janpio that you should add this restriction to the Action description.
from size-label-action.
I think this is not yet fixed, or at least it's not clear what the cause for the problem is. However, it's a long time since there was some activity in this issue, so I will close it for now. If you have any new information or need any help, feel free to reopen this issue!
from size-label-action.
Related Issues (16)
- Pre-defined size of PRs HOT 2
- Consider the option to ommit deleted files count HOT 2
- does not add labels on reopening HOT 1
- Automatically set label colors HOT 5
- Possibility to ignore commits HOT 1
- Convert to pure JavaScript Action? HOT 2
- Add support for HTTPS proxy HOT 2
- Custom size shows error HOT 2
- Multiple github checks created HOT 2
- Resource not accessible by integration - Pull request opened by dependabot HOT 1
- Resource not accessible by integration HOT 2
- Node.js 12 actions are deprecated HOT 2
- Cancels action when deleting branch HOT 2
- Cannot read property 'substr' of undefined HOT 2
- Error when label already assigned HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from size-label-action.