Electron-builder snap not working

Hi, I’ve been trying to build snaps using electron-builder but after installation the default command does not run the snap.

Running <app_name> from the command line does nothing with no errors. Same with clicking the icon. Running /snap/<app_name>/current/<app_name> works.

I’ve reported this at https://github.com/electron-userland/electron-builder/issues/5067 to no avail.

I realise that /snap/bin/<app_name> is a symlink to /usr/bin/snap (a binary file) so I don’t really know how to debug it when there are no errors.

Can anyone help? Thanks a lot.