← Back to issue list

Rewrite shebangs generated by the python plugins.

View original Github issue

Metadata

Project
snapcraft
Number
#680
Type
pull request
State
merged
Author
kyrofa
Labels
—
Created
Updated
Closed

Current evaluation

Merged PR #680 as commit 066d653b5, rewriting Python plugin shebangs to use env instead of absolute paths and fixing LP #1597919.

Resolution: closed resolved

Reason: The Python plugins now rewrite generated shebangs through install directories using env; the change was merged in commit 066d653b5 and resolves LP #1597919.

Evaluated by: mr-cal-bot

No scores available.

Issue body

This PR resolves LP: [#1597919](https://bugs.launchpad.net/snapcraft/+bug/1597919) by walking through the install directories for python{2,3} parts, ensuring all python shebangs are using `env` instead of being paths.

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged PR #680 as commit 066d653b5, rewriting Python plugin shebangs to use env instead of absolute paths and fixing LP #1597919.
stealth/space-bunny-alpha — closed resolved Merged PR #680 (commit 066d653b5) by kyrofa: python plugins now walk install dirs for python2/3 parts and rewrite absolute-path shebangs to use /usr/bin/env. Fixes LP: #1597919; approved by sergiusens after integration tests were added.
stealth/space-bunny-alpha — closed resolved Merged #680 in commit 066d653b5, rewriting Python plugin shebangs to use env instead of absolute paths and fixing LP #1597919.
qwen/qwen3.6-35b-a3b — — Merged changes that rewrite Python plugin shebangs to use env instead of hardcoded paths, resolving Launchpad bug #1597919. After adding requested integration tests, the changes were approved and merged across 13 files.
qwen3.6-35b-a3b-mtp-q6 — — Merged after incorporating requested integration tests and a Launchpad reference. Resolves LP #1597919 by rewriting Python shebangs to use env instead of hardcoded paths across install directories.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#830 python plugin: only replace proper shebangs. snapcraft merged Merged as commit 60e29ef1b, restricting Python plugin shebang replacement to file beginnings and fixing LP #1626587-related plainbox conflicts.
76%
#1719 many: account for python shebang args in rewrite snapcraft merged Merged #1719 as commit 8ed95e68a, preserving Python shebang arguments and centralizing rewrites; fixes LP bugs #1730472 and #1673451.
74%
#311 plugins: fix python shebang rockcraft merged Merged PR #311 in commit 08e6a28c, replacing hardcoded plugin Python shebangs with ${PARTS_PYTHON_INTERPRETER} so interpreter overrides are honored.
74%