From 6d12f786af69925cfac04c2cc723725941352928 Mon Sep 17 00:00:00 2001 From: Caleb Date: Thu, 25 Jun 2026 23:59:08 +0300 Subject: [PATCH 1/3] fix: remove box shadow from header --- src/index.html | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/index.html b/src/index.html index e174a4a..aabb1cb 100644 --- a/src/index.html +++ b/src/index.html @@ -21,7 +21,6 @@ --text: #e5e7ff; --muted: #9194b8; --accent: #8b8dff; - --accent-glow: rgba(139, 141, 255, 0.35); } * { @@ -91,8 +90,6 @@ line-height: 1.05; margin-bottom: 24px; - - text-shadow: 0 0 30px var(--accent-glow); } .accent { From 4d40c56abd5fa76e925d06a863be8462eef58e5d Mon Sep 17 00:00:00 2001 From: Caleb Date: Fri, 26 Jun 2026 00:53:09 +0300 Subject: [PATCH 2/3] fix: resolve pr number via branch fallback when pull_requests is empty --- .../workflow_run.completed/checklint.ts | 49 ++++++++++++++----- 1 file changed, 36 insertions(+), 13 deletions(-) diff --git a/src/events/workflow_run.completed/checklint.ts b/src/events/workflow_run.completed/checklint.ts index f7ed318..54240df 100644 --- a/src/events/workflow_run.completed/checklint.ts +++ b/src/events/workflow_run.completed/checklint.ts @@ -12,19 +12,22 @@ export default async (context: Context<"workflow_run.completed">) => { const { owner, repo } = context.repo(); const workflowRun = context.payload.workflow_run; - if (workflowRun.conclusion === "success") { - const pullRequests = workflowRun.pull_requests as Array<{ number: number }>; - if (!pullRequests || pullRequests.length === 0) return; - - const pull_number = pullRequests[0].number; + const pull_number = await resolvePullNumber( + context, + workflowRun, + owner, + repo, + ); + if (!pull_number) return; + if (workflowRun.conclusion === "success") { const body = [ "> [!NOTE]", "> Linting checks passed successfully πŸŽ‰", "", "All formatting and code quality checks are clean.", "", - "You’re good to merge πŸš€", + "You're good to merge πŸš€", ].join("\n"); await context.octokit.rest.issues.createComment({ @@ -37,13 +40,6 @@ export default async (context: Context<"workflow_run.completed">) => { return; } - // Find the PR associated with this workflow run - const pullRequests = workflowRun.pull_requests as Array<{ number: number }>; - - if (!pullRequests || pullRequests.length === 0) return; - - const pull_number = pullRequests[0].number; - const logsUrl = `https://github.com/${owner}/${repo}/actions/runs/${workflowRun.id}`; const body = [ @@ -77,3 +73,30 @@ export default async (context: Context<"workflow_run.completed">) => { body, }); }; + +async function resolvePullNumber( + context: Context<"workflow_run.completed">, + workflowRun: Context<"workflow_run.completed">["payload"]["workflow_run"], + owner: string, + repo: string, +): Promise { + const directPRs = workflowRun.pull_requests as Array<{ number: number }>; + if (directPRs?.length > 0) { + return directPRs[0].number; + } + + const headBranch = workflowRun.head_branch; + const headSha = workflowRun.head_sha; + + if (!headBranch) return null; + + const { data: prs } = await context.octokit.rest.pulls.list({ + owner, + repo, + state: "open", + head: `${owner}:${headBranch}`, + }); + + const match = prs.find((pr) => pr.head.sha === headSha) ?? prs[0]; + return match?.number ?? null; +} From ac5a6aeee4d51e581914297dab909dbe84f433a7 Mon Sep 17 00:00:00 2001 From: Caleb Date: Fri, 26 Jun 2026 00:56:52 +0300 Subject: [PATCH 3/3] fix: remove prs[0] fallback in `resolvePullNumber` Co-authored-by: beetle-ai[bot] <221859081+beetle-ai[bot]@users.noreply.github.com> --- src/events/workflow_run.completed/checklint.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/events/workflow_run.completed/checklint.ts b/src/events/workflow_run.completed/checklint.ts index 54240df..0b5d2de 100644 --- a/src/events/workflow_run.completed/checklint.ts +++ b/src/events/workflow_run.completed/checklint.ts @@ -97,6 +97,6 @@ async function resolvePullNumber( head: `${owner}:${headBranch}`, }); - const match = prs.find((pr) => pr.head.sha === headSha) ?? prs[0]; + const match = prs.find((pr) => pr.head.sha === headSha); return match?.number ?? null; }