--debug does not expose appropriate environment variables

Bug #1848513 reported by Robie Basak
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
New
Undecided
Unassigned

Bug Description

It's great that when a command fails I am dropped into a shell.

However if the failing command relied on environment variables, those variables aren't set and so I can't reproduce the same failure.

There are two cases when this happens.

1) During an override such as an override-pull, where I expect SNAPCRAFT_* to be set (from https://snapcraft.io/docs/t/environment-variables-that-snapcraft-exposes/7569)

2) Inside a command that snapcraft itself ran. For example, if "snapcraftctl pull" runs "pip install" which fails, I expect to be able to run the command that failed (from the debug output) in the shell and see the same failure. This doesn't happen because the Python-specific environment variables aren't propagated.

Revision history for this message
Robie Basak (racb) wrote :

I'm using --use-lxd if that makes a difference.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.