Skip to content

Fix #17: Add Node.js version check with clear error message#77

Open
bluerook2000 wants to merge 2 commits intoVibiumDev:mainfrom
bluerook2000:fix/issue-17-node-version-check
Open

Fix #17: Add Node.js version check with clear error message#77
bluerook2000 wants to merge 2 commits intoVibiumDev:mainfrom
bluerook2000:fix/issue-17-node-version-check

Conversation

@bluerook2000
Copy link
Copy Markdown

Problem

When Vibium is run with an incompatible Node.js version (< 18), users get cryptic failures like Chrome not launching, with no indication that the Node.js version is the root cause (see #17).

Solution

Added a checkNodeVersion() utility that runs at the start of browser.launch() and throws a clear, actionable error if Node.js < 18 is detected:

Error: Vibium requires Node.js >= 18.0.0, but you are running Node.js 16.20.2. Please upgrade Node.js: https://nodejs.org/

Changes

  • clients/javascript/src/utils/version.ts — New utility with checkNodeVersion() function
  • clients/javascript/src/browser.ts — Call version check at the start of launch()
  • clients/javascript/package.json — Added engines field declaring node >= 18.0.0

Why this approach

  • Fail-fast with a clear message before any browser/clicker operations
  • The engines field in package.json also lets npm/yarn warn during install
  • Minimal footprint — just a single lightweight check at launch time

Closes #17

Red Ventra and others added 2 commits February 11, 2026 22:40
Add a checkNodeVersion() utility that validates Node.js >= 18.0.0
at browser launch time, providing a clear actionable error message
instead of cryptic failures when running on older versions.

Changes:
- Add clients/javascript/src/utils/version.ts with version check
- Call checkNodeVersion() at the start of browser.launch()
- Add engines field to package.json declaring node >= 18.0.0
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.

Improve error/warning when incompatible Node.js version is detected

2 participants