catkin part error when built after python part

Bug #1730248 reported by Ruddick Lawrence
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
Fix Released
Critical
Kyle Fazzari

Bug Description

When snapping the attached example with the snapcraft master branch (currently https://github.com/snapcore/snapcraft/tree/52e03e5e46d88809f706fb4f45e6556710d576ba), it fails with the error:

Unable to find user site packages: /home/ruddick/Downloads/snapcraft_ros_example/parts/ros-project/install/lib/python2*/site-packages

The cause is the following new code since 2.34: https://github.com/snapcore/snapcraft/blob/52e03e5e46d88809f706fb4f45e6556710d576ba/snapcraft/plugins/catkin.py#L652-L657

It fails because self._pip.is_setup() uses stage to see if pip is installed, which it was in the pip-install part, but _python.generate_sitecustomize() operates on parts/ros-project/install, which does not have any python code or site-packages directory.

Revision history for this message
Ruddick Lawrence (mrjogo) wrote :
Revision history for this message
Kyle Fazzari (kyrofa) wrote :

Good catch Ruddick, thank you. Indeed, there's no reason to generate a sitecustomize unless pip dependencies were pulled in the Catkin part itself, which it's not. Fixing now.

Changed in snapcraft:
status: New → In Progress
importance: Undecided → Critical
assignee: nobody → Kyle Fazzari (kyrofa)
Revision history for this message
Kyle Fazzari (kyrofa) wrote :
Changed in snapcraft:
status: In Progress → Fix Committed
milestone: none → 2.35
Changed in snapcraft:
status: Fix Committed → Fix Released
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.