This was reported first on Discord in this thread. During sst deploy
you would get an error like this:
Error: ENOENT: no such file or directory, open '/home/user/reproductions/sst-opennext-semver/.sst/dist/asset.ac657782e4de0bc902dc2aa50204299a3d4f962bb14db71e08584c7ec5c4da48/node_modules/.bin/semver'
This symbolic link was pointing to a file that does not exist so it would crash during sst deploy
as it would not find those files.
semver -> /tmp/open-next-install-image-optimization-functioneUpKfE/node_modules/semver/bin/semver.js
It seems to only affect Node version 22.17.0
and 22.17.1
. All other Node versions seems to work fine. I debugged this down to these lines. Setting dereference: true
should remove all references to symbolic links and copy the target to the destination instead.
In theory we could patch this one on our side, or wait until Node fixes it upstream.
Related issue: nodejs/node#59168