Am I correctly testing a snap locally

So I built the snap that has some stagePackages. To test it, I installed it via snap install mysnapfile.snap --dangerous.

When I started mysnapfile, I get following error in the terminal

error while loading shared libraries: cannot open shared object file: No such file or directory

My questions are

  1. Is this the right way to test a new snap package? Should I expect the same error when I upload this to snapcraft?
  2. What could be the reason behind this error?

Hey there the testing method isnt bad, i also use the same method frequently. Yes you should expect that error to persist when uploading to the store

Regarding the error , try to search the package in ubuntu repositories similar to that of your core version (core22-jammy, core20-focal) and stage it in your snap.

1 Like