{gradle.fetchDeps,shattered-pixel-dungeon}: fix eval on Nix 2.3.18#329212
Merged
roberth merged 2 commits intoNixOS:masterfrom Jul 24, 2024
Merged
{gradle.fetchDeps,shattered-pixel-dungeon}: fix eval on Nix 2.3.18#329212roberth merged 2 commits intoNixOS:masterfrom
roberth merged 2 commits intoNixOS:masterfrom
Conversation
13 tasks
philiptaron
commented
Jul 22, 2024
chayleaf
reviewed
Jul 22, 2024
To reproduce, run `nix shell nixpkgs#nixVersions.minimum --command nix-build -A shattered-pixel-dungeon`
In 2.3, lists aren't able to be compared with `<`, but `builtins.compareVersions` does exist.
5d27c29 to
2b7232d
Compare
Contributor
Author
|
OK, this should be better. |
Contributor
|
Result of 1 package built:
|
Contributor
|
the rebuild is because of the following: --- a.json 2024-07-24 06:14:53.288998420 +0700
+++ b.json 2024-07-24 06:14:56.910078145 +0700
@@ -541,7 +541,7 @@
"hash": "sha256-5e/PA5zZCWiMIB3FR5sUT9bwHw5AJSt/xefS4bXAeZA="
},
"https://repo.maven.apache.org/maven2/commons-codec/commons-codec/maven-metadata.xml": {
- "text": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<metadata modelVersion=\"1.1.0\">\n <groupId>commons-codec</groupId>\n <artifactId>commons-codec</artifactId>\n <versioning>\n <latest>1.17.0</latest>\n <release>1.17.0</release>\n <versions>\n <version>1.11</version>\n <version>1.17.0</version>\n <version>1.3</version>\n <version>1.9</version>\n </versions>\n <lastUpdated>20240427124755</lastUpdated>\n </versioning>\n</metadata>\n"
+ "text": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<metadata modelVersion=\"1.1.0\">\n <groupId>commons-codec</groupId>\n <artifactId>commons-codec</artifactId>\n <versioning>\n <latest>1.17.0</latest>\n <release>1.17.0</release>\n <versions>\n <version>1.3</version>\n <version>1.9</version>\n <version>1.11</version>\n <version>1.17.0</version>\n </versions>\n <lastUpdated>20240427124755</lastUpdated>\n </versioning>\n</metadata>\n"
},
"https://repo.maven.apache.org/maven2/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar": {
"hash": "sha256-7urpF5FxRKaKdB1MDf9mqlxcX9hVk/8he87T/Iyng7g="which is more correct, so LGTM (nit: the diff could be made smaller by inlining the compare function) |
chayleaf
approved these changes
Jul 23, 2024
13 tasks
13 tasks
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.
Motivation
I discovered this problem developing tests for
nixpkgs-check-by-namein NixOS/nixpkgs-vet#79. Nix 2.3.18 isnixVersions.minimum.The changes were introduced in #272380. CC @chayleaf.
Description of changes
./. + "relative path"instead of constructing a path with newer Nix syntax.lib.compareListsinstead of comparing lists directly.Things done
nixVersions.minimum)nixVersions.latest)nixVersions.stable)