0.0.112
This commit is contained in:
+248
-144
@@ -21799,13 +21799,13 @@ var require_mock_call_history = __commonJS({
|
|||||||
function makeFilterCalls(parameterName) {
|
function makeFilterCalls(parameterName) {
|
||||||
return (parameterValue) => {
|
return (parameterValue) => {
|
||||||
if (typeof parameterValue === "string" || parameterValue == null) {
|
if (typeof parameterValue === "string" || parameterValue == null) {
|
||||||
return this.logs.filter((log2) => {
|
return this.logs.filter((log3) => {
|
||||||
return log2[parameterName] === parameterValue;
|
return log3[parameterName] === parameterValue;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
if (parameterValue instanceof RegExp) {
|
if (parameterValue instanceof RegExp) {
|
||||||
return this.logs.filter((log2) => {
|
return this.logs.filter((log3) => {
|
||||||
return parameterValue.test(log2[parameterName]);
|
return parameterValue.test(log3[parameterName]);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
throw new InvalidArgumentError(`${parameterName} parameter should be one of string, regexp, undefined or null`);
|
throw new InvalidArgumentError(`${parameterName} parameter should be one of string, regexp, undefined or null`);
|
||||||
@@ -21900,8 +21900,8 @@ var require_mock_call_history = __commonJS({
|
|||||||
return this.logs.filter(criteria);
|
return this.logs.filter(criteria);
|
||||||
}
|
}
|
||||||
if (criteria instanceof RegExp) {
|
if (criteria instanceof RegExp) {
|
||||||
return this.logs.filter((log2) => {
|
return this.logs.filter((log3) => {
|
||||||
return criteria.test(log2.toString());
|
return criteria.test(log3.toString());
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
if (typeof criteria === "object" && criteria !== null) {
|
if (typeof criteria === "object" && criteria !== null) {
|
||||||
@@ -21951,13 +21951,13 @@ var require_mock_call_history = __commonJS({
|
|||||||
this.logs = [];
|
this.logs = [];
|
||||||
}
|
}
|
||||||
[kMockCallHistoryAddLog](requestInit) {
|
[kMockCallHistoryAddLog](requestInit) {
|
||||||
const log2 = new MockCallHistoryLog(requestInit);
|
const log3 = new MockCallHistoryLog(requestInit);
|
||||||
this.logs.push(log2);
|
this.logs.push(log3);
|
||||||
return log2;
|
return log3;
|
||||||
}
|
}
|
||||||
*[Symbol.iterator]() {
|
*[Symbol.iterator]() {
|
||||||
for (const log2 of this.calls()) {
|
for (const log3 of this.calls()) {
|
||||||
yield log2;
|
yield log3;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -65002,7 +65002,7 @@ var require_core = __commonJS({
|
|||||||
process.env["PATH"] = `${inputPath}${path.delimiter}${process.env["PATH"]}`;
|
process.env["PATH"] = `${inputPath}${path.delimiter}${process.env["PATH"]}`;
|
||||||
}
|
}
|
||||||
exports.addPath = addPath;
|
exports.addPath = addPath;
|
||||||
function getInput2(name, options) {
|
function getInput(name, options) {
|
||||||
const val = process.env[`INPUT_${name.replace(/ /g, "_").toUpperCase()}`] || "";
|
const val = process.env[`INPUT_${name.replace(/ /g, "_").toUpperCase()}`] || "";
|
||||||
if (options && options.required && !val) {
|
if (options && options.required && !val) {
|
||||||
throw new Error(`Input required and not supplied: ${name}`);
|
throw new Error(`Input required and not supplied: ${name}`);
|
||||||
@@ -65012,9 +65012,9 @@ var require_core = __commonJS({
|
|||||||
}
|
}
|
||||||
return val.trim();
|
return val.trim();
|
||||||
}
|
}
|
||||||
exports.getInput = getInput2;
|
exports.getInput = getInput;
|
||||||
function getMultilineInput(name, options) {
|
function getMultilineInput(name, options) {
|
||||||
const inputs = getInput2(name, options).split("\n").filter((x) => x !== "");
|
const inputs = getInput(name, options).split("\n").filter((x) => x !== "");
|
||||||
if (options && options.trimWhitespace === false) {
|
if (options && options.trimWhitespace === false) {
|
||||||
return inputs;
|
return inputs;
|
||||||
}
|
}
|
||||||
@@ -65024,7 +65024,7 @@ var require_core = __commonJS({
|
|||||||
function getBooleanInput(name, options) {
|
function getBooleanInput(name, options) {
|
||||||
const trueValue = ["true", "True", "TRUE"];
|
const trueValue = ["true", "True", "TRUE"];
|
||||||
const falseValue = ["false", "False", "FALSE"];
|
const falseValue = ["false", "False", "FALSE"];
|
||||||
const val = getInput2(name, options);
|
const val = getInput(name, options);
|
||||||
if (trueValue.includes(val))
|
if (trueValue.includes(val))
|
||||||
return true;
|
return true;
|
||||||
if (falseValue.includes(val))
|
if (falseValue.includes(val))
|
||||||
@@ -79113,7 +79113,7 @@ var require_depd = /* @__PURE__ */ __commonJS2({ "node_modules/.pnpm/depd@2.0.0/
|
|||||||
var stack = getStack();
|
var stack = getStack();
|
||||||
var file = callSiteLocation(stack[1])[0];
|
var file = callSiteLocation(stack[1])[0];
|
||||||
function deprecate$1(message) {
|
function deprecate$1(message) {
|
||||||
log2.call(deprecate$1, message);
|
log3.call(deprecate$1, message);
|
||||||
}
|
}
|
||||||
deprecate$1._file = file;
|
deprecate$1._file = file;
|
||||||
deprecate$1._ignored = isignored(namespace);
|
deprecate$1._ignored = isignored(namespace);
|
||||||
@@ -79137,7 +79137,7 @@ var require_depd = /* @__PURE__ */ __commonJS2({ "node_modules/.pnpm/depd@2.0.0/
|
|||||||
var str = process.env.TRACE_DEPRECATION || "";
|
var str = process.env.TRACE_DEPRECATION || "";
|
||||||
return containsNamespace(str, namespace);
|
return containsNamespace(str, namespace);
|
||||||
}
|
}
|
||||||
function log2(message, site) {
|
function log3(message, site) {
|
||||||
var haslisteners = eehaslisteners(process, "deprecation");
|
var haslisteners = eehaslisteners(process, "deprecation");
|
||||||
if (!haslisteners && this._ignored) return;
|
if (!haslisteners && this._ignored) return;
|
||||||
var caller;
|
var caller;
|
||||||
@@ -79244,7 +79244,7 @@ var require_depd = /* @__PURE__ */ __commonJS2({ "node_modules/.pnpm/depd@2.0.0/
|
|||||||
var stack = getStack();
|
var stack = getStack();
|
||||||
var site = callSiteLocation(stack[1]);
|
var site = callSiteLocation(stack[1]);
|
||||||
site.name = fn2.name;
|
site.name = fn2.name;
|
||||||
return new Function("fn", "log", "deprecate", "message", "site", '"use strict"\nreturn function (' + args2 + ") {log.call(deprecate, message, site)\nreturn fn.apply(this, arguments)\n}")(fn2, log2, this, message, site);
|
return new Function("fn", "log", "deprecate", "message", "site", '"use strict"\nreturn function (' + args2 + ") {log.call(deprecate, message, site)\nreturn fn.apply(this, arguments)\n}")(fn2, log3, this, message, site);
|
||||||
}
|
}
|
||||||
function wrapproperty(obj, prop, message) {
|
function wrapproperty(obj, prop, message) {
|
||||||
if (!obj || typeof obj !== "object" && typeof obj !== "function") throw new TypeError("argument obj must be object");
|
if (!obj || typeof obj !== "object" && typeof obj !== "function") throw new TypeError("argument obj must be object");
|
||||||
@@ -79259,11 +79259,11 @@ var require_depd = /* @__PURE__ */ __commonJS2({ "node_modules/.pnpm/depd@2.0.0/
|
|||||||
var get2 = descriptor.get;
|
var get2 = descriptor.get;
|
||||||
var set = descriptor.set;
|
var set = descriptor.set;
|
||||||
if (typeof get2 === "function") descriptor.get = function getter() {
|
if (typeof get2 === "function") descriptor.get = function getter() {
|
||||||
log2.call(deprecate$1, message, site);
|
log3.call(deprecate$1, message, site);
|
||||||
return get2.apply(this, arguments);
|
return get2.apply(this, arguments);
|
||||||
};
|
};
|
||||||
if (typeof set === "function") descriptor.set = function setter() {
|
if (typeof set === "function") descriptor.set = function setter() {
|
||||||
log2.call(deprecate$1, message, site);
|
log3.call(deprecate$1, message, site);
|
||||||
return set.apply(this, arguments);
|
return set.apply(this, arguments);
|
||||||
};
|
};
|
||||||
Object.defineProperty(obj, prop, descriptor);
|
Object.defineProperty(obj, prop, descriptor);
|
||||||
@@ -95651,7 +95651,7 @@ ${error41 instanceof Error ? error41.stack : JSON.stringify(error41)}`
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const log2 = {
|
const log3 = {
|
||||||
debug: (message, context) => {
|
debug: (message, context) => {
|
||||||
this.#server.sendLoggingMessage({
|
this.#server.sendLoggingMessage({
|
||||||
data: {
|
data: {
|
||||||
@@ -95713,7 +95713,7 @@ ${error41 instanceof Error ? error41.stack : JSON.stringify(error41)}`
|
|||||||
client: {
|
client: {
|
||||||
version: this.#server.getClientVersion()
|
version: this.#server.getClientVersion()
|
||||||
},
|
},
|
||||||
log: log2,
|
log: log3,
|
||||||
reportProgress,
|
reportProgress,
|
||||||
requestId: typeof request2.params?._meta?.requestId === "string" ? request2.params._meta.requestId : void 0,
|
requestId: typeof request2.params?._meta?.requestId === "string" ? request2.params._meta.requestId : void 0,
|
||||||
session: this.#auth,
|
session: this.#auth,
|
||||||
@@ -96178,9 +96178,6 @@ var FastMCP = class extends FastMCPEventEmitter {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// external.ts
|
|
||||||
var ghPullfrogMcpName = "gh_pullfrog";
|
|
||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/shared/errors.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/shared/errors.js
|
||||||
var ArkError = class _ArkError extends CastableBase {
|
var ArkError = class _ArkError extends CastableBase {
|
||||||
[arkKind] = "error";
|
[arkKind] = "error";
|
||||||
@@ -96625,7 +96622,7 @@ var BaseNode = class extends Callable {
|
|||||||
get shallowMorphs() {
|
get shallowMorphs() {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
constructor(attachments, $) {
|
constructor(attachments, $2) {
|
||||||
super((data, pipedFromCtx, onFail = this.onFail) => {
|
super((data, pipedFromCtx, onFail = this.onFail) => {
|
||||||
if (pipedFromCtx) {
|
if (pipedFromCtx) {
|
||||||
this.traverseApply(data, pipedFromCtx);
|
this.traverseApply(data, pipedFromCtx);
|
||||||
@@ -96634,7 +96631,7 @@ var BaseNode = class extends Callable {
|
|||||||
return this.rootApply(data, onFail);
|
return this.rootApply(data, onFail);
|
||||||
}, { attach: attachments });
|
}, { attach: attachments });
|
||||||
this.attachments = attachments;
|
this.attachments = attachments;
|
||||||
this.$ = $;
|
this.$ = $2;
|
||||||
this.onFail = this.meta.onFail ?? this.$.resolvedConfig.onFail;
|
this.onFail = this.meta.onFail ?? this.$.resolvedConfig.onFail;
|
||||||
this.includesTransform = this.hasKind("morph") || this.hasKind("structure") && this.structuralMorph !== void 0 || this.hasKind("sequence") && this.inner.defaultables !== void 0;
|
this.includesTransform = this.hasKind("morph") || this.hasKind("structure") && this.structuralMorph !== void 0 || this.hasKind("sequence") && this.inner.defaultables !== void 0;
|
||||||
this.includesContextualPredicate = this.hasKind("predicate") && this.inner.predicate.length !== 1;
|
this.includesContextualPredicate = this.hasKind("predicate") && this.inner.predicate.length !== 1;
|
||||||
@@ -96852,7 +96849,7 @@ var BaseNode = class extends Callable {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
_transform(mapper, ctx) {
|
_transform(mapper, ctx) {
|
||||||
const $ = ctx.bindScope ?? this.$;
|
const $2 = ctx.bindScope ?? this.$;
|
||||||
if (ctx.seen[this.id])
|
if (ctx.seen[this.id])
|
||||||
return this.$.lazilyResolve(ctx.seen[this.id]);
|
return this.$.lazilyResolve(ctx.seen[this.id]);
|
||||||
if (ctx.shouldTransform?.(this, ctx) === false)
|
if (ctx.shouldTransform?.(this, ctx) === false)
|
||||||
@@ -96902,7 +96899,7 @@ var BaseNode = class extends Callable {
|
|||||||
;
|
;
|
||||||
transformedInner.in ??= $ark.intrinsic.unknown;
|
transformedInner.in ??= $ark.intrinsic.unknown;
|
||||||
}
|
}
|
||||||
return transformedNode = $.node(this.kind, transformedInner, ctx.parseOptions);
|
return transformedNode = $2.node(this.kind, transformedInner, ctx.parseOptions);
|
||||||
}
|
}
|
||||||
configureReferences(meta, selector = "references") {
|
configureReferences(meta, selector = "references") {
|
||||||
const normalized = NodeSelector.normalize(selector);
|
const normalized = NodeSelector.normalize(selector);
|
||||||
@@ -97030,13 +97027,13 @@ var writeUnsatisfiableExpressionError = (expression) => `${expression} results i
|
|||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/shared/intersections.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/shared/intersections.js
|
||||||
var intersectionCache = {};
|
var intersectionCache = {};
|
||||||
var intersectNodesRoot = (l, r, $) => intersectOrPipeNodes(l, r, {
|
var intersectNodesRoot = (l, r, $2) => intersectOrPipeNodes(l, r, {
|
||||||
$,
|
$: $2,
|
||||||
invert: false,
|
invert: false,
|
||||||
pipe: false
|
pipe: false
|
||||||
});
|
});
|
||||||
var pipeNodesRoot = (l, r, $) => intersectOrPipeNodes(l, r, {
|
var pipeNodesRoot = (l, r, $2) => intersectOrPipeNodes(l, r, {
|
||||||
$,
|
$: $2,
|
||||||
invert: false,
|
invert: false,
|
||||||
pipe: true
|
pipe: true
|
||||||
});
|
});
|
||||||
@@ -97141,8 +97138,8 @@ var _pipeMorphed = (from, to, ctx) => {
|
|||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/constraint.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/constraint.js
|
||||||
var BaseConstraint = class extends BaseNode {
|
var BaseConstraint = class extends BaseNode {
|
||||||
constructor(attachments, $) {
|
constructor(attachments, $2) {
|
||||||
super(attachments, $);
|
super(attachments, $2);
|
||||||
Object.defineProperty(this, arkKind, {
|
Object.defineProperty(this, arkKind, {
|
||||||
value: "constraint",
|
value: "constraint",
|
||||||
enumerable: false
|
enumerable: false
|
||||||
@@ -97254,7 +97251,7 @@ var writeInvalidOperandMessage = (kind, expected, actual) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/generic.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/generic.js
|
||||||
var parseGeneric = (paramDefs, bodyDef, $) => new GenericRoot(paramDefs, bodyDef, $, $, null);
|
var parseGeneric = (paramDefs, bodyDef, $2) => new GenericRoot(paramDefs, bodyDef, $2, $2, null);
|
||||||
var LazyGenericBody = class extends Callable {
|
var LazyGenericBody = class extends Callable {
|
||||||
};
|
};
|
||||||
var GenericRoot = class extends Callable {
|
var GenericRoot = class extends Callable {
|
||||||
@@ -97266,7 +97263,7 @@ var GenericRoot = class extends Callable {
|
|||||||
baseInstantiation;
|
baseInstantiation;
|
||||||
hkt;
|
hkt;
|
||||||
description;
|
description;
|
||||||
constructor(paramDefs, bodyDef, $, arg$, hkt) {
|
constructor(paramDefs, bodyDef, $2, arg$, hkt) {
|
||||||
super((...args2) => {
|
super((...args2) => {
|
||||||
const argNodes = flatMorph(this.names, (i, name) => {
|
const argNodes = flatMorph(this.names, (i, name) => {
|
||||||
const arg = this.arg$.parse(args2[i]);
|
const arg = this.arg$.parse(args2[i]);
|
||||||
@@ -97283,7 +97280,7 @@ var GenericRoot = class extends Callable {
|
|||||||
});
|
});
|
||||||
this.paramDefs = paramDefs;
|
this.paramDefs = paramDefs;
|
||||||
this.bodyDef = bodyDef;
|
this.bodyDef = bodyDef;
|
||||||
this.$ = $;
|
this.$ = $2;
|
||||||
this.arg$ = arg$;
|
this.arg$ = arg$;
|
||||||
this.hkt = hkt;
|
this.hkt = hkt;
|
||||||
this.description = hkt ? new hkt().description ?? `a generic type for ${hkt.constructor.name}` : "a generic type";
|
this.description = hkt ? new hkt().description ?? `a generic type for ${hkt.constructor.name}` : "a generic type";
|
||||||
@@ -97678,7 +97675,7 @@ var implementation7 = implementNode({
|
|||||||
parse: createLengthRuleParser("maxLength")
|
parse: createLengthRuleParser("maxLength")
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
reduce: (inner, $) => inner.rule === 0 ? $.node("exactLength", inner) : void 0,
|
reduce: (inner, $2) => inner.rule === 0 ? $2.node("exactLength", inner) : void 0,
|
||||||
normalize: createLengthSchemaNormalizer("maxLength"),
|
normalize: createLengthSchemaNormalizer("maxLength"),
|
||||||
defaults: {
|
defaults: {
|
||||||
description: (node2) => `at most length ${node2.rule}`,
|
description: (node2) => `at most length ${node2.rule}`,
|
||||||
@@ -97943,7 +97940,7 @@ var parseNode = (ctx) => {
|
|||||||
});
|
});
|
||||||
return node2;
|
return node2;
|
||||||
};
|
};
|
||||||
var createNode = ({ id, kind, inner, meta, $, ignoreCache }) => {
|
var createNode = ({ id, kind, inner, meta, $: $2, ignoreCache }) => {
|
||||||
const impl = nodeImplementationsByKind[kind];
|
const impl = nodeImplementationsByKind[kind];
|
||||||
const innerEntries = entriesOf(inner);
|
const innerEntries = entriesOf(inner);
|
||||||
const children = [];
|
const children = [];
|
||||||
@@ -97977,8 +97974,8 @@ var createNode = ({ id, kind, inner, meta, $, ignoreCache }) => {
|
|||||||
json3 = possiblyCollapse(json3, impl.collapsibleKey, false);
|
json3 = possiblyCollapse(json3, impl.collapsibleKey, false);
|
||||||
const collapsibleJson = possiblyCollapse(json3, impl.collapsibleKey, true);
|
const collapsibleJson = possiblyCollapse(json3, impl.collapsibleKey, true);
|
||||||
const hash = JSON.stringify({ kind, ...json3 });
|
const hash = JSON.stringify({ kind, ...json3 });
|
||||||
if ($.nodesByHash[hash] && !ignoreCache)
|
if ($2.nodesByHash[hash] && !ignoreCache)
|
||||||
return $.nodesByHash[hash];
|
return $2.nodesByHash[hash];
|
||||||
const attachments = {
|
const attachments = {
|
||||||
id,
|
id,
|
||||||
kind,
|
kind,
|
||||||
@@ -97999,8 +97996,8 @@ var createNode = ({ id, kind, inner, meta, $, ignoreCache }) => {
|
|||||||
if (k !== "in" && k !== "out")
|
if (k !== "in" && k !== "out")
|
||||||
attachments[k] = inner[k];
|
attachments[k] = inner[k];
|
||||||
}
|
}
|
||||||
const node2 = new nodeClassesByKind[kind](attachments, $);
|
const node2 = new nodeClassesByKind[kind](attachments, $2);
|
||||||
return $.nodesByHash[hash] = node2;
|
return $2.nodesByHash[hash] = node2;
|
||||||
};
|
};
|
||||||
var withId = (node2, id) => {
|
var withId = (node2, id) => {
|
||||||
if (node2.id === id)
|
if (node2.id === id)
|
||||||
@@ -98127,10 +98124,10 @@ var implementation11 = implementNode({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
normalize: (schema2) => schema2,
|
normalize: (schema2) => schema2,
|
||||||
reduce: (inner, $) => {
|
reduce: (inner, $2) => {
|
||||||
if ($.resolvedConfig.exactOptionalPropertyTypes === false) {
|
if ($2.resolvedConfig.exactOptionalPropertyTypes === false) {
|
||||||
if (!inner.value.allows(void 0)) {
|
if (!inner.value.allows(void 0)) {
|
||||||
return $.node("optional", { ...inner, value: inner.value.or(intrinsic.undefined) }, { prereduced: true });
|
return $2.node("optional", { ...inner, value: inner.value.or(intrinsic.undefined) }, { prereduced: true });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -98219,8 +98216,8 @@ var writeNonPrimitiveNonFunctionDefaultValueMessage = (key) => {
|
|||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/roots/root.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/roots/root.js
|
||||||
var BaseRoot = class extends BaseNode {
|
var BaseRoot = class extends BaseNode {
|
||||||
constructor(attachments, $) {
|
constructor(attachments, $2) {
|
||||||
super(attachments, $);
|
super(attachments, $2);
|
||||||
Object.defineProperty(this, arkKind, { value: "root", enumerable: false });
|
Object.defineProperty(this, arkKind, { value: "root", enumerable: false });
|
||||||
}
|
}
|
||||||
// doesn't seem possible to override this at a type-level (e.g. via declare)
|
// doesn't seem possible to override this at a type-level (e.g. via declare)
|
||||||
@@ -98881,11 +98878,11 @@ var implementation14 = implementNode({
|
|||||||
},
|
},
|
||||||
// leverage reduction logic from intersection and identity to ensure initial
|
// leverage reduction logic from intersection and identity to ensure initial
|
||||||
// parse result is reduced
|
// parse result is reduced
|
||||||
reduce: (inner, $) => (
|
reduce: (inner, $2) => (
|
||||||
// we cast union out of the result here since that only occurs when intersecting two sequences
|
// we cast union out of the result here since that only occurs when intersecting two sequences
|
||||||
// that cannot occur when reducing a single intersection schema using unknown
|
// that cannot occur when reducing a single intersection schema using unknown
|
||||||
intersectIntersections({}, inner, {
|
intersectIntersections({}, inner, {
|
||||||
$,
|
$: $2,
|
||||||
invert: false,
|
invert: false,
|
||||||
pipe: false
|
pipe: false
|
||||||
})
|
})
|
||||||
@@ -99301,13 +99298,13 @@ var implementation17 = implementNode({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
normalize: (schema2) => isArray(schema2) ? { branches: schema2 } : schema2,
|
normalize: (schema2) => isArray(schema2) ? { branches: schema2 } : schema2,
|
||||||
reduce: (inner, $) => {
|
reduce: (inner, $2) => {
|
||||||
const reducedBranches = reduceBranches(inner);
|
const reducedBranches = reduceBranches(inner);
|
||||||
if (reducedBranches.length === 1)
|
if (reducedBranches.length === 1)
|
||||||
return reducedBranches[0];
|
return reducedBranches[0];
|
||||||
if (reducedBranches.length === inner.branches.length)
|
if (reducedBranches.length === inner.branches.length)
|
||||||
return;
|
return;
|
||||||
return $.node("union", {
|
return $2.node("union", {
|
||||||
...inner,
|
...inner,
|
||||||
branches: reducedBranches
|
branches: reducedBranches
|
||||||
}, { prereduced: true });
|
}, { prereduced: true });
|
||||||
@@ -99704,11 +99701,11 @@ var viableOrderedCandidates = (candidates, originalBranches) => {
|
|||||||
});
|
});
|
||||||
return viableCandidates;
|
return viableCandidates;
|
||||||
};
|
};
|
||||||
var discriminantCaseToNode = (caseDiscriminant, path, $) => {
|
var discriminantCaseToNode = (caseDiscriminant, path, $2) => {
|
||||||
let node2 = caseDiscriminant === "undefined" ? $.node("unit", { unit: void 0 }) : caseDiscriminant === "null" ? $.node("unit", { unit: null }) : caseDiscriminant === "boolean" ? $.units([true, false]) : caseDiscriminant;
|
let node2 = caseDiscriminant === "undefined" ? $2.node("unit", { unit: void 0 }) : caseDiscriminant === "null" ? $2.node("unit", { unit: null }) : caseDiscriminant === "boolean" ? $2.units([true, false]) : caseDiscriminant;
|
||||||
for (let i = path.length - 1; i >= 0; i--) {
|
for (let i = path.length - 1; i >= 0; i--) {
|
||||||
const key = path[i];
|
const key = path[i];
|
||||||
node2 = $.node("intersection", typeof key === "number" ? {
|
node2 = $2.node("intersection", typeof key === "number" ? {
|
||||||
proto: "Array",
|
proto: "Array",
|
||||||
// create unknown for preceding elements (could be optimized with safe imports)
|
// create unknown for preceding elements (could be optimized with safe imports)
|
||||||
sequence: [...range(key).map((_) => ({})), node2]
|
sequence: [...range(key).map((_) => ({})), node2]
|
||||||
@@ -100110,7 +100107,7 @@ var implementation21 = implementNode({
|
|||||||
}
|
}
|
||||||
return { variadic: schema2 };
|
return { variadic: schema2 };
|
||||||
},
|
},
|
||||||
reduce: (raw, $) => {
|
reduce: (raw, $2) => {
|
||||||
let minVariadicLength = raw.minVariadicLength ?? 0;
|
let minVariadicLength = raw.minVariadicLength ?? 0;
|
||||||
const prefix = raw.prefix?.slice() ?? [];
|
const prefix = raw.prefix?.slice() ?? [];
|
||||||
const defaultables = raw.defaultables?.slice() ?? [];
|
const defaultables = raw.defaultables?.slice() ?? [];
|
||||||
@@ -100137,7 +100134,7 @@ var implementation21 = implementNode({
|
|||||||
minVariadicLength !== raw.minVariadicLength || // or any postfix elements were moved to prefix
|
minVariadicLength !== raw.minVariadicLength || // or any postfix elements were moved to prefix
|
||||||
raw.prefix && raw.prefix.length !== prefix.length
|
raw.prefix && raw.prefix.length !== prefix.length
|
||||||
) {
|
) {
|
||||||
return $.node("sequence", {
|
return $2.node("sequence", {
|
||||||
...raw,
|
...raw,
|
||||||
// empty lists will be omitted during parsing
|
// empty lists will be omitted during parsing
|
||||||
prefix,
|
prefix,
|
||||||
@@ -100452,13 +100449,13 @@ var createStructuralWriter = (childStringProp) => (node2) => {
|
|||||||
};
|
};
|
||||||
var structuralDescription = createStructuralWriter("description");
|
var structuralDescription = createStructuralWriter("description");
|
||||||
var structuralExpression = createStructuralWriter("expression");
|
var structuralExpression = createStructuralWriter("expression");
|
||||||
var intersectPropsAndIndex = (l, r, $) => {
|
var intersectPropsAndIndex = (l, r, $2) => {
|
||||||
const kind = l.required ? "required" : "optional";
|
const kind = l.required ? "required" : "optional";
|
||||||
if (!r.signature.allows(l.key))
|
if (!r.signature.allows(l.key))
|
||||||
return null;
|
return null;
|
||||||
const value2 = intersectNodesRoot(l.value, r.value, $);
|
const value2 = intersectNodesRoot(l.value, r.value, $2);
|
||||||
if (value2 instanceof Disjoint) {
|
if (value2 instanceof Disjoint) {
|
||||||
return kind === "optional" ? $.node("optional", {
|
return kind === "optional" ? $2.node("optional", {
|
||||||
key: l.key,
|
key: l.key,
|
||||||
value: $ark.intrinsic.never.internal
|
value: $ark.intrinsic.never.internal
|
||||||
}) : value2.withPrefixKey(l.key, l.kind);
|
}) : value2.withPrefixKey(l.key, l.kind);
|
||||||
@@ -100607,7 +100604,7 @@ var implementation22 = implementNode({
|
|||||||
return childIntersectionResult;
|
return childIntersectionResult;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
reduce: (inner, $) => {
|
reduce: (inner, $2) => {
|
||||||
if (!inner.required && !inner.optional)
|
if (!inner.required && !inner.optional)
|
||||||
return;
|
return;
|
||||||
const seen = {};
|
const seen = {};
|
||||||
@@ -100621,7 +100618,7 @@ var implementation22 = implementNode({
|
|||||||
seen[requiredProp.key] = true;
|
seen[requiredProp.key] = true;
|
||||||
if (inner.index) {
|
if (inner.index) {
|
||||||
for (const index of inner.index) {
|
for (const index of inner.index) {
|
||||||
const intersection = intersectPropsAndIndex(requiredProp, index, $);
|
const intersection = intersectPropsAndIndex(requiredProp, index, $2);
|
||||||
if (intersection instanceof Disjoint)
|
if (intersection instanceof Disjoint)
|
||||||
return intersection;
|
return intersection;
|
||||||
}
|
}
|
||||||
@@ -100636,7 +100633,7 @@ var implementation22 = implementNode({
|
|||||||
seen[optionalProp.key] = true;
|
seen[optionalProp.key] = true;
|
||||||
if (inner.index) {
|
if (inner.index) {
|
||||||
for (const index of inner.index) {
|
for (const index of inner.index) {
|
||||||
const intersection = intersectPropsAndIndex(optionalProp, index, $);
|
const intersection = intersectPropsAndIndex(optionalProp, index, $2);
|
||||||
if (intersection instanceof Disjoint)
|
if (intersection instanceof Disjoint)
|
||||||
return intersection;
|
return intersection;
|
||||||
if (intersection !== null) {
|
if (intersection !== null) {
|
||||||
@@ -100648,7 +100645,7 @@ var implementation22 = implementNode({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (updated) {
|
if (updated) {
|
||||||
return $.node("structure", { ...inner, optional: newOptionalProps }, { prereduced: true });
|
return $2.node("structure", { ...inner, optional: newOptionalProps }, { prereduced: true });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -101098,17 +101095,17 @@ var indexerToKey = (indexable) => {
|
|||||||
return indexable;
|
return indexable;
|
||||||
};
|
};
|
||||||
var writeNumberIndexMessage = (indexExpression, sequenceExpression) => `${indexExpression} is not allowed as an array index on ${sequenceExpression}. Use the 'nonNegativeIntegerString' keyword instead.`;
|
var writeNumberIndexMessage = (indexExpression, sequenceExpression) => `${indexExpression} is not allowed as an array index on ${sequenceExpression}. Use the 'nonNegativeIntegerString' keyword instead.`;
|
||||||
var normalizeIndex = (signature, value2, $) => {
|
var normalizeIndex = (signature, value2, $2) => {
|
||||||
const [enumerableBranches, nonEnumerableBranches] = spliterate(signature.branches, (k) => k.hasKind("unit"));
|
const [enumerableBranches, nonEnumerableBranches] = spliterate(signature.branches, (k) => k.hasKind("unit"));
|
||||||
if (!enumerableBranches.length)
|
if (!enumerableBranches.length)
|
||||||
return { index: $.node("index", { signature, value: value2 }) };
|
return { index: $2.node("index", { signature, value: value2 }) };
|
||||||
const normalized = {};
|
const normalized = {};
|
||||||
for (const n of enumerableBranches) {
|
for (const n of enumerableBranches) {
|
||||||
const prop = $.node("required", { key: n.unit, value: value2 });
|
const prop = $2.node("required", { key: n.unit, value: value2 });
|
||||||
normalized[prop.kind] = append(normalized[prop.kind], prop);
|
normalized[prop.kind] = append(normalized[prop.kind], prop);
|
||||||
}
|
}
|
||||||
if (nonEnumerableBranches.length) {
|
if (nonEnumerableBranches.length) {
|
||||||
normalized.index = $.node("index", {
|
normalized.index = $2.node("index", {
|
||||||
signature: nonEnumerableBranches,
|
signature: nonEnumerableBranches,
|
||||||
value: value2
|
value: value2
|
||||||
});
|
});
|
||||||
@@ -101179,9 +101176,9 @@ var RootModule = class extends DynamicBase {
|
|||||||
return "module";
|
return "module";
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
var bindModule = (module, $) => new RootModule(flatMorph(module, (alias, value2) => [
|
var bindModule = (module, $2) => new RootModule(flatMorph(module, (alias, value2) => [
|
||||||
alias,
|
alias,
|
||||||
hasArkKind(value2, "module") ? bindModule(value2, $) : $.bindReference(value2)
|
hasArkKind(value2, "module") ? bindModule(value2, $2) : $2.bindReference(value2)
|
||||||
]));
|
]));
|
||||||
|
|
||||||
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/scope.js
|
// node_modules/.pnpm/@ark+schema@0.53.0/node_modules/@ark/schema/out/scope.js
|
||||||
@@ -101312,8 +101309,8 @@ var BaseScope = class {
|
|||||||
return def;
|
return def;
|
||||||
}
|
}
|
||||||
generic = (...params) => {
|
generic = (...params) => {
|
||||||
const $ = this;
|
const $2 = this;
|
||||||
return (def, possibleHkt) => new GenericRoot(params, possibleHkt ? new LazyGenericBody(def) : def, $, $, possibleHkt ?? null);
|
return (def, possibleHkt) => new GenericRoot(params, possibleHkt ? new LazyGenericBody(def) : def, $2, $2, possibleHkt ?? null);
|
||||||
};
|
};
|
||||||
units = (values, opts) => {
|
units = (values, opts) => {
|
||||||
const uniqueValues = [];
|
const uniqueValues = [];
|
||||||
@@ -101571,12 +101568,12 @@ var maybeResolveSubalias = (base, name) => {
|
|||||||
};
|
};
|
||||||
var schemaScope = (aliases, config2) => new SchemaScope(aliases, config2);
|
var schemaScope = (aliases, config2) => new SchemaScope(aliases, config2);
|
||||||
var rootSchemaScope = new SchemaScope({});
|
var rootSchemaScope = new SchemaScope({});
|
||||||
var resolutionsOfModule = ($, typeSet) => {
|
var resolutionsOfModule = ($2, typeSet) => {
|
||||||
const result = {};
|
const result = {};
|
||||||
for (const k in typeSet) {
|
for (const k in typeSet) {
|
||||||
const v = typeSet[k];
|
const v = typeSet[k];
|
||||||
if (hasArkKind(v, "module")) {
|
if (hasArkKind(v, "module")) {
|
||||||
const innerResolutions = resolutionsOfModule($, v);
|
const innerResolutions = resolutionsOfModule($2, v);
|
||||||
const prefixedResolutions = flatMorph(innerResolutions, (innerK, innerV) => [`${k}.${innerK}`, innerV]);
|
const prefixedResolutions = flatMorph(innerResolutions, (innerK, innerV) => [`${k}.${innerK}`, innerV]);
|
||||||
Object.assign(result, prefixedResolutions);
|
Object.assign(result, prefixedResolutions);
|
||||||
} else if (hasArkKind(v, "root") || hasArkKind(v, "generic"))
|
} else if (hasArkKind(v, "root") || hasArkKind(v, "generic"))
|
||||||
@@ -102164,21 +102161,21 @@ var _parseOptionalConstraint = (scanner, name, result, ctx) => {
|
|||||||
|
|
||||||
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/fn.js
|
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/fn.js
|
||||||
var InternalFnParser = class extends Callable {
|
var InternalFnParser = class extends Callable {
|
||||||
constructor($) {
|
constructor($2) {
|
||||||
const attach = {
|
const attach = {
|
||||||
$,
|
$: $2,
|
||||||
raw: $.fn
|
raw: $2.fn
|
||||||
};
|
};
|
||||||
super((...signature) => {
|
super((...signature) => {
|
||||||
const returnOperatorIndex = signature.indexOf(":");
|
const returnOperatorIndex = signature.indexOf(":");
|
||||||
const lastParamIndex = returnOperatorIndex === -1 ? signature.length - 1 : returnOperatorIndex - 1;
|
const lastParamIndex = returnOperatorIndex === -1 ? signature.length - 1 : returnOperatorIndex - 1;
|
||||||
const paramDefs = signature.slice(0, lastParamIndex + 1);
|
const paramDefs = signature.slice(0, lastParamIndex + 1);
|
||||||
const paramTuple = $.parse(paramDefs).assertHasKind("intersection");
|
const paramTuple = $2.parse(paramDefs).assertHasKind("intersection");
|
||||||
let returnType = $.intrinsic.unknown;
|
let returnType = $2.intrinsic.unknown;
|
||||||
if (returnOperatorIndex !== -1) {
|
if (returnOperatorIndex !== -1) {
|
||||||
if (returnOperatorIndex !== signature.length - 2)
|
if (returnOperatorIndex !== signature.length - 2)
|
||||||
return throwParseError(badFnReturnTypeMessage);
|
return throwParseError(badFnReturnTypeMessage);
|
||||||
returnType = $.parse(signature[returnOperatorIndex + 1]);
|
returnType = $2.parse(signature[returnOperatorIndex + 1]);
|
||||||
}
|
}
|
||||||
return (impl) => new InternalTypedFn(impl, paramTuple, returnType);
|
return (impl) => new InternalTypedFn(impl, paramTuple, returnType);
|
||||||
}, { attach });
|
}, { attach });
|
||||||
@@ -102217,11 +102214,11 @@ fn("string", ":", "number")(s => s.length)`;
|
|||||||
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/match.js
|
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/match.js
|
||||||
var InternalMatchParser = class extends Callable {
|
var InternalMatchParser = class extends Callable {
|
||||||
$;
|
$;
|
||||||
constructor($) {
|
constructor($2) {
|
||||||
super((...args2) => new InternalChainedMatchParser($)(...args2), {
|
super((...args2) => new InternalChainedMatchParser($2)(...args2), {
|
||||||
bind: $
|
bind: $2
|
||||||
});
|
});
|
||||||
this.$ = $;
|
this.$ = $2;
|
||||||
}
|
}
|
||||||
in(def) {
|
in(def) {
|
||||||
return new InternalChainedMatchParser(this.$, def === void 0 ? void 0 : this.$.parse(def));
|
return new InternalChainedMatchParser(this.$, def === void 0 ? void 0 : this.$.parse(def));
|
||||||
@@ -102238,9 +102235,9 @@ var InternalChainedMatchParser = class extends Callable {
|
|||||||
in;
|
in;
|
||||||
key;
|
key;
|
||||||
branches = [];
|
branches = [];
|
||||||
constructor($, In) {
|
constructor($2, In) {
|
||||||
super((cases) => this.caseEntries(Object.entries(cases).map(([k, v]) => k === "default" ? [k, v] : [this.$.parse(k), v])));
|
super((cases) => this.caseEntries(Object.entries(cases).map(([k, v]) => k === "default" ? [k, v] : [this.$.parse(k), v])));
|
||||||
this.$ = $;
|
this.$ = $2;
|
||||||
this.in = In;
|
this.in = In;
|
||||||
}
|
}
|
||||||
at(key, cases) {
|
at(key, cases) {
|
||||||
@@ -102616,45 +102613,45 @@ var writeBadDefinitionTypeMessage = (actual) => `Type definitions must be string
|
|||||||
|
|
||||||
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/type.js
|
// node_modules/.pnpm/arktype@2.1.25/node_modules/arktype/out/type.js
|
||||||
var InternalTypeParser = class extends Callable {
|
var InternalTypeParser = class extends Callable {
|
||||||
constructor($) {
|
constructor($2) {
|
||||||
const attach = Object.assign(
|
const attach = Object.assign(
|
||||||
{
|
{
|
||||||
errors: ArkErrors,
|
errors: ArkErrors,
|
||||||
hkt: Hkt,
|
hkt: Hkt,
|
||||||
$,
|
$: $2,
|
||||||
raw: $.parse,
|
raw: $2.parse,
|
||||||
module: $.constructor.module,
|
module: $2.constructor.module,
|
||||||
scope: $.constructor.scope,
|
scope: $2.constructor.scope,
|
||||||
declare: $.declare,
|
declare: $2.declare,
|
||||||
define: $.define,
|
define: $2.define,
|
||||||
match: $.match,
|
match: $2.match,
|
||||||
generic: $.generic,
|
generic: $2.generic,
|
||||||
schema: $.schema,
|
schema: $2.schema,
|
||||||
// this won't be defined during bootstrapping, but externally always will be
|
// this won't be defined during bootstrapping, but externally always will be
|
||||||
keywords: $.ambient,
|
keywords: $2.ambient,
|
||||||
unit: $.unit,
|
unit: $2.unit,
|
||||||
enumerated: $.enumerated,
|
enumerated: $2.enumerated,
|
||||||
instanceOf: $.instanceOf,
|
instanceOf: $2.instanceOf,
|
||||||
valueOf: $.valueOf,
|
valueOf: $2.valueOf,
|
||||||
or: $.or,
|
or: $2.or,
|
||||||
and: $.and,
|
and: $2.and,
|
||||||
merge: $.merge,
|
merge: $2.merge,
|
||||||
pipe: $.pipe,
|
pipe: $2.pipe,
|
||||||
fn: $.fn
|
fn: $2.fn
|
||||||
},
|
},
|
||||||
// also won't be defined during bootstrapping
|
// also won't be defined during bootstrapping
|
||||||
$.ambientAttachments
|
$2.ambientAttachments
|
||||||
);
|
);
|
||||||
super((...args2) => {
|
super((...args2) => {
|
||||||
if (args2.length === 1) {
|
if (args2.length === 1) {
|
||||||
return $.parse(args2[0]);
|
return $2.parse(args2[0]);
|
||||||
}
|
}
|
||||||
if (args2.length === 2 && typeof args2[0] === "string" && args2[0][0] === "<" && args2[0].at(-1) === ">") {
|
if (args2.length === 2 && typeof args2[0] === "string" && args2[0][0] === "<" && args2[0].at(-1) === ">") {
|
||||||
const paramString = args2[0].slice(1, -1);
|
const paramString = args2[0].slice(1, -1);
|
||||||
const params = $.parseGenericParams(paramString, {});
|
const params = $2.parseGenericParams(paramString, {});
|
||||||
return new GenericRoot(params, args2[1], $, $, null);
|
return new GenericRoot(params, args2[1], $2, $2, null);
|
||||||
}
|
}
|
||||||
return $.parse(args2);
|
return $2.parse(args2);
|
||||||
}, {
|
}, {
|
||||||
attach
|
attach
|
||||||
});
|
});
|
||||||
@@ -103427,6 +103424,32 @@ var schema = ark.schema;
|
|||||||
var define2 = ark.define;
|
var define2 = ark.define;
|
||||||
var declare = ark.declare;
|
var declare = ark.declare;
|
||||||
|
|
||||||
|
// external.ts
|
||||||
|
var ghPullfrogMcpName = "gh_pullfrog";
|
||||||
|
var agentsManifest = {
|
||||||
|
claude: {
|
||||||
|
displayName: "Claude Code",
|
||||||
|
apiKeyNames: ["anthropic_api_key"],
|
||||||
|
url: "https://claude.com/claude-code"
|
||||||
|
},
|
||||||
|
codex: {
|
||||||
|
displayName: "Codex CLI",
|
||||||
|
apiKeyNames: ["openai_api_key"],
|
||||||
|
url: "https://platform.openai.com/docs/guides/codex"
|
||||||
|
},
|
||||||
|
cursor: {
|
||||||
|
displayName: "Cursor CLI",
|
||||||
|
apiKeyNames: ["cursor_api_key"],
|
||||||
|
url: "https://cursor.com/"
|
||||||
|
},
|
||||||
|
gemini: {
|
||||||
|
displayName: "Gemini CLI",
|
||||||
|
apiKeyNames: ["google_api_key", "gemini_api_key"],
|
||||||
|
url: "https://ai.google.dev/gemini-api/docs"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
var AgentName = type.enumerated(...Object.keys(agentsManifest));
|
||||||
|
|
||||||
// node_modules/.pnpm/universal-user-agent@7.0.3/node_modules/universal-user-agent/index.js
|
// node_modules/.pnpm/universal-user-agent@7.0.3/node_modules/universal-user-agent/index.js
|
||||||
function getUserAgent() {
|
function getUserAgent() {
|
||||||
if (typeof navigator === "object" && "userAgent" in navigator) {
|
if (typeof navigator === "object" && "userAgent" in navigator) {
|
||||||
@@ -103921,7 +103944,7 @@ async function fetchWrapper(requestOptions) {
|
|||||||
"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"
|
"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"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
const log2 = requestOptions.request?.log || console;
|
const log3 = requestOptions.request?.log || console;
|
||||||
const parseSuccessResponseBody = requestOptions.request?.parseSuccessResponseBody !== false;
|
const parseSuccessResponseBody = requestOptions.request?.parseSuccessResponseBody !== false;
|
||||||
const body = isPlainObject3(requestOptions.body) || Array.isArray(requestOptions.body) ? JSON.stringify(requestOptions.body) : requestOptions.body;
|
const body = isPlainObject3(requestOptions.body) || Array.isArray(requestOptions.body) ? JSON.stringify(requestOptions.body) : requestOptions.body;
|
||||||
const requestHeaders = Object.fromEntries(
|
const requestHeaders = Object.fromEntries(
|
||||||
@@ -103979,7 +104002,7 @@ async function fetchWrapper(requestOptions) {
|
|||||||
if ("deprecation" in responseHeaders) {
|
if ("deprecation" in responseHeaders) {
|
||||||
const matches = responseHeaders.link && responseHeaders.link.match(/<([^<>]+)>; rel="deprecation"/);
|
const matches = responseHeaders.link && responseHeaders.link.match(/<([^<>]+)>; rel="deprecation"/);
|
||||||
const deprecationLink = matches && matches.pop();
|
const deprecationLink = matches && matches.pop();
|
||||||
log2.warn(
|
log3.warn(
|
||||||
`[@octokit/request] "${requestOptions.method} ${requestOptions.url}" is deprecated. It is scheduled to be removed on ${responseHeaders.sunset}${deprecationLink ? `. See ${deprecationLink}` : ""}`
|
`[@octokit/request] "${requestOptions.method} ${requestOptions.url}" is deprecated. It is scheduled to be removed on ${responseHeaders.sunset}${deprecationLink ? `. See ${deprecationLink}` : ""}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -106856,7 +106879,7 @@ var import_table = __toESM(require_src(), 1);
|
|||||||
import { appendFileSync, existsSync } from "node:fs";
|
import { appendFileSync, existsSync } from "node:fs";
|
||||||
import { join } from "node:path";
|
import { join } from "node:path";
|
||||||
var isGitHubActions = !!process.env.GITHUB_ACTIONS;
|
var isGitHubActions = !!process.env.GITHUB_ACTIONS;
|
||||||
var isDebugEnabled = process.env.LOG_LEVEL === "debug";
|
var isDebugEnabled = () => process.env.LOG_LEVEL === "debug";
|
||||||
function startGroup2(name) {
|
function startGroup2(name) {
|
||||||
if (isGitHubActions) {
|
if (isGitHubActions) {
|
||||||
core.startGroup(name);
|
core.startGroup(name);
|
||||||
@@ -106901,7 +106924,9 @@ function boxString(text, options) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const maxLineLength = Math.max(...wrappedLines.map((line) => line.length));
|
const maxLineLength = Math.max(...wrappedLines.map((line) => line.length));
|
||||||
const boxWidth = maxLineLength + padding * 2;
|
const contentBoxWidth = maxLineLength + padding * 2;
|
||||||
|
const titleLineLength = title ? ` ${title} `.length : 0;
|
||||||
|
const boxWidth = Math.max(contentBoxWidth, titleLineLength);
|
||||||
let result = "";
|
let result = "";
|
||||||
if (title) {
|
if (title) {
|
||||||
const titleLine = ` ${title} `;
|
const titleLine = ` ${title} `;
|
||||||
@@ -107043,7 +107068,7 @@ var log = {
|
|||||||
* Print debug message (only if LOG_LEVEL=debug)
|
* Print debug message (only if LOG_LEVEL=debug)
|
||||||
*/
|
*/
|
||||||
debug: (message) => {
|
debug: (message) => {
|
||||||
if (isDebugEnabled) {
|
if (isDebugEnabled()) {
|
||||||
if (isGitHubActions) {
|
if (isGitHubActions) {
|
||||||
core.debug(message);
|
core.debug(message);
|
||||||
} else {
|
} else {
|
||||||
@@ -107085,10 +107110,22 @@ var log = {
|
|||||||
* End a collapsed group
|
* End a collapsed group
|
||||||
*/
|
*/
|
||||||
endGroup: endGroup2,
|
endGroup: endGroup2,
|
||||||
|
/**
|
||||||
|
* Log tool call information to console with formatted output
|
||||||
|
*/
|
||||||
|
toolCall: ({ toolName, input }) => {
|
||||||
|
let output = `\u2192 ${toolName}
|
||||||
|
`;
|
||||||
|
const inputFormatted = formatJsonValue(input);
|
||||||
|
if (inputFormatted !== "{}") {
|
||||||
|
output += formatIndentedField("input", inputFormatted);
|
||||||
|
}
|
||||||
|
log.info(output.trimEnd());
|
||||||
|
},
|
||||||
/**
|
/**
|
||||||
* Log MCP tool call information to mcpLog.txt in the temp directory
|
* Log MCP tool call information to mcpLog.txt in the temp directory
|
||||||
*/
|
*/
|
||||||
toolCall: ({
|
toolCallToFile: ({
|
||||||
toolName,
|
toolName,
|
||||||
request: request2,
|
request: request2,
|
||||||
result,
|
result,
|
||||||
@@ -107176,7 +107213,20 @@ function parseRepoContext() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// mcp/shared.ts
|
// mcp/shared.ts
|
||||||
var getMcpContext = cached(() => {
|
function getPayload() {
|
||||||
|
const payloadEnv = process.env.PULLFROG_PAYLOAD;
|
||||||
|
if (!payloadEnv) {
|
||||||
|
throw new Error("PULLFROG_PAYLOAD environment variable is required");
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
return JSON.parse(payloadEnv);
|
||||||
|
} catch (error41) {
|
||||||
|
throw new Error(
|
||||||
|
`Failed to parse PULLFROG_PAYLOAD: ${error41 instanceof Error ? error41.message : String(error41)}`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function getMcpContext() {
|
||||||
const githubInstallationToken = process.env.GITHUB_INSTALLATION_TOKEN;
|
const githubInstallationToken = process.env.GITHUB_INSTALLATION_TOKEN;
|
||||||
if (!githubInstallationToken) {
|
if (!githubInstallationToken) {
|
||||||
throw new Error("GITHUB_INSTALLATION_TOKEN environment variable is required");
|
throw new Error("GITHUB_INSTALLATION_TOKEN environment variable is required");
|
||||||
@@ -107185,28 +107235,18 @@ var getMcpContext = cached(() => {
|
|||||||
...parseRepoContext(),
|
...parseRepoContext(),
|
||||||
octokit: new Octokit2({
|
octokit: new Octokit2({
|
||||||
auth: githubInstallationToken
|
auth: githubInstallationToken
|
||||||
})
|
}),
|
||||||
|
payload: getPayload()
|
||||||
};
|
};
|
||||||
});
|
}
|
||||||
var tool = (toolDef) => {
|
var tool = (toolDef) => {
|
||||||
const toolName = toolDef.name;
|
const toolName = toolDef.name;
|
||||||
const originalExecute = toolDef.execute;
|
const originalExecute = toolDef.execute;
|
||||||
toolDef.execute = async (args2, context) => {
|
toolDef.execute = async (args2, context) => {
|
||||||
try {
|
try {
|
||||||
const result = await originalExecute(args2, context);
|
const result = await originalExecute(args2, context);
|
||||||
const isError = result && typeof result === "object" && "isError" in result && result.isError === true;
|
|
||||||
const resultData = result && typeof result === "object" && "content" in result ? result.content[0]?.text : void 0;
|
|
||||||
if (isError && resultData) {
|
|
||||||
log.toolCall({ toolName, request: args2, error: resultData });
|
|
||||||
} else if (resultData) {
|
|
||||||
log.toolCall({ toolName, request: args2, result: resultData });
|
|
||||||
} else {
|
|
||||||
log.toolCall({ toolName, request: args2 });
|
|
||||||
}
|
|
||||||
return result;
|
return result;
|
||||||
} catch (error41) {
|
} catch (error41) {
|
||||||
const errorMessage = error41 instanceof Error ? error41.message : String(error41);
|
|
||||||
log.toolCall({ toolName, request: args2, error: errorMessage });
|
|
||||||
throw error41;
|
throw error41;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -107332,6 +107372,33 @@ var GetCheckSuiteLogsTool = tool({
|
|||||||
});
|
});
|
||||||
|
|
||||||
// mcp/comment.ts
|
// mcp/comment.ts
|
||||||
|
var PULLFROG_DIVIDER = "<!-- PULLFROG_DIVIDER_DO_NOT_REMOVE_PLZ -->";
|
||||||
|
function buildCommentFooter(payload) {
|
||||||
|
const repoContext = parseRepoContext();
|
||||||
|
const runId = process.env.GITHUB_RUN_ID;
|
||||||
|
const agentName = payload.agent;
|
||||||
|
const agentInfo = agentName ? agentsManifest[agentName] : null;
|
||||||
|
const agentDisplayName = agentInfo?.displayName || "Unknown Agent";
|
||||||
|
const agentUrl = agentInfo?.url || "https://pullfrog.ai";
|
||||||
|
const workflowRunUrl = runId ? `https://github.com/${repoContext.owner}/${repoContext.name}/actions/runs/${runId}` : `https://github.com/${repoContext.owner}/${repoContext.name}`;
|
||||||
|
return `
|
||||||
|
${PULLFROG_DIVIDER}
|
||||||
|
---
|
||||||
|
|
||||||
|
<sup>\u{1F438} Triggered by [Pullfrog](https://pullfrog.ai) | \u{1F916} [${agentDisplayName}](${agentUrl}) | [View workflow run](${workflowRunUrl}) | [\u{1D54F}](https://x.com/pullfrogai)</sup>`;
|
||||||
|
}
|
||||||
|
function stripExistingFooter(body) {
|
||||||
|
const dividerIndex = body.indexOf(PULLFROG_DIVIDER);
|
||||||
|
if (dividerIndex === -1) {
|
||||||
|
return body;
|
||||||
|
}
|
||||||
|
return body.substring(0, dividerIndex).trimEnd();
|
||||||
|
}
|
||||||
|
function addFooter(body, payload) {
|
||||||
|
const bodyWithoutFooter = stripExistingFooter(body);
|
||||||
|
const footer = buildCommentFooter(payload);
|
||||||
|
return `${bodyWithoutFooter}${footer}`;
|
||||||
|
}
|
||||||
var Comment = type({
|
var Comment = type({
|
||||||
issueNumber: type.number.describe("the issue number to comment on"),
|
issueNumber: type.number.describe("the issue number to comment on"),
|
||||||
body: type.string.describe("the comment body content")
|
body: type.string.describe("the comment body content")
|
||||||
@@ -107341,11 +107408,12 @@ var CreateCommentTool = tool({
|
|||||||
description: "Create a comment on a GitHub issue",
|
description: "Create a comment on a GitHub issue",
|
||||||
parameters: Comment,
|
parameters: Comment,
|
||||||
execute: contextualize(async ({ issueNumber, body }, ctx) => {
|
execute: contextualize(async ({ issueNumber, body }, ctx) => {
|
||||||
|
const bodyWithFooter = addFooter(body, ctx.payload);
|
||||||
const result = await ctx.octokit.rest.issues.createComment({
|
const result = await ctx.octokit.rest.issues.createComment({
|
||||||
owner: ctx.owner,
|
owner: ctx.owner,
|
||||||
repo: ctx.name,
|
repo: ctx.name,
|
||||||
issue_number: issueNumber,
|
issue_number: issueNumber,
|
||||||
body
|
body: bodyWithFooter
|
||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
success: true,
|
success: true,
|
||||||
@@ -107364,11 +107432,12 @@ var EditCommentTool = tool({
|
|||||||
description: "Edit a GitHub issue comment by its ID",
|
description: "Edit a GitHub issue comment by its ID",
|
||||||
parameters: EditComment,
|
parameters: EditComment,
|
||||||
execute: contextualize(async ({ commentId, body }, ctx) => {
|
execute: contextualize(async ({ commentId, body }, ctx) => {
|
||||||
|
const bodyWithFooter = addFooter(body, ctx.payload);
|
||||||
const result = await ctx.octokit.rest.issues.updateComment({
|
const result = await ctx.octokit.rest.issues.updateComment({
|
||||||
owner: ctx.owner,
|
owner: ctx.owner,
|
||||||
repo: ctx.name,
|
repo: ctx.name,
|
||||||
comment_id: commentId,
|
comment_id: commentId,
|
||||||
body
|
body: bodyWithFooter
|
||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
success: true,
|
success: true,
|
||||||
@@ -107394,11 +107463,13 @@ var CreateWorkingCommentTool = tool({
|
|||||||
if (workingCommentId) {
|
if (workingCommentId) {
|
||||||
throw new Error("create_working_comment may not be called multiple times");
|
throw new Error("create_working_comment may not be called multiple times");
|
||||||
}
|
}
|
||||||
|
const body = `${intent} <img src="https://pullfrog.ai/party-parrot.gif" width="14px" height="14px" style="vertical-align: middle; margin-left: 4px;" />`;
|
||||||
|
const bodyWithFooter = addFooter(body, ctx.payload);
|
||||||
const result = await ctx.octokit.rest.issues.createComment({
|
const result = await ctx.octokit.rest.issues.createComment({
|
||||||
owner: ctx.owner,
|
owner: ctx.owner,
|
||||||
repo: ctx.name,
|
repo: ctx.name,
|
||||||
issue_number: issueNumber,
|
issue_number: issueNumber,
|
||||||
body: `${intent} <img src="https://pullfrog.ai/party-parrot.gif" width="14px" height="14px" style="vertical-align: middle; margin-left: 4px;" />`
|
body: bodyWithFooter
|
||||||
});
|
});
|
||||||
workingCommentId = result.data.id;
|
workingCommentId = result.data.id;
|
||||||
return {
|
return {
|
||||||
@@ -107420,11 +107491,12 @@ var UpdateWorkingCommentTool = tool({
|
|||||||
if (!workingCommentId) {
|
if (!workingCommentId) {
|
||||||
throw new Error("create_working_comment must be called before update_working_comment");
|
throw new Error("create_working_comment must be called before update_working_comment");
|
||||||
}
|
}
|
||||||
|
const bodyWithFooter = addFooter(body, ctx.payload);
|
||||||
const result = await ctx.octokit.rest.issues.updateComment({
|
const result = await ctx.octokit.rest.issues.updateComment({
|
||||||
owner: ctx.owner,
|
owner: ctx.owner,
|
||||||
repo: ctx.name,
|
repo: ctx.name,
|
||||||
comment_id: workingCommentId,
|
comment_id: workingCommentId,
|
||||||
body
|
body: bodyWithFooter
|
||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
success: true,
|
success: true,
|
||||||
@@ -107468,8 +107540,43 @@ var IssueTool = tool({
|
|||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// utils/shell.ts
|
||||||
|
import { spawnSync } from "node:child_process";
|
||||||
|
function $(cmd, args2, options) {
|
||||||
|
const encoding = options?.encoding ?? "utf-8";
|
||||||
|
const result = spawnSync(cmd, args2, {
|
||||||
|
stdio: ["inherit", "pipe", "pipe"],
|
||||||
|
encoding,
|
||||||
|
cwd: options?.cwd
|
||||||
|
});
|
||||||
|
const stdout = result.stdout ?? "";
|
||||||
|
const stderr = result.stderr ?? "";
|
||||||
|
if (options?.log !== false) {
|
||||||
|
if (stdout) {
|
||||||
|
process.stdout.write(stdout);
|
||||||
|
}
|
||||||
|
if (stderr) {
|
||||||
|
process.stderr.write(stderr);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (result.status !== 0) {
|
||||||
|
const errorResult = {
|
||||||
|
status: result.status ?? -1,
|
||||||
|
stdout,
|
||||||
|
stderr
|
||||||
|
};
|
||||||
|
if (options?.onError) {
|
||||||
|
options.onError(errorResult);
|
||||||
|
return stdout.trim();
|
||||||
|
}
|
||||||
|
throw new Error(
|
||||||
|
`Command failed with exit code ${errorResult.status}: ${stderr || "Unknown error"}`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return stdout.trim();
|
||||||
|
}
|
||||||
|
|
||||||
// mcp/pr.ts
|
// mcp/pr.ts
|
||||||
import { execSync } from "node:child_process";
|
|
||||||
var PullRequest = type({
|
var PullRequest = type({
|
||||||
title: type.string.describe("the title of the pull request"),
|
title: type.string.describe("the title of the pull request"),
|
||||||
body: type.string.describe("the body content of the pull request"),
|
body: type.string.describe("the body content of the pull request"),
|
||||||
@@ -107480,9 +107587,7 @@ var PullRequestTool = tool({
|
|||||||
description: "Create a pull request from the current branch",
|
description: "Create a pull request from the current branch",
|
||||||
parameters: PullRequest,
|
parameters: PullRequest,
|
||||||
execute: contextualize(async ({ title, body, base }, ctx) => {
|
execute: contextualize(async ({ title, body, base }, ctx) => {
|
||||||
const currentBranch = execSync("git rev-parse --abbrev-ref HEAD", {
|
const currentBranch = $("git", ["rev-parse", "--abbrev-ref", "HEAD"], { log: false });
|
||||||
encoding: "utf8"
|
|
||||||
}).trim();
|
|
||||||
log.info(`Current branch: ${currentBranch}`);
|
log.info(`Current branch: ${currentBranch}`);
|
||||||
const result = await ctx.octokit.rest.pulls.create({
|
const result = await ctx.octokit.rest.pulls.create({
|
||||||
owner: ctx.owner,
|
owner: ctx.owner,
|
||||||
@@ -107505,7 +107610,6 @@ var PullRequestTool = tool({
|
|||||||
});
|
});
|
||||||
|
|
||||||
// mcp/prInfo.ts
|
// mcp/prInfo.ts
|
||||||
import { execSync as execSync2 } from "node:child_process";
|
|
||||||
var PullRequestInfo = type({
|
var PullRequestInfo = type({
|
||||||
pull_number: type.number.describe("The pull request number to fetch")
|
pull_number: type.number.describe("The pull request number to fetch")
|
||||||
});
|
});
|
||||||
@@ -107526,11 +107630,11 @@ var PullRequestInfoTool = tool({
|
|||||||
throw new Error(`Base branch not found for PR #${pull_number}`);
|
throw new Error(`Base branch not found for PR #${pull_number}`);
|
||||||
}
|
}
|
||||||
log.info(`Fetching base branch: origin/${baseBranch}`);
|
log.info(`Fetching base branch: origin/${baseBranch}`);
|
||||||
execSync2(`git fetch origin ${baseBranch} --depth=20`, { stdio: "inherit" });
|
$("git", ["fetch", "origin", baseBranch, "--depth=20"]);
|
||||||
log.info(`Fetching PR branch: origin/${headBranch}`);
|
log.info(`Fetching PR branch: origin/${headBranch}`);
|
||||||
execSync2(`git fetch origin ${headBranch}`, { stdio: "inherit" });
|
$("git", ["fetch", "origin", headBranch]);
|
||||||
log.info(`Checking out PR branch: origin/${headBranch}`);
|
log.info(`Checking out PR branch: origin/${headBranch}`);
|
||||||
execSync2(`git checkout -B ${headBranch} origin/${headBranch}`, { stdio: "inherit" });
|
$("git", ["checkout", "-B", headBranch, `origin/${headBranch}`]);
|
||||||
return {
|
return {
|
||||||
number: data.number,
|
number: data.number,
|
||||||
url: data.html_url,
|
url: data.html_url,
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@pullfrog/action",
|
"name": "@pullfrog/action",
|
||||||
"version": "0.0.111",
|
"version": "0.0.112",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"files": [
|
"files": [
|
||||||
"index.js",
|
"index.js",
|
||||||
|
|||||||
Reference in New Issue
Block a user