add #timeout, macro errors, refactor tests (#191)

This commit is contained in:
David Blass
2026-01-28 21:06:57 +00:00
committed by pullfrog[bot]
parent f77fecc2a0
commit 943409c417
18 changed files with 472 additions and 94 deletions
+4
View File
@@ -22,6 +22,7 @@ export const JsonPayload = type({
"repoInstructions?": "string",
"event?": "object",
"effort?": Effort.or("undefined"),
"timeout?": type.string.or("undefined"),
});
// permission levels that indicate collaborator status (have push access)
@@ -41,6 +42,7 @@ function isCollaborator(event: PayloadEvent): boolean {
export const Inputs = type({
prompt: "string",
"effort?": Effort.or("undefined"),
"timeout?": type.string.or("undefined"),
"agent?": AgentName.or("undefined"),
"web?": ToolPermissionInput.or("undefined"),
"search?": ToolPermissionInput.or("undefined"),
@@ -70,6 +72,7 @@ export function resolvePayload(repoSettings: RepoSettings) {
const inputs = Inputs.assert({
prompt: core.getInput("prompt", { required: true }),
effort: core.getInput("effort") || undefined,
timeout: core.getInput("timeout") || undefined,
agent: core.getInput("agent") || undefined,
cwd: core.getInput("cwd") || undefined,
web: core.getInput("web") || undefined,
@@ -145,6 +148,7 @@ export function resolvePayload(repoSettings: RepoSettings) {
repoInstructions: jsonPayload?.repoInstructions,
event,
effort: inputs.effort ?? jsonPayload?.effort ?? "auto",
timeout: inputs.timeout ?? jsonPayload?.timeout,
cwd: resolveCwd(inputs.cwd),
// permissions: inputs > repoSettings > fallbacks