From 7e8725cf2bc4dee76def8cb867ae8ee0f5c024e6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Apr 2024 23:21:21 +0900 Subject: [PATCH] Bump the octokit-dependencies group with 3 updates (#750) * Bump the octokit-dependencies group with 3 updates Bumps the octokit-dependencies group with 3 updates: [@octokit/core](https://github.com/octokit/core.js), [@octokit/graphql-schema](https://github.com/octokit/graphql-schema) and [@octokit/plugin-paginate-graphql](https://github.com/octokit/plugin-paginate-graphql.js). Updates `@octokit/core` from 5.1.0 to 6.1.1 - [Release notes](https://github.com/octokit/core.js/releases) - [Commits](https://github.com/octokit/core.js/compare/v5.1.0...v6.1.1) Updates `@octokit/graphql-schema` from 14.57.0 to 15.4.2 - [Release notes](https://github.com/octokit/graphql-schema/releases) - [Commits](https://github.com/octokit/graphql-schema/compare/v14.57.0...v15.4.2) Updates `@octokit/plugin-paginate-graphql` from 4.0.0 to 5.2.0 - [Release notes](https://github.com/octokit/plugin-paginate-graphql.js/releases) - [Commits](https://github.com/octokit/plugin-paginate-graphql.js/compare/v4.0.0...v5.2.0) --- updated-dependencies: - dependency-name: "@octokit/core" dependency-type: direct:production update-type: version-update:semver-major dependency-group: octokit-dependencies - dependency-name: "@octokit/graphql-schema" dependency-type: direct:production update-type: version-update:semver-major dependency-group: octokit-dependencies - dependency-name: "@octokit/plugin-paginate-graphql" dependency-type: direct:production update-type: version-update:semver-major dependency-group: octokit-dependencies ... Signed-off-by: dependabot[bot] * Follow octokit/plugin-paginate-graphql.js#175 Resolves #713 See https://github.com/kachick/wait-other-jobs/pull/747#discussion_r1553098530 for the detail --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Kenichi Kamiya --- dist/index.js | 2692 ++++++++++++++++++++++++++++++--------------- package-lock.json | 483 ++++++-- package.json | 6 +- src/github-api.ts | 4 +- 4 files changed, 2176 insertions(+), 1009 deletions(-) diff --git a/dist/index.js b/dist/index.js index 16d93973..e5885b19 100644 --- a/dist/index.js +++ b/dist/index.js @@ -3434,11 +3434,11 @@ var require_util2 = __commonJS({ } return location; } - function requestCurrentURL(request) { - return request.urlList[request.urlList.length - 1]; + function requestCurrentURL(request2) { + return request2.urlList[request2.urlList.length - 1]; } - function requestBadPort(request) { - const url = requestCurrentURL(request); + function requestBadPort(request2) { + const url = requestCurrentURL(request2); if (urlIsHttpHttpsScheme(url) && badPortsSet.has(url.port)) { return "blocked"; } @@ -3505,7 +3505,7 @@ var require_util2 = __commonJS({ } return true; } - function setRequestReferrerPolicyOnRedirect(request, actualResponse) { + function setRequestReferrerPolicyOnRedirect(request2, actualResponse) { const { headersList } = actualResponse; const policyHeader = (headersList.get("referrer-policy") ?? "").split(","); let policy = ""; @@ -3519,7 +3519,7 @@ var require_util2 = __commonJS({ } } if (policy !== "") { - request.referrerPolicy = policy; + request2.referrerPolicy = policy; } } function crossOriginResourcePolicyCheck() { @@ -3536,33 +3536,33 @@ var require_util2 = __commonJS({ header = httpRequest.mode; httpRequest.headersList.set("sec-fetch-mode", header); } - function appendRequestOriginHeader(request) { - let serializedOrigin = request.origin; - if (request.responseTainting === "cors" || request.mode === "websocket") { + function appendRequestOriginHeader(request2) { + let serializedOrigin = request2.origin; + if (request2.responseTainting === "cors" || request2.mode === "websocket") { if (serializedOrigin) { - request.headersList.append("origin", serializedOrigin); + request2.headersList.append("origin", serializedOrigin); } - } else if (request.method !== "GET" && request.method !== "HEAD") { - switch (request.referrerPolicy) { + } else if (request2.method !== "GET" && request2.method !== "HEAD") { + switch (request2.referrerPolicy) { case "no-referrer": serializedOrigin = null; break; case "no-referrer-when-downgrade": case "strict-origin": case "strict-origin-when-cross-origin": - if (request.origin && urlHasHttpsScheme(request.origin) && !urlHasHttpsScheme(requestCurrentURL(request))) { + if (request2.origin && urlHasHttpsScheme(request2.origin) && !urlHasHttpsScheme(requestCurrentURL(request2))) { serializedOrigin = null; } break; case "same-origin": - if (!sameOrigin(request, requestCurrentURL(request))) { + if (!sameOrigin(request2, requestCurrentURL(request2))) { serializedOrigin = null; } break; default: } if (serializedOrigin) { - request.headersList.append("origin", serializedOrigin); + request2.headersList.append("origin", serializedOrigin); } } } @@ -3594,26 +3594,26 @@ var require_util2 = __commonJS({ referrerPolicy: policyContainer.referrerPolicy }; } - function determineRequestsReferrer(request) { - const policy = request.referrerPolicy; + function determineRequestsReferrer(request2) { + const policy = request2.referrerPolicy; assert(policy); let referrerSource = null; - if (request.referrer === "client") { + if (request2.referrer === "client") { const globalOrigin = getGlobalOrigin(); if (!globalOrigin || globalOrigin.origin === "null") { return "no-referrer"; } referrerSource = new URL(globalOrigin); - } else if (request.referrer instanceof URL) { - referrerSource = request.referrer; + } else if (request2.referrer instanceof URL) { + referrerSource = request2.referrer; } let referrerURL = stripURLForReferrer(referrerSource); const referrerOrigin = stripURLForReferrer(referrerSource, true); if (referrerURL.toString().length > 4096) { referrerURL = referrerOrigin; } - const areSameOrigin = sameOrigin(request, referrerURL); - const isNonPotentiallyTrustWorthy = isURLPotentiallyTrustworthy(referrerURL) && !isURLPotentiallyTrustworthy(request.url); + const areSameOrigin = sameOrigin(request2, referrerURL); + const isNonPotentiallyTrustWorthy = isURLPotentiallyTrustworthy(referrerURL) && !isURLPotentiallyTrustworthy(request2.url); switch (policy) { case "origin": return referrerOrigin != null ? referrerOrigin : stripURLForReferrer(referrerSource, true); @@ -3624,7 +3624,7 @@ var require_util2 = __commonJS({ case "origin-when-cross-origin": return areSameOrigin ? referrerURL : referrerOrigin; case "strict-origin-when-cross-origin": { - const currentURL = requestCurrentURL(request); + const currentURL = requestCurrentURL(request2); if (sameOrigin(referrerURL, currentURL)) { return referrerURL; } @@ -3773,7 +3773,7 @@ var require_util2 = __commonJS({ } return true; } - function tryUpgradeRequestToAPotentiallyTrustworthyURL(request) { + function tryUpgradeRequestToAPotentiallyTrustworthyURL(request2) { } function sameOrigin(A, B) { if (A.origin === B.origin && A.origin === "null") { @@ -5661,25 +5661,25 @@ var require_request = __commonJS({ static [kHTTP2BuildRequest](origin, opts, handler) { const headers = opts.headers; opts = { ...opts, headers: null }; - const request = new _Request(origin, opts, handler); - request.headers = {}; + const request2 = new _Request(origin, opts, handler); + request2.headers = {}; if (Array.isArray(headers)) { if (headers.length % 2 !== 0) { throw new InvalidArgumentError("headers array must be even"); } for (let i = 0; i < headers.length; i += 2) { - processHeader(request, headers[i], headers[i + 1], true); + processHeader(request2, headers[i], headers[i + 1], true); } } else if (headers && typeof headers === "object") { const keys = Object.keys(headers); for (let i = 0; i < keys.length; i++) { const key = keys[i]; - processHeader(request, key, headers[key], true); + processHeader(request2, key, headers[key], true); } } else if (headers != null) { throw new InvalidArgumentError("headers must be an object or an array"); } - return request; + return request2; } static [kHTTP2CopyHeaders](raw) { const rawHeaders = raw.split("\r\n"); @@ -5707,28 +5707,28 @@ var require_request = __commonJS({ return skipAppend ? val : `${key}: ${val}\r `; } - function processHeader(request, key, val, skipAppend = false) { + function processHeader(request2, key, val, skipAppend = false) { if (val && (typeof val === "object" && !Array.isArray(val))) { throw new InvalidArgumentError(`invalid ${key} header`); } else if (val === void 0) { return; } - if (request.host === null && key.length === 4 && key.toLowerCase() === "host") { + if (request2.host === null && key.length === 4 && key.toLowerCase() === "host") { if (headerCharRegex.exec(val) !== null) { throw new InvalidArgumentError(`invalid ${key} header`); } - request.host = val; - } else if (request.contentLength === null && key.length === 14 && key.toLowerCase() === "content-length") { - request.contentLength = parseInt(val, 10); - if (!Number.isFinite(request.contentLength)) { + request2.host = val; + } else if (request2.contentLength === null && key.length === 14 && key.toLowerCase() === "content-length") { + request2.contentLength = parseInt(val, 10); + if (!Number.isFinite(request2.contentLength)) { throw new InvalidArgumentError("invalid content-length header"); } - } else if (request.contentType === null && key.length === 12 && key.toLowerCase() === "content-type") { - request.contentType = val; + } else if (request2.contentType === null && key.length === 12 && key.toLowerCase() === "content-type") { + request2.contentType = val; if (skipAppend) - request.headers[key] = processHeaderValue(key, val, skipAppend); + request2.headers[key] = processHeaderValue(key, val, skipAppend); else - request.headers += processHeaderValue(key, val); + request2.headers += processHeaderValue(key, val); } else if (key.length === 17 && key.toLowerCase() === "transfer-encoding") { throw new InvalidArgumentError("invalid transfer-encoding header"); } else if (key.length === 10 && key.toLowerCase() === "connection") { @@ -5736,7 +5736,7 @@ var require_request = __commonJS({ if (value !== "close" && value !== "keep-alive") { throw new InvalidArgumentError("invalid connection header"); } else if (value === "close") { - request.reset = true; + request2.reset = true; } } else if (key.length === 10 && key.toLowerCase() === "keep-alive") { throw new InvalidArgumentError("invalid keep-alive header"); @@ -5750,19 +5750,19 @@ var require_request = __commonJS({ if (Array.isArray(val)) { for (let i = 0; i < val.length; i++) { if (skipAppend) { - if (request.headers[key]) - request.headers[key] += `,${processHeaderValue(key, val[i], skipAppend)}`; + if (request2.headers[key]) + request2.headers[key] += `,${processHeaderValue(key, val[i], skipAppend)}`; else - request.headers[key] = processHeaderValue(key, val[i], skipAppend); + request2.headers[key] = processHeaderValue(key, val[i], skipAppend); } else { - request.headers += processHeaderValue(key, val[i]); + request2.headers += processHeaderValue(key, val[i]); } } } else { if (skipAppend) - request.headers[key] = processHeaderValue(key, val, skipAppend); + request2.headers[key] = processHeaderValue(key, val, skipAppend); else - request.headers += processHeaderValue(key, val); + request2.headers += processHeaderValue(key, val); } } } @@ -6926,10 +6926,10 @@ var require_client = __commonJS({ } [kDispatch](opts, handler) { const origin = opts.origin || this[kUrl].origin; - const request = this[kHTTPConnVersion] === "h2" ? Request[kHTTP2BuildRequest](origin, opts, handler) : Request[kHTTP1BuildRequest](origin, opts, handler); - this[kQueue].push(request); + const request2 = this[kHTTPConnVersion] === "h2" ? Request[kHTTP2BuildRequest](origin, opts, handler) : Request[kHTTP1BuildRequest](origin, opts, handler); + this[kQueue].push(request2); if (this[kResuming]) { - } else if (util2.bodyLength(request.body) == null && util2.isIterable(request.body)) { + } else if (util2.bodyLength(request2.body) == null && util2.isIterable(request2.body)) { this[kResuming] = 1; process.nextTick(resume, this); } else { @@ -6953,8 +6953,8 @@ var require_client = __commonJS({ return new Promise((resolve) => { const requests = this[kQueue].splice(this[kPendingIdx]); for (let i = 0; i < requests.length; i++) { - const request = requests[i]; - errorRequest(this, request, err); + const request2 = requests[i]; + errorRequest(this, request2, err); } const callback = () => { if (this[kClosedResolve]) { @@ -7002,13 +7002,13 @@ var require_client = __commonJS({ assert(this[kPending] === 0); const requests = client[kQueue].splice(client[kRunningIdx]); for (let i = 0; i < requests.length; i++) { - const request = requests[i]; - errorRequest(this, request, err); + const request2 = requests[i]; + errorRequest(this, request2, err); } } else if (client[kRunning] > 0) { - const request = client[kQueue][client[kRunningIdx]]; + const request2 = client[kQueue][client[kRunningIdx]]; client[kQueue][client[kRunningIdx]++] = null; - errorRequest(client, request, err); + errorRequest(client, request2, err); } client[kPendingIdx] = client[kRunningIdx]; assert(client[kRunning] === 0); @@ -7216,8 +7216,8 @@ var require_client = __commonJS({ if (socket.destroyed) { return -1; } - const request = client[kQueue][client[kRunningIdx]]; - if (!request) { + const request2 = client[kQueue][client[kRunningIdx]]; + if (!request2) { return -1; } } @@ -7257,12 +7257,12 @@ var require_client = __commonJS({ onUpgrade(head) { const { upgrade, client, socket, headers, statusCode } = this; assert(upgrade); - const request = client[kQueue][client[kRunningIdx]]; - assert(request); + const request2 = client[kQueue][client[kRunningIdx]]; + assert(request2); assert(!socket.destroyed); assert(socket === client[kSocket]); assert(!this.paused); - assert(request.upgrade || request.method === "CONNECT"); + assert(request2.upgrade || request2.method === "CONNECT"); this.statusCode = null; this.statusText = ""; this.shouldKeepAlive = null; @@ -7279,7 +7279,7 @@ var require_client = __commonJS({ client[kQueue][client[kRunningIdx]++] = null; client.emit("disconnect", client[kUrl], [client], new InformationalError("upgrade")); try { - request.onUpgrade(statusCode, headers, socket); + request2.onUpgrade(statusCode, headers, socket); } catch (err) { util2.destroy(socket, err); } @@ -7290,8 +7290,8 @@ var require_client = __commonJS({ if (socket.destroyed) { return -1; } - const request = client[kQueue][client[kRunningIdx]]; - if (!request) { + const request2 = client[kQueue][client[kRunningIdx]]; + if (!request2) { return -1; } assert(!this.upgrade); @@ -7300,23 +7300,23 @@ var require_client = __commonJS({ util2.destroy(socket, new SocketError("bad response", util2.getSocketInfo(socket))); return -1; } - if (upgrade && !request.upgrade) { + if (upgrade && !request2.upgrade) { util2.destroy(socket, new SocketError("bad upgrade", util2.getSocketInfo(socket))); return -1; } assert.strictEqual(this.timeoutType, TIMEOUT_HEADERS); this.statusCode = statusCode; this.shouldKeepAlive = shouldKeepAlive || // Override llhttp value which does not allow keepAlive for HEAD. - request.method === "HEAD" && !socket[kReset] && this.connection.toLowerCase() === "keep-alive"; + request2.method === "HEAD" && !socket[kReset] && this.connection.toLowerCase() === "keep-alive"; if (this.statusCode >= 200) { - const bodyTimeout = request.bodyTimeout != null ? request.bodyTimeout : client[kBodyTimeout]; + const bodyTimeout = request2.bodyTimeout != null ? request2.bodyTimeout : client[kBodyTimeout]; this.setTimeout(bodyTimeout, TIMEOUT_BODY); } else if (this.timeout) { if (this.timeout.refresh) { this.timeout.refresh(); } } - if (request.method === "CONNECT") { + if (request2.method === "CONNECT") { assert(client[kRunning] === 1); this.upgrade = true; return 2; @@ -7347,11 +7347,11 @@ var require_client = __commonJS({ } else { socket[kReset] = true; } - const pause = request.onHeaders(statusCode, headers, this.resume, statusText) === false; - if (request.aborted) { + const pause = request2.onHeaders(statusCode, headers, this.resume, statusText) === false; + if (request2.aborted) { return -1; } - if (request.method === "HEAD") { + if (request2.method === "HEAD") { return 1; } if (statusCode < 200) { @@ -7368,8 +7368,8 @@ var require_client = __commonJS({ if (socket.destroyed) { return -1; } - const request = client[kQueue][client[kRunningIdx]]; - assert(request); + const request2 = client[kQueue][client[kRunningIdx]]; + assert(request2); assert.strictEqual(this.timeoutType, TIMEOUT_BODY); if (this.timeout) { if (this.timeout.refresh) { @@ -7382,7 +7382,7 @@ var require_client = __commonJS({ return -1; } this.bytesRead += buf.length; - if (request.onData(buf) === false) { + if (request2.onData(buf) === false) { return constants.ERROR.PAUSED; } } @@ -7394,8 +7394,8 @@ var require_client = __commonJS({ if (upgrade) { return; } - const request = client[kQueue][client[kRunningIdx]]; - assert(request); + const request2 = client[kQueue][client[kRunningIdx]]; + assert(request2); assert(statusCode >= 100); this.statusCode = null; this.statusText = ""; @@ -7409,11 +7409,11 @@ var require_client = __commonJS({ if (statusCode < 200) { return; } - if (request.method !== "HEAD" && contentLength && bytesRead !== parseInt(contentLength, 10)) { + if (request2.method !== "HEAD" && contentLength && bytesRead !== parseInt(contentLength, 10)) { util2.destroy(socket, new ResponseContentLengthMismatchError()); return -1; } - request.onComplete(headers); + request2.onComplete(headers); client[kQueue][client[kRunningIdx]++] = null; if (socket[kWriting]) { assert.strictEqual(client[kRunning], 0); @@ -7471,8 +7471,8 @@ var require_client = __commonJS({ assert(client[kPendingIdx] === client[kRunningIdx]); const requests = client[kQueue].splice(client[kRunningIdx]); for (let i = 0; i < requests.length; i++) { - const request = requests[i]; - errorRequest(client, request, err); + const request2 = requests[i]; + errorRequest(client, request2, err); } assert(client[kSize] === 0); } @@ -7502,13 +7502,13 @@ var require_client = __commonJS({ assert(client[kPending] === 0); const requests = client[kQueue].splice(client[kRunningIdx]); for (let i = 0; i < requests.length; i++) { - const request = requests[i]; - errorRequest(client, request, err); + const request2 = requests[i]; + errorRequest(client, request2, err); } } else if (client[kRunning] > 0 && err.code !== "UND_ERR_INFO") { - const request = client[kQueue][client[kRunningIdx]]; + const request2 = client[kQueue][client[kRunningIdx]]; client[kQueue][client[kRunningIdx]++] = null; - errorRequest(client, request, err); + errorRequest(client, request2, err); } client[kPendingIdx] = client[kRunningIdx]; assert(client[kRunning] === 0); @@ -7641,8 +7641,8 @@ var require_client = __commonJS({ if (err.code === "ERR_TLS_CERT_ALTNAME_INVALID") { assert(client[kRunning] === 0); while (client[kPending] > 0 && client[kQueue][client[kPendingIdx]].servername === client[kServerName]) { - const request = client[kQueue][client[kPendingIdx]++]; - errorRequest(client, request, err); + const request2 = client[kQueue][client[kPendingIdx]++]; + errorRequest(client, request2, err); } } else { onError(client, err); @@ -7696,8 +7696,8 @@ var require_client = __commonJS({ } } else if (client[kRunning] > 0 && socket[kParser].statusCode < 200) { if (socket[kParser].timeoutType !== TIMEOUT_HEADERS) { - const request2 = client[kQueue][client[kRunningIdx]]; - const headersTimeout = request2.headersTimeout != null ? request2.headersTimeout : client[kHeadersTimeout]; + const request3 = client[kQueue][client[kRunningIdx]]; + const headersTimeout = request3.headersTimeout != null ? request3.headersTimeout : client[kHeadersTimeout]; socket[kParser].setTimeout(headersTimeout, TIMEOUT_HEADERS); } } @@ -7719,13 +7719,13 @@ var require_client = __commonJS({ if (client[kRunning] >= (client[kPipelining] || 1)) { return; } - const request = client[kQueue][client[kPendingIdx]]; - if (client[kUrl].protocol === "https:" && client[kServerName] !== request.servername) { + const request2 = client[kQueue][client[kPendingIdx]]; + if (client[kUrl].protocol === "https:" && client[kServerName] !== request2.servername) { if (client[kRunning] > 0) { return; } - client[kServerName] = request.servername; - if (socket && socket.servername !== request.servername) { + client[kServerName] = request2.servername; + if (socket && socket.servername !== request2.servername) { util2.destroy(socket, new InformationalError("servername changed")); return; } @@ -7740,16 +7740,16 @@ var require_client = __commonJS({ if (socket.destroyed || socket[kWriting] || socket[kReset] || socket[kBlocking]) { return; } - if (client[kRunning] > 0 && !request.idempotent) { + if (client[kRunning] > 0 && !request2.idempotent) { return; } - if (client[kRunning] > 0 && (request.upgrade || request.method === "CONNECT")) { + if (client[kRunning] > 0 && (request2.upgrade || request2.method === "CONNECT")) { return; } - if (client[kRunning] > 0 && util2.bodyLength(request.body) !== 0 && (util2.isStream(request.body) || util2.isAsyncIterable(request.body))) { + if (client[kRunning] > 0 && util2.bodyLength(request2.body) !== 0 && (util2.isStream(request2.body) || util2.isAsyncIterable(request2.body))) { return; } - if (!request.aborted && write(client, request)) { + if (!request2.aborted && write(client, request2)) { client[kPendingIdx]++; } else { client[kQueue].splice(client[kPendingIdx], 1); @@ -7759,12 +7759,12 @@ var require_client = __commonJS({ function shouldSendContentLength(method) { return method !== "GET" && method !== "HEAD" && method !== "OPTIONS" && method !== "TRACE" && method !== "CONNECT"; } - function write(client, request) { + function write(client, request2) { if (client[kHTTPConnVersion] === "h2") { - writeH2(client, client[kHTTP2Session], request); + writeH2(client, client[kHTTP2Session], request2); return; } - const { body, method, path, host, upgrade, headers, blocking, reset } = request; + const { body, method, path, host, upgrade, headers, blocking, reset } = request2; const expectsPayload = method === "PUT" || method === "POST" || method === "PATCH"; if (body && typeof body.read === "function") { body.read(0); @@ -7772,31 +7772,31 @@ var require_client = __commonJS({ const bodyLength = util2.bodyLength(body); let contentLength = bodyLength; if (contentLength === null) { - contentLength = request.contentLength; + contentLength = request2.contentLength; } if (contentLength === 0 && !expectsPayload) { contentLength = null; } - if (shouldSendContentLength(method) && contentLength > 0 && request.contentLength !== null && request.contentLength !== contentLength) { + if (shouldSendContentLength(method) && contentLength > 0 && request2.contentLength !== null && request2.contentLength !== contentLength) { if (client[kStrictContentLength]) { - errorRequest(client, request, new RequestContentLengthMismatchError()); + errorRequest(client, request2, new RequestContentLengthMismatchError()); return false; } process.emitWarning(new RequestContentLengthMismatchError()); } const socket = client[kSocket]; try { - request.onConnect((err) => { - if (request.aborted || request.completed) { + request2.onConnect((err) => { + if (request2.aborted || request2.completed) { return; } - errorRequest(client, request, err || new RequestAbortedError()); + errorRequest(client, request2, err || new RequestAbortedError()); util2.destroy(socket, new InformationalError("aborted")); }); } catch (err) { - errorRequest(client, request, err); + errorRequest(client, request2, err); } - if (request.aborted) { + if (request2.aborted) { return false; } if (method === "HEAD") { @@ -7835,7 +7835,7 @@ upgrade: ${upgrade}\r header += headers; } if (channels.sendHeaders.hasSubscribers) { - channels.sendHeaders.publish({ request, headers: header, socket }); + channels.sendHeaders.publish({ request: request2, headers: header, socket }); } if (!body || bodyLength === 0) { if (contentLength === 0) { @@ -7847,7 +7847,7 @@ upgrade: ${upgrade}\r socket.write(`${header}\r `, "latin1"); } - request.onRequestSent(); + request2.onRequestSent(); } else if (util2.isBuffer(body)) { assert(contentLength === body.byteLength, "buffer body must have content length"); socket.cork(); @@ -7856,48 +7856,48 @@ upgrade: ${upgrade}\r `, "latin1"); socket.write(body); socket.uncork(); - request.onBodySent(body); - request.onRequestSent(); + request2.onBodySent(body); + request2.onRequestSent(); if (!expectsPayload) { socket[kReset] = true; } } else if (util2.isBlobLike(body)) { if (typeof body.stream === "function") { - writeIterable({ body: body.stream(), client, request, socket, contentLength, header, expectsPayload }); + writeIterable({ body: body.stream(), client, request: request2, socket, contentLength, header, expectsPayload }); } else { - writeBlob({ body, client, request, socket, contentLength, header, expectsPayload }); + writeBlob({ body, client, request: request2, socket, contentLength, header, expectsPayload }); } } else if (util2.isStream(body)) { - writeStream({ body, client, request, socket, contentLength, header, expectsPayload }); + writeStream({ body, client, request: request2, socket, contentLength, header, expectsPayload }); } else if (util2.isIterable(body)) { - writeIterable({ body, client, request, socket, contentLength, header, expectsPayload }); + writeIterable({ body, client, request: request2, socket, contentLength, header, expectsPayload }); } else { assert(false); } return true; } - function writeH2(client, session, request) { - const { body, method, path, host, upgrade, expectContinue, signal, headers: reqHeaders } = request; + function writeH2(client, session, request2) { + const { body, method, path, host, upgrade, expectContinue, signal, headers: reqHeaders } = request2; let headers; if (typeof reqHeaders === "string") headers = Request[kHTTP2CopyHeaders](reqHeaders.trim()); else headers = reqHeaders; if (upgrade) { - errorRequest(client, request, new Error("Upgrade not supported for H2")); + errorRequest(client, request2, new Error("Upgrade not supported for H2")); return false; } try { - request.onConnect((err) => { - if (request.aborted || request.completed) { + request2.onConnect((err) => { + if (request2.aborted || request2.completed) { return; } - errorRequest(client, request, err || new RequestAbortedError()); + errorRequest(client, request2, err || new RequestAbortedError()); }); } catch (err) { - errorRequest(client, request, err); + errorRequest(client, request2, err); } - if (request.aborted) { + if (request2.aborted) { return false; } let stream; @@ -7908,11 +7908,11 @@ upgrade: ${upgrade}\r session.ref(); stream = session.request(headers, { endStream: false, signal }); if (stream.id && !stream.pending) { - request.onUpgrade(null, null, stream); + request2.onUpgrade(null, null, stream); ++h2State.openStreams; } else { stream.once("ready", () => { - request.onUpgrade(null, null, stream); + request2.onUpgrade(null, null, stream); ++h2State.openStreams; }); } @@ -7931,14 +7931,14 @@ upgrade: ${upgrade}\r } let contentLength = util2.bodyLength(body); if (contentLength == null) { - contentLength = request.contentLength; + contentLength = request2.contentLength; } if (contentLength === 0 || !expectsPayload) { contentLength = null; } - if (shouldSendContentLength(method) && contentLength > 0 && request.contentLength != null && request.contentLength !== contentLength) { + if (shouldSendContentLength(method) && contentLength > 0 && request2.contentLength != null && request2.contentLength !== contentLength) { if (client[kStrictContentLength]) { - errorRequest(client, request, new RequestContentLengthMismatchError()); + errorRequest(client, request2, new RequestContentLengthMismatchError()); return false; } process.emitWarning(new RequestContentLengthMismatchError()); @@ -7963,15 +7963,15 @@ upgrade: ${upgrade}\r ++h2State.openStreams; stream.once("response", (headers2) => { const { [HTTP2_HEADER_STATUS]: statusCode, ...realHeaders } = headers2; - if (request.onHeaders(Number(statusCode), realHeaders, stream.resume.bind(stream), "") === false) { + if (request2.onHeaders(Number(statusCode), realHeaders, stream.resume.bind(stream), "") === false) { stream.pause(); } }); stream.once("end", () => { - request.onComplete([]); + request2.onComplete([]); }); stream.on("data", (chunk) => { - if (request.onData(chunk) === false) { + if (request2.onData(chunk) === false) { stream.pause(); } }); @@ -7989,7 +7989,7 @@ upgrade: ${upgrade}\r }); stream.once("frameError", (type, code) => { const err = new InformationalError(`HTTP/2: "frameError" received - type ${type}, code ${code}`); - errorRequest(client, request, err); + errorRequest(client, request2, err); if (client[kHTTP2Session] && !client[kHTTP2Session].destroyed && !this.closed && !this.destroyed) { h2State.streams -= 1; util2.destroy(stream, err); @@ -7998,20 +7998,20 @@ upgrade: ${upgrade}\r return true; function writeBodyH2() { if (!body) { - request.onRequestSent(); + request2.onRequestSent(); } else if (util2.isBuffer(body)) { assert(contentLength === body.byteLength, "buffer body must have content length"); stream.cork(); stream.write(body); stream.uncork(); stream.end(); - request.onBodySent(body); - request.onRequestSent(); + request2.onBodySent(body); + request2.onRequestSent(); } else if (util2.isBlobLike(body)) { if (typeof body.stream === "function") { writeIterable({ client, - request, + request: request2, contentLength, h2stream: stream, expectsPayload, @@ -8023,7 +8023,7 @@ upgrade: ${upgrade}\r writeBlob({ body, client, - request, + request: request2, contentLength, expectsPayload, h2stream: stream, @@ -8035,7 +8035,7 @@ upgrade: ${upgrade}\r writeStream({ body, client, - request, + request: request2, contentLength, expectsPayload, socket: client[kSocket], @@ -8046,7 +8046,7 @@ upgrade: ${upgrade}\r writeIterable({ body, client, - request, + request: request2, contentLength, expectsPayload, header: "", @@ -8058,11 +8058,11 @@ upgrade: ${upgrade}\r } } } - function writeStream({ h2stream, body, client, request, socket, contentLength, header, expectsPayload }) { + function writeStream({ h2stream, body, client, request: request2, socket, contentLength, header, expectsPayload }) { assert(contentLength !== 0 || client[kRunning] === 0, "stream body cannot be pipelined"); if (client[kHTTPConnVersion] === "h2") { let onPipeData = function(chunk) { - request.onBodySent(chunk); + request2.onBodySent(chunk); }; const pipe = pipeline( body, @@ -8072,7 +8072,7 @@ upgrade: ${upgrade}\r util2.destroy(body, err); util2.destroy(h2stream, err); } else { - request.onRequestSent(); + request2.onRequestSent(); } } ); @@ -8084,7 +8084,7 @@ upgrade: ${upgrade}\r return; } let finished = false; - const writer = new AsyncWriter({ socket, request, contentLength, client, expectsPayload, header }); + const writer = new AsyncWriter({ socket, request: request2, contentLength, client, expectsPayload, header }); const onData = function(chunk) { if (finished) { return; @@ -8140,7 +8140,7 @@ upgrade: ${upgrade}\r } socket.on("drain", onDrain).on("error", onFinished); } - async function writeBlob({ h2stream, body, client, request, socket, contentLength, header, expectsPayload }) { + async function writeBlob({ h2stream, body, client, request: request2, socket, contentLength, header, expectsPayload }) { assert(contentLength === body.size, "blob body must have content length"); const isH2 = client[kHTTPConnVersion] === "h2"; try { @@ -8160,8 +8160,8 @@ upgrade: ${upgrade}\r socket.write(buffer); socket.uncork(); } - request.onBodySent(buffer); - request.onRequestSent(); + request2.onBodySent(buffer); + request2.onRequestSent(); if (!expectsPayload) { socket[kReset] = true; } @@ -8170,7 +8170,7 @@ upgrade: ${upgrade}\r util2.destroy(isH2 ? h2stream : socket, err); } } - async function writeIterable({ h2stream, body, client, request, socket, contentLength, header, expectsPayload }) { + async function writeIterable({ h2stream, body, client, request: request2, socket, contentLength, header, expectsPayload }) { assert(contentLength !== 0 || client[kRunning] === 0, "iterator body cannot be pipelined"); let callback = null; function onDrain() { @@ -8196,7 +8196,7 @@ upgrade: ${upgrade}\r throw socket[kError]; } const res = h2stream.write(chunk); - request.onBodySent(chunk); + request2.onBodySent(chunk); if (!res) { await waitForDrain(); } @@ -8204,14 +8204,14 @@ upgrade: ${upgrade}\r } catch (err) { h2stream.destroy(err); } finally { - request.onRequestSent(); + request2.onRequestSent(); h2stream.end(); h2stream.off("close", onDrain).off("drain", onDrain); } return; } socket.on("close", onDrain).on("drain", onDrain); - const writer = new AsyncWriter({ socket, request, contentLength, client, expectsPayload, header }); + const writer = new AsyncWriter({ socket, request: request2, contentLength, client, expectsPayload, header }); try { for await (const chunk of body) { if (socket[kError]) { @@ -8229,9 +8229,9 @@ upgrade: ${upgrade}\r } } var AsyncWriter = class { - constructor({ socket, request, contentLength, client, expectsPayload, header }) { + constructor({ socket, request: request2, contentLength, client, expectsPayload, header }) { this.socket = socket; - this.request = request; + this.request = request2; this.contentLength = contentLength; this.client = client; this.bytesWritten = 0; @@ -8240,7 +8240,7 @@ upgrade: ${upgrade}\r socket[kWriting] = true; } write(chunk) { - const { socket, request, contentLength, client, bytesWritten, expectsPayload, header } = this; + const { socket, request: request2, contentLength, client, bytesWritten, expectsPayload, header } = this; if (socket[kError]) { throw socket[kError]; } @@ -8279,7 +8279,7 @@ ${len.toString(16)}\r this.bytesWritten += len; const ret = socket.write(chunk); socket.uncork(); - request.onBodySent(chunk); + request2.onBodySent(chunk); if (!ret) { if (socket[kParser].timeout && socket[kParser].timeoutType === TIMEOUT_HEADERS) { if (socket[kParser].timeout.refresh) { @@ -8290,8 +8290,8 @@ ${len.toString(16)}\r return ret; } end() { - const { socket, contentLength, client, bytesWritten, expectsPayload, header, request } = this; - request.onRequestSent(); + const { socket, contentLength, client, bytesWritten, expectsPayload, header, request: request2 } = this; + request2.onRequestSent(); socket[kWriting] = false; if (socket[kError]) { throw socket[kError]; @@ -8334,10 +8334,10 @@ ${len.toString(16)}\r } } }; - function errorRequest(client, request, err) { + function errorRequest(client, request2, err) { try { - request.onError(err); - assert(request.aborted); + request2.onError(err); + assert(request2.aborted); } catch (err2) { client.emit("error", err2); } @@ -8983,7 +8983,7 @@ var require_readable = __commonJS({ var kBody = Symbol("kBody"); var kAbort = Symbol("abort"); var kContentType = Symbol("kContentType"); - var noop = () => { + var noop2 = () => { }; module.exports = class BodyReadable extends Readable { constructor({ @@ -9105,7 +9105,7 @@ var require_readable = __commonJS({ return new Promise((resolve, reject) => { const signalListenerCleanup = signal ? util2.addAbortListener(signal, () => { this.destroy(); - }) : noop; + }) : noop2; this.on("close", function() { signalListenerCleanup(); if (signal && signal.aborted) { @@ -9113,7 +9113,7 @@ var require_readable = __commonJS({ } else { resolve(null); } - }).on("error", noop).on("data", function(chunk) { + }).on("error", noop2).on("data", function(chunk) { limit -= chunk.length; if (limit <= 0) { this.destroy(); @@ -9443,10 +9443,10 @@ var require_api_request = __commonJS({ } } }; - function request(opts, callback) { + function request2(opts, callback) { if (callback === void 0) { return new Promise((resolve, reject) => { - request.call(this, opts, (err, data) => { + request2.call(this, opts, (err, data) => { return err ? reject(err) : resolve(data); }); }); @@ -9461,7 +9461,7 @@ var require_api_request = __commonJS({ queueMicrotask(() => callback(err, { opaque })); } } - module.exports = request; + module.exports = request2; module.exports.RequestHandler = RequestHandler; } }); @@ -10175,7 +10175,7 @@ var require_mock_utils = __commonJS({ const headersMatch = matchHeaders(mockDispatch2, headers); return pathMatch && methodMatch && bodyMatch && headersMatch; } - function getResponseData(data) { + function getResponseData2(data) { if (Buffer.isBuffer(data)) { return data; } else if (typeof data === "object") { @@ -10280,7 +10280,7 @@ var require_mock_utils = __commonJS({ body.then((newData) => handleReply(mockDispatches, newData)); return; } - const responseData = getResponseData(body); + const responseData = getResponseData2(body); const responseHeaders = generateKeyValues(headers); const responseTrailers = generateKeyValues(trailers); handler.abort = nop; @@ -10337,7 +10337,7 @@ var require_mock_utils = __commonJS({ } } module.exports = { - getResponseData, + getResponseData: getResponseData2, getMockDispatch, addMockDispatch, deleteMockDispatch, @@ -10359,7 +10359,7 @@ var require_mock_utils = __commonJS({ var require_mock_interceptor = __commonJS({ "node_modules/undici/lib/mock/mock-interceptor.js"(exports, module) { "use strict"; - var { getResponseData, buildKey, addMockDispatch } = require_mock_utils(); + var { getResponseData: getResponseData2, buildKey, addMockDispatch } = require_mock_utils(); var { kDispatches, kDispatchKey, @@ -10431,7 +10431,7 @@ var require_mock_interceptor = __commonJS({ this[kContentLength] = false; } createMockScopeDispatchData(statusCode, data, responseOptions = {}) { - const responseData = getResponseData(data); + const responseData = getResponseData2(data); const contentLength = this[kContentLength] ? { "content-length": responseData.length } : {}; const headers = { ...this[kDefaultHeaders], ...contentLength, ...responseOptions.headers }; const trailers = { ...this[kDefaultTrailers], ...responseOptions.trailers }; @@ -12138,7 +12138,7 @@ var require_request2 = __commonJS({ policyContainer: makePolicyContainer() } }; - let request = null; + let request2 = null; let fallbackMode = null; const baseUrl = this[kRealm].settingsObject.baseUrl; let signal = null; @@ -12154,17 +12154,17 @@ var require_request2 = __commonJS({ "Request cannot be constructed from a URL that includes credentials: " + input ); } - request = makeRequest({ urlList: [parsedURL] }); + request2 = makeRequest({ urlList: [parsedURL] }); fallbackMode = "cors"; } else { assert(input instanceof _Request); - request = input[kState]; + request2 = input[kState]; signal = input[kSignal]; } const origin = this[kRealm].settingsObject.origin; let window = "client"; - if (request.window?.constructor?.name === "EnvironmentSettingsObject" && sameOrigin(request.window, origin)) { - window = request.window; + if (request2.window?.constructor?.name === "EnvironmentSettingsObject" && sameOrigin(request2.window, origin)) { + window = request2.window; } if (init.window != null) { throw new TypeError(`'window' option '${window}' must be null`); @@ -12172,66 +12172,66 @@ var require_request2 = __commonJS({ if ("window" in init) { window = "no-window"; } - request = makeRequest({ + request2 = makeRequest({ // URL request’s URL. // undici implementation note: this is set as the first item in request's urlList in makeRequest // method request’s method. - method: request.method, + method: request2.method, // header list A copy of request’s header list. // undici implementation note: headersList is cloned in makeRequest - headersList: request.headersList, + headersList: request2.headersList, // unsafe-request flag Set. - unsafeRequest: request.unsafeRequest, + unsafeRequest: request2.unsafeRequest, // client This’s relevant settings object. client: this[kRealm].settingsObject, // window window. window, // priority request’s priority. - priority: request.priority, + priority: request2.priority, // origin request’s origin. The propagation of the origin is only significant for navigation requests // being handled by a service worker. In this scenario a request can have an origin that is different // from the current client. - origin: request.origin, + origin: request2.origin, // referrer request’s referrer. - referrer: request.referrer, + referrer: request2.referrer, // referrer policy request’s referrer policy. - referrerPolicy: request.referrerPolicy, + referrerPolicy: request2.referrerPolicy, // mode request’s mode. - mode: request.mode, + mode: request2.mode, // credentials mode request’s credentials mode. - credentials: request.credentials, + credentials: request2.credentials, // cache mode request’s cache mode. - cache: request.cache, + cache: request2.cache, // redirect mode request’s redirect mode. - redirect: request.redirect, + redirect: request2.redirect, // integrity metadata request’s integrity metadata. - integrity: request.integrity, + integrity: request2.integrity, // keepalive request’s keepalive. - keepalive: request.keepalive, + keepalive: request2.keepalive, // reload-navigation flag request’s reload-navigation flag. - reloadNavigation: request.reloadNavigation, + reloadNavigation: request2.reloadNavigation, // history-navigation flag request’s history-navigation flag. - historyNavigation: request.historyNavigation, + historyNavigation: request2.historyNavigation, // URL list A clone of request’s URL list. - urlList: [...request.urlList] + urlList: [...request2.urlList] }); const initHasKey = Object.keys(init).length !== 0; if (initHasKey) { - if (request.mode === "navigate") { - request.mode = "same-origin"; + if (request2.mode === "navigate") { + request2.mode = "same-origin"; } - request.reloadNavigation = false; - request.historyNavigation = false; - request.origin = "client"; - request.referrer = "client"; - request.referrerPolicy = ""; - request.url = request.urlList[request.urlList.length - 1]; - request.urlList = [request.url]; + request2.reloadNavigation = false; + request2.historyNavigation = false; + request2.origin = "client"; + request2.referrer = "client"; + request2.referrerPolicy = ""; + request2.url = request2.urlList[request2.urlList.length - 1]; + request2.urlList = [request2.url]; } if (init.referrer !== void 0) { const referrer = init.referrer; if (referrer === "") { - request.referrer = "no-referrer"; + request2.referrer = "no-referrer"; } else { let parsedReferrer; try { @@ -12240,14 +12240,14 @@ var require_request2 = __commonJS({ throw new TypeError(`Referrer "${referrer}" is not a valid URL.`, { cause: err }); } if (parsedReferrer.protocol === "about:" && parsedReferrer.hostname === "client" || origin && !sameOrigin(parsedReferrer, this[kRealm].settingsObject.baseUrl)) { - request.referrer = "client"; + request2.referrer = "client"; } else { - request.referrer = parsedReferrer; + request2.referrer = parsedReferrer; } } } if (init.referrerPolicy !== void 0) { - request.referrerPolicy = init.referrerPolicy; + request2.referrerPolicy = init.referrerPolicy; } let mode; if (init.mode !== void 0) { @@ -12262,27 +12262,27 @@ var require_request2 = __commonJS({ }); } if (mode != null) { - request.mode = mode; + request2.mode = mode; } if (init.credentials !== void 0) { - request.credentials = init.credentials; + request2.credentials = init.credentials; } if (init.cache !== void 0) { - request.cache = init.cache; + request2.cache = init.cache; } - if (request.cache === "only-if-cached" && request.mode !== "same-origin") { + if (request2.cache === "only-if-cached" && request2.mode !== "same-origin") { throw new TypeError( "'only-if-cached' can be set only with 'same-origin' mode" ); } if (init.redirect !== void 0) { - request.redirect = init.redirect; + request2.redirect = init.redirect; } if (init.integrity != null) { - request.integrity = String(init.integrity); + request2.integrity = String(init.integrity); } if (init.keepalive !== void 0) { - request.keepalive = Boolean(init.keepalive); + request2.keepalive = Boolean(init.keepalive); } if (init.method !== void 0) { let method = init.method; @@ -12293,12 +12293,12 @@ var require_request2 = __commonJS({ throw new TypeError(`'${method}' HTTP method is unsupported.`); } method = normalizeMethodRecord[method] ?? normalizeMethod(method); - request.method = method; + request2.method = method; } if (init.signal !== void 0) { signal = init.signal; } - this[kState] = request; + this[kState] = request2; const ac = new AbortController(); this[kSignal] = ac.signal; this[kSignal][kRealm] = this[kRealm]; @@ -12332,13 +12332,13 @@ var require_request2 = __commonJS({ } } this[kHeaders] = new Headers(kConstruct); - this[kHeaders][kHeadersList] = request.headersList; + this[kHeaders][kHeadersList] = request2.headersList; this[kHeaders][kGuard] = "request"; this[kHeaders][kRealm] = this[kRealm]; if (mode === "no-cors") { - if (!corsSafeListedMethodsSet.has(request.method)) { + if (!corsSafeListedMethodsSet.has(request2.method)) { throw new TypeError( - `'${request.method} is unsupported in no-cors mode.` + `'${request2.method} is unsupported in no-cors mode.` ); } this[kHeaders][kGuard] = "request-no-cors"; @@ -12357,14 +12357,14 @@ var require_request2 = __commonJS({ } } const inputBody = input instanceof _Request ? input[kState].body : null; - if ((init.body != null || inputBody != null) && (request.method === "GET" || request.method === "HEAD")) { + if ((init.body != null || inputBody != null) && (request2.method === "GET" || request2.method === "HEAD")) { throw new TypeError("Request with GET/HEAD method cannot have body."); } let initBody = null; if (init.body != null) { const [extractedBody, contentType] = extractBody( init.body, - request.keepalive + request2.keepalive ); initBody = extractedBody; if (contentType && !this[kHeaders][kHeadersList].contains("content-type")) { @@ -12376,12 +12376,12 @@ var require_request2 = __commonJS({ if (initBody != null && init.duplex == null) { throw new TypeError("RequestInit: duplex option is required when sending a body."); } - if (request.mode !== "same-origin" && request.mode !== "cors") { + if (request2.mode !== "same-origin" && request2.mode !== "cors") { throw new TypeError( 'If request is made from ReadableStream, mode should be "same-origin" or "cors"' ); } - request.useCORSPreflightFlag = true; + request2.useCORSPreflightFlag = true; } let finalBody = inputOrInitBody; if (initBody == null && inputBody != null) { @@ -12551,7 +12551,7 @@ var require_request2 = __commonJS({ }; mixinBody(Request); function makeRequest(init) { - const request = { + const request2 = { method: "GET", localURLsOnly: false, unsafeRequest: false, @@ -12590,13 +12590,13 @@ var require_request2 = __commonJS({ ...init, headersList: init.headersList ? new HeadersList(init.headersList) : new HeadersList() }; - request.url = request.urlList[0]; - return request; + request2.url = request2.urlList[0]; + return request2; } - function cloneRequest(request) { - const newRequest = makeRequest({ ...request, body: null }); - if (request.body != null) { - newRequest.body = cloneBody(request.body); + function cloneRequest(request2) { + const newRequest = makeRequest({ ...request2, body: null }); + if (request2.body != null) { + newRequest.body = cloneBody(request2.body); } return newRequest; } @@ -12829,14 +12829,14 @@ var require_fetch = __commonJS({ p.reject(e); return p.promise; } - const request = requestObject[kState]; + const request2 = requestObject[kState]; if (requestObject.signal.aborted) { - abortFetch(p, request, null, requestObject.signal.reason); + abortFetch(p, request2, null, requestObject.signal.reason); return p.promise; } - const globalObject = request.client.globalObject; + const globalObject = request2.client.globalObject; if (globalObject?.constructor?.name === "ServiceWorkerGlobalScope") { - request.serviceWorkers = "none"; + request2.serviceWorkers = "none"; } let responseObject = null; const relevantRealm = null; @@ -12848,7 +12848,7 @@ var require_fetch = __commonJS({ locallyAborted = true; assert(controller != null); controller.abort(requestObject.signal.reason); - abortFetch(p, request, responseObject, requestObject.signal.reason); + abortFetch(p, request2, responseObject, requestObject.signal.reason); } ); const handleFetchDone = (response) => finalizeAndReportTiming(response, "fetch"); @@ -12857,7 +12857,7 @@ var require_fetch = __commonJS({ return Promise.resolve(); } if (response.aborted) { - abortFetch(p, request, responseObject, controller.serializedAbortReason); + abortFetch(p, request2, responseObject, controller.serializedAbortReason); return Promise.resolve(); } if (response.type === "error") { @@ -12875,7 +12875,7 @@ var require_fetch = __commonJS({ p.resolve(responseObject); }; controller = fetching({ - request, + request: request2, processResponseEndOfBody: handleFetchDone, processResponse, dispatcher: init.dispatcher ?? getGlobalDispatcher() @@ -12920,13 +12920,13 @@ var require_fetch = __commonJS({ performance.markResourceTiming(timingInfo, originalURL.href, initiatorType, globalThis2, cacheState); } } - function abortFetch(p, request, responseObject, error2) { + function abortFetch(p, request2, responseObject, error2) { if (!error2) { error2 = new DOMException2("The operation was aborted.", "AbortError"); } p.reject(error2); - if (request.body != null && isReadable(request.body?.stream)) { - request.body.stream.cancel(error2).catch((err) => { + if (request2.body != null && isReadable(request2.body?.stream)) { + request2.body.stream.cancel(error2).catch((err) => { if (err.code === "ERR_INVALID_STATE") { return; } @@ -12947,7 +12947,7 @@ var require_fetch = __commonJS({ } } function fetching({ - request, + request: request2, processRequestBodyChunkLength, processRequestEndOfBody, processResponse, @@ -12959,9 +12959,9 @@ var require_fetch = __commonJS({ }) { let taskDestination = null; let crossOriginIsolatedCapability = false; - if (request.client != null) { - taskDestination = request.client.globalObject; - crossOriginIsolatedCapability = request.client.crossOriginIsolatedCapability; + if (request2.client != null) { + taskDestination = request2.client.globalObject; + crossOriginIsolatedCapability = request2.client.crossOriginIsolatedCapability; } const currenTime = coarsenedSharedCurrentTime(crossOriginIsolatedCapability); const timingInfo = createOpaqueTimingInfo({ @@ -12969,7 +12969,7 @@ var require_fetch = __commonJS({ }); const fetchParams = { controller: new Fetch(dispatcher), - request, + request: request2, timingInfo, processRequestBodyChunkLength, processRequestEndOfBody, @@ -12979,32 +12979,32 @@ var require_fetch = __commonJS({ taskDestination, crossOriginIsolatedCapability }; - assert(!request.body || request.body.stream); - if (request.window === "client") { - request.window = request.client?.globalObject?.constructor?.name === "Window" ? request.client : "no-window"; + assert(!request2.body || request2.body.stream); + if (request2.window === "client") { + request2.window = request2.client?.globalObject?.constructor?.name === "Window" ? request2.client : "no-window"; } - if (request.origin === "client") { - request.origin = request.client?.origin; + if (request2.origin === "client") { + request2.origin = request2.client?.origin; } - if (request.policyContainer === "client") { - if (request.client != null) { - request.policyContainer = clonePolicyContainer( - request.client.policyContainer + if (request2.policyContainer === "client") { + if (request2.client != null) { + request2.policyContainer = clonePolicyContainer( + request2.client.policyContainer ); } else { - request.policyContainer = makePolicyContainer(); + request2.policyContainer = makePolicyContainer(); } } - if (!request.headersList.contains("accept")) { + if (!request2.headersList.contains("accept")) { const value = "*/*"; - request.headersList.append("accept", value); + request2.headersList.append("accept", value); } - if (!request.headersList.contains("accept-language")) { - request.headersList.append("accept-language", "*"); + if (!request2.headersList.contains("accept-language")) { + request2.headersList.append("accept-language", "*"); } - if (request.priority === null) { + if (request2.priority === null) { } - if (subresourceSet.has(request.destination)) { + if (subresourceSet.has(request2.destination)) { } mainFetch(fetchParams).catch((err) => { fetchParams.controller.terminate(err); @@ -13012,50 +13012,50 @@ var require_fetch = __commonJS({ return fetchParams.controller; } async function mainFetch(fetchParams, recursive = false) { - const request = fetchParams.request; + const request2 = fetchParams.request; let response = null; - if (request.localURLsOnly && !urlIsLocal(requestCurrentURL(request))) { + if (request2.localURLsOnly && !urlIsLocal(requestCurrentURL(request2))) { response = makeNetworkError("local URLs only"); } - tryUpgradeRequestToAPotentiallyTrustworthyURL(request); - if (requestBadPort(request) === "blocked") { + tryUpgradeRequestToAPotentiallyTrustworthyURL(request2); + if (requestBadPort(request2) === "blocked") { response = makeNetworkError("bad port"); } - if (request.referrerPolicy === "") { - request.referrerPolicy = request.policyContainer.referrerPolicy; + if (request2.referrerPolicy === "") { + request2.referrerPolicy = request2.policyContainer.referrerPolicy; } - if (request.referrer !== "no-referrer") { - request.referrer = determineRequestsReferrer(request); + if (request2.referrer !== "no-referrer") { + request2.referrer = determineRequestsReferrer(request2); } if (response === null) { response = await (async () => { - const currentURL = requestCurrentURL(request); + const currentURL = requestCurrentURL(request2); if ( // - request’s current URL’s origin is same origin with request’s origin, // and request’s response tainting is "basic" - sameOrigin(currentURL, request.url) && request.responseTainting === "basic" || // request’s current URL’s scheme is "data" + sameOrigin(currentURL, request2.url) && request2.responseTainting === "basic" || // request’s current URL’s scheme is "data" currentURL.protocol === "data:" || // - request’s mode is "navigate" or "websocket" - (request.mode === "navigate" || request.mode === "websocket") + (request2.mode === "navigate" || request2.mode === "websocket") ) { - request.responseTainting = "basic"; + request2.responseTainting = "basic"; return await schemeFetch(fetchParams); } - if (request.mode === "same-origin") { + if (request2.mode === "same-origin") { return makeNetworkError('request mode cannot be "same-origin"'); } - if (request.mode === "no-cors") { - if (request.redirect !== "follow") { + if (request2.mode === "no-cors") { + if (request2.redirect !== "follow") { return makeNetworkError( 'redirect mode cannot be "follow" for "no-cors" request' ); } - request.responseTainting = "opaque"; + request2.responseTainting = "opaque"; return await schemeFetch(fetchParams); } - if (!urlIsHttpHttpsScheme(requestCurrentURL(request))) { + if (!urlIsHttpHttpsScheme(requestCurrentURL(request2))) { return makeNetworkError("URL scheme must be a HTTP(S) scheme"); } - request.responseTainting = "cors"; + request2.responseTainting = "cors"; return await httpFetch(fetchParams); })(); } @@ -13063,13 +13063,13 @@ var require_fetch = __commonJS({ return response; } if (response.status !== 0 && !response.internalResponse) { - if (request.responseTainting === "cors") { + if (request2.responseTainting === "cors") { } - if (request.responseTainting === "basic") { + if (request2.responseTainting === "basic") { response = filterResponse(response, "basic"); - } else if (request.responseTainting === "cors") { + } else if (request2.responseTainting === "cors") { response = filterResponse(response, "cors"); - } else if (request.responseTainting === "opaque") { + } else if (request2.responseTainting === "opaque") { response = filterResponse(response, "opaque"); } else { assert(false); @@ -13077,26 +13077,26 @@ var require_fetch = __commonJS({ } let internalResponse = response.status === 0 ? response : response.internalResponse; if (internalResponse.urlList.length === 0) { - internalResponse.urlList.push(...request.urlList); + internalResponse.urlList.push(...request2.urlList); } - if (!request.timingAllowFailed) { + if (!request2.timingAllowFailed) { response.timingAllowPassed = true; } - if (response.type === "opaque" && internalResponse.status === 206 && internalResponse.rangeRequested && !request.headers.contains("range")) { + if (response.type === "opaque" && internalResponse.status === 206 && internalResponse.rangeRequested && !request2.headers.contains("range")) { response = internalResponse = makeNetworkError(); } - if (response.status !== 0 && (request.method === "HEAD" || request.method === "CONNECT" || nullBodyStatus.includes(internalResponse.status))) { + if (response.status !== 0 && (request2.method === "HEAD" || request2.method === "CONNECT" || nullBodyStatus.includes(internalResponse.status))) { internalResponse.body = null; fetchParams.controller.dump = true; } - if (request.integrity) { + if (request2.integrity) { const processBodyError = (reason) => fetchFinale(fetchParams, makeNetworkError(reason)); - if (request.responseTainting === "opaque" || response.body == null) { + if (request2.responseTainting === "opaque" || response.body == null) { processBodyError(response.error); return; } const processBody = (bytes) => { - if (!bytesMatch(bytes, request.integrity)) { + if (!bytesMatch(bytes, request2.integrity)) { processBodyError("integrity mismatch"); return; } @@ -13112,8 +13112,8 @@ var require_fetch = __commonJS({ if (isCancelled(fetchParams) && fetchParams.request.redirectCount === 0) { return Promise.resolve(makeAppropriateNetworkError(fetchParams)); } - const { request } = fetchParams; - const { protocol: scheme } = requestCurrentURL(request); + const { request: request2 } = fetchParams; + const { protocol: scheme } = requestCurrentURL(request2); switch (scheme) { case "about:": { return Promise.resolve(makeNetworkError("about scheme is not supported")); @@ -13122,12 +13122,12 @@ var require_fetch = __commonJS({ if (!resolveObjectURL) { resolveObjectURL = __require("buffer").resolveObjectURL; } - const blobURLEntry = requestCurrentURL(request); + const blobURLEntry = requestCurrentURL(request2); if (blobURLEntry.search.length !== 0) { return Promise.resolve(makeNetworkError("NetworkError when attempting to fetch resource.")); } const blobURLEntryObject = resolveObjectURL(blobURLEntry.toString()); - if (request.method !== "GET" || !isBlobLike(blobURLEntryObject)) { + if (request2.method !== "GET" || !isBlobLike(blobURLEntryObject)) { return Promise.resolve(makeNetworkError("invalid method")); } const bodyWithType = safelyExtractBody(blobURLEntryObject); @@ -13145,7 +13145,7 @@ var require_fetch = __commonJS({ return Promise.resolve(response); } case "data:": { - const currentURL = requestCurrentURL(request); + const currentURL = requestCurrentURL(request2); const dataURLStruct = dataURLProcessor(currentURL); if (dataURLStruct === "failure") { return Promise.resolve(makeNetworkError("failed to fetch the data URL")); @@ -13227,41 +13227,41 @@ var require_fetch = __commonJS({ } } async function httpFetch(fetchParams) { - const request = fetchParams.request; + const request2 = fetchParams.request; let response = null; let actualResponse = null; const timingInfo = fetchParams.timingInfo; - if (request.serviceWorkers === "all") { + if (request2.serviceWorkers === "all") { } if (response === null) { - if (request.redirect === "follow") { - request.serviceWorkers = "none"; + if (request2.redirect === "follow") { + request2.serviceWorkers = "none"; } actualResponse = response = await httpNetworkOrCacheFetch(fetchParams); - if (request.responseTainting === "cors" && corsCheck(request, response) === "failure") { + if (request2.responseTainting === "cors" && corsCheck(request2, response) === "failure") { return makeNetworkError("cors failure"); } - if (TAOCheck(request, response) === "failure") { - request.timingAllowFailed = true; + if (TAOCheck(request2, response) === "failure") { + request2.timingAllowFailed = true; } } - if ((request.responseTainting === "opaque" || response.type === "opaque") && crossOriginResourcePolicyCheck( - request.origin, - request.client, - request.destination, + if ((request2.responseTainting === "opaque" || response.type === "opaque") && crossOriginResourcePolicyCheck( + request2.origin, + request2.client, + request2.destination, actualResponse ) === "blocked") { return makeNetworkError("blocked"); } if (redirectStatusSet.has(actualResponse.status)) { - if (request.redirect !== "manual") { + if (request2.redirect !== "manual") { fetchParams.controller.connection.destroy(); } - if (request.redirect === "error") { + if (request2.redirect === "error") { response = makeNetworkError("unexpected redirect"); - } else if (request.redirect === "manual") { + } else if (request2.redirect === "manual") { response = actualResponse; - } else if (request.redirect === "follow") { + } else if (request2.redirect === "follow") { response = await httpRedirectFetch(fetchParams, response); } else { assert(false); @@ -13271,13 +13271,13 @@ var require_fetch = __commonJS({ return response; } function httpRedirectFetch(fetchParams, response) { - const request = fetchParams.request; + const request2 = fetchParams.request; const actualResponse = response.internalResponse ? response.internalResponse : response; let locationURL; try { locationURL = responseLocationURL( actualResponse, - requestCurrentURL(request).hash + requestCurrentURL(request2).hash ); if (locationURL == null) { return response; @@ -13288,63 +13288,63 @@ var require_fetch = __commonJS({ if (!urlIsHttpHttpsScheme(locationURL)) { return Promise.resolve(makeNetworkError("URL scheme must be a HTTP(S) scheme")); } - if (request.redirectCount === 20) { + if (request2.redirectCount === 20) { return Promise.resolve(makeNetworkError("redirect count exceeded")); } - request.redirectCount += 1; - if (request.mode === "cors" && (locationURL.username || locationURL.password) && !sameOrigin(request, locationURL)) { + request2.redirectCount += 1; + if (request2.mode === "cors" && (locationURL.username || locationURL.password) && !sameOrigin(request2, locationURL)) { return Promise.resolve(makeNetworkError('cross origin not allowed for request mode "cors"')); } - if (request.responseTainting === "cors" && (locationURL.username || locationURL.password)) { + if (request2.responseTainting === "cors" && (locationURL.username || locationURL.password)) { return Promise.resolve(makeNetworkError( 'URL cannot contain credentials for request mode "cors"' )); } - if (actualResponse.status !== 303 && request.body != null && request.body.source == null) { + if (actualResponse.status !== 303 && request2.body != null && request2.body.source == null) { return Promise.resolve(makeNetworkError()); } - if ([301, 302].includes(actualResponse.status) && request.method === "POST" || actualResponse.status === 303 && !GET_OR_HEAD.includes(request.method)) { - request.method = "GET"; - request.body = null; + if ([301, 302].includes(actualResponse.status) && request2.method === "POST" || actualResponse.status === 303 && !GET_OR_HEAD.includes(request2.method)) { + request2.method = "GET"; + request2.body = null; for (const headerName of requestBodyHeader) { - request.headersList.delete(headerName); + request2.headersList.delete(headerName); } } - if (!sameOrigin(requestCurrentURL(request), locationURL)) { - request.headersList.delete("authorization"); - request.headersList.delete("proxy-authorization", true); - request.headersList.delete("cookie"); - request.headersList.delete("host"); + if (!sameOrigin(requestCurrentURL(request2), locationURL)) { + request2.headersList.delete("authorization"); + request2.headersList.delete("proxy-authorization", true); + request2.headersList.delete("cookie"); + request2.headersList.delete("host"); } - if (request.body != null) { - assert(request.body.source != null); - request.body = safelyExtractBody(request.body.source)[0]; + if (request2.body != null) { + assert(request2.body.source != null); + request2.body = safelyExtractBody(request2.body.source)[0]; } const timingInfo = fetchParams.timingInfo; timingInfo.redirectEndTime = timingInfo.postRedirectStartTime = coarsenedSharedCurrentTime(fetchParams.crossOriginIsolatedCapability); if (timingInfo.redirectStartTime === 0) { timingInfo.redirectStartTime = timingInfo.startTime; } - request.urlList.push(locationURL); - setRequestReferrerPolicyOnRedirect(request, actualResponse); + request2.urlList.push(locationURL); + setRequestReferrerPolicyOnRedirect(request2, actualResponse); return mainFetch(fetchParams, true); } async function httpNetworkOrCacheFetch(fetchParams, isAuthenticationFetch = false, isNewConnectionFetch = false) { - const request = fetchParams.request; + const request2 = fetchParams.request; let httpFetchParams = null; let httpRequest = null; let response = null; const httpCache = null; const revalidatingFlag = false; - if (request.window === "no-window" && request.redirect === "error") { + if (request2.window === "no-window" && request2.redirect === "error") { httpFetchParams = fetchParams; - httpRequest = request; + httpRequest = request2; } else { - httpRequest = makeRequest(request); + httpRequest = makeRequest(request2); httpFetchParams = { ...fetchParams }; httpFetchParams.request = httpRequest; } - const includeCredentials = request.credentials === "include" || request.credentials === "same-origin" && request.responseTainting === "basic"; + const includeCredentials = request2.credentials === "include" || request2.credentials === "same-origin" && request2.responseTainting === "basic"; const contentLength = httpRequest.body ? httpRequest.body.length : null; let contentLengthHeaderValue = null; if (httpRequest.body == null && ["POST", "PUT"].includes(httpRequest.method)) { @@ -13421,7 +13421,7 @@ var require_fetch = __commonJS({ } response.requestIncludesCredentials = includeCredentials; if (response.status === 407) { - if (request.window === "no-window") { + if (request2.window === "no-window") { return makeNetworkError(); } if (isCancelled(fetchParams)) { @@ -13433,7 +13433,7 @@ var require_fetch = __commonJS({ // response’s status is 421 response.status === 421 && // isNewConnectionFetch is false !isNewConnectionFetch && // request’s body is null, or request’s body is non-null and request’s body’s source is non-null - (request.body == null || request.body.source != null) + (request2.body == null || request2.body.source != null) ) { if (isCancelled(fetchParams)) { return makeAppropriateNetworkError(fetchParams); @@ -13461,21 +13461,21 @@ var require_fetch = __commonJS({ } } }; - const request = fetchParams.request; + const request2 = fetchParams.request; let response = null; const timingInfo = fetchParams.timingInfo; const httpCache = null; if (httpCache == null) { - request.cache = "no-store"; + request2.cache = "no-store"; } const newConnection = forceNewConnection ? "yes" : "no"; - if (request.mode === "websocket") { + if (request2.mode === "websocket") { } else { } let requestBody = null; - if (request.body == null && fetchParams.processRequestEndOfBody) { + if (request2.body == null && fetchParams.processRequestEndOfBody) { queueMicrotask(() => fetchParams.processRequestEndOfBody()); - } else if (request.body != null) { + } else if (request2.body != null) { const processBodyChunk = async function* (bytes) { if (isCancelled(fetchParams)) { return; @@ -13503,7 +13503,7 @@ var require_fetch = __commonJS({ }; requestBody = async function* () { try { - for await (const bytes of request.body.stream) { + for await (const bytes of request2.body.stream) { yield* processBodyChunk(bytes); } processEndOfBody(); @@ -13615,17 +13615,17 @@ var require_fetch = __commonJS({ } return response; async function dispatch({ body }) { - const url = requestCurrentURL(request); + const url = requestCurrentURL(request2); const agent = fetchParams.controller.dispatcher; return new Promise((resolve, reject) => agent.dispatch( { path: url.pathname + url.search, origin: url.origin, - method: request.method, - body: fetchParams.controller.dispatcher.isMockActive ? request.body && (request.body.source || request.body.stream) : body, - headers: request.headersList.entries, + method: request2.method, + body: fetchParams.controller.dispatcher.isMockActive ? request2.body && (request2.body.source || request2.body.stream) : body, + headers: request2.headersList.entries, maxRedirections: 0, - upgrade: request.mode === "websocket" ? "websocket" : void 0 + upgrade: request2.mode === "websocket" ? "websocket" : void 0 }, { body: null, @@ -13671,8 +13671,8 @@ var require_fetch = __commonJS({ } this.body = new Readable({ read: resume }); const decoders = []; - const willFollow = request.redirect === "follow" && location && redirectStatusSet.has(status); - if (request.method !== "HEAD" && request.method !== "CONNECT" && !nullBodyStatus.includes(status) && !willFollow) { + const willFollow = request2.redirect === "follow" && location && redirectStatusSet.has(status); + if (request2.method !== "HEAD" && request2.method !== "CONNECT" && !nullBodyStatus.includes(status) && !willFollow) { for (const coding of codings) { if (coding === "x-gzip" || coding === "gzip") { decoders.push(zlib.createGunzip({ @@ -14642,35 +14642,35 @@ var require_cache = __commonJS({ } this.#relevantRequestResponseList = arguments[1]; } - async match(request, options = {}) { + async match(request2, options = {}) { webidl.brandCheck(this, _Cache); webidl.argumentLengthCheck(arguments, 1, { header: "Cache.match" }); - request = webidl.converters.RequestInfo(request); + request2 = webidl.converters.RequestInfo(request2); options = webidl.converters.CacheQueryOptions(options); - const p = await this.matchAll(request, options); + const p = await this.matchAll(request2, options); if (p.length === 0) { return; } return p[0]; } - async matchAll(request = void 0, options = {}) { + async matchAll(request2 = void 0, options = {}) { webidl.brandCheck(this, _Cache); - if (request !== void 0) - request = webidl.converters.RequestInfo(request); + if (request2 !== void 0) + request2 = webidl.converters.RequestInfo(request2); options = webidl.converters.CacheQueryOptions(options); let r = null; - if (request !== void 0) { - if (request instanceof Request) { - r = request[kState]; + if (request2 !== void 0) { + if (request2 instanceof Request) { + r = request2[kState]; if (r.method !== "GET" && !options.ignoreMethod) { return []; } - } else if (typeof request === "string") { - r = new Request(request)[kState]; + } else if (typeof request2 === "string") { + r = new Request(request2)[kState]; } } const responses = []; - if (request === void 0) { + if (request2 === void 0) { for (const requestResponse of this.#relevantRequestResponseList) { responses.push(requestResponse[1]); } @@ -14692,11 +14692,11 @@ var require_cache = __commonJS({ } return Object.freeze(responseList); } - async add(request) { + async add(request2) { webidl.brandCheck(this, _Cache); webidl.argumentLengthCheck(arguments, 1, { header: "Cache.add" }); - request = webidl.converters.RequestInfo(request); - const requests = [request]; + request2 = webidl.converters.RequestInfo(request2); + const requests = [request2]; const responseArrayPromise = this.addAll(requests); return await responseArrayPromise; } @@ -14706,11 +14706,11 @@ var require_cache = __commonJS({ requests = webidl.converters["sequence"](requests); const responsePromises = []; const requestList = []; - for (const request of requests) { - if (typeof request === "string") { + for (const request2 of requests) { + if (typeof request2 === "string") { continue; } - const r = request[kState]; + const r = request2[kState]; if (!urlIsHttpHttpsScheme(r.url) || r.method !== "GET") { throw webidl.errors.exception({ header: "Cache.addAll", @@ -14719,8 +14719,8 @@ var require_cache = __commonJS({ } } const fetchControllers = []; - for (const request of requests) { - const r = new Request(request)[kState]; + for (const request2 of requests) { + const r = new Request(request2)[kState]; if (!urlIsHttpHttpsScheme(r.url)) { throw webidl.errors.exception({ header: "Cache.addAll", @@ -14798,16 +14798,16 @@ var require_cache = __commonJS({ }); return cacheJobPromise.promise; } - async put(request, response) { + async put(request2, response) { webidl.brandCheck(this, _Cache); webidl.argumentLengthCheck(arguments, 2, { header: "Cache.put" }); - request = webidl.converters.RequestInfo(request); + request2 = webidl.converters.RequestInfo(request2); response = webidl.converters.Response(response); let innerRequest = null; - if (request instanceof Request) { - innerRequest = request[kState]; + if (request2 instanceof Request) { + innerRequest = request2[kState]; } else { - innerRequest = new Request(request)[kState]; + innerRequest = new Request(request2)[kState]; } if (!urlIsHttpHttpsScheme(innerRequest.url) || innerRequest.method !== "GET") { throw webidl.errors.exception({ @@ -14878,20 +14878,20 @@ var require_cache = __commonJS({ }); return cacheJobPromise.promise; } - async delete(request, options = {}) { + async delete(request2, options = {}) { webidl.brandCheck(this, _Cache); webidl.argumentLengthCheck(arguments, 1, { header: "Cache.delete" }); - request = webidl.converters.RequestInfo(request); + request2 = webidl.converters.RequestInfo(request2); options = webidl.converters.CacheQueryOptions(options); let r = null; - if (request instanceof Request) { - r = request[kState]; + if (request2 instanceof Request) { + r = request2[kState]; if (r.method !== "GET" && !options.ignoreMethod) { return false; } } else { - assert(typeof request === "string"); - r = new Request(request)[kState]; + assert(typeof request2 === "string"); + r = new Request(request2)[kState]; } const operations = []; const operation = { @@ -14923,25 +14923,25 @@ var require_cache = __commonJS({ * @param {import('../../types/cache').CacheQueryOptions} options * @returns {readonly Request[]} */ - async keys(request = void 0, options = {}) { + async keys(request2 = void 0, options = {}) { webidl.brandCheck(this, _Cache); - if (request !== void 0) - request = webidl.converters.RequestInfo(request); + if (request2 !== void 0) + request2 = webidl.converters.RequestInfo(request2); options = webidl.converters.CacheQueryOptions(options); let r = null; - if (request !== void 0) { - if (request instanceof Request) { - r = request[kState]; + if (request2 !== void 0) { + if (request2 instanceof Request) { + r = request2[kState]; if (r.method !== "GET" && !options.ignoreMethod) { return []; } - } else if (typeof request === "string") { - r = new Request(request)[kState]; + } else if (typeof request2 === "string") { + r = new Request(request2)[kState]; } } const promise = createDeferredPromise(); const requests = []; - if (request === void 0) { + if (request2 === void 0) { for (const requestResponse of this.#relevantRequestResponseList) { requests.push(requestResponse[0]); } @@ -14953,12 +14953,12 @@ var require_cache = __commonJS({ } queueMicrotask(() => { const requestList = []; - for (const request2 of requests) { + for (const request3 of requests) { const requestObject = new Request("https://a"); - requestObject[kState] = request2; - requestObject[kHeaders][kHeadersList] = request2.headersList; + requestObject[kState] = request3; + requestObject[kHeaders][kHeadersList] = request3.headersList; requestObject[kHeaders][kGuard] = "immutable"; - requestObject[kRealm] = request2.client; + requestObject[kRealm] = request3.client; requestList.push(requestObject); } promise.resolve(Object.freeze(requestList)); @@ -15073,9 +15073,9 @@ var require_cache = __commonJS({ * @param {import('../../types/cache').CacheQueryOptions | undefined} options * @returns {boolean} */ - #requestMatchesCachedItem(requestQuery, request, response = null, options) { + #requestMatchesCachedItem(requestQuery, request2, response = null, options) { const queryURL = new URL(requestQuery.url); - const cachedURL = new URL(request.url); + const cachedURL = new URL(request2.url); if (options?.ignoreSearch) { cachedURL.search = ""; queryURL.search = ""; @@ -15091,7 +15091,7 @@ var require_cache = __commonJS({ if (fieldValue === "*") { return false; } - const requestValue = request.headersList.get(fieldValue); + const requestValue = request2.headersList.get(fieldValue); const queryValue = requestQuery.headersList.get(fieldValue); if (requestValue !== queryValue) { return false; @@ -15167,21 +15167,21 @@ var require_cachestorage = __commonJS({ webidl.illegalConstructor(); } } - async match(request, options = {}) { + async match(request2, options = {}) { webidl.brandCheck(this, _CacheStorage); webidl.argumentLengthCheck(arguments, 1, { header: "CacheStorage.match" }); - request = webidl.converters.RequestInfo(request); + request2 = webidl.converters.RequestInfo(request2); options = webidl.converters.MultiCacheQueryOptions(options); if (options.cacheName != null) { if (this.#caches.has(options.cacheName)) { const cacheList = this.#caches.get(options.cacheName); const cache = new Cache(kConstruct, cacheList); - return await cache.match(request, options); + return await cache.match(request2, options); } } else { for (const cacheList of this.#caches.values()) { const cache = new Cache(kConstruct, cacheList); - const response = await cache.match(request, options); + const response = await cache.match(request2, options); if (response !== void 0) { return response; } @@ -16119,7 +16119,7 @@ var require_connection = __commonJS({ function establishWebSocketConnection(url, protocols, ws, onEstablish, options) { const requestURL = url; requestURL.protocol = url.protocol === "ws:" ? "http:" : "https:"; - const request = makeRequest({ + const request2 = makeRequest({ urlList: [requestURL], serviceWorkers: "none", referrer: "no-referrer", @@ -16130,17 +16130,17 @@ var require_connection = __commonJS({ }); if (options.headers) { const headersList = new Headers(options.headers)[kHeadersList]; - request.headersList = headersList; + request2.headersList = headersList; } const keyValue = crypto4.randomBytes(16).toString("base64"); - request.headersList.append("sec-websocket-key", keyValue); - request.headersList.append("sec-websocket-version", "13"); + request2.headersList.append("sec-websocket-key", keyValue); + request2.headersList.append("sec-websocket-version", "13"); for (const protocol of protocols) { - request.headersList.append("sec-websocket-protocol", protocol); + request2.headersList.append("sec-websocket-protocol", protocol); } const permessageDeflate = ""; const controller = fetching({ - request, + request: request2, useParallelQueue: true, dispatcher: options.dispatcher ?? getGlobalDispatcher(), processResponse(response) { @@ -16172,7 +16172,7 @@ var require_connection = __commonJS({ return; } const secProtocol = response.headersList.get("Sec-WebSocket-Protocol"); - if (secProtocol !== null && secProtocol !== request.headersList.get("Sec-WebSocket-Protocol")) { + if (secProtocol !== null && secProtocol !== request2.headersList.get("Sec-WebSocket-Protocol")) { failWebsocketConnection(ws, "Protocol was not set in the opening handshake."); return; } @@ -17249,7 +17249,7 @@ var require_lib = __commonJS({ } exports.isHttps = isHttps; var HttpClient = class { - constructor(userAgent, handlers, requestOptions) { + constructor(userAgent2, handlers, requestOptions) { this._ignoreSslError = false; this._allowRedirects = true; this._allowRedirectDowngrade = false; @@ -17258,7 +17258,7 @@ var require_lib = __commonJS({ this._maxRetries = 1; this._keepAlive = false; this._disposed = false; - this.userAgent = userAgent; + this.userAgent = userAgent2; this.handlers = handlers || []; this.requestOptions = requestOptions; if (requestOptions) { @@ -17551,14 +17551,14 @@ var require_lib = __commonJS({ } _mergeHeaders(headers) { if (this.requestOptions && this.requestOptions.headers) { - return Object.assign({}, lowercaseKeys(this.requestOptions.headers), lowercaseKeys(headers || {})); + return Object.assign({}, lowercaseKeys2(this.requestOptions.headers), lowercaseKeys2(headers || {})); } - return lowercaseKeys(headers || {}); + return lowercaseKeys2(headers || {}); } _getExistingOrDefaultHeader(additionalHeaders, header, _default) { let clientHeader; if (this.requestOptions && this.requestOptions.headers) { - clientHeader = lowercaseKeys(this.requestOptions.headers)[header]; + clientHeader = lowercaseKeys2(this.requestOptions.headers)[header]; } return additionalHeaders[header] || clientHeader || _default; } @@ -17696,7 +17696,7 @@ var require_lib = __commonJS({ } }; exports.HttpClient = HttpClient; - var lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {}); + var lowercaseKeys2 = (obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {}); } }); @@ -18634,29 +18634,29 @@ var require_utils3 = __commonJS({ } }); -// node_modules/universal-user-agent/dist-node/index.js +// node_modules/@actions/github/node_modules/universal-user-agent/dist-node/index.js var require_dist_node = __commonJS({ - "node_modules/universal-user-agent/dist-node/index.js"(exports) { + "node_modules/@actions/github/node_modules/universal-user-agent/dist-node/index.js"(exports) { "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); - function getUserAgent() { + function getUserAgent2() { if (typeof navigator === "object" && "userAgent" in navigator) { return navigator.userAgent; } - if (typeof process === "object" && "version" in process) { + if (typeof process === "object" && process.version !== void 0) { return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; } return ""; } - exports.getUserAgent = getUserAgent; + exports.getUserAgent = getUserAgent2; } }); -// node_modules/before-after-hook/lib/register.js +// node_modules/@actions/github/node_modules/before-after-hook/lib/register.js var require_register = __commonJS({ - "node_modules/before-after-hook/lib/register.js"(exports, module) { - module.exports = register; - function register(state, name, method, options) { + "node_modules/@actions/github/node_modules/before-after-hook/lib/register.js"(exports, module) { + module.exports = register2; + function register2(state, name, method, options) { if (typeof method !== "function") { throw new Error("method for before hook must be a function"); } @@ -18665,7 +18665,7 @@ var require_register = __commonJS({ } if (Array.isArray(name)) { return name.reverse().reduce(function(callback, name2) { - return register.bind(null, state, name2, callback, options); + return register2.bind(null, state, name2, callback, options); }, method)(); } return Promise.resolve().then(function() { @@ -18680,22 +18680,22 @@ var require_register = __commonJS({ } }); -// node_modules/before-after-hook/lib/add.js +// node_modules/@actions/github/node_modules/before-after-hook/lib/add.js var require_add = __commonJS({ - "node_modules/before-after-hook/lib/add.js"(exports, module) { - module.exports = addHook; - function addHook(state, kind, name, hook) { - var orig = hook; + "node_modules/@actions/github/node_modules/before-after-hook/lib/add.js"(exports, module) { + module.exports = addHook2; + function addHook2(state, kind, name, hook2) { + var orig = hook2; if (!state.registry[name]) { state.registry[name] = []; } if (kind === "before") { - hook = function(method, options) { + hook2 = function(method, options) { return Promise.resolve().then(orig.bind(null, options)).then(method.bind(null, options)); }; } if (kind === "after") { - hook = function(method, options) { + hook2 = function(method, options) { var result; return Promise.resolve().then(method.bind(null, options)).then(function(result_) { result = result_; @@ -18706,25 +18706,25 @@ var require_add = __commonJS({ }; } if (kind === "error") { - hook = function(method, options) { + hook2 = function(method, options) { return Promise.resolve().then(method.bind(null, options)).catch(function(error2) { return orig(error2, options); }); }; } state.registry[name].push({ - hook, + hook: hook2, orig }); } } }); -// node_modules/before-after-hook/lib/remove.js +// node_modules/@actions/github/node_modules/before-after-hook/lib/remove.js var require_remove = __commonJS({ - "node_modules/before-after-hook/lib/remove.js"(exports, module) { - module.exports = removeHook; - function removeHook(state, name, method) { + "node_modules/@actions/github/node_modules/before-after-hook/lib/remove.js"(exports, module) { + module.exports = removeHook2; + function removeHook2(state, name, method) { if (!state.registry[name]) { return; } @@ -18739,21 +18739,24 @@ var require_remove = __commonJS({ } }); -// node_modules/before-after-hook/index.js +// node_modules/@actions/github/node_modules/before-after-hook/index.js var require_before_after_hook = __commonJS({ - "node_modules/before-after-hook/index.js"(exports, module) { - var register = require_register(); - var addHook = require_add(); - var removeHook = require_remove(); - var bind = Function.bind; - var bindable = bind.bind(bind); - function bindApi(hook, state, name) { - var removeHookRef = bindable(removeHook, null).apply(null, name ? [state, name] : [state]); - hook.api = { remove: removeHookRef }; - hook.remove = removeHookRef; + "node_modules/@actions/github/node_modules/before-after-hook/index.js"(exports, module) { + var register2 = require_register(); + var addHook2 = require_add(); + var removeHook2 = require_remove(); + var bind2 = Function.bind; + var bindable2 = bind2.bind(bind2); + function bindApi2(hook2, state, name) { + var removeHookRef = bindable2(removeHook2, null).apply( + null, + name ? [state, name] : [state] + ); + hook2.api = { remove: removeHookRef }; + hook2.remove = removeHookRef; ["before", "error", "after", "wrap"].forEach(function(kind) { var args = name ? [state, kind, name] : [state, kind]; - hook[kind] = hook.api[kind] = bindable(addHook, null).apply(null, args); + hook2[kind] = hook2.api[kind] = bindable2(addHook2, null).apply(null, args); }); } function HookSingular() { @@ -18761,22 +18764,24 @@ var require_before_after_hook = __commonJS({ var singularHookState = { registry: {} }; - var singularHook = register.bind(null, singularHookState, singularHookName); - bindApi(singularHook, singularHookState, singularHookName); + var singularHook = register2.bind(null, singularHookState, singularHookName); + bindApi2(singularHook, singularHookState, singularHookName); return singularHook; } function HookCollection() { var state = { registry: {} }; - var hook = register.bind(null, state); - bindApi(hook, state); - return hook; + var hook2 = register2.bind(null, state); + bindApi2(hook2, state); + return hook2; } var collectionHookDeprecationMessageDisplayed = false; function Hook() { if (!collectionHookDeprecationMessageDisplayed) { - console.warn('[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4'); + console.warn( + '[before-after-hook]: "Hook()" repurposing warning, use "Hook.Collection()". Read more: https://git.io/upgrade-before-after-hook-to-1.4' + ); collectionHookDeprecationMessageDisplayed = true; } return HookCollection(); @@ -18790,36 +18795,9 @@ var require_before_after_hook = __commonJS({ } }); -// node_modules/is-plain-object/dist/is-plain-object.js -var require_is_plain_object = __commonJS({ - "node_modules/is-plain-object/dist/is-plain-object.js"(exports) { - "use strict"; - Object.defineProperty(exports, "__esModule", { value: true }); - function isObject(o) { - return Object.prototype.toString.call(o) === "[object Object]"; - } - function isPlainObject(o) { - var ctor, prot; - if (isObject(o) === false) - return false; - ctor = o.constructor; - if (ctor === void 0) - return true; - prot = ctor.prototype; - if (isObject(prot) === false) - return false; - if (prot.hasOwnProperty("isPrototypeOf") === false) { - return false; - } - return true; - } - exports.isPlainObject = isPlainObject; - } -}); - -// node_modules/@octokit/endpoint/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/endpoint/dist-node/index.js var require_dist_node2 = __commonJS({ - "node_modules/@octokit/endpoint/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/endpoint/dist-node/index.js"(exports, module) { "use strict"; var __defProp2 = Object.defineProperty; var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; @@ -18840,24 +18818,24 @@ var require_dist_node2 = __commonJS({ var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); var dist_src_exports = {}; __export2(dist_src_exports, { - endpoint: () => endpoint + endpoint: () => endpoint2 }); module.exports = __toCommonJS2(dist_src_exports); - var import_universal_user_agent = require_dist_node(); - var VERSION = "9.0.1"; - var userAgent = `octokit-endpoint.js/${VERSION} ${(0, import_universal_user_agent.getUserAgent)()}`; - var DEFAULTS = { + var import_universal_user_agent5 = require_dist_node(); + var VERSION5 = "9.0.4"; + var userAgent2 = `octokit-endpoint.js/${VERSION5} ${(0, import_universal_user_agent5.getUserAgent)()}`; + var DEFAULTS2 = { method: "GET", baseUrl: "https://api.github.com", headers: { accept: "application/vnd.github.v3+json", - "user-agent": userAgent + "user-agent": userAgent2 }, mediaType: { format: "" } }; - function lowercaseKeys(object) { + function lowercaseKeys2(object) { if (!object) { return {}; } @@ -18866,22 +18844,32 @@ var require_dist_node2 = __commonJS({ return newObj; }, {}); } - var import_is_plain_object = require_is_plain_object(); - function mergeDeep(defaults, options) { + function isPlainObject3(value) { + if (typeof value !== "object" || value === null) + return false; + if (Object.prototype.toString.call(value) !== "[object Object]") + return false; + const proto = Object.getPrototypeOf(value); + if (proto === null) + return true; + const Ctor = Object.prototype.hasOwnProperty.call(proto, "constructor") && proto.constructor; + return typeof Ctor === "function" && Ctor instanceof Ctor && Function.prototype.call(Ctor) === Function.prototype.call(value); + } + function mergeDeep2(defaults, options) { const result = Object.assign({}, defaults); Object.keys(options).forEach((key) => { - if ((0, import_is_plain_object.isPlainObject)(options[key])) { + if (isPlainObject3(options[key])) { if (!(key in defaults)) Object.assign(result, { [key]: options[key] }); else - result[key] = mergeDeep(defaults[key], options[key]); + result[key] = mergeDeep2(defaults[key], options[key]); } else { Object.assign(result, { [key]: options[key] }); } }); return result; } - function removeUndefinedProperties(obj) { + function removeUndefinedProperties2(obj) { for (const key in obj) { if (obj[key] === void 0) { delete obj[key]; @@ -18889,17 +18877,17 @@ var require_dist_node2 = __commonJS({ } return obj; } - function merge(defaults, route, options) { + function merge2(defaults, route, options) { if (typeof route === "string") { let [method, url] = route.split(" "); options = Object.assign(url ? { method, url } : { url: method }, options); } else { options = Object.assign({}, route); } - options.headers = lowercaseKeys(options.headers); - removeUndefinedProperties(options); - removeUndefinedProperties(options.headers); - const mergedOptions = mergeDeep(defaults || {}, options); + options.headers = lowercaseKeys2(options.headers); + removeUndefinedProperties2(options); + removeUndefinedProperties2(options.headers); + const mergedOptions = mergeDeep2(defaults || {}, options); if (options.url === "/graphql") { if (defaults && defaults.mediaType.previews?.length) { mergedOptions.mediaType.previews = defaults.mediaType.previews.filter( @@ -18910,7 +18898,7 @@ var require_dist_node2 = __commonJS({ } return mergedOptions; } - function addQueryParameters(url, parameters) { + function addQueryParameters2(url, parameters) { const separator = /\?/.test(url) ? "&" : "?"; const names = Object.keys(parameters); if (names.length === 0) { @@ -18923,24 +18911,27 @@ var require_dist_node2 = __commonJS({ return `${name}=${encodeURIComponent(parameters[name])}`; }).join("&"); } - var urlVariableRegex = /\{[^}]+\}/g; - function removeNonChars(variableName) { + var urlVariableRegex2 = /\{[^}]+\}/g; + function removeNonChars2(variableName) { return variableName.replace(/^\W+|\W+$/g, "").split(/,/); } - function extractUrlVariableNames(url) { - const matches = url.match(urlVariableRegex); + function extractUrlVariableNames2(url) { + const matches = url.match(urlVariableRegex2); if (!matches) { return []; } - return matches.map(removeNonChars).reduce((a, b) => a.concat(b), []); + return matches.map(removeNonChars2).reduce((a, b) => a.concat(b), []); } - function omit(object, keysToOmit) { - return Object.keys(object).filter((option) => !keysToOmit.includes(option)).reduce((obj, key) => { - obj[key] = object[key]; - return obj; - }, {}); + function omit2(object, keysToOmit) { + const result = { __proto__: null }; + for (const key of Object.keys(object)) { + if (keysToOmit.indexOf(key) === -1) { + result[key] = object[key]; + } + } + return result; } - function encodeReserved(str) { + function encodeReserved2(str) { return str.split(/(%[0-9A-Fa-f]{2})/g).map(function(part) { if (!/%[0-9A-Fa-f]/.test(part)) { part = encodeURI(part).replace(/%5B/g, "[").replace(/%5D/g, "]"); @@ -18948,67 +18939,67 @@ var require_dist_node2 = __commonJS({ return part; }).join(""); } - function encodeUnreserved(str) { + function encodeUnreserved2(str) { return encodeURIComponent(str).replace(/[!'()*]/g, function(c) { return "%" + c.charCodeAt(0).toString(16).toUpperCase(); }); } - function encodeValue(operator, value, key) { - value = operator === "+" || operator === "#" ? encodeReserved(value) : encodeUnreserved(value); + function encodeValue2(operator, value, key) { + value = operator === "+" || operator === "#" ? encodeReserved2(value) : encodeUnreserved2(value); if (key) { - return encodeUnreserved(key) + "=" + value; + return encodeUnreserved2(key) + "=" + value; } else { return value; } } - function isDefined(value) { + function isDefined2(value) { return value !== void 0 && value !== null; } - function isKeyOperator(operator) { + function isKeyOperator2(operator) { return operator === ";" || operator === "&" || operator === "?"; } - function getValues(context2, operator, key, modifier) { + function getValues2(context2, operator, key, modifier) { var value = context2[key], result = []; - if (isDefined(value) && value !== "") { + if (isDefined2(value) && value !== "") { if (typeof value === "string" || typeof value === "number" || typeof value === "boolean") { value = value.toString(); if (modifier && modifier !== "*") { value = value.substring(0, parseInt(modifier, 10)); } result.push( - encodeValue(operator, value, isKeyOperator(operator) ? key : "") + encodeValue2(operator, value, isKeyOperator2(operator) ? key : "") ); } else { if (modifier === "*") { if (Array.isArray(value)) { - value.filter(isDefined).forEach(function(value2) { + value.filter(isDefined2).forEach(function(value2) { result.push( - encodeValue(operator, value2, isKeyOperator(operator) ? key : "") + encodeValue2(operator, value2, isKeyOperator2(operator) ? key : "") ); }); } else { Object.keys(value).forEach(function(k) { - if (isDefined(value[k])) { - result.push(encodeValue(operator, value[k], k)); + if (isDefined2(value[k])) { + result.push(encodeValue2(operator, value[k], k)); } }); } } else { const tmp = []; if (Array.isArray(value)) { - value.filter(isDefined).forEach(function(value2) { - tmp.push(encodeValue(operator, value2)); + value.filter(isDefined2).forEach(function(value2) { + tmp.push(encodeValue2(operator, value2)); }); } else { Object.keys(value).forEach(function(k) { - if (isDefined(value[k])) { - tmp.push(encodeUnreserved(k)); - tmp.push(encodeValue(operator, value[k].toString())); + if (isDefined2(value[k])) { + tmp.push(encodeUnreserved2(k)); + tmp.push(encodeValue2(operator, value[k].toString())); } }); } - if (isKeyOperator(operator)) { - result.push(encodeUnreserved(key) + "=" + tmp.join(",")); + if (isKeyOperator2(operator)) { + result.push(encodeUnreserved2(key) + "=" + tmp.join(",")); } else if (tmp.length !== 0) { result.push(tmp.join(",")); } @@ -19016,25 +19007,25 @@ var require_dist_node2 = __commonJS({ } } else { if (operator === ";") { - if (isDefined(value)) { - result.push(encodeUnreserved(key)); + if (isDefined2(value)) { + result.push(encodeUnreserved2(key)); } } else if (value === "" && (operator === "&" || operator === "?")) { - result.push(encodeUnreserved(key) + "="); + result.push(encodeUnreserved2(key) + "="); } else if (value === "") { result.push(""); } } return result; } - function parseUrl(template) { + function parseUrl2(template) { return { - expand: expand.bind(null, template) + expand: expand2.bind(null, template) }; } - function expand(template, context2) { + function expand2(template, context2) { var operators = ["+", "#", ".", "/", ";", "?", "&"]; - return template.replace( + template = template.replace( /\{([^\{\}]+)\}|([^\{\}]+)/g, function(_, expression, literal) { if (expression) { @@ -19046,7 +19037,7 @@ var require_dist_node2 = __commonJS({ } expression.split(/,/g).forEach(function(variable) { var tmp = /([^:\*]*)(?::(\d+)|(\*))?/.exec(variable); - values.push(getValues(context2, operator, tmp[1], tmp[2] || tmp[3])); + values.push(getValues2(context2, operator, tmp[1], tmp[2] || tmp[3])); }); if (operator && operator !== "+") { var separator = ","; @@ -19060,17 +19051,22 @@ var require_dist_node2 = __commonJS({ return values.join(","); } } else { - return encodeReserved(literal); + return encodeReserved2(literal); } } ); + if (template === "/") { + return template; + } else { + return template.replace(/\/$/, ""); + } } - function parse2(options) { + function parse3(options) { let method = options.method.toUpperCase(); let url = (options.url || "/").replace(/:([a-z]\w+)/g, "{$1}"); let headers = Object.assign({}, options.headers); let body; - let parameters = omit(options, [ + let parameters = omit2(options, [ "method", "baseUrl", "url", @@ -19078,13 +19074,13 @@ var require_dist_node2 = __commonJS({ "request", "mediaType" ]); - const urlVariableNames = extractUrlVariableNames(url); - url = parseUrl(url).expand(parameters); + const urlVariableNames = extractUrlVariableNames2(url); + url = parseUrl2(url).expand(parameters); if (!/^http/.test(url)) { url = options.baseUrl + url; } const omittedParameters = Object.keys(options).filter((option) => urlVariableNames.includes(option)).concat("baseUrl"); - const remainingParameters = omit(parameters, omittedParameters); + const remainingParameters = omit2(parameters, omittedParameters); const isBinaryRequest = /application\/octet-stream/i.test(headers.accept); if (!isBinaryRequest) { if (options.mediaType.format) { @@ -19106,7 +19102,7 @@ var require_dist_node2 = __commonJS({ } } if (["GET", "HEAD"].includes(method)) { - url = addQueryParameters(url, remainingParameters); + url = addQueryParameters2(url, remainingParameters); } else { if ("data" in remainingParameters) { body = remainingParameters.data; @@ -19128,20 +19124,20 @@ var require_dist_node2 = __commonJS({ options.request ? { request: options.request } : null ); } - function endpointWithDefaults(defaults, route, options) { - return parse2(merge(defaults, route, options)); - } - function withDefaults(oldDefaults, newDefaults) { - const DEFAULTS2 = merge(oldDefaults, newDefaults); - const endpoint2 = endpointWithDefaults.bind(null, DEFAULTS2); - return Object.assign(endpoint2, { - DEFAULTS: DEFAULTS2, - defaults: withDefaults.bind(null, DEFAULTS2), - merge: merge.bind(null, DEFAULTS2), - parse: parse2 + function endpointWithDefaults2(defaults, route, options) { + return parse3(merge2(defaults, route, options)); + } + function withDefaults4(oldDefaults, newDefaults) { + const DEFAULTS22 = merge2(oldDefaults, newDefaults); + const endpoint22 = endpointWithDefaults2.bind(null, DEFAULTS22); + return Object.assign(endpoint22, { + DEFAULTS: DEFAULTS22, + defaults: withDefaults4.bind(null, DEFAULTS22), + merge: merge2.bind(null, DEFAULTS22), + parse: parse3 }); } - var endpoint = withDefaults(null, DEFAULTS); + var endpoint2 = withDefaults4(null, DEFAULTS2); } }); @@ -19239,9 +19235,9 @@ var require_once = __commonJS({ } }); -// node_modules/@octokit/request-error/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/request-error/dist-node/index.js var require_dist_node4 = __commonJS({ - "node_modules/@octokit/request-error/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/request-error/dist-node/index.js"(exports, module) { "use strict"; var __create2 = Object.create; var __defProp2 = Object.defineProperty; @@ -19272,14 +19268,14 @@ var require_dist_node4 = __commonJS({ var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); var dist_src_exports = {}; __export2(dist_src_exports, { - RequestError: () => RequestError + RequestError: () => RequestError2 }); module.exports = __toCommonJS2(dist_src_exports); var import_deprecation = require_dist_node3(); var import_once = __toESM2(require_once()); var logOnceCode = (0, import_once.default)((deprecation) => console.warn(deprecation)); var logOnceHeaders = (0, import_once.default)((deprecation) => console.warn(deprecation)); - var RequestError = class extends Error { + var RequestError2 = class extends Error { constructor(message, statusCode, options) { super(message); if (Error.captureStackTrace) { @@ -19331,9 +19327,9 @@ var require_dist_node4 = __commonJS({ } }); -// node_modules/@octokit/request/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/request/dist-node/index.js var require_dist_node5 = __commonJS({ - "node_modules/@octokit/request/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/request/dist-node/index.js"(exports, module) { "use strict"; var __defProp2 = Object.defineProperty; var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; @@ -19354,22 +19350,32 @@ var require_dist_node5 = __commonJS({ var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); var dist_src_exports = {}; __export2(dist_src_exports, { - request: () => request + request: () => request2 }); module.exports = __toCommonJS2(dist_src_exports); - var import_endpoint = require_dist_node2(); - var import_universal_user_agent = require_dist_node(); - var VERSION = "8.1.2"; - var import_is_plain_object = require_is_plain_object(); - var import_request_error = require_dist_node4(); - function getBufferResponse(response) { + var import_endpoint2 = require_dist_node2(); + var import_universal_user_agent5 = require_dist_node(); + var VERSION5 = "8.2.0"; + function isPlainObject3(value) { + if (typeof value !== "object" || value === null) + return false; + if (Object.prototype.toString.call(value) !== "[object Object]") + return false; + const proto = Object.getPrototypeOf(value); + if (proto === null) + return true; + const Ctor = Object.prototype.hasOwnProperty.call(proto, "constructor") && proto.constructor; + return typeof Ctor === "function" && Ctor instanceof Ctor && Function.prototype.call(Ctor) === Function.prototype.call(value); + } + var import_request_error2 = require_dist_node4(); + function getBufferResponse2(response) { return response.arrayBuffer(); } - function fetchWrapper(requestOptions) { + function fetchWrapper2(requestOptions) { var _a, _b, _c; const log = requestOptions.request && requestOptions.request.log ? requestOptions.request.log : console; const parseSuccessResponseBody = ((_a = requestOptions.request) == null ? void 0 : _a.parseSuccessResponseBody) !== false; - if ((0, import_is_plain_object.isPlainObject)(requestOptions.body) || Array.isArray(requestOptions.body)) { + if (isPlainObject3(requestOptions.body) || Array.isArray(requestOptions.body)) { requestOptions.body = JSON.stringify(requestOptions.body); } let headers = {}; @@ -19412,7 +19418,7 @@ var require_dist_node5 = __commonJS({ if (status < 400) { return; } - throw new import_request_error.RequestError(response.statusText, status, { + throw new import_request_error2.RequestError(response.statusText, status, { response: { url, status, @@ -19423,19 +19429,19 @@ var require_dist_node5 = __commonJS({ }); } if (status === 304) { - throw new import_request_error.RequestError("Not modified", status, { + throw new import_request_error2.RequestError("Not modified", status, { response: { url, status, headers, - data: await getResponseData(response) + data: await getResponseData2(response) }, request: requestOptions }); } if (status >= 400) { - const data = await getResponseData(response); - const error2 = new import_request_error.RequestError(toErrorMessage(data), status, { + const data = await getResponseData2(response); + const error2 = new import_request_error2.RequestError(toErrorMessage2(data), status, { response: { url, status, @@ -19446,7 +19452,7 @@ var require_dist_node5 = __commonJS({ }); throw error2; } - return parseSuccessResponseBody ? await getResponseData(response) : response.body; + return parseSuccessResponseBody ? await getResponseData2(response) : response.body; }).then((data) => { return { status, @@ -19455,70 +19461,84 @@ var require_dist_node5 = __commonJS({ data }; }).catch((error2) => { - if (error2 instanceof import_request_error.RequestError) + if (error2 instanceof import_request_error2.RequestError) throw error2; else if (error2.name === "AbortError") throw error2; - throw new import_request_error.RequestError(error2.message, 500, { + let message = error2.message; + if (error2.name === "TypeError" && "cause" in error2) { + if (error2.cause instanceof Error) { + message = error2.cause.message; + } else if (typeof error2.cause === "string") { + message = error2.cause; + } + } + throw new import_request_error2.RequestError(message, 500, { request: requestOptions }); }); } - async function getResponseData(response) { + async function getResponseData2(response) { const contentType = response.headers.get("content-type"); if (/application\/json/.test(contentType)) { - return response.json(); + return response.json().catch(() => response.text()).catch(() => ""); } if (!contentType || /^text\/|charset=utf-8$/.test(contentType)) { return response.text(); } - return getBufferResponse(response); + return getBufferResponse2(response); } - function toErrorMessage(data) { + function toErrorMessage2(data) { if (typeof data === "string") return data; + let suffix; + if ("documentation_url" in data) { + suffix = ` - ${data.documentation_url}`; + } else { + suffix = ""; + } if ("message" in data) { if (Array.isArray(data.errors)) { - return `${data.message}: ${data.errors.map(JSON.stringify).join(", ")}`; + return `${data.message}: ${data.errors.map(JSON.stringify).join(", ")}${suffix}`; } - return data.message; + return `${data.message}${suffix}`; } return `Unknown error: ${JSON.stringify(data)}`; } - function withDefaults(oldEndpoint, newDefaults) { + function withDefaults4(oldEndpoint, newDefaults) { const endpoint2 = oldEndpoint.defaults(newDefaults); const newApi = function(route, parameters) { const endpointOptions = endpoint2.merge(route, parameters); if (!endpointOptions.request || !endpointOptions.request.hook) { - return fetchWrapper(endpoint2.parse(endpointOptions)); + return fetchWrapper2(endpoint2.parse(endpointOptions)); } - const request2 = (route2, parameters2) => { - return fetchWrapper( + const request22 = (route2, parameters2) => { + return fetchWrapper2( endpoint2.parse(endpoint2.merge(route2, parameters2)) ); }; - Object.assign(request2, { + Object.assign(request22, { endpoint: endpoint2, - defaults: withDefaults.bind(null, endpoint2) + defaults: withDefaults4.bind(null, endpoint2) }); - return endpointOptions.request.hook(request2, endpointOptions); + return endpointOptions.request.hook(request22, endpointOptions); }; return Object.assign(newApi, { endpoint: endpoint2, - defaults: withDefaults.bind(null, endpoint2) + defaults: withDefaults4.bind(null, endpoint2) }); } - var request = withDefaults(import_endpoint.endpoint, { + var request2 = withDefaults4(import_endpoint2.endpoint, { headers: { - "user-agent": `octokit-request.js/${VERSION} ${(0, import_universal_user_agent.getUserAgent)()}` + "user-agent": `octokit-request.js/${VERSION5} ${(0, import_universal_user_agent5.getUserAgent)()}` } }); } }); -// node_modules/@octokit/graphql/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/graphql/dist-node/index.js var require_dist_node6 = __commonJS({ - "node_modules/@octokit/graphql/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/graphql/dist-node/index.js"(exports, module) { "use strict"; var __defProp2 = Object.defineProperty; var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; @@ -19539,23 +19559,23 @@ var require_dist_node6 = __commonJS({ var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); var dist_src_exports = {}; __export2(dist_src_exports, { - GraphqlResponseError: () => GraphqlResponseError, - graphql: () => graphql2, - withCustomRequest: () => withCustomRequest + GraphqlResponseError: () => GraphqlResponseError2, + graphql: () => graphql22, + withCustomRequest: () => withCustomRequest2 }); module.exports = __toCommonJS2(dist_src_exports); var import_request3 = require_dist_node5(); - var import_universal_user_agent = require_dist_node(); - var VERSION = "7.0.2"; - var import_request2 = require_dist_node5(); - var import_request = require_dist_node5(); - function _buildMessageForResponseErrors(data) { + var import_universal_user_agent5 = require_dist_node(); + var VERSION5 = "7.0.2"; + var import_request22 = require_dist_node5(); + var import_request4 = require_dist_node5(); + function _buildMessageForResponseErrors2(data) { return `Request failed due to following response errors: ` + data.errors.map((e) => ` - ${e.message}`).join("\n"); } - var GraphqlResponseError = class extends Error { + var GraphqlResponseError2 = class extends Error { constructor(request2, headers, response) { - super(_buildMessageForResponseErrors(response)); + super(_buildMessageForResponseErrors2(response)); this.request = request2; this.headers = headers; this.response = response; @@ -19567,7 +19587,7 @@ var require_dist_node6 = __commonJS({ } } }; - var NON_VARIABLE_OPTIONS = [ + var NON_VARIABLE_OPTIONS2 = [ "method", "baseUrl", "url", @@ -19576,9 +19596,9 @@ var require_dist_node6 = __commonJS({ "query", "mediaType" ]; - var FORBIDDEN_VARIABLE_OPTIONS = ["query", "method", "url"]; - var GHES_V3_SUFFIX_REGEX = /\/api\/v3\/?$/; - function graphql(request2, query, options) { + var FORBIDDEN_VARIABLE_OPTIONS2 = ["query", "method", "url"]; + var GHES_V3_SUFFIX_REGEX2 = /\/api\/v3\/?$/; + function graphql3(request2, query, options) { if (options) { if (typeof query === "string" && "query" in options) { return Promise.reject( @@ -19586,7 +19606,7 @@ var require_dist_node6 = __commonJS({ ); } for (const key in options) { - if (!FORBIDDEN_VARIABLE_OPTIONS.includes(key)) + if (!FORBIDDEN_VARIABLE_OPTIONS2.includes(key)) continue; return Promise.reject( new Error( @@ -19599,7 +19619,7 @@ var require_dist_node6 = __commonJS({ const requestOptions = Object.keys( parsedOptions ).reduce((result, key) => { - if (NON_VARIABLE_OPTIONS.includes(key)) { + if (NON_VARIABLE_OPTIONS2.includes(key)) { result[key] = parsedOptions[key]; return result; } @@ -19610,8 +19630,8 @@ var require_dist_node6 = __commonJS({ return result; }, {}); const baseUrl = parsedOptions.baseUrl || request2.endpoint.DEFAULTS.baseUrl; - if (GHES_V3_SUFFIX_REGEX.test(baseUrl)) { - requestOptions.url = baseUrl.replace(GHES_V3_SUFFIX_REGEX, "/api/graphql"); + if (GHES_V3_SUFFIX_REGEX2.test(baseUrl)) { + requestOptions.url = baseUrl.replace(GHES_V3_SUFFIX_REGEX2, "/api/graphql"); } return request2(requestOptions).then((response) => { if (response.data.errors) { @@ -19619,7 +19639,7 @@ var require_dist_node6 = __commonJS({ for (const key of Object.keys(response.headers)) { headers[key] = response.headers[key]; } - throw new GraphqlResponseError( + throw new GraphqlResponseError2( requestOptions, headers, response.data @@ -19628,25 +19648,25 @@ var require_dist_node6 = __commonJS({ return response.data.data; }); } - function withDefaults(request2, newDefaults) { + function withDefaults4(request2, newDefaults) { const newRequest = request2.defaults(newDefaults); const newApi = (query, options) => { - return graphql(newRequest, query, options); + return graphql3(newRequest, query, options); }; return Object.assign(newApi, { - defaults: withDefaults.bind(null, newRequest), + defaults: withDefaults4.bind(null, newRequest), endpoint: newRequest.endpoint }); } - var graphql2 = withDefaults(import_request3.request, { + var graphql22 = withDefaults4(import_request3.request, { headers: { - "user-agent": `octokit-graphql.js/${VERSION} ${(0, import_universal_user_agent.getUserAgent)()}` + "user-agent": `octokit-graphql.js/${VERSION5} ${(0, import_universal_user_agent5.getUserAgent)()}` }, method: "POST", url: "/graphql" }); - function withCustomRequest(customRequest) { - return withDefaults(customRequest, { + function withCustomRequest2(customRequest) { + return withDefaults4(customRequest, { method: "POST", url: "/graphql" }); @@ -19654,9 +19674,9 @@ var require_dist_node6 = __commonJS({ } }); -// node_modules/@octokit/auth-token/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/auth-token/dist-node/index.js var require_dist_node7 = __commonJS({ - "node_modules/@octokit/auth-token/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/auth-token/dist-node/index.js"(exports, module) { "use strict"; var __defProp2 = Object.defineProperty; var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; @@ -19677,16 +19697,16 @@ var require_dist_node7 = __commonJS({ var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); var dist_src_exports = {}; __export2(dist_src_exports, { - createTokenAuth: () => createTokenAuth + createTokenAuth: () => createTokenAuth3 }); module.exports = __toCommonJS2(dist_src_exports); - var REGEX_IS_INSTALLATION_LEGACY = /^v1\./; - var REGEX_IS_INSTALLATION = /^ghs_/; - var REGEX_IS_USER_TO_SERVER = /^ghu_/; - async function auth(token) { + var REGEX_IS_INSTALLATION_LEGACY2 = /^v1\./; + var REGEX_IS_INSTALLATION2 = /^ghs_/; + var REGEX_IS_USER_TO_SERVER2 = /^ghu_/; + async function auth2(token) { const isApp = token.split(/\./).length === 3; - const isInstallation = REGEX_IS_INSTALLATION_LEGACY.test(token) || REGEX_IS_INSTALLATION.test(token); - const isUserToServer = REGEX_IS_USER_TO_SERVER.test(token); + const isInstallation = REGEX_IS_INSTALLATION_LEGACY2.test(token) || REGEX_IS_INSTALLATION2.test(token); + const isUserToServer = REGEX_IS_USER_TO_SERVER2.test(token); const tokenType = isApp ? "app" : isInstallation ? "installation" : isUserToServer ? "user-to-server" : "oauth"; return { type: "token", @@ -19694,21 +19714,21 @@ var require_dist_node7 = __commonJS({ tokenType }; } - function withAuthorizationPrefix(token) { + function withAuthorizationPrefix2(token) { if (token.split(/\./).length === 3) { return `bearer ${token}`; } return `token ${token}`; } - async function hook(token, request, route, parameters) { - const endpoint = request.endpoint.merge( + async function hook2(token, request2, route, parameters) { + const endpoint2 = request2.endpoint.merge( route, parameters ); - endpoint.headers.authorization = withAuthorizationPrefix(token); - return request(endpoint); + endpoint2.headers.authorization = withAuthorizationPrefix2(token); + return request2(endpoint2); } - var createTokenAuth = function createTokenAuth2(token) { + var createTokenAuth3 = function createTokenAuth22(token) { if (!token) { throw new Error("[@octokit/auth-token] No token passed to createTokenAuth"); } @@ -19718,16 +19738,16 @@ var require_dist_node7 = __commonJS({ ); } token = token.replace(/^(token|bearer) +/i, ""); - return Object.assign(auth.bind(null, token), { - hook: hook.bind(null, token) + return Object.assign(auth2.bind(null, token), { + hook: hook2.bind(null, token) }); }; } }); -// node_modules/@octokit/core/dist-node/index.js +// node_modules/@actions/github/node_modules/@octokit/core/dist-node/index.js var require_dist_node8 = __commonJS({ - "node_modules/@octokit/core/dist-node/index.js"(exports, module) { + "node_modules/@actions/github/node_modules/@octokit/core/dist-node/index.js"(exports, module) { "use strict"; var __defProp2 = Object.defineProperty; var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; @@ -19751,20 +19771,20 @@ var require_dist_node8 = __commonJS({ Octokit: () => Octokit2 }); module.exports = __toCommonJS2(dist_src_exports); - var import_universal_user_agent = require_dist_node(); - var import_before_after_hook = require_before_after_hook(); - var import_request = require_dist_node5(); - var import_graphql = require_dist_node6(); - var import_auth_token = require_dist_node7(); - var VERSION = "5.1.0"; - var noop = () => { - }; - var consoleWarn = console.warn.bind(console); - var consoleError = console.error.bind(console); - var userAgentTrail = `octokit-core.js/${VERSION} ${(0, import_universal_user_agent.getUserAgent)()}`; + var import_universal_user_agent5 = require_dist_node(); + var import_before_after_hook2 = require_before_after_hook(); + var import_request3 = require_dist_node5(); + var import_graphql2 = require_dist_node6(); + var import_auth_token2 = require_dist_node7(); + var VERSION5 = "5.1.0"; + var noop2 = () => { + }; + var consoleWarn2 = console.warn.bind(console); + var consoleError2 = console.error.bind(console); + var userAgentTrail2 = `octokit-core.js/${VERSION5} ${(0, import_universal_user_agent5.getUserAgent)()}`; var Octokit2 = class { static { - this.VERSION = VERSION; + this.VERSION = VERSION5; } static defaults(defaults) { const OctokitWithDefaults = class extends this { @@ -19809,20 +19829,20 @@ var require_dist_node8 = __commonJS({ return NewOctokit; } constructor(options = {}) { - const hook = new import_before_after_hook.Collection(); + const hook2 = new import_before_after_hook2.Collection(); const requestDefaults = { - baseUrl: import_request.request.endpoint.DEFAULTS.baseUrl, + baseUrl: import_request3.request.endpoint.DEFAULTS.baseUrl, headers: {}, request: Object.assign({}, options.request, { // @ts-ignore internal usage only, no need to type - hook: hook.bind(null, "request") + hook: hook2.bind(null, "request") }), mediaType: { previews: [], format: "" } }; - requestDefaults.headers["user-agent"] = options.userAgent ? `${options.userAgent} ${userAgentTrail}` : userAgentTrail; + requestDefaults.headers["user-agent"] = options.userAgent ? `${options.userAgent} ${userAgentTrail2}` : userAgentTrail2; if (options.baseUrl) { requestDefaults.baseUrl = options.baseUrl; } @@ -19832,31 +19852,31 @@ var require_dist_node8 = __commonJS({ if (options.timeZone) { requestDefaults.headers["time-zone"] = options.timeZone; } - this.request = import_request.request.defaults(requestDefaults); - this.graphql = (0, import_graphql.withCustomRequest)(this.request).defaults(requestDefaults); + this.request = import_request3.request.defaults(requestDefaults); + this.graphql = (0, import_graphql2.withCustomRequest)(this.request).defaults(requestDefaults); this.log = Object.assign( { - debug: noop, - info: noop, - warn: consoleWarn, - error: consoleError + debug: noop2, + info: noop2, + warn: consoleWarn2, + error: consoleError2 }, options.log ); - this.hook = hook; + this.hook = hook2; if (!options.authStrategy) { if (!options.auth) { this.auth = async () => ({ type: "unauthenticated" }); } else { - const auth = (0, import_auth_token.createTokenAuth)(options.auth); - hook.wrap("request", auth.hook); - this.auth = auth; + const auth2 = (0, import_auth_token2.createTokenAuth)(options.auth); + hook2.wrap("request", auth2.hook); + this.auth = auth2; } } else { const { authStrategy, ...otherOptions } = options; - const auth = authStrategy( + const auth2 = authStrategy( Object.assign( { request: this.request, @@ -19872,8 +19892,8 @@ var require_dist_node8 = __commonJS({ options.auth ) ); - hook.wrap("request", auth.hook); - this.auth = auth; + hook2.wrap("request", auth2.hook); + this.auth = auth2; } const classConstructor = this.constructor; for (let i = 0; i < classConstructor.plugins.length; ++i) { @@ -19911,7 +19931,7 @@ var require_dist_node9 = __commonJS({ restEndpointMethods: () => restEndpointMethods }); module.exports = __toCommonJS2(dist_src_exports); - var VERSION = "10.0.1"; + var VERSION5 = "10.0.1"; var Endpoints = { actions: { addCustomLabelsToSelfHostedRunnerForOrg: [ @@ -21768,8 +21788,8 @@ var require_dist_node9 = __commonJS({ var endpoints_default = Endpoints; var endpointMethodsMap = /* @__PURE__ */ new Map(); for (const [scope, endpoints] of Object.entries(endpoints_default)) { - for (const [methodName, endpoint] of Object.entries(endpoints)) { - const [route, defaults, decorations] = endpoint; + for (const [methodName, endpoint2] of Object.entries(endpoints)) { + const [route, defaults, decorations] = endpoint2; const [method, url] = route.split(/ /); const endpointDefaults = Object.assign( { @@ -21893,7 +21913,7 @@ var require_dist_node9 = __commonJS({ rest: api }; } - restEndpointMethods.VERSION = VERSION; + restEndpointMethods.VERSION = VERSION5; function legacyRestEndpointMethods(octokit) { const api = endpointsToMethods(octokit); return { @@ -21901,7 +21921,7 @@ var require_dist_node9 = __commonJS({ rest: api }; } - legacyRestEndpointMethods.VERSION = VERSION; + legacyRestEndpointMethods.VERSION = VERSION5; } }); @@ -21934,7 +21954,7 @@ var require_dist_node10 = __commonJS({ paginatingEndpoints: () => paginatingEndpoints }); module.exports = __toCommonJS2(dist_src_exports); - var VERSION = "9.0.0"; + var VERSION5 = "9.0.0"; function normalizePaginatedListResponse(response) { if (!response.data) { return { @@ -22275,7 +22295,7 @@ var require_dist_node10 = __commonJS({ }) }; } - paginateRest.VERSION = VERSION; + paginateRest.VERSION = VERSION5; } }); @@ -22334,9 +22354,9 @@ var require_utils4 = __commonJS({ exports.GitHub = core_1.Octokit.plugin(plugin_rest_endpoint_methods_1.restEndpointMethods, plugin_paginate_rest_1.paginateRest).defaults(exports.defaults); function getOctokitOptions(token, options) { const opts = Object.assign({}, options || {}); - const auth = Utils.getAuthString(token, opts); - if (auth) { - opts.auth = auth; + const auth2 = Utils.getAuthString(token, opts); + if (auth2) { + opts.auth = auth2; } return opts; } @@ -22393,199 +22413,6 @@ var require_github = __commonJS({ } }); -// node_modules/@octokit/plugin-paginate-graphql/dist-node/index.js -var require_dist_node11 = __commonJS({ - "node_modules/@octokit/plugin-paginate-graphql/dist-node/index.js"(exports, module) { - "use strict"; - var __defProp2 = Object.defineProperty; - var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor; - var __getOwnPropNames2 = Object.getOwnPropertyNames; - var __hasOwnProp2 = Object.prototype.hasOwnProperty; - var __export2 = (target, all) => { - for (var name in all) - __defProp2(target, name, { get: all[name], enumerable: true }); - }; - var __copyProps2 = (to, from, except, desc) => { - if (from && typeof from === "object" || typeof from === "function") { - for (let key of __getOwnPropNames2(from)) - if (!__hasOwnProp2.call(to, key) && key !== except) - __defProp2(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc2(from, key)) || desc.enumerable }); - } - return to; - }; - var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod); - var dist_src_exports = {}; - __export2(dist_src_exports, { - paginateGraphql: () => paginateGraphql2 - }); - module.exports = __toCommonJS2(dist_src_exports); - var import_core3 = require_dist_node8(); - var generateMessage = (path, cursorValue) => `The cursor at "${path.join( - "," - )}" did not change its value "${cursorValue}" after a page transition. Please make sure your that your query is set up correctly.`; - var MissingCursorChange = class extends Error { - constructor(pageInfo, cursorValue) { - super(generateMessage(pageInfo.pathInQuery, cursorValue)); - this.pageInfo = pageInfo; - this.cursorValue = cursorValue; - this.name = "MissingCursorChangeError"; - if (Error.captureStackTrace) { - Error.captureStackTrace(this, this.constructor); - } - } - }; - var MissingPageInfo = class extends Error { - constructor(response) { - super( - `No pageInfo property found in response. Please make sure to specify the pageInfo in your query. Response-Data: ${JSON.stringify( - response, - null, - 2 - )}` - ); - this.response = response; - this.name = "MissingPageInfo"; - if (Error.captureStackTrace) { - Error.captureStackTrace(this, this.constructor); - } - } - }; - var isObject = (value) => Object.prototype.toString.call(value) === "[object Object]"; - function findPaginatedResourcePath(responseData) { - const paginatedResourcePath = deepFindPathToProperty( - responseData, - "pageInfo" - ); - if (paginatedResourcePath.length === 0) { - throw new MissingPageInfo(responseData); - } - return paginatedResourcePath; - } - var deepFindPathToProperty = (object, searchProp, path = []) => { - for (const key of Object.keys(object)) { - const currentPath = [...path, key]; - const currentValue = object[key]; - if (currentValue.hasOwnProperty(searchProp)) { - return currentPath; - } - if (isObject(currentValue)) { - const result = deepFindPathToProperty( - currentValue, - searchProp, - currentPath - ); - if (result.length > 0) { - return result; - } - } - } - return []; - }; - var get = (object, path) => { - return path.reduce((current, nextProperty) => current[nextProperty], object); - }; - var set = (object, path, mutator) => { - const lastProperty = path[path.length - 1]; - const parentPath = [...path].slice(0, -1); - const parent = get(object, parentPath); - if (typeof mutator === "function") { - parent[lastProperty] = mutator(parent[lastProperty]); - } else { - parent[lastProperty] = mutator; - } - }; - var extractPageInfos = (responseData) => { - const pageInfoPath = findPaginatedResourcePath(responseData); - return { - pathInQuery: pageInfoPath, - pageInfo: get(responseData, [...pageInfoPath, "pageInfo"]) - }; - }; - var import_core4 = require_dist_node8(); - var isForwardSearch = (givenPageInfo) => { - return givenPageInfo.hasOwnProperty("hasNextPage"); - }; - var getCursorFrom = (pageInfo) => isForwardSearch(pageInfo) ? pageInfo.endCursor : pageInfo.startCursor; - var hasAnotherPage = (pageInfo) => isForwardSearch(pageInfo) ? pageInfo.hasNextPage : pageInfo.hasPreviousPage; - var createIterator = (octokit) => { - return (query, initialParameters = {}) => { - let nextPageExists = true; - let parameters = { ...initialParameters }; - return { - [Symbol.asyncIterator]: () => ({ - async next() { - if (!nextPageExists) - return { done: true, value: {} }; - const response = await octokit.graphql( - query, - parameters - ); - const pageInfoContext = extractPageInfos(response); - const nextCursorValue = getCursorFrom(pageInfoContext.pageInfo); - nextPageExists = hasAnotherPage(pageInfoContext.pageInfo); - if (nextPageExists && nextCursorValue === parameters.cursor) { - throw new MissingCursorChange(pageInfoContext, nextCursorValue); - } - parameters = { - ...parameters, - cursor: nextCursorValue - }; - return { done: false, value: response }; - } - }) - }; - }; - }; - var import_core22 = require_dist_node8(); - var mergeResponses = (response1, response2) => { - if (Object.keys(response1).length === 0) { - return Object.assign(response1, response2); - } - const path = findPaginatedResourcePath(response1); - const nodesPath = [...path, "nodes"]; - const newNodes = get(response2, nodesPath); - if (newNodes) { - set(response1, nodesPath, (values) => { - return [...values, ...newNodes]; - }); - } - const edgesPath = [...path, "edges"]; - const newEdges = get(response2, edgesPath); - if (newEdges) { - set(response1, edgesPath, (values) => { - return [...values, ...newEdges]; - }); - } - const pageInfoPath = [...path, "pageInfo"]; - set(response1, pageInfoPath, get(response2, pageInfoPath)); - return response1; - }; - var createPaginate = (octokit) => { - const iterator = createIterator(octokit); - return async (query, initialParameters = {}) => { - let mergedResponse = {}; - for await (const response of iterator( - query, - initialParameters - )) { - mergedResponse = mergeResponses(mergedResponse, response); - } - return mergedResponse; - }; - }; - function paginateGraphql2(octokit) { - octokit.graphql; - return { - graphql: Object.assign(octokit.graphql, { - paginate: Object.assign(createPaginate(octokit), { - iterator: createIterator(octokit) - }) - }) - }; - } - } -}); - // src/main.ts var import_core2 = __toESM(require_core(), 1); var import_github = __toESM(require_github(), 1); @@ -22776,9 +22603,1108 @@ function assembleStyles() { var ansiStyles = assembleStyles(); var ansi_styles_default = ansiStyles; +// node_modules/universal-user-agent/index.js +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + if (typeof process === "object" && process.version !== void 0) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + return ""; +} + +// node_modules/before-after-hook/lib/register.js +function register(state, name, method, options) { + if (typeof method !== "function") { + throw new Error("method for before hook must be a function"); + } + if (!options) { + options = {}; + } + if (Array.isArray(name)) { + return name.reverse().reduce((callback, name2) => { + return register.bind(null, state, name2, callback, options); + }, method)(); + } + return Promise.resolve().then(() => { + if (!state.registry[name]) { + return method(options); + } + return state.registry[name].reduce((method2, registered) => { + return registered.hook.bind(null, method2, options); + }, method)(); + }); +} + +// node_modules/before-after-hook/lib/add.js +function addHook(state, kind, name, hook2) { + const orig = hook2; + if (!state.registry[name]) { + state.registry[name] = []; + } + if (kind === "before") { + hook2 = (method, options) => { + return Promise.resolve().then(orig.bind(null, options)).then(method.bind(null, options)); + }; + } + if (kind === "after") { + hook2 = (method, options) => { + let result; + return Promise.resolve().then(method.bind(null, options)).then((result_) => { + result = result_; + return orig(result, options); + }).then(() => { + return result; + }); + }; + } + if (kind === "error") { + hook2 = (method, options) => { + return Promise.resolve().then(method.bind(null, options)).catch((error2) => { + return orig(error2, options); + }); + }; + } + state.registry[name].push({ + hook: hook2, + orig + }); +} + +// node_modules/before-after-hook/lib/remove.js +function removeHook(state, name, method) { + if (!state.registry[name]) { + return; + } + const index = state.registry[name].map((registered) => { + return registered.orig; + }).indexOf(method); + if (index === -1) { + return; + } + state.registry[name].splice(index, 1); +} + +// node_modules/before-after-hook/index.js +var bind = Function.bind; +var bindable = bind.bind(bind); +function bindApi(hook2, state, name) { + const removeHookRef = bindable(removeHook, null).apply( + null, + name ? [state, name] : [state] + ); + hook2.api = { remove: removeHookRef }; + hook2.remove = removeHookRef; + ["before", "error", "after", "wrap"].forEach((kind) => { + const args = name ? [state, kind, name] : [state, kind]; + hook2[kind] = hook2.api[kind] = bindable(addHook, null).apply(null, args); + }); +} +function Singular() { + const singularHookName = Symbol("Singular"); + const singularHookState = { + registry: {} + }; + const singularHook = register.bind(null, singularHookState, singularHookName); + bindApi(singularHook, singularHookState, singularHookName); + return singularHook; +} +function Collection() { + const state = { + registry: {} + }; + const hook2 = register.bind(null, state); + bindApi(hook2, state); + return hook2; +} +var before_after_hook_default = { Singular, Collection }; + +// node_modules/@octokit/endpoint/dist-bundle/index.js +var VERSION = "0.0.0-development"; +var userAgent = `octokit-endpoint.js/${VERSION} ${getUserAgent()}`; +var DEFAULTS = { + method: "GET", + baseUrl: "https://api.github.com", + headers: { + accept: "application/vnd.github.v3+json", + "user-agent": userAgent + }, + mediaType: { + format: "" + } +}; +function lowercaseKeys(object) { + if (!object) { + return {}; + } + return Object.keys(object).reduce((newObj, key) => { + newObj[key.toLowerCase()] = object[key]; + return newObj; + }, {}); +} +function isPlainObject(value) { + if (typeof value !== "object" || value === null) + return false; + if (Object.prototype.toString.call(value) !== "[object Object]") + return false; + const proto = Object.getPrototypeOf(value); + if (proto === null) + return true; + const Ctor = Object.prototype.hasOwnProperty.call(proto, "constructor") && proto.constructor; + return typeof Ctor === "function" && Ctor instanceof Ctor && Function.prototype.call(Ctor) === Function.prototype.call(value); +} +function mergeDeep(defaults, options) { + const result = Object.assign({}, defaults); + Object.keys(options).forEach((key) => { + if (isPlainObject(options[key])) { + if (!(key in defaults)) + Object.assign(result, { [key]: options[key] }); + else + result[key] = mergeDeep(defaults[key], options[key]); + } else { + Object.assign(result, { [key]: options[key] }); + } + }); + return result; +} +function removeUndefinedProperties(obj) { + for (const key in obj) { + if (obj[key] === void 0) { + delete obj[key]; + } + } + return obj; +} +function merge(defaults, route, options) { + if (typeof route === "string") { + let [method, url] = route.split(" "); + options = Object.assign(url ? { method, url } : { url: method }, options); + } else { + options = Object.assign({}, route); + } + options.headers = lowercaseKeys(options.headers); + removeUndefinedProperties(options); + removeUndefinedProperties(options.headers); + const mergedOptions = mergeDeep(defaults || {}, options); + if (options.url === "/graphql") { + if (defaults && defaults.mediaType.previews?.length) { + mergedOptions.mediaType.previews = defaults.mediaType.previews.filter( + (preview) => !mergedOptions.mediaType.previews.includes(preview) + ).concat(mergedOptions.mediaType.previews); + } + mergedOptions.mediaType.previews = (mergedOptions.mediaType.previews || []).map((preview) => preview.replace(/-preview/, "")); + } + return mergedOptions; +} +function addQueryParameters(url, parameters) { + const separator = /\?/.test(url) ? "&" : "?"; + const names = Object.keys(parameters); + if (names.length === 0) { + return url; + } + return url + separator + names.map((name) => { + if (name === "q") { + return "q=" + parameters.q.split("+").map(encodeURIComponent).join("+"); + } + return `${name}=${encodeURIComponent(parameters[name])}`; + }).join("&"); +} +var urlVariableRegex = /\{[^}]+\}/g; +function removeNonChars(variableName) { + return variableName.replace(/^\W+|\W+$/g, "").split(/,/); +} +function extractUrlVariableNames(url) { + const matches = url.match(urlVariableRegex); + if (!matches) { + return []; + } + return matches.map(removeNonChars).reduce((a, b) => a.concat(b), []); +} +function omit(object, keysToOmit) { + const result = { __proto__: null }; + for (const key of Object.keys(object)) { + if (keysToOmit.indexOf(key) === -1) { + result[key] = object[key]; + } + } + return result; +} +function encodeReserved(str) { + return str.split(/(%[0-9A-Fa-f]{2})/g).map(function(part) { + if (!/%[0-9A-Fa-f]/.test(part)) { + part = encodeURI(part).replace(/%5B/g, "[").replace(/%5D/g, "]"); + } + return part; + }).join(""); +} +function encodeUnreserved(str) { + return encodeURIComponent(str).replace(/[!'()*]/g, function(c) { + return "%" + c.charCodeAt(0).toString(16).toUpperCase(); + }); +} +function encodeValue(operator, value, key) { + value = operator === "+" || operator === "#" ? encodeReserved(value) : encodeUnreserved(value); + if (key) { + return encodeUnreserved(key) + "=" + value; + } else { + return value; + } +} +function isDefined(value) { + return value !== void 0 && value !== null; +} +function isKeyOperator(operator) { + return operator === ";" || operator === "&" || operator === "?"; +} +function getValues(context2, operator, key, modifier) { + var value = context2[key], result = []; + if (isDefined(value) && value !== "") { + if (typeof value === "string" || typeof value === "number" || typeof value === "boolean") { + value = value.toString(); + if (modifier && modifier !== "*") { + value = value.substring(0, parseInt(modifier, 10)); + } + result.push( + encodeValue(operator, value, isKeyOperator(operator) ? key : "") + ); + } else { + if (modifier === "*") { + if (Array.isArray(value)) { + value.filter(isDefined).forEach(function(value2) { + result.push( + encodeValue(operator, value2, isKeyOperator(operator) ? key : "") + ); + }); + } else { + Object.keys(value).forEach(function(k) { + if (isDefined(value[k])) { + result.push(encodeValue(operator, value[k], k)); + } + }); + } + } else { + const tmp = []; + if (Array.isArray(value)) { + value.filter(isDefined).forEach(function(value2) { + tmp.push(encodeValue(operator, value2)); + }); + } else { + Object.keys(value).forEach(function(k) { + if (isDefined(value[k])) { + tmp.push(encodeUnreserved(k)); + tmp.push(encodeValue(operator, value[k].toString())); + } + }); + } + if (isKeyOperator(operator)) { + result.push(encodeUnreserved(key) + "=" + tmp.join(",")); + } else if (tmp.length !== 0) { + result.push(tmp.join(",")); + } + } + } + } else { + if (operator === ";") { + if (isDefined(value)) { + result.push(encodeUnreserved(key)); + } + } else if (value === "" && (operator === "&" || operator === "?")) { + result.push(encodeUnreserved(key) + "="); + } else if (value === "") { + result.push(""); + } + } + return result; +} +function parseUrl(template) { + return { + expand: expand.bind(null, template) + }; +} +function expand(template, context2) { + var operators = ["+", "#", ".", "/", ";", "?", "&"]; + template = template.replace( + /\{([^\{\}]+)\}|([^\{\}]+)/g, + function(_, expression, literal) { + if (expression) { + let operator = ""; + const values = []; + if (operators.indexOf(expression.charAt(0)) !== -1) { + operator = expression.charAt(0); + expression = expression.substr(1); + } + expression.split(/,/g).forEach(function(variable) { + var tmp = /([^:\*]*)(?::(\d+)|(\*))?/.exec(variable); + values.push(getValues(context2, operator, tmp[1], tmp[2] || tmp[3])); + }); + if (operator && operator !== "+") { + var separator = ","; + if (operator === "?") { + separator = "&"; + } else if (operator !== "#") { + separator = operator; + } + return (values.length !== 0 ? operator : "") + values.join(separator); + } else { + return values.join(","); + } + } else { + return encodeReserved(literal); + } + } + ); + if (template === "/") { + return template; + } else { + return template.replace(/\/$/, ""); + } +} +function parse2(options) { + let method = options.method.toUpperCase(); + let url = (options.url || "/").replace(/:([a-z]\w+)/g, "{$1}"); + let headers = Object.assign({}, options.headers); + let body; + let parameters = omit(options, [ + "method", + "baseUrl", + "url", + "headers", + "request", + "mediaType" + ]); + const urlVariableNames = extractUrlVariableNames(url); + url = parseUrl(url).expand(parameters); + if (!/^http/.test(url)) { + url = options.baseUrl + url; + } + const omittedParameters = Object.keys(options).filter((option) => urlVariableNames.includes(option)).concat("baseUrl"); + const remainingParameters = omit(parameters, omittedParameters); + const isBinaryRequest = /application\/octet-stream/i.test(headers.accept); + if (!isBinaryRequest) { + if (options.mediaType.format) { + headers.accept = headers.accept.split(/,/).map( + (format) => format.replace( + /application\/vnd(\.\w+)(\.v3)?(\.\w+)?(\+json)?$/, + `application/vnd$1$2.${options.mediaType.format}` + ) + ).join(","); + } + if (url.endsWith("/graphql")) { + if (options.mediaType.previews?.length) { + const previewsFromAcceptHeader = headers.accept.match(/[\w-]+(?=-preview)/g) || []; + headers.accept = previewsFromAcceptHeader.concat(options.mediaType.previews).map((preview) => { + const format = options.mediaType.format ? `.${options.mediaType.format}` : "+json"; + return `application/vnd.github.${preview}-preview${format}`; + }).join(","); + } + } + } + if (["GET", "HEAD"].includes(method)) { + url = addQueryParameters(url, remainingParameters); + } else { + if ("data" in remainingParameters) { + body = remainingParameters.data; + } else { + if (Object.keys(remainingParameters).length) { + body = remainingParameters; + } + } + } + if (!headers["content-type"] && typeof body !== "undefined") { + headers["content-type"] = "application/json; charset=utf-8"; + } + if (["PATCH", "PUT"].includes(method) && typeof body === "undefined") { + body = ""; + } + return Object.assign( + { method, url, headers }, + typeof body !== "undefined" ? { body } : null, + options.request ? { request: options.request } : null + ); +} +function endpointWithDefaults(defaults, route, options) { + return parse2(merge(defaults, route, options)); +} +function withDefaults(oldDefaults, newDefaults) { + const DEFAULTS2 = merge(oldDefaults, newDefaults); + const endpoint2 = endpointWithDefaults.bind(null, DEFAULTS2); + return Object.assign(endpoint2, { + DEFAULTS: DEFAULTS2, + defaults: withDefaults.bind(null, DEFAULTS2), + merge: merge.bind(null, DEFAULTS2), + parse: parse2 + }); +} +var endpoint = withDefaults(null, DEFAULTS); + +// node_modules/@octokit/request-error/dist-src/index.js +var RequestError = class extends Error { + name; + /** + * http status code + */ + status; + /** + * Request options that lead to the error. + */ + request; + /** + * Response object if a response was received + */ + response; + constructor(message, statusCode, options) { + super(message); + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + this.name = "HttpError"; + this.status = statusCode; + if ("response" in options) { + this.response = options.response; + } + const requestCopy = Object.assign({}, options.request); + if (options.request.headers.authorization) { + requestCopy.headers = Object.assign({}, options.request.headers, { + authorization: options.request.headers.authorization.replace( + / .*$/, + " [REDACTED]" + ) + }); + } + requestCopy.url = requestCopy.url.replace(/\bclient_secret=\w+/g, "client_secret=[REDACTED]").replace(/\baccess_token=\w+/g, "access_token=[REDACTED]"); + this.request = requestCopy; + } +}; + +// node_modules/@octokit/request/dist-bundle/index.js +var VERSION2 = "0.0.0-development"; +function isPlainObject2(value) { + if (typeof value !== "object" || value === null) + return false; + if (Object.prototype.toString.call(value) !== "[object Object]") + return false; + const proto = Object.getPrototypeOf(value); + if (proto === null) + return true; + const Ctor = Object.prototype.hasOwnProperty.call(proto, "constructor") && proto.constructor; + return typeof Ctor === "function" && Ctor instanceof Ctor && Function.prototype.call(Ctor) === Function.prototype.call(value); +} +function getBufferResponse(response) { + return response.arrayBuffer(); +} +function fetchWrapper(requestOptions) { + const log = requestOptions.request && requestOptions.request.log ? requestOptions.request.log : console; + const parseSuccessResponseBody = requestOptions.request?.parseSuccessResponseBody !== false; + if (isPlainObject2(requestOptions.body) || Array.isArray(requestOptions.body)) { + requestOptions.body = JSON.stringify(requestOptions.body); + } + let headers = {}; + let status; + let url; + let { fetch } = globalThis; + if (requestOptions.request?.fetch) { + fetch = requestOptions.request.fetch; + } + if (!fetch) { + throw new Error( + "fetch is not set. Please pass a fetch implementation as new Octokit({ request: { fetch }}). Learn more at https://github.com/octokit/octokit.js/#fetch-missing" + ); + } + return fetch(requestOptions.url, { + method: requestOptions.method, + body: requestOptions.body, + // Header values must be `string` + headers: Object.fromEntries( + Object.entries(requestOptions.headers).map(([name, value]) => [ + name, + String(value) + ]) + ), + signal: requestOptions.request?.signal, + // duplex must be set if request.body is ReadableStream or Async Iterables. + // See https://fetch.spec.whatwg.org/#dom-requestinit-duplex. + ...requestOptions.body && { duplex: "half" } + }).then(async (response) => { + url = response.url; + status = response.status; + for (const keyAndValue of response.headers) { + headers[keyAndValue[0]] = keyAndValue[1]; + } + if ("deprecation" in headers) { + const matches = headers.link && headers.link.match(/<([^>]+)>; rel="deprecation"/); + const deprecationLink = matches && matches.pop(); + log.warn( + `[@octokit/request] "${requestOptions.method} ${requestOptions.url}" is deprecated. It is scheduled to be removed on ${headers.sunset}${deprecationLink ? `. See ${deprecationLink}` : ""}` + ); + } + if (status === 204 || status === 205) { + return; + } + if (requestOptions.method === "HEAD") { + if (status < 400) { + return; + } + throw new RequestError(response.statusText, status, { + response: { + url, + status, + headers, + data: void 0 + }, + request: requestOptions + }); + } + if (status === 304) { + throw new RequestError("Not modified", status, { + response: { + url, + status, + headers, + data: await getResponseData(response) + }, + request: requestOptions + }); + } + if (status >= 400) { + const data = await getResponseData(response); + const error2 = new RequestError(toErrorMessage(data), status, { + response: { + url, + status, + headers, + data + }, + request: requestOptions + }); + throw error2; + } + return parseSuccessResponseBody ? await getResponseData(response) : response.body; + }).then((data) => { + return { + status, + url, + headers, + data + }; + }).catch((error2) => { + if (error2 instanceof RequestError) + throw error2; + else if (error2.name === "AbortError") + throw error2; + let message = error2.message; + if (error2.name === "TypeError" && "cause" in error2) { + if (error2.cause instanceof Error) { + message = error2.cause.message; + } else if (typeof error2.cause === "string") { + message = error2.cause; + } + } + throw new RequestError(message, 500, { + request: requestOptions + }); + }); +} +async function getResponseData(response) { + const contentType = response.headers.get("content-type"); + if (/application\/json/.test(contentType)) { + return response.json().catch(() => response.text()).catch(() => ""); + } + if (!contentType || /^text\/|charset=utf-8$/.test(contentType)) { + return response.text(); + } + return getBufferResponse(response); +} +function toErrorMessage(data) { + if (typeof data === "string") + return data; + let suffix; + if ("documentation_url" in data) { + suffix = ` - ${data.documentation_url}`; + } else { + suffix = ""; + } + if ("message" in data) { + if (Array.isArray(data.errors)) { + return `${data.message}: ${data.errors.map(JSON.stringify).join(", ")}${suffix}`; + } + return `${data.message}${suffix}`; + } + return `Unknown error: ${JSON.stringify(data)}`; +} +function withDefaults2(oldEndpoint, newDefaults) { + const endpoint2 = oldEndpoint.defaults(newDefaults); + const newApi = function(route, parameters) { + const endpointOptions = endpoint2.merge(route, parameters); + if (!endpointOptions.request || !endpointOptions.request.hook) { + return fetchWrapper(endpoint2.parse(endpointOptions)); + } + const request2 = (route2, parameters2) => { + return fetchWrapper( + endpoint2.parse(endpoint2.merge(route2, parameters2)) + ); + }; + Object.assign(request2, { + endpoint: endpoint2, + defaults: withDefaults2.bind(null, endpoint2) + }); + return endpointOptions.request.hook(request2, endpointOptions); + }; + return Object.assign(newApi, { + endpoint: endpoint2, + defaults: withDefaults2.bind(null, endpoint2) + }); +} +var request = withDefaults2(endpoint, { + headers: { + "user-agent": `octokit-request.js/${VERSION2} ${getUserAgent()}` + } +}); + +// node_modules/@octokit/graphql/dist-bundle/index.js +var VERSION3 = "0.0.0-development"; +function _buildMessageForResponseErrors(data) { + return `Request failed due to following response errors: +` + data.errors.map((e) => ` - ${e.message}`).join("\n"); +} +var GraphqlResponseError = class extends Error { + constructor(request2, headers, response) { + super(_buildMessageForResponseErrors(response)); + this.request = request2; + this.headers = headers; + this.response = response; + this.errors = response.errors; + this.data = response.data; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + } + name = "GraphqlResponseError"; + errors; + data; +}; +var NON_VARIABLE_OPTIONS = [ + "method", + "baseUrl", + "url", + "headers", + "request", + "query", + "mediaType" +]; +var FORBIDDEN_VARIABLE_OPTIONS = ["query", "method", "url"]; +var GHES_V3_SUFFIX_REGEX = /\/api\/v3\/?$/; +function graphql(request2, query, options) { + if (options) { + if (typeof query === "string" && "query" in options) { + return Promise.reject( + new Error(`[@octokit/graphql] "query" cannot be used as variable name`) + ); + } + for (const key in options) { + if (!FORBIDDEN_VARIABLE_OPTIONS.includes(key)) + continue; + return Promise.reject( + new Error( + `[@octokit/graphql] "${key}" cannot be used as variable name` + ) + ); + } + } + const parsedOptions = typeof query === "string" ? Object.assign({ query }, options) : query; + const requestOptions = Object.keys( + parsedOptions + ).reduce((result, key) => { + if (NON_VARIABLE_OPTIONS.includes(key)) { + result[key] = parsedOptions[key]; + return result; + } + if (!result.variables) { + result.variables = {}; + } + result.variables[key] = parsedOptions[key]; + return result; + }, {}); + const baseUrl = parsedOptions.baseUrl || request2.endpoint.DEFAULTS.baseUrl; + if (GHES_V3_SUFFIX_REGEX.test(baseUrl)) { + requestOptions.url = baseUrl.replace(GHES_V3_SUFFIX_REGEX, "/api/graphql"); + } + return request2(requestOptions).then((response) => { + if (response.data.errors) { + const headers = {}; + for (const key of Object.keys(response.headers)) { + headers[key] = response.headers[key]; + } + throw new GraphqlResponseError( + requestOptions, + headers, + response.data + ); + } + return response.data.data; + }); +} +function withDefaults3(request2, newDefaults) { + const newRequest = request2.defaults(newDefaults); + const newApi = (query, options) => { + return graphql(newRequest, query, options); + }; + return Object.assign(newApi, { + defaults: withDefaults3.bind(null, newRequest), + endpoint: newRequest.endpoint + }); +} +var graphql2 = withDefaults3(request, { + headers: { + "user-agent": `octokit-graphql.js/${VERSION3} ${getUserAgent()}` + }, + method: "POST", + url: "/graphql" +}); +function withCustomRequest(customRequest) { + return withDefaults3(customRequest, { + method: "POST", + url: "/graphql" + }); +} + +// node_modules/@octokit/auth-token/dist-bundle/index.js +var REGEX_IS_INSTALLATION_LEGACY = /^v1\./; +var REGEX_IS_INSTALLATION = /^ghs_/; +var REGEX_IS_USER_TO_SERVER = /^ghu_/; +async function auth(token) { + const isApp = token.split(/\./).length === 3; + const isInstallation = REGEX_IS_INSTALLATION_LEGACY.test(token) || REGEX_IS_INSTALLATION.test(token); + const isUserToServer = REGEX_IS_USER_TO_SERVER.test(token); + const tokenType = isApp ? "app" : isInstallation ? "installation" : isUserToServer ? "user-to-server" : "oauth"; + return { + type: "token", + token, + tokenType + }; +} +function withAuthorizationPrefix(token) { + if (token.split(/\./).length === 3) { + return `bearer ${token}`; + } + return `token ${token}`; +} +async function hook(token, request2, route, parameters) { + const endpoint2 = request2.endpoint.merge( + route, + parameters + ); + endpoint2.headers.authorization = withAuthorizationPrefix(token); + return request2(endpoint2); +} +var createTokenAuth = function createTokenAuth2(token) { + if (!token) { + throw new Error("[@octokit/auth-token] No token passed to createTokenAuth"); + } + if (typeof token !== "string") { + throw new Error( + "[@octokit/auth-token] Token passed to createTokenAuth is not a string" + ); + } + token = token.replace(/^(token|bearer) +/i, ""); + return Object.assign(auth.bind(null, token), { + hook: hook.bind(null, token) + }); +}; + +// node_modules/@octokit/core/dist-src/version.js +var VERSION4 = "6.1.1"; + +// node_modules/@octokit/core/dist-src/index.js +var noop = () => { +}; +var consoleWarn = console.warn.bind(console); +var consoleError = console.error.bind(console); +var userAgentTrail = `octokit-core.js/${VERSION4} ${getUserAgent()}`; +var Octokit = class { + static VERSION = VERSION4; + static defaults(defaults) { + const OctokitWithDefaults = class extends this { + constructor(...args) { + const options = args[0] || {}; + if (typeof defaults === "function") { + super(defaults(options)); + return; + } + super( + Object.assign( + {}, + defaults, + options, + options.userAgent && defaults.userAgent ? { + userAgent: `${options.userAgent} ${defaults.userAgent}` + } : null + ) + ); + } + }; + return OctokitWithDefaults; + } + static plugins = []; + /** + * Attach a plugin (or many) to your Octokit instance. + * + * @example + * const API = Octokit.plugin(plugin1, plugin2, plugin3, ...) + */ + static plugin(...newPlugins) { + const currentPlugins = this.plugins; + const NewOctokit = class extends this { + static plugins = currentPlugins.concat( + newPlugins.filter((plugin) => !currentPlugins.includes(plugin)) + ); + }; + return NewOctokit; + } + constructor(options = {}) { + const hook2 = new before_after_hook_default.Collection(); + const requestDefaults = { + baseUrl: request.endpoint.DEFAULTS.baseUrl, + headers: {}, + request: Object.assign({}, options.request, { + // @ts-ignore internal usage only, no need to type + hook: hook2.bind(null, "request") + }), + mediaType: { + previews: [], + format: "" + } + }; + requestDefaults.headers["user-agent"] = options.userAgent ? `${options.userAgent} ${userAgentTrail}` : userAgentTrail; + if (options.baseUrl) { + requestDefaults.baseUrl = options.baseUrl; + } + if (options.previews) { + requestDefaults.mediaType.previews = options.previews; + } + if (options.timeZone) { + requestDefaults.headers["time-zone"] = options.timeZone; + } + this.request = request.defaults(requestDefaults); + this.graphql = withCustomRequest(this.request).defaults(requestDefaults); + this.log = Object.assign( + { + debug: noop, + info: noop, + warn: consoleWarn, + error: consoleError + }, + options.log + ); + this.hook = hook2; + if (!options.authStrategy) { + if (!options.auth) { + this.auth = async () => ({ + type: "unauthenticated" + }); + } else { + const auth2 = createTokenAuth(options.auth); + hook2.wrap("request", auth2.hook); + this.auth = auth2; + } + } else { + const { authStrategy, ...otherOptions } = options; + const auth2 = authStrategy( + Object.assign( + { + request: this.request, + log: this.log, + // we pass the current octokit instance as well as its constructor options + // to allow for authentication strategies that return a new octokit instance + // that shares the same internal state as the current one. The original + // requirement for this was the "event-octokit" authentication strategy + // of https://github.com/probot/octokit-auth-probot. + octokit: this, + octokitOptions: otherOptions + }, + options.auth + ) + ); + hook2.wrap("request", auth2.hook); + this.auth = auth2; + } + const classConstructor = this.constructor; + for (let i = 0; i < classConstructor.plugins.length; ++i) { + Object.assign(this, classConstructor.plugins[i](this, options)); + } + } + // assigned during constructor + request; + graphql; + log; + hook; + // TODO: type `octokit.auth` based on passed options.authStrategy + auth; +}; + +// node_modules/@octokit/plugin-paginate-graphql/dist-bundle/index.js +var generateMessage = (path, cursorValue) => `The cursor at "${path.join( + "," +)}" did not change its value "${cursorValue}" after a page transition. Please make sure your that your query is set up correctly.`; +var MissingCursorChange = class extends Error { + constructor(pageInfo, cursorValue) { + super(generateMessage(pageInfo.pathInQuery, cursorValue)); + this.pageInfo = pageInfo; + this.cursorValue = cursorValue; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + } + name = "MissingCursorChangeError"; +}; +var MissingPageInfo = class extends Error { + constructor(response) { + super( + `No pageInfo property found in response. Please make sure to specify the pageInfo in your query. Response-Data: ${JSON.stringify( + response, + null, + 2 + )}` + ); + this.response = response; + if (Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + } + name = "MissingPageInfo"; +}; +var isObject = (value) => Object.prototype.toString.call(value) === "[object Object]"; +function findPaginatedResourcePath(responseData) { + const paginatedResourcePath = deepFindPathToProperty( + responseData, + "pageInfo" + ); + if (paginatedResourcePath.length === 0) { + throw new MissingPageInfo(responseData); + } + return paginatedResourcePath; +} +var deepFindPathToProperty = (object, searchProp, path = []) => { + for (const key of Object.keys(object)) { + const currentPath = [...path, key]; + const currentValue = object[key]; + if (currentValue.hasOwnProperty(searchProp)) { + return currentPath; + } + if (isObject(currentValue)) { + const result = deepFindPathToProperty( + currentValue, + searchProp, + currentPath + ); + if (result.length > 0) { + return result; + } + } + } + return []; +}; +var get = (object, path) => { + return path.reduce((current, nextProperty) => current[nextProperty], object); +}; +var set = (object, path, mutator) => { + const lastProperty = path[path.length - 1]; + const parentPath = [...path].slice(0, -1); + const parent = get(object, parentPath); + if (typeof mutator === "function") { + parent[lastProperty] = mutator(parent[lastProperty]); + } else { + parent[lastProperty] = mutator; + } +}; +var extractPageInfos = (responseData) => { + const pageInfoPath = findPaginatedResourcePath(responseData); + return { + pathInQuery: pageInfoPath, + pageInfo: get(responseData, [...pageInfoPath, "pageInfo"]) + }; +}; +var isForwardSearch = (givenPageInfo) => { + return givenPageInfo.hasOwnProperty("hasNextPage"); +}; +var getCursorFrom = (pageInfo) => isForwardSearch(pageInfo) ? pageInfo.endCursor : pageInfo.startCursor; +var hasAnotherPage = (pageInfo) => isForwardSearch(pageInfo) ? pageInfo.hasNextPage : pageInfo.hasPreviousPage; +var createIterator = (octokit) => { + return (query, initialParameters = {}) => { + let nextPageExists = true; + let parameters = { ...initialParameters }; + return { + [Symbol.asyncIterator]: () => ({ + async next() { + if (!nextPageExists) + return { done: true, value: {} }; + const response = await octokit.graphql( + query, + parameters + ); + const pageInfoContext = extractPageInfos(response); + const nextCursorValue = getCursorFrom(pageInfoContext.pageInfo); + nextPageExists = hasAnotherPage(pageInfoContext.pageInfo); + if (nextPageExists && nextCursorValue === parameters.cursor) { + throw new MissingCursorChange(pageInfoContext, nextCursorValue); + } + parameters = { + ...parameters, + cursor: nextCursorValue + }; + return { done: false, value: response }; + } + }) + }; + }; +}; +var mergeResponses = (response1, response2) => { + if (Object.keys(response1).length === 0) { + return Object.assign(response1, response2); + } + const path = findPaginatedResourcePath(response1); + const nodesPath = [...path, "nodes"]; + const newNodes = get(response2, nodesPath); + if (newNodes) { + set(response1, nodesPath, (values) => { + return [...values, ...newNodes]; + }); + } + const edgesPath = [...path, "edges"]; + const newEdges = get(response2, edgesPath); + if (newEdges) { + set(response1, edgesPath, (values) => { + return [...values, ...newEdges]; + }); + } + const pageInfoPath = [...path, "pageInfo"]; + set(response1, pageInfoPath, get(response2, pageInfoPath)); + return response1; +}; +var createPaginate = (octokit) => { + const iterator = createIterator(octokit); + return async (query, initialParameters = {}) => { + let mergedResponse = {}; + for await (const response of iterator( + query, + initialParameters + )) { + mergedResponse = mergeResponses(mergedResponse, response); + } + return mergedResponse; + }; +}; +function paginateGraphQL(octokit) { + return { + graphql: Object.assign(octokit.graphql, { + paginate: Object.assign(createPaginate(octokit), { + iterator: createIterator(octokit) + }) + }) + }; +} + // src/github-api.ts -var import_core = __toESM(require_dist_node8(), 1); -var import_plugin_paginate_graphql = __toESM(require_dist_node11(), 1); import { join, relative } from "path"; // node_modules/zod/lib/index.mjs @@ -26515,7 +27441,7 @@ var z = /* @__PURE__ */ Object.freeze({ }); // src/github-api.ts -var PaginatableOctokit = import_core.Octokit.plugin(import_plugin_paginate_graphql.paginateGraphql); +var PaginatableOctokit = Octokit.plugin(paginateGraphQL); var ListItem = z.object({ workflowFile: z.string().endsWith(".yml"), jobName: z.string().min(1).optional() @@ -26852,12 +27778,4 @@ undici/lib/fetch/body.js: undici/lib/websocket/frame.js: (*! ws. MIT License. Einar Otto Stangvik *) - -is-plain-object/dist/is-plain-object.js: - (*! - * is-plain-object - * - * Copyright (c) 2014-2017, Jon Schlinkert. - * Released under the MIT License. - *) */ diff --git a/package-lock.json b/package-lock.json index c5397428..62de07ac 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,9 +11,9 @@ "dependencies": { "@actions/core": "^1.10.1", "@actions/github": "^6.0.0", - "@octokit/core": "^5.1.0", - "@octokit/graphql-schema": "^14.57.0", - "@octokit/plugin-paginate-graphql": "^4.0.0", + "@octokit/core": "^6.1.1", + "@octokit/graphql-schema": "^15.4.2", + "@octokit/plugin-paginate-graphql": "^5.2.0", "ansi-styles": "^6.2.1", "zod": "^3.22.4" }, @@ -49,6 +49,93 @@ "@octokit/plugin-rest-endpoint-methods": "^10.0.0" } }, + "node_modules/@actions/github/node_modules/@octokit/auth-token": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-4.0.0.tgz", + "integrity": "sha512-tY/msAuJo6ARbK6SPIxZrPBms3xPbfwBrulZe0Wtr/DIY9lje2HeV1uoebShn6mx7SjCHif6EjMvoREj+gZ+SA==", + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/@octokit/core": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-5.1.0.tgz", + "integrity": "sha512-BDa2VAMLSh3otEiaMJ/3Y36GU4qf6GI+VivQ/P41NC6GHcdxpKlqV0ikSZ5gdQsmS3ojXeRx5vasgNTinF0Q4g==", + "dependencies": { + "@octokit/auth-token": "^4.0.0", + "@octokit/graphql": "^7.0.0", + "@octokit/request": "^8.0.2", + "@octokit/request-error": "^5.0.0", + "@octokit/types": "^12.0.0", + "before-after-hook": "^2.2.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/@octokit/endpoint": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-9.0.4.tgz", + "integrity": "sha512-DWPLtr1Kz3tv8L0UvXTDP1fNwM0S+z6EJpRcvH66orY6Eld4XBMCSYsaWp4xIm61jTWxK68BrR7ibO+vSDnZqw==", + "dependencies": { + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/@octokit/graphql": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-7.0.2.tgz", + "integrity": "sha512-OJ2iGMtj5Tg3s6RaXH22cJcxXRi7Y3EBqbHTBRq+PQAqfaS8f/236fUrWhfSn8P4jovyzqucxme7/vWSSZBX2Q==", + "dependencies": { + "@octokit/request": "^8.0.1", + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/@octokit/request": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-8.2.0.tgz", + "integrity": "sha512-exPif6x5uwLqv1N1irkLG1zZNJkOtj8bZxuVHd71U5Ftuxf2wGNvAJyNBcPbPC+EBzwYEbBDdSFb8EPcjpYxPQ==", + "dependencies": { + "@octokit/endpoint": "^9.0.0", + "@octokit/request-error": "^5.0.0", + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/@octokit/request-error": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-5.0.1.tgz", + "integrity": "sha512-X7pnyTMV7MgtGmiXBwmO6M5kIPrntOXdyKZLigNfQWSEQzVxR4a4vo49vJjTWX70mPndj8KhfT4Dx+2Ng3vnBQ==", + "dependencies": { + "@octokit/types": "^12.0.0", + "deprecation": "^2.0.0", + "once": "^1.4.0" + }, + "engines": { + "node": ">= 18" + } + }, + "node_modules/@actions/github/node_modules/before-after-hook": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.3.tgz", + "integrity": "sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ==" + }, + "node_modules/@actions/github/node_modules/universal-user-agent": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.1.tgz", + "integrity": "sha512-yCzhz6FN2wU1NiiQRogkTQszlQSlpWaw8SvVegAc+bDxbzHgh1vX8uIe8OYyMH6DwH+sdTJsgMl36+mSMdRJIQ==" + }, "node_modules/@actions/http-client": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-2.2.0.tgz", @@ -435,79 +522,117 @@ } }, "node_modules/@octokit/auth-token": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-4.0.0.tgz", - "integrity": "sha512-tY/msAuJo6ARbK6SPIxZrPBms3xPbfwBrulZe0Wtr/DIY9lje2HeV1uoebShn6mx7SjCHif6EjMvoREj+gZ+SA==", + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-5.1.0.tgz", + "integrity": "sha512-JH+5PhVMjpbBuKlykiseCHa2uZdEd8Qm/N9Kpqncx4o/wkGF38gqVjIP2gZqfaP3nxFZPpg0FwGClKzBi6nS2g==", "engines": { "node": ">= 18" } }, "node_modules/@octokit/core": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@octokit/core/-/core-5.1.0.tgz", - "integrity": "sha512-BDa2VAMLSh3otEiaMJ/3Y36GU4qf6GI+VivQ/P41NC6GHcdxpKlqV0ikSZ5gdQsmS3ojXeRx5vasgNTinF0Q4g==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-6.1.1.tgz", + "integrity": "sha512-uVypPdnZV7YoEa69Ky2kTSw3neFLGT0PZ54OwUMDph7w6TmhF0ZnoVcvb/kYnjDHCFo2mfoeRDYifLKhLNasUg==", "dependencies": { - "@octokit/auth-token": "^4.0.0", - "@octokit/graphql": "^7.0.0", - "@octokit/request": "^8.0.2", - "@octokit/request-error": "^5.0.0", - "@octokit/types": "^12.0.0", - "before-after-hook": "^2.2.0", - "universal-user-agent": "^6.0.0" + "@octokit/auth-token": "^5.0.0", + "@octokit/graphql": "^8.0.0", + "@octokit/request": "^9.0.0", + "@octokit/request-error": "^6.0.1", + "@octokit/types": "^13.0.0", + "before-after-hook": "^3.0.2", + "universal-user-agent": "^7.0.0" }, "engines": { "node": ">= 18" } }, + "node_modules/@octokit/core/node_modules/@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "node_modules/@octokit/core/node_modules/@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "dependencies": { + "@octokit/openapi-types": "^21.0.0" + } + }, "node_modules/@octokit/endpoint": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-9.0.1.tgz", - "integrity": "sha512-hRlOKAovtINHQPYHZlfyFwaM8OyetxeoC81lAkBy34uLb8exrZB50SQdeW3EROqiY9G9yxQTpp5OHTV54QD+vA==", + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-10.1.0.tgz", + "integrity": "sha512-ogZ5uLMeGBZUzS32fNt9j+dNw3kkEn5CSw4CVkN1EvCNdFYWrQ5diQR6Hh52VrPR0oayIoYTqQFL/l8RqkV0qw==", "dependencies": { - "@octokit/types": "^12.0.0", - "is-plain-object": "^5.0.0", - "universal-user-agent": "^6.0.0" + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.2" }, "engines": { "node": ">= 18" } }, + "node_modules/@octokit/endpoint/node_modules/@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "node_modules/@octokit/endpoint/node_modules/@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "dependencies": { + "@octokit/openapi-types": "^21.0.0" + } + }, "node_modules/@octokit/graphql": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-7.0.2.tgz", - "integrity": "sha512-OJ2iGMtj5Tg3s6RaXH22cJcxXRi7Y3EBqbHTBRq+PQAqfaS8f/236fUrWhfSn8P4jovyzqucxme7/vWSSZBX2Q==", + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-8.1.0.tgz", + "integrity": "sha512-XDvj6GcUnQYgbCLXElt3vZDzNIPGvGiwxQO2XzsvfVUjebGh0E5eCD/1My9zUGSNKaGVZitVuO8LMziGmoFryg==", "dependencies": { - "@octokit/request": "^8.0.1", - "@octokit/types": "^12.0.0", - "universal-user-agent": "^6.0.0" + "@octokit/request": "^9.0.0", + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.0" }, "engines": { "node": ">= 18" } }, "node_modules/@octokit/graphql-schema": { - "version": "14.57.0", - "resolved": "https://registry.npmjs.org/@octokit/graphql-schema/-/graphql-schema-14.57.0.tgz", - "integrity": "sha512-DvUIxJkfboiQEOme4DOpF4+EtOh1qbYffm/hbcFdqAQzWFPV19Nkul9t/XnyKRPFyy26Nwf8QesCOeYw8os5rQ==", + "version": "15.4.2", + "resolved": "https://registry.npmjs.org/@octokit/graphql-schema/-/graphql-schema-15.4.2.tgz", + "integrity": "sha512-PIfFAnTgRN5MW9ndnYIL3R07LZXQd8JlP1e2s4Ku7T+pvVXgl8JaAuongNdImKYOhrqEukgXNusKTZc2KEXUmg==", "dependencies": { "graphql": "^16.0.0", "graphql-tag": "^2.10.3" } }, + "node_modules/@octokit/graphql/node_modules/@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "node_modules/@octokit/graphql/node_modules/@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "dependencies": { + "@octokit/openapi-types": "^21.0.0" + } + }, "node_modules/@octokit/openapi-types": { "version": "19.0.0", "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-19.0.0.tgz", "integrity": "sha512-PclQ6JGMTE9iUStpzMkwLCISFn/wDeRjkZFIKALpvJQNBGwDoYYi2fFvuHwssoQ1rXI5mfh6jgTgWuddeUzfWw==" }, "node_modules/@octokit/plugin-paginate-graphql": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-graphql/-/plugin-paginate-graphql-4.0.0.tgz", - "integrity": "sha512-7HcYW5tP7/Z6AETAPU14gp5H5KmCPT3hmJrS/5tO7HIgbwenYmgw4OY9Ma54FDySuxMwD+wsJlxtuGWwuZuItA==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-graphql/-/plugin-paginate-graphql-5.2.0.tgz", + "integrity": "sha512-nrv3qH8gyLXxl6MdQMG8EV4+y5IfFCHQy+MxDk52flg6N9mMkTuTdMiedh9fccD3g/6X560jaQFJk88IBZqCtw==", "engines": { "node": ">= 18" }, "peerDependencies": { - "@octokit/core": ">=5" + "@octokit/core": ">=6" } }, "node_modules/@octokit/plugin-paginate-rest": { @@ -539,33 +664,43 @@ } }, "node_modules/@octokit/request": { - "version": "8.1.2", - "resolved": "https://registry.npmjs.org/@octokit/request/-/request-8.1.2.tgz", - "integrity": "sha512-A0RJJfzjlZQwb+39eDm5UM23dkxbp28WEG4p2ueH+Q2yY4p349aRK/vcUlEuIB//ggcrHJceoYYkBP/LYCoXEg==", + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-9.0.1.tgz", + "integrity": "sha512-kL+cAcbSl3dctYLuJmLfx6Iku2MXXy0jszhaEIjQNaCp4zjHXrhVAHeuaRdNvJjW9qjl3u1MJ72+OuBP0YW/pg==", "dependencies": { - "@octokit/endpoint": "^9.0.0", - "@octokit/request-error": "^5.0.0", + "@octokit/endpoint": "^10.0.0", + "@octokit/request-error": "^6.0.1", "@octokit/types": "^12.0.0", - "is-plain-object": "^5.0.0", - "universal-user-agent": "^6.0.0" + "universal-user-agent": "^7.0.2" }, "engines": { "node": ">= 18" } }, "node_modules/@octokit/request-error": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-5.0.1.tgz", - "integrity": "sha512-X7pnyTMV7MgtGmiXBwmO6M5kIPrntOXdyKZLigNfQWSEQzVxR4a4vo49vJjTWX70mPndj8KhfT4Dx+2Ng3vnBQ==", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-6.1.0.tgz", + "integrity": "sha512-xcLJv4IgfWIOEEVZwfhUN3yHNWJL0AMw1J1Ba8BofM9RdDTbapg6MO4zNxlPS4XXX9aAIsbDRa47K57EhgeVAw==", "dependencies": { - "@octokit/types": "^12.0.0", - "deprecation": "^2.0.0", - "once": "^1.4.0" + "@octokit/types": "^13.0.0" }, "engines": { "node": ">= 18" } }, + "node_modules/@octokit/request-error/node_modules/@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "node_modules/@octokit/request-error/node_modules/@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "dependencies": { + "@octokit/openapi-types": "^21.0.0" + } + }, "node_modules/@octokit/types": { "version": "12.0.0", "resolved": "https://registry.npmjs.org/@octokit/types/-/types-12.0.0.tgz", @@ -607,9 +742,9 @@ } }, "node_modules/before-after-hook": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.2.tgz", - "integrity": "sha512-3pZEU3NT5BFUo/AD5ERPWOgQOCZITni6iavr5AUw5AUwQjMlI0kzu5btnyD39AF0gUEsDPwJT+oY1ORBJijPjQ==" + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-3.0.2.tgz", + "integrity": "sha512-Nik3Sc0ncrMK4UUdXQmAnRtzmNQTAAXmXIopizwZ1W1t8QmfJj+zL4OA2I7XPTPW5z5TDqv4hRo/JzouDJnX3A==" }, "node_modules/deprecation": { "version": "2.3.1", @@ -702,14 +837,6 @@ "graphql": "^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0" } }, - "node_modules/is-plain-object": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", - "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==", - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -1196,9 +1323,9 @@ "dev": true }, "node_modules/universal-user-agent": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz", - "integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w==" + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-7.0.2.tgz", + "integrity": "sha512-0JCqzSKnStlRRQfCdowvqy3cy0Dvtlb8xecj/H8JFZuCze4rwjPZQOgvFvn0Ws/usCHQFGpyr+pB9adaGwXn4Q==" }, "node_modules/uuid": { "version": "8.3.2", @@ -1241,6 +1368,77 @@ "@octokit/core": "^5.0.1", "@octokit/plugin-paginate-rest": "^9.0.0", "@octokit/plugin-rest-endpoint-methods": "^10.0.0" + }, + "dependencies": { + "@octokit/auth-token": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-4.0.0.tgz", + "integrity": "sha512-tY/msAuJo6ARbK6SPIxZrPBms3xPbfwBrulZe0Wtr/DIY9lje2HeV1uoebShn6mx7SjCHif6EjMvoREj+gZ+SA==" + }, + "@octokit/core": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-5.1.0.tgz", + "integrity": "sha512-BDa2VAMLSh3otEiaMJ/3Y36GU4qf6GI+VivQ/P41NC6GHcdxpKlqV0ikSZ5gdQsmS3ojXeRx5vasgNTinF0Q4g==", + "requires": { + "@octokit/auth-token": "^4.0.0", + "@octokit/graphql": "^7.0.0", + "@octokit/request": "^8.0.2", + "@octokit/request-error": "^5.0.0", + "@octokit/types": "^12.0.0", + "before-after-hook": "^2.2.0", + "universal-user-agent": "^6.0.0" + } + }, + "@octokit/endpoint": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-9.0.4.tgz", + "integrity": "sha512-DWPLtr1Kz3tv8L0UvXTDP1fNwM0S+z6EJpRcvH66orY6Eld4XBMCSYsaWp4xIm61jTWxK68BrR7ibO+vSDnZqw==", + "requires": { + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + } + }, + "@octokit/graphql": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-7.0.2.tgz", + "integrity": "sha512-OJ2iGMtj5Tg3s6RaXH22cJcxXRi7Y3EBqbHTBRq+PQAqfaS8f/236fUrWhfSn8P4jovyzqucxme7/vWSSZBX2Q==", + "requires": { + "@octokit/request": "^8.0.1", + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + } + }, + "@octokit/request": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-8.2.0.tgz", + "integrity": "sha512-exPif6x5uwLqv1N1irkLG1zZNJkOtj8bZxuVHd71U5Ftuxf2wGNvAJyNBcPbPC+EBzwYEbBDdSFb8EPcjpYxPQ==", + "requires": { + "@octokit/endpoint": "^9.0.0", + "@octokit/request-error": "^5.0.0", + "@octokit/types": "^12.0.0", + "universal-user-agent": "^6.0.0" + } + }, + "@octokit/request-error": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-5.0.1.tgz", + "integrity": "sha512-X7pnyTMV7MgtGmiXBwmO6M5kIPrntOXdyKZLigNfQWSEQzVxR4a4vo49vJjTWX70mPndj8KhfT4Dx+2Ng3vnBQ==", + "requires": { + "@octokit/types": "^12.0.0", + "deprecation": "^2.0.0", + "once": "^1.4.0" + } + }, + "before-after-hook": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.3.tgz", + "integrity": "sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ==" + }, + "universal-user-agent": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.1.tgz", + "integrity": "sha512-yCzhz6FN2wU1NiiQRogkTQszlQSlpWaw8SvVegAc+bDxbzHgh1vX8uIe8OYyMH6DwH+sdTJsgMl36+mSMdRJIQ==" + } } }, "@actions/http-client": { @@ -1419,48 +1617,92 @@ "integrity": "sha512-JUFJad5lv7jxj926GPgymrWQxxjPYuJNiNjNMzqT+HiuP6Vl3dk5xzG+8sTX96np0ZAluvaMzPsjhHZ5rNuNQQ==" }, "@octokit/auth-token": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-4.0.0.tgz", - "integrity": "sha512-tY/msAuJo6ARbK6SPIxZrPBms3xPbfwBrulZe0Wtr/DIY9lje2HeV1uoebShn6mx7SjCHif6EjMvoREj+gZ+SA==" + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-5.1.0.tgz", + "integrity": "sha512-JH+5PhVMjpbBuKlykiseCHa2uZdEd8Qm/N9Kpqncx4o/wkGF38gqVjIP2gZqfaP3nxFZPpg0FwGClKzBi6nS2g==" }, "@octokit/core": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@octokit/core/-/core-5.1.0.tgz", - "integrity": "sha512-BDa2VAMLSh3otEiaMJ/3Y36GU4qf6GI+VivQ/P41NC6GHcdxpKlqV0ikSZ5gdQsmS3ojXeRx5vasgNTinF0Q4g==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@octokit/core/-/core-6.1.1.tgz", + "integrity": "sha512-uVypPdnZV7YoEa69Ky2kTSw3neFLGT0PZ54OwUMDph7w6TmhF0ZnoVcvb/kYnjDHCFo2mfoeRDYifLKhLNasUg==", "requires": { - "@octokit/auth-token": "^4.0.0", - "@octokit/graphql": "^7.0.0", - "@octokit/request": "^8.0.2", - "@octokit/request-error": "^5.0.0", - "@octokit/types": "^12.0.0", - "before-after-hook": "^2.2.0", - "universal-user-agent": "^6.0.0" + "@octokit/auth-token": "^5.0.0", + "@octokit/graphql": "^8.0.0", + "@octokit/request": "^9.0.0", + "@octokit/request-error": "^6.0.1", + "@octokit/types": "^13.0.0", + "before-after-hook": "^3.0.2", + "universal-user-agent": "^7.0.0" + }, + "dependencies": { + "@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "requires": { + "@octokit/openapi-types": "^21.0.0" + } + } } }, "@octokit/endpoint": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-9.0.1.tgz", - "integrity": "sha512-hRlOKAovtINHQPYHZlfyFwaM8OyetxeoC81lAkBy34uLb8exrZB50SQdeW3EROqiY9G9yxQTpp5OHTV54QD+vA==", + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-10.1.0.tgz", + "integrity": "sha512-ogZ5uLMeGBZUzS32fNt9j+dNw3kkEn5CSw4CVkN1EvCNdFYWrQ5diQR6Hh52VrPR0oayIoYTqQFL/l8RqkV0qw==", "requires": { - "@octokit/types": "^12.0.0", - "is-plain-object": "^5.0.0", - "universal-user-agent": "^6.0.0" + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.2" + }, + "dependencies": { + "@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "requires": { + "@octokit/openapi-types": "^21.0.0" + } + } } }, "@octokit/graphql": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-7.0.2.tgz", - "integrity": "sha512-OJ2iGMtj5Tg3s6RaXH22cJcxXRi7Y3EBqbHTBRq+PQAqfaS8f/236fUrWhfSn8P4jovyzqucxme7/vWSSZBX2Q==", + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-8.1.0.tgz", + "integrity": "sha512-XDvj6GcUnQYgbCLXElt3vZDzNIPGvGiwxQO2XzsvfVUjebGh0E5eCD/1My9zUGSNKaGVZitVuO8LMziGmoFryg==", "requires": { - "@octokit/request": "^8.0.1", - "@octokit/types": "^12.0.0", - "universal-user-agent": "^6.0.0" + "@octokit/request": "^9.0.0", + "@octokit/types": "^13.0.0", + "universal-user-agent": "^7.0.0" + }, + "dependencies": { + "@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "requires": { + "@octokit/openapi-types": "^21.0.0" + } + } } }, "@octokit/graphql-schema": { - "version": "14.57.0", - "resolved": "https://registry.npmjs.org/@octokit/graphql-schema/-/graphql-schema-14.57.0.tgz", - "integrity": "sha512-DvUIxJkfboiQEOme4DOpF4+EtOh1qbYffm/hbcFdqAQzWFPV19Nkul9t/XnyKRPFyy26Nwf8QesCOeYw8os5rQ==", + "version": "15.4.2", + "resolved": "https://registry.npmjs.org/@octokit/graphql-schema/-/graphql-schema-15.4.2.tgz", + "integrity": "sha512-PIfFAnTgRN5MW9ndnYIL3R07LZXQd8JlP1e2s4Ku7T+pvVXgl8JaAuongNdImKYOhrqEukgXNusKTZc2KEXUmg==", "requires": { "graphql": "^16.0.0", "graphql-tag": "^2.10.3" @@ -1472,9 +1714,9 @@ "integrity": "sha512-PclQ6JGMTE9iUStpzMkwLCISFn/wDeRjkZFIKALpvJQNBGwDoYYi2fFvuHwssoQ1rXI5mfh6jgTgWuddeUzfWw==" }, "@octokit/plugin-paginate-graphql": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-graphql/-/plugin-paginate-graphql-4.0.0.tgz", - "integrity": "sha512-7HcYW5tP7/Z6AETAPU14gp5H5KmCPT3hmJrS/5tO7HIgbwenYmgw4OY9Ma54FDySuxMwD+wsJlxtuGWwuZuItA==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-graphql/-/plugin-paginate-graphql-5.2.0.tgz", + "integrity": "sha512-nrv3qH8gyLXxl6MdQMG8EV4+y5IfFCHQy+MxDk52flg6N9mMkTuTdMiedh9fccD3g/6X560jaQFJk88IBZqCtw==", "requires": {} }, "@octokit/plugin-paginate-rest": { @@ -1494,25 +1736,37 @@ } }, "@octokit/request": { - "version": "8.1.2", - "resolved": "https://registry.npmjs.org/@octokit/request/-/request-8.1.2.tgz", - "integrity": "sha512-A0RJJfzjlZQwb+39eDm5UM23dkxbp28WEG4p2ueH+Q2yY4p349aRK/vcUlEuIB//ggcrHJceoYYkBP/LYCoXEg==", + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/@octokit/request/-/request-9.0.1.tgz", + "integrity": "sha512-kL+cAcbSl3dctYLuJmLfx6Iku2MXXy0jszhaEIjQNaCp4zjHXrhVAHeuaRdNvJjW9qjl3u1MJ72+OuBP0YW/pg==", "requires": { - "@octokit/endpoint": "^9.0.0", - "@octokit/request-error": "^5.0.0", + "@octokit/endpoint": "^10.0.0", + "@octokit/request-error": "^6.0.1", "@octokit/types": "^12.0.0", - "is-plain-object": "^5.0.0", - "universal-user-agent": "^6.0.0" + "universal-user-agent": "^7.0.2" } }, "@octokit/request-error": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-5.0.1.tgz", - "integrity": "sha512-X7pnyTMV7MgtGmiXBwmO6M5kIPrntOXdyKZLigNfQWSEQzVxR4a4vo49vJjTWX70mPndj8KhfT4Dx+2Ng3vnBQ==", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-6.1.0.tgz", + "integrity": "sha512-xcLJv4IgfWIOEEVZwfhUN3yHNWJL0AMw1J1Ba8BofM9RdDTbapg6MO4zNxlPS4XXX9aAIsbDRa47K57EhgeVAw==", "requires": { - "@octokit/types": "^12.0.0", - "deprecation": "^2.0.0", - "once": "^1.4.0" + "@octokit/types": "^13.0.0" + }, + "dependencies": { + "@octokit/openapi-types": { + "version": "21.2.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-21.2.0.tgz", + "integrity": "sha512-xx+Xd6I7rYvul/hgUDqv6TeGX0IOGnhSg9IOeYgd/uI7IAqUy6DE2B6Ipv2M4mWoxaMcWjIzgTIcv8pMO3F3vw==" + }, + "@octokit/types": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/@octokit/types/-/types-13.1.0.tgz", + "integrity": "sha512-nBwAFOYqVUUJ2AZFK4ZzESQptaAVqdTDKk8gE0Xr0o99WuPDSrhUC38x0F40xD9OUxXhOOuZKWNNVVLPSHQDvQ==", + "requires": { + "@octokit/openapi-types": "^21.0.0" + } + } } }, "@octokit/types": { @@ -1550,9 +1804,9 @@ "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==" }, "before-after-hook": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.2.tgz", - "integrity": "sha512-3pZEU3NT5BFUo/AD5ERPWOgQOCZITni6iavr5AUw5AUwQjMlI0kzu5btnyD39AF0gUEsDPwJT+oY1ORBJijPjQ==" + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-3.0.2.tgz", + "integrity": "sha512-Nik3Sc0ncrMK4UUdXQmAnRtzmNQTAAXmXIopizwZ1W1t8QmfJj+zL4OA2I7XPTPW5z5TDqv4hRo/JzouDJnX3A==" }, "deprecation": { "version": "2.3.1", @@ -1619,11 +1873,6 @@ "tslib": "^2.1.0" } }, - "is-plain-object": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz", - "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==" - }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -1874,9 +2123,9 @@ "dev": true }, "universal-user-agent": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz", - "integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w==" + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-7.0.2.tgz", + "integrity": "sha512-0JCqzSKnStlRRQfCdowvqy3cy0Dvtlb8xecj/H8JFZuCze4rwjPZQOgvFvn0Ws/usCHQFGpyr+pB9adaGwXn4Q==" }, "uuid": { "version": "8.3.2", diff --git a/package.json b/package.json index 00fbbe4f..78f3efc6 100644 --- a/package.json +++ b/package.json @@ -24,9 +24,9 @@ "dependencies": { "@actions/core": "^1.10.1", "@actions/github": "^6.0.0", - "@octokit/core": "^5.1.0", - "@octokit/graphql-schema": "^14.57.0", - "@octokit/plugin-paginate-graphql": "^4.0.0", + "@octokit/core": "^6.1.1", + "@octokit/graphql-schema": "^15.4.2", + "@octokit/plugin-paginate-graphql": "^5.2.0", "ansi-styles": "^6.2.1", "zod": "^3.22.4" }, diff --git a/src/github-api.ts b/src/github-api.ts index d5b478db..d6320329 100644 --- a/src/github-api.ts +++ b/src/github-api.ts @@ -1,10 +1,10 @@ import { Octokit } from '@octokit/core'; -import { paginateGraphql } from '@octokit/plugin-paginate-graphql'; +import { paginateGraphQL } from '@octokit/plugin-paginate-graphql'; import { CheckSuite, Workflow, CheckRun, Commit } from '@octokit/graphql-schema'; import { join, relative } from 'path'; import { z } from 'zod'; -const PaginatableOctokit = Octokit.plugin(paginateGraphql); +const PaginatableOctokit = Octokit.plugin(paginateGraphQL); const ListItem = z.object({ workflowFile: z.string().endsWith('.yml'),