diff --git a/package-lock.json b/package-lock.json index 71024e92..6072e2c4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -115,9 +115,9 @@ } }, "node_modules/@actions/http-client": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-2.2.0.tgz", - "integrity": "sha512-q+epW0trjVUUHboliPb4UF9g2msf+w61b32tAkFEwL/IwP0DQWgbCMM0Hbe3e3WXSKz5VcUXbzJQgy8Hkra/Lg==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-2.2.1.tgz", + "integrity": "sha512-KhC/cZsq7f8I4LfZSJKgCvEwfkE8o1538VoBeoGzokVLLnbFDEAdFD3UhoMklxo2un9NJVBdANOresx7vTHlHw==", "dependencies": { "tunnel": "^0.0.6", "undici": "^5.25.4" @@ -10409,7 +10409,7 @@ "@actions/core": "^1.10.1", "@actions/exec": "^1.1.1", "@actions/glob": "^0.4.0", - "@actions/http-client": "^2.2.0", + "@actions/http-client": "^2.2.1", "@actions/io": "^1.1.3", "@actions/tool-cache": "^2.0.1", "ansi-styles": "^6.2.1", diff --git a/package.json b/package.json index b8dc3b80..0bbf5bee 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,6 @@ "fmt": "npm run dprint fmt", "fmt-check": "run-p --aggregate-output -c 'dprint check' fmt-check:ec", "fmt-check:ec": "git ls-files -z | xargs -0 ec", - "postinstall": "patch-package", "licenses": "webpack -c packages/config/webpack/config.mjs", "link-check": "markdown-link-check README.md", "lint": "npm run -ws --if-present lint", diff --git a/packages/main/package.json b/packages/main/package.json index aef8e76a..3ec9781a 100644 --- a/packages/main/package.json +++ b/packages/main/package.json @@ -12,7 +12,7 @@ "@actions/core": "^1.10.1", "@actions/exec": "^1.1.1", "@actions/glob": "^0.4.0", - "@actions/http-client": "^2.2.0", + "@actions/http-client": "^2.2.1", "@actions/io": "^1.1.3", "@actions/tool-cache": "^2.0.1", "ansi-styles": "^6.2.1", diff --git a/patches/@actions+http-client+2.2.0.patch b/patches/@actions+http-client+2.2.0.patch deleted file mode 100644 index 3c4bee19..00000000 --- a/patches/@actions+http-client+2.2.0.patch +++ /dev/null @@ -1,35 +0,0 @@ -diff --git a/node_modules/@actions/http-client/lib/index.js b/node_modules/@actions/http-client/lib/index.js -index 5a3cad3..363604a 100644 ---- a/node_modules/@actions/http-client/lib/index.js -+++ b/node_modules/@actions/http-client/lib/index.js -@@ -502,7 +502,7 @@ class HttpClient { - if (this._keepAlive && useProxy) { - agent = this._proxyAgent; - } -- if (this._keepAlive && !useProxy) { -+ if (!useProxy) { - agent = this._agent; - } - // if agent is already assigned use that agent. -@@ -535,15 +535,16 @@ class HttpClient { - this._proxyAgent = agent; - } - // if reusing agent across request and tunneling agent isn't assigned create a new agent -- if (this._keepAlive && !agent) { -+ // Always use a custom agent so that `keep-alive` works correctly -+ // on both `node16` and `node20` runtimes. See: -+ // - https://github.com/node-fetch/node-fetch/issues/1735 -+ // - https://github.com/nodejs/node/issues/37184 -+ // - https://github.com/nodejs/node/pull/43522 -+ if (!agent) { - const options = { keepAlive: this._keepAlive, maxSockets }; - agent = usingSsl ? new https.Agent(options) : new http.Agent(options); - this._agent = agent; - } -- // if not using private agent and tunnel agent isn't setup then use global agent -- if (!agent) { -- agent = usingSsl ? https.globalAgent : http.globalAgent; -- } - if (usingSsl && this._ignoreSslError) { - // we don't want to set NODE_TLS_REJECT_UNAUTHORIZED=0 since that will affect request for entire process - // http.RequestOptions doesn't expose a way to modify RequestOptions.agent.options