feat: test msnodesqlv8 against v2-v5 across supported Node versions#1870
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the Windows CI workflow to exercise msnodesqlv8 majors v2–v5 only on Node.js versions where prebuilt win32-x64 binaries are available, avoiding flaky node-gyp source builds on newer GitHub runner images (e.g., VS 2026 on windows-2025). It also updates documentation to reflect the expanded supported driver major range.
Changes:
- Update the Windows CI matrix steps to install/test
msnodesqlv8across v2, v3, v4, and v5 with Node-version gating. - Remove the previously always-false condition that prevented
msnodesqlv8tests from running on some Node versions. - Update README driver description to indicate
msnodesqlv8coverage across v2–v5.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| README.md | Updates the MSNodeSQLv8 driver description to reflect v2–v5 coverage. |
| .github/workflows/nodejs.yml | Expands and gates Windows CI msnodesqlv8 installs/tests across majors v2–v5 to avoid source builds and improve coverage. |
Exercise the optional msnodesqlv8 driver against every supported major on each Node version that ships a prebuilt win32-x64 binary for it, rather than only v2 (Node 18/20) and v4 (Node 22/24): v2: Node 18 v3: Node 18, 20 v4: Node 18-24 v5: Node 20, 22, 24 v2 ships no prebuilt binary for Node 20+, so it fell back to a node-gyp source build that broke once windows-2025 moved to Visual Studio 2026 (which the bundled node-gyp cannot detect). Gating each major to its prebuilt-binary range removes the source build entirely and broadens coverage to v3 and v5. Also drops an always-false condition (node == '22.x' && node == '24.x') that silently skipped the driver tests on Node 22 and 24. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
8a0fceb to
9ed51d2
Compare
|
🎉 This PR is included in version 12.6.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
PRs were failing on the Windows CI matrix — specifically Node 20 on
windows-2025(every SQL Server version) — while installingmsnodesqlv8@^2, which fell back to anode-gypsource build that couldn't find a Visual Studio toolchain:The cause is environmental, not in node-mssql: GitHub's
windows-2025label is being routed to thewindows-2025-vs2026image (Visual Studio 2026, internal version 18), and the bundlednode-gypcan't detect VS 2026 — see actions/runner-images#14004 and nodejs/node-gyp#3250.It only hit Node 20 because that was the one matrix cell that compiled from source:
msnodesqlv8@^2ships no prebuiltwin32-x64binary for Node 20 (ABI 115), whereas Node 18 (v2 prebuild) and Node 22/24 (v4 prebuilds) loaded prebuilt binaries and never invokednode-gyp.What
Gate each
msnodesqlv8major to the Node versions it actually ships a prebuiltwin32-x64binary for, so CI never compiles from source — which makes the VS toolchain on the runner image irrelevant:This fixes the failure and broadens driver coverage from
{v2, v4}to{v2, v3, v4, v5}. The README driver line is updated tov2-v5.It also removes a pre-existing always-false condition (
node == '22.x' && node == '24.x') that silently skipped themsnodesqlv8tests on Node 22/24 entirely.Notes
fail-fast: false(already on the windows matrix) means any such failure reports independently rather than cancelling siblings.msnodesqlv8testing remains disabled (separate, pre-existing segfault) and is out of scope here.🤖 Generated with Claude Code