Please test my asciinema snap

Michael Hudson-Doyle michael.hudson at canonical.com
Tue Jan 24 22:28:30 UTC 2017


On 25 January 2017 at 11:02, Sergio Schvezov <sergio.schvezov at canonical.com>
wrote:

> On Wed, 25 Jan 2017 08:17:17 +1300, Michael Hudson-Doyle wrote:
> > Hm, I was assuming that the PYTHONHOME leaking was due to things in the
> > snap specifically (is the source to the snap available?), but are they
> set
> > by snapd or snap-confine or something?
>
> Might be easier to follow in the bug Dave logged and linked to earlier,
> but in a nutshell: snapcraft sets up  a couple of variables to get things
> going. There seems to be conflicts with classic systems but are only
> viewable now with trusty enablement.
>

Well no, what I am complaining about is something perhaps related to that
bug but not the same.


> I am guessing the snapcraft.yaml for this looks like
>
> parts:
>     asciinema:
>         plugin: python
>         python-packages: [asciinema]
>
> I've added python3 as a part and did some environment tweaks locally and
> it works like a charm.
>

But if you did that, PYTHONHOME is presumably still set in the environment
of the command you are recording with asciinema. I was trying to record me
using a new widget in a program using urwid and getting this sort of thing:

mwhudson at aeglos:/opt/opensource$ asciinema rec -c 'python3
urwid/examples/pop_up.py '
~ Asciicast recording started.
~ Hit Ctrl-D or type "exit" to finish.
Traceback (most recent call last):
  File "urwid/examples/pop_up.py", line 3, in <module>
    import urwid
ImportError: No module named 'urwid'
~ Asciicast recording finished.
~ Press <Enter> to upload, <Ctrl-C> to cancel.

You have to do this "asciinema rec -c 'PYTHONHOME=/usr python3
urwid/examples/pop_up.py '" instead (and even that ends up using python3
from the core snap, not the one I have installed).

Cheers,
mwh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/snapcraft/attachments/20170125/05a4246f/attachment.html>


More information about the Snapcraft mailing list