Homey Cli on Windows on ARM

Hello,
I’ve recently purchased a new machine powered by Snapdragon X Elite, and I must say I’m extremely satisfied with it. However, I’m unable to make any progress developing Homey apps on this device.

Whenever I run the command Homey app run, I receive the following error:

TypeError: Cannot read properties of undefined (reading 'push')
    at Object.libvipsVersion (C:\Users\jirip\AppData\Roaming\npm\node_modules\homey\node_modules\@img\sharp-wasm32\lib\sharp-wasm32.node.js:1:122617)
    at Object.<anonymous> (C:\Users\jirip\AppData\Roaming\npm\node_modules\homey\node_modules\sharp\lib\utility.js:14:30)
    at Module._compile (node:internal/modules/cjs/loader:1554:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1706:10)
    at Module.load (node:internal/modules/cjs/loader:1289:32)
    at Module._load (node:internal/modules/cjs/loader:1108:12)
    at TracingChannel.traceSync (node:diagnostics_channel:322:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)
    at Module.require (node:internal/modules/cjs/loader:1311:12)
    at require (node:internal/modules/helpers:136:16)

Node.js v22.14.0

I haven’t been able to resolve this issue yet, despite trying to debug it with Gemini and ChatGPT.

Does anyone have any ideas on how to fix this?

Original error:

PS C:\Users\jirip\SynologyDrive\HomeyApps\V2CWallbox> homey app run
C:\Users\jirip\AppData\Roaming\npm\node_modules\homey\node_modules\sharp\lib\sharp.js:113
  throw new Error(help.join('\n'));
        ^

Error: Could not load the "sharp" module using the win32-arm64 runtime
Possible solutions:
- Manually install libvips >= 8.15.3
- Add experimental WebAssembly-based dependencies:
    npm install --cpu=wasm32 sharp
    npm install @img/sharp-wasm32
- Consult the installation documentation:
    See https://sharp.pixelplumbing.com/install
    at Object.<anonymous> (C:\Users\jirip\AppData\Roaming\npm\node_modules\homey\node_modules\sharp\lib\sharp.js:113:9)
    at Module._compile (node:internal/modules/cjs/loader:1554:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1706:10)
    at Module.load (node:internal/modules/cjs/loader:1289:32)
    at Module._load (node:internal/modules/cjs/loader:1108:12)
    at TracingChannel.traceSync (node:diagnostics_channel:322:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:220:24)
    at Module.require (node:internal/modules/cjs/loader:1311:12)
    at require (node:internal/modules/helpers:136:16)
    at Object.<anonymous> (C:\Users\jirip\AppData\Roaming\npm\node_modules\homey\node_modules\sharp\lib\constructor.js:10:1)

Node.js v22.14.0

?

Didnt worked :frowning: tried both of them :frowning:

  1. resulted in error in 1st post
  2. didnt changed anything :frowning:

In that case, you can report it here: GitHub · Where software is built

1 Like

Thanks a lot :slight_smile:

One workaround is to build homey apps in wsl. It can be used as a cli, while still one can use for example visual studio code to access the files. One hint - dont install in windows shared folders (mapped in wsl like mnt/c…) but in wsl native folder structure (ie in home for example). Tried it and it works ok. It is simply because important libraries are already available for linux arm64 but not for windows arm64.