NS8 module developers: fix UI builds on Node.js 26 and enable UI test screenshots

Hi all,

three recent changes may need a small update in your NS8 module. Example PR with the first two fixes: fix: Node.js 26 build and UI screenshots by andre8244 · Pull Request #10 · stephdl/ns8-discourse · GitHub

1. UI build fails on Node.js 26: corepack: not found

Node.js 26 no longer ships Corepack, and node:lts points to it since 2026-10-28. We already talked about this here GitHub Action publish-images doesn't work anymore due to missing yarn/corepack

  • Pin an exact Node.js image instead of node:lts (e.g. node:26.13.0-slim)
  • Run npm install -g corepack before corepack enable, in build-images.sh and ui/Containerfile

2. Optional: UI test screenshots need contents: write

Only if your module has UI tests and you want their screenshots in a pull request comment. CML’s image host (asset.cml.dev) stopped accepting uploads, so screenshots now go to a ci-screenshots branch of your repository. Grant the permission in the job that calls test-module-qemu.yml@v1:

    permissions:
      contents: write
      pull-requests: write
      statuses: write

Without it, nothing breaks: the comment links the run artifacts instead.

3. DigitalOcean test workflows removed from @v1

If you call test-module.yml or test-on-digitalocean-infra.yml, switch to test-module-qemu.yml@v1.

4. Tests fail installing tests/pythonreq.txt

See reply below

Details here:

3 Likes

a big thank you @andre8244

1 Like

Hey mates, do you use screenshots in your QEMU tests?

It’s a good habit, especially with Renovate. Combined with Robot tests, we can capture screenshots of our app’s web pages and make sure a Webpack update hasn’t broken the build or messed up the UI.

Andre gave a tour and mentioned that I’m the only one doing this. Come on, don’t leave me alone on this one! :grin:

2 Likes

I tested it yesterday but it failed on installing rocky and debian, see Test main on QEMU · mrmarkuz/ns8-guacamole@e4e06ff · GitHub
I’m going to give it another try…

EDIT:

Thanks for your PR @andre8244 , OS installation is working now, I just need to fix my tests…

2 Likes

One more thing for modules switching to test-module-qemu.yml@v1 (item 3):

4. Tests fail while installing tests/pythonreq.txt: No such file or directory: ‘gcc’

Many modules created from the old module template ship a tests/pythonreq.txt with very old pinned versions, such as cffi==1.15.0 and robotframework==4.1.2. These have no prebuilt package for the Python of the test container, which has no compiler to build them.

The action already installs robotframework, robotframework-sshlibrary and, for UI tests, robotframework-browser, together with their dependencies (paramiko, scp, cryptography, bcrypt, pynacl, cffi, pycparser…). So:

  • If your tests only use Robot Framework, SSHLibrary and Browser, delete tests/pythonreq.txt. The old template file contains only packages of this kind, so most modules can simply delete it.
  • If your tests import other Python libraries, keep only those lines in tests/pythonreq.txt, pinned to recent versions that publish wheels for Python 3.11 and 3.12, or that are pure Python.
  • Don’t pin robotframework, robotframework-sshlibrary or robotframework-browser: a pin replaces the version installed by the action.

The test log now shows a clear error naming the package that cannot be built, and a warning when the file pins one of those three packages.

Details:

2 Likes