Skip to content

Handle missing LTS schedule dates in lts-lint-definitions - #122

Merged
jasonkarns merged 1 commit into
nodenv:mainfrom
nmackey:fix-lts-lint-missing-dates
Oct 30, 2026
Merged

jasonkarns merged 1 commit into
nodenv:mainfrom
nmackey:fix-lts-lint-missing-dates

Conversation

@nmackey

@nmackey nmackey commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

Node's schedule.json now includes a v27 entry with no maintenance date:

"v27": {
  "alpha": "2026-10-28",
  "start": "2027-04-22",
  "lts": "2027-10-20",
  "end": "2030-04-30",
  "codename": ""
}

lts-lint-definitions runs under set -u, so ${!maint_date_var} aborts with:

script/lts-lint-definitions: line 115: !maint_date_var: unbound variable

This fails the lts job on every node-build PR (e.g. nodenv/node-build#1143), and silently on the scheduled scrape since that step is continue-on-error.

Fix

  • Default missing end/maintenance dates to empty (${!var-}).
  • past() returns false for an empty date. Otherwise "" < TODAY is true and every v27 definition would be flagged as needing an LTS warning.

Verified

Against node-build's share/node-build (with #1143's definitions added):

  • exits 0 (currently crashes)
  • with the warning stripped from 24.22.1, it reports that file and exits 1
  • --fix re-inserts the warning

🤖 Generated with Claude Code

Node's schedule.json now lists v27 without a "maintenance" date. Under
`set -u`, the indirect expansion of the missing variable aborts the lint
with "maint_date_var: unbound variable", failing every run.

Default missing dates to empty, and treat an empty date as not yet past
so release lines without a scheduled phase aren't flagged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@jasonkarns
jasonkarns merged commit cc30a17 into nodenv:main Oct 30, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants