Use node-gyp compatible version of Python in runner for test workflow #19
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.
The
node-gyp
dependency of this project uses a Python script.Previously, the test GitHub Actions workflow was not configured to install a specific version of Python, so whichever version of Python 3.x that was pre-installed on the GitHub Actions runner machine was used.
The documentation for the
[email protected]
version used by this project indicates the newest supported Python version is 3.8:https://github.com/nodejs/node-gyp/tree/v7.1.2#installation
Clearly newer versions did work because the workflow has been running with Python 3.10. However, the
macos-latest
runner was updated to using Python 3.11 and the script now fails whennpm install
is ran in the project:https://github.com/arduino/arduino-serial-plotter-webapp/actions/runs/3428463267/jobs/5714559323#step:4:122
The solution is to install a specific version of Python for use in the runner. It seems safest to use the newest version explicitly stated as supported by the
[email protected]
documentation, so Python 3.8 is installed.