Skip to content

Commit

Permalink
pypa: Dont sort by platform tag
Browse files Browse the repository at this point in the history
  • Loading branch information
adisbladis committed Nov 2, 2023
1 parent ead9da8 commit d39da14
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 0 additions & 2 deletions lib/pypa.nix
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,6 @@ lib.fix (self: {
in
{
bestLanguageTag = head (sort (x: y: x > y) languageTags');
platformTagJoined = concatStringsSep "." file.platformTags;
compatible = abiCompatible && length languageTags > 0 && lib.any (self.isPlatformTagCompatible python) file.platformTags;
inherit file;
})
Expand All @@ -334,7 +333,6 @@ lib.fix (self: {
|| x.file.version > y.file.version
|| (x.file.buildTag != null && (y.file.buildTag == null || x.file.buildTag > y.file.buildTag))
|| x.bestLanguageTag > y.bestLanguageTag
|| x.platformTagJoined > y.platformTagJoined
)
compatibleFiles;

Expand Down
8 changes: 4 additions & 4 deletions lib/test_pypa.nix
Original file line number Diff line number Diff line change
Expand Up @@ -348,16 +348,16 @@ in
testCPythonDarwin311 = mkTest {
input = zmqWheels;
output = [
"pyzmq-24.0.1-cp311-cp311-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp39-cp39-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp311-cp311-macosx_10_15_universal2.whl"
"pyzmq-24.0.1-cp311-cp311-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp310-cp310-macosx_10_15_universal2.whl"
"pyzmq-24.0.1-cp310-cp310-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp39-cp39-macosx_10_15_universal2.whl"
"pyzmq-24.0.1-cp38-cp38-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp39-cp39-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp38-cp38-macosx_10_15_universal2.whl"
"pyzmq-24.0.1-cp38-cp38-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp37-cp37m-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp36-cp36m-macosx_10_9_x86_64.whl"
"pyzmq-24.0.1-cp310-cp310-macosx_10_15_universal2.whl"
];
python = mocks.cpythonDarwin311;
};
Expand Down

0 comments on commit d39da14

Please sign in to comment.