octokit / request-action

A GitHub Action to send arbitrary requests to GitHub's REST API
https://github.com/marketplace/actions/GitHub-API-Request
MIT License
362 stars 48 forks source link

[BUG]: Proxy error #300

Closed jwygoda closed 2 months ago

jwygoda commented 3 months ago

What happened?

Tried running action with a self-hosted runner with proxy and got a 500 response. octokit/request-action@v2.1.9 works correctly.

Versions

octokit/request-action@v2.2.0

Relevant log output

Run octokit/request-action@v2.2.0
GET /repos/{owner}/{repo}/commits
> owner: test
> repo: octokit-test
> mediaType: [object Object]
##[debug]route: 'GET /repos/{owner}/{repo}/commits'
##[debug]parameters: { owner: 'test', repo: 'octokit-test', mediaType: {} }
##[debug]parsed request options: {
##[debug]  method: 'GET',
##[debug]  headers: {
##[debug]    accept: 'application/vnd.github.v3+json',
##[debug]    'user-agent': 'octokit-action.js/6.0.5 octokit-core.js/5.0.0 Node.js/20.8.1 (linux; x64)'
##[debug]  },
##[debug]  request: {
##[debug]    fetch: [AsyncFunction: customFetch],
##[debug]    hook: [Function: bound bound register]
##[debug]  },
##[debug]  data: undefined,
##[debug]  url: 'https://api.github.com/repos/test/octokit-test/commits'
##[debug]}
< 500 114ms
##[debug]RequestError [HttpError]: fetch failed
##[debug]    at /opt/actions-runner/_work/_actions/octokit/request-action/v2.2.0/dist/index.js:6770:11
##[debug]    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
##[debug]    at async main (/opt/actions-runner/_work/_actions/octokit/request-action/v2.2.0/dist/index.js:34487:39) {
##[debug]  status: 500,
##[debug]  request: {
##[debug]    method: 'GET',
##[debug]    url: 'https://api.github.com/repos/test/octokit-test/commits',
##[debug]    headers: {
##[debug]      accept: 'application/vnd.github.v3+json',
##[debug]      'user-agent': 'octokit-action.js/6.0.5 octokit-core.js/5.0.0 Node.js/20.8.1 (linux; x64)',
##[debug]      authorization: 'token [REDACTED]'
##[debug]    },
##[debug]    request: {
##[debug]      fetch: [AsyncFunction: customFetch],
##[debug]      hook: [Function: bound bound register]
##[debug]    }
##[debug]  }
##[debug]}
Error: fetch failed
##[debug]Node Action run completed with exit code 1
##[debug]Set output status = 500
##[debug]Finishing: Run octokit/request-action@v2.2.0

Code of Conduct

github-actions[bot] commented 3 months ago

👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀

jwygoda commented 2 months ago

Fixed in v2.3.0