Skip to content

fix: name the cron and pull request dispatchers in their failure messages - #271

Merged
jeefy merged 1 commit into
cncf:mainfrom
jeefy:fix/dispatcher-error-prefix
Oct 3, 2026
Merged

jeefy merged 1 commit into
cncf:mainfrom
jeefy:fix/dispatcher-error-prefix

Conversation

@jeefy

@jeefy jeefy commented Oct 3, 2026

Copy link
Copy Markdown
Member

What was wrong

src/cronJobs/handleCronJob.ts and src/pullReq/handlePullReq.ts both wrap their job results in:

new TypeError(`error handling issue comment: ${result}`)

That prefix was copy-pasted from src/issueComment/handleIssueComment.ts — but these are the cron-job and pull-request dispatchers, so failures in scheduled jobs and PR events are mislabeled as issue-comment failures.

What changed

  • handleCronJob.ts: error handling cron job: …
  • handlePullReq.ts: error handling pull request: …
  • handleIssueComment.ts untouched (it was already correct).
  • No test changes needed: every existing assertion on the old string exercises the handleIssueComment path (issue_comment event or direct call), not the cron/PR dispatchers.
  • dist/index.js regenerated; only the two intended lines changed.

Unblocks review feedback on #242 and #248.

…ages

handleCronJob and handlePullReq both copied the issue-comment dispatcher's 'error handling issue comment' TypeError prefix. Report what each one actually dispatches. Unblocks review feedback on cncf#242 and cncf#248.

Signed-off-by: Jeffrey Sica <me@jeefy.dev>
@jeefy
jeefy requested a review from jpmcb as a code owner October 3, 2026 04:10
@github-actions

github-actions Bot commented Oct 3, 2026

Copy link
Copy Markdown
Contributor

Please add a kind label with /kind failing-test or /kind cleanup.

@jeefy
jeefy merged commit 14f94d0 into cncf:main Oct 3, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant