[Backport staging-25.05] versionCheckHook: Default versionCheckProgram to mainProgram#454228
Closed
nixpkgs-ci[bot] wants to merge 5 commits intostaging-25.05from
Closed
[Backport staging-25.05] versionCheckHook: Default versionCheckProgram to mainProgram#454228nixpkgs-ci[bot] wants to merge 5 commits intostaging-25.05from
versionCheckProgram to mainProgram#454228nixpkgs-ci[bot] wants to merge 5 commits intostaging-25.05from
Conversation
…GRAM` (cherry picked from commit 0c8cc4c)
(cherry picked from commit 98380fc)
…ionCheckProgram` Should `versionCheckProgram` not be specified, the hook now first defaults to `$outputBin/bin/$NIX_MAIN_PROGRAM` before considering `$outputBin/bin/$pname`. Falling back to $pname will also emit a warning now, similar to that of `lib.getExe`. (cherry picked from commit 1b92d2f)
…N_PROGRAM` (cherry picked from commit 651abd9)
(cherry picked from commit 32a6fb6)
13 tasks
Member
JohnRTitor
added a commit
to JohnRTitor/nixpkgs
that referenced
this pull request
Oct 21, 2025
This should be reverted once/if NixOS#454228 is merged to release-25.05.
emilazy
requested changes
Oct 21, 2025
Member
emilazy
left a comment
There was a problem hiding this comment.
I don’t think it’s acceptable to make meta cause rebuilds on the release branch. This change has been controversial enough in unstable; see e.g. #412768 (comment) and #430810.
|
|
||
| - `meta.mainProgram`: Changing this `meta` entry can lead to a package rebuild due to being used to determine the `NIX_MAIN_PROGRAM` environment variable. | ||
|
|
||
| - `versionCheckHook`: Packages that previously relied solely on `pname` to locate the program used to version check, but have a differing `meta.mainProgram` entry, might now fail. |
Member
There was a problem hiding this comment.
As you can see here, this is a breaking change, and therefore not suitable for backport.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bot-based backport to
staging-25.05, triggered by a label in #412768.