Snap Creation

Asked by ChrisOfBristol on 2018-03-08

I've got an application which I have made into a deb and is available on GetDeb. It is a simple Python application which uses GTK+ for the GUI. I want to make it available as a Snap. Using LXD 'snapcraft cleanbuild' creates a Snap which can be installed, but it fails to run, with an error related to GTK+.

I can't find a GTK+ forum and haven't had any knowledgeable suggestions on a Snap forum. Since Python and GTK+ are both fundamental parts of Ubuntu, I am beginning to suspect that Snap is still too experimental for it to be practical for anyone other than a real expert to create one. Am I right? If not where will I get competent help?

Question information

English Edit question
Ubuntu Edit question
No assignee Edit question
Last query:
Last reply:

Are there any guides on YouTube?

It's more a question of error fixing than learning how to construct it.

chris@Dell-DXP051:~/myapp$ myapp
Traceback (most recent call last):
  File "<frozen importlib._bootstrap>", line 890, in _find_spec
AttributeError: 'DynamicImporter' object has no attribute 'find_spec'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "", line 125, in <module>
    from gi.repository import Gtk, GdkPixbuf
  File "/snap/myapp/x11/usr/lib/python3/dist-packages/gi/", line 127, in find_module
    'introspection typelib not found' % namespace)
ImportError: cannot import name Gtk, introspection typelib not found

Manfred Hampl (m-hampl) said : #3

According to you might be missing the gir1.2-gtk-3.0 package (at least for the second error).

Can you help with this problem?

Provide an answer of your own, or ask ChrisOfBristol for more information if necessary.

To post a message you must log in.