From ce5d1ba8f8b1c0226a4fdd73ff11304fc78dd9ec Mon Sep 17 00:00:00 2001 From: Kristoffer Dalby Date: Fri, 17 Apr 2026 08:33:49 +0000 Subject: [PATCH] github: split nu where in needs-more-info timer GitHub's /issues/:n/events endpoint returns a mixed-schema table. Only labeled/unlabeled rows carry a `label` column. Nu's `where` does not short-circuit on missing columns, so the combined predicate `event == "labeled" and label.name == ...` dereferenced `label.name` on every row and crashed on the first non-labeled event with `nu::shell::column_not_found`. The scheduled job has failed every night since 2026-04-13 (the first run with a labeled issue), so no `needs-more-info` issue has been auto-closed. Split into two sequential `where` filters so `label.name` is only accessed on rows that have the column. --- .github/workflows/needs-more-info-timer.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/needs-more-info-timer.yml b/.github/workflows/needs-more-info-timer.yml index c53cdd5c..de46c7b1 100644 --- a/.github/workflows/needs-more-info-timer.yml +++ b/.github/workflows/needs-more-info-timer.yml @@ -60,7 +60,8 @@ jobs: let events = (gh api $"repos/($env.GH_REPO)/issues/($number)/events" --paginate | from json | flatten) let label_event = ($events - | where event == "labeled" and label.name == "needs-more-info" + | where event == "labeled" + | where label.name == "needs-more-info" | last) let label_added_at = ($label_event.created_at | into datetime)