Enable snap version to be used in other parts of the snapcraft.yaml
Metadata
Current evaluation
Feature request for using the snap version inside other snapcraft.yaml fields delivered by merged snapcore/snapcraft PR #757 (commit dc0b68174), exporting SNAPCRAFT_PROJECT_NAME/VERSION/STAGE so sources can use $SNAPCRAFT_PROJECT_VERSION. LP bug closed.
Resolution: closed resolved
Reason: The discussion was redirected to snapcore/snapcraft PR #757 'Export important project variables', which was merged as dc0b68174; it moved _expand_env into the project loader and exported SNAPCRAFT_PROJECT_VERSION (still documented in docs/reference/part-environment-variables.rst and used in docs examples), and the LP bug was closed citing that PR.
Evaluated by: mr-cal-bot
Issue body
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Feature request for using the snap version inside other snapcraft.yaml fields delivered by merged snapcore/snapcraft PR #757 (commit dc0b68174), exporting SNAPCRAFT_PROJECT_NAME/VERSION/STAGE so sources can use $SNAPCRAFT_PROJECT_VERSION. LP bug closed. | |
| stealth/space-bunny-alpha | — | closed resolved | Project variables were added by merged PR #757 (dc0b68174), enabling reuse of the snap version in part configuration and source URLs. | |
| stealth/space-bunny-alpha | — | closed resolved | Snap name and version variable handling was added in PR #773, enabling project metadata to be referenced elsewhere in snapcraft.yaml. | |
| qwen/qwen3.6-35b-a3b | — | — | Abandoned. The feature request to template the snap version in other YAML fields was closed without implementation due to prolonged inactivity and zero comments. | |
| qwen/qwen3.6-35b-a3b | — | — | Abandoned without resolution. The request to interpolate the snapcraft version in other YAML fields received no comments or implementation, leaving the feature unimplemented. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without implementation. The request to interpolate the snap version in snapcraft.yaml fields was abandoned. Lacking discussion or patches, it was not adopted or superseded. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without implementation. The feature to interpolate the snapcraft version in other YAML fields received no comments or resolution, indicating it was abandoned. |
Update history
| Date | Change |
|---|---|
| created |
Related work
-
Likely Fixed By:
canonical/snapcraft#757
(confidence 95%)
Merged PR referenced in the last comment; commit dc0b68174 exports SNAPCRAFT_PROJECT_VERSION and related project variables usable in part sources.
-
Related To:
snapcraft#3350
(confidence 55%)
Later added advanced grammar support for build-environment (commit ef2fa17e1), enabling {version}-style substitution in fixed yaml fields.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1538688 Support referencing the stage dir from snapcraft.yaml | snapcraft (launchpad) | closed | Implemented SNAPCRAFT_STAGE substitution for part properties and merged the fix in canonical/snapcraft#270 via eb033b40c. | |
| #1587933 Allow using .snapcraft.yaml as input | snapcraft (launchpad) | closed | Feature implemented in canonical/snapcraft PR #582 (commit 98eda9897), shipped in snapcraft 2.12 to xenial; SRU verified by elopio and released to -updates, closing the Launchpad bug. |