Skip to content

feat: accept alpha versions in YAML comments - #729

Merged
Trott merged 1 commit into
nodejs:mainfrom
RafaelGSS:feat-accept-alpha-versions-in-yaml-comments
Oct 17, 2026
Merged

Trott merged 1 commit into
nodejs:mainfrom
RafaelGSS:feat-accept-alpha-versions-in-yaml-comments

Conversation

@RafaelGSS

Copy link
Copy Markdown
Member

feat: accept alpha versions in YAML comments

Node.js 27 introduces Alpha releases versioned as
vN.0.0-alpha.X.Y.Z (see nodejs/node#63135), and REPLACEME
placeholders are replaced with the full Alpha version when releasing
them. Accept those versions in the YAML comments of the docs.

Refs: https://github.com/nodejs/Release/issues/1187

Node.js 27 introduces Alpha releases versioned as
vN.0.0-alpha.X.Y.Z (see nodejs/node#63135), and REPLACEME
placeholders are replaced with the full Alpha version when releasing
them. Accept those versions in the YAML comments of the docs.

Refs: nodejs/Release#1187
Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
@RafaelGSS RafaelGSS mentioned this pull request Oct 16, 2026
8 tasks
@Trott

Trott commented Oct 16, 2026

Copy link
Copy Markdown
Member

Change looks good to me. I'm sure releasers have thought about this, but just in case: I'm not sure if these eventually get replaced with production release numbers or not, but I hope so. Seems like we should only include production releases in the docs, since something might be introduced in 20.0.0-alpha1 but not actually show up in a production release until 20.17.2 or whatever. And it's that second number that matters for someone trying to figure out what versions of Node.js they support.

@Trott

Trott commented Oct 16, 2026

Copy link
Copy Markdown
Member

@nschonni You and I are the only people who have merged anything in this repository in the last 6 months. Any chance you want to review this? (If not, no problem, I'll just go ahead and merge it.)

@nschonni nschonni left a comment •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a blocker, but I note that the semver package is refrenced, but doesn't seem to be used. Possible it could be used for this, or dropped (in a separate PR)

edit: the package is used, but GitHub Code Search is flakey

Array.from({ length: 3 }, () => Number.MAX_SAFE_INTEGER).join("."),
);
const validVersionNumberRegex = /^v\d+\.\d+\.\d+$/;
const validVersionNumberRegex = /^v\d+\.\d+\.\d+(?:-alpha\.\d+\.\d+\.\d+)?$/;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Took a look at https://www.npmjs.com/package/semver, and it does seem like the call on 62 could be replaced with a call to semverValid

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But that would be more permissive, wouldn't it? It would permit valid semver versions that we don't use in the project, I think?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think that's why it wasn't used in the original PR

@Trott
Trott merged commit 1887657 into nodejs:main Oct 17, 2026
4 checks passed
@Trott

Trott commented Oct 17, 2026

Copy link
Copy Markdown
Member

The GitHub Action successfully published the package, but then failed.....

https://github.com/nodejs/remark-preset-lint-node/actions/runs/39009971958/job/117330590785

Guess we should debug that......

@Trott

Trott commented Oct 17, 2026

Copy link
Copy Markdown
Member

The GitHub Action successfully published the package, but then failed.....

https://github.com/nodejs/remark-preset-lint-node/actions/runs/39009971958/job/117330590785

Guess we should debug that......

#730

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.

3 participants