Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 30 additions & 16 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -100926,12 +100926,13 @@ class RequestError extends Error {
*/
response;
constructor(message, statusCode, options) {
super(message);
super(message, { cause: options.cause });
this.name = "HttpError";
this.status = Number.parseInt(statusCode);
if (Number.isNaN(this.status)) {
this.status = 0;
}
/* v8 ignore else -- @preserve -- Bug with vitest coverage where it sees an else branch that doesn't exist */
if ("response" in options) {
this.response = options.response;
}
Expand All @@ -100958,7 +100959,7 @@ class RequestError extends Error {


// pkg/dist-src/version.js
var dist_bundle_VERSION = "0.0.0-development";
var dist_bundle_VERSION = "10.0.7";

// pkg/dist-src/defaults.js
var defaults_default = {
Expand All @@ -100982,6 +100983,7 @@ function dist_bundle_isPlainObject(value) {

// pkg/dist-src/fetch-wrapper.js

var noop = () => "";
async function fetchWrapper(requestOptions) {
const fetch = requestOptions.request?.fetch || globalThis.fetch;
if (!fetch) {
Expand Down Expand Up @@ -101083,7 +101085,7 @@ async function fetchWrapper(requestOptions) {
async function getResponseData(response) {
const contentType = response.headers.get("content-type");
if (!contentType) {
return response.text().catch(() => "");
return response.text().catch(noop);
}
const mimetype = (0,fast_content_type_parse/* safeParse */.xL)(contentType);
if (isJSONResponse(mimetype)) {
Expand All @@ -101095,9 +101097,12 @@ async function getResponseData(response) {
return text;
}
} else if (mimetype.type.startsWith("text/") || mimetype.parameters.charset?.toLowerCase() === "utf-8") {
return response.text().catch(() => "");
return response.text().catch(noop);
} else {
return response.arrayBuffer().catch(() => new ArrayBuffer(0));
return response.arrayBuffer().catch(
/* v8 ignore next -- @preserve */
() => new ArrayBuffer(0)
);
}
}
function isJSONResponse(mimetype) {
Expand Down Expand Up @@ -101145,6 +101150,8 @@ function dist_bundle_withDefaults(oldEndpoint, newDefaults) {
// pkg/dist-src/index.js
var request = dist_bundle_withDefaults(endpoint, defaults_default);

/* v8 ignore next -- @preserve */
/* v8 ignore else -- @preserve */

;// CONCATENATED MODULE: ./node_modules/@octokit/graphql/dist-bundle/index.js
// pkg/dist-src/index.js
Expand Down Expand Up @@ -101329,7 +101336,7 @@ var createTokenAuth = function createTokenAuth2(token) {


;// CONCATENATED MODULE: ./node_modules/@octokit/core/dist-src/version.js
const version_VERSION = "6.1.4";
const version_VERSION = "7.0.6";


;// CONCATENATED MODULE: ./node_modules/@octokit/core/dist-src/index.js
Expand All @@ -101339,10 +101346,25 @@ const version_VERSION = "6.1.4";



const noop = () => {
const dist_src_noop = () => {
};
const consoleWarn = console.warn.bind(console);
const consoleError = console.error.bind(console);
function createLogger(logger = {}) {
if (typeof logger.debug !== "function") {
logger.debug = dist_src_noop;
}
if (typeof logger.info !== "function") {
logger.info = dist_src_noop;
}
if (typeof logger.warn !== "function") {
logger.warn = consoleWarn;
}
if (typeof logger.error !== "function") {
logger.error = consoleError;
}
return logger;
}
const userAgentTrail = `octokit-core.js/${version_VERSION} ${getUserAgent()}`;
class Octokit {
static VERSION = version_VERSION;
Expand Down Expand Up @@ -101410,15 +101432,7 @@ class Octokit {
}
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.log = createLogger(options.log);
this.hook = hook;
if (!options.authStrategy) {
if (!options.auth) {
Expand Down
110 changes: 55 additions & 55 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"@actions/core": "2.0.1",
"@actions/exec": "2.0.0",
"@actions/io": "2.0.0",
"@octokit/core": "6.1.4",
"@octokit/core": "7.0.6",
"argument-vector": "1.0.2",
"debug": "4.4.0",
"find-yarn-workspace-root": "2.0.0",
Expand Down