From 0b13d04ac49d327e17813deebe2aa70b1f00bd26 Mon Sep 17 00:00:00 2001 From: "John J. Camilleri" Date: Mon, 18 Oct 2021 14:42:37 +0200 Subject: [PATCH] Use Node.js 12 in CI --- .github/workflows/build-majestic.yml | 12 ++++++++++-- src/runtime/javascript/README.md | 9 +++++---- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-majestic.yml b/.github/workflows/build-majestic.yml index e336f4cf6..fc0453c21 100644 --- a/.github/workflows/build-majestic.yml +++ b/.github/workflows/build-majestic.yml @@ -84,7 +84,6 @@ jobs: name: JavaScript (Ubuntu) runs-on: ubuntu-20.04 needs: ubuntu-runtime - if: false steps: - uses: actions/checkout@v2 @@ -96,6 +95,11 @@ jobs: sudo mv lib/* /usr/local/lib/ sudo mv include/* /usr/local/include/ + - name: Setup Node.js + run: | + nvm install 12 + nvm use 12 + - name: Install dependencies working-directory: ./src/runtime/javascript run: | @@ -193,7 +197,6 @@ jobs: name: JavaScript (macOS) runs-on: macOS-11 needs: macos-runtime - if: false steps: - uses: actions/checkout@v2 @@ -205,6 +208,11 @@ jobs: sudo mv lib/* /usr/local/lib/ sudo mv include/* /usr/local/include/ + - name: Setup Node.js + run: | + nvm install 12 + nvm use 12 + - name: Install dependencies working-directory: ./src/runtime/javascript run: | diff --git a/src/runtime/javascript/README.md b/src/runtime/javascript/README.md index a0c4052aa..6dc3200b8 100644 --- a/src/runtime/javascript/README.md +++ b/src/runtime/javascript/README.md @@ -31,11 +31,12 @@ npm run build npm run test ``` -## Known issues +## Compatability + +Unfortunately, these bindings currently only work properly with Node.js < 14. +Newer versions of Node.js case the bindings to crash randomly, and/or run very slowly. +This issue is discussed here: -There is a known issue with random crashes with Node 14 and 16 on macOS. See here: - https://github.com/nodejs/node/issues/32463 - https://github.com/node-ffi-napi/node-ffi-napi/issues/97 - https://github.com/node-ffi-napi/ref-napi/issues/47 - -It seems to work with Node 12 on macOS, as well as on other platforms.