← Back to issue list

staging lsb-release in python part make the part fail

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#2017688
Type
issue
State
open
Author
~gbeuzeboc
Labels
—
Created
Updated
Closed
—

Current evaluation

Python part venv creation fails in ensurepip when lsb-release is staged or part ordering changes; the cause appears tied to interpreter PATH resolution, but the report remains untriaged.

Suggested action: needs triage

Reason: No labels, assignee, or maintainer response are present; the sole follow-up is from the reporter, who showed that an earlier nil part makes staging lsb-release reproducible. Current craft-parts code still prepends part-install/bin to PATH, and open craft-parts#675 documents the same PATH-driven ensurepip failure, so this is a valid, specific report needing triage rather than closure.

Evaluated by: mr-cal-bot

Impact: 48 Quick Win: 18 Complexity: 52 Confidence: 91 Actionability: 78

Issue body

Staging the apt package lsb-release in python part make the build of the part fail with the following message: Pulling my-part + snapcraftctl pull Building my-part + snapcraftctl build + python3 -m venv /root/parts/my-part/install Error: Command '['/root/parts/my-part/install/bin/python3', '-Im', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 1. Failed to build 'my-part'. The snapcraft.yaml is: name: my-snap-name base: core20 version: '0.1' summary: text description: | more text grade: devel # must be 'stable' to release into candidate/stable channels confinement: devmode # use 'strict' once you have the right plugs and slots parts: my-part: plugin: python python-packages: [numpy] stage-packages: [lsb-release] apps: my-snap-name: command: bin/python3 Calling snapcraft over it causes the issue. Removing ${SNAPCRAFT_PART_INSTALL}/bin from the PATH seems to solve the issue, but this is hardcoded in the plugin

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha
Impact: 48
Quick Win: 18
Complexity: 52
Confidence: 91
Actionability: 78
needs triage Python part venv creation fails in ensurepip when lsb-release is staged or part ordering changes; the cause appears tied to interpreter PATH resolution, but the report remains untriaged.
stealth/space-bunny-alpha
Impact: 40
Quick Win: 12
Complexity: 58
Confidence: 94
Actionability: 72
close stale A core20 Python-part build failed during ensurepip when an earlier part staged lsb-release into the install PATH; core20 support has since been removed from Snapcraft.
stealth/space-bunny-alpha
Impact: 48
Quick Win: 17
Complexity: 52
Confidence: 83
Actionability: 74
needs triage Untriaged core20 Python-part builds fail during venv/ensurepip when lsb-release is staged; removing the part's bin directory from PATH works around it.
qwen3.6-35b-a3b-mtp-q6
Impact: 40
Quick Win: 28
Staleness: 95
Complexity: 30
Confidence: 70
Support Request: 10
needs triage Untriaged bug report stating that staging lsb-release in a python part causes ensurepip to fail due to PATH pollution. No maintainer interaction in over 3 years.
qwen/qwen3.6-35b-a3b
Staleness: 95
Complexity: 40
Confidence: 80
Support Request: 5
close stale Python part build fails when staging lsb-release due to PATH/ensurepip issues. Reported 3 years ago with no maintainer response or updates.
qwen/qwen3.6-35b-a3b
Staleness: 98
Complexity: 65
Confidence: 90
Support Request: 20
close stale Build failure in Snapcraft Python part when staging lsb-release due to PATH conflict with ensurepip. Issue is inactive for over 3 years with no maintainer response.
qwen3.6-35b-a3b-mtp-q6
Staleness: 95
Complexity: 45
Confidence: 85
Support Request: 10
close stale Build fails when staging lsb-release in a Python part due to ensurepip error. Untriaged, no maintainer response, inactive for over three years.

Update history

Date Change
created

Related work

  • Related To: craft-parts#675 (confidence 94%)

    The open issue identifies Python plugin PATH prepending and an ensurepip failure caused by resolving python3 from an install venv.

Related issues

No related issues found above the similarity threshold.