python37Packages.cryptography: Improve the test vectors integration
This should make the management easier. The package cryptography_vectors contains the test vectors for cryptography and should therefore always have the same version. By linking the version of cryptography_vectors to cryptography, this simply cannot be forgotten.
This commit is contained in:
@@ -20,9 +20,8 @@
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
# also bump cryptography_vectors
|
||||
pname = "cryptography";
|
||||
version = "2.5";
|
||||
version = "2.5"; # Also update the hash in vectors.nix
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
|
||||
23
pkgs/development/python-modules/cryptography/vectors.nix
Normal file
23
pkgs/development/python-modules/cryptography/vectors.nix
Normal file
@@ -0,0 +1,23 @@
|
||||
{ buildPythonPackage, fetchPypi, lib, cryptography }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "cryptography_vectors";
|
||||
# The test vectors must have the same version as the cryptography package:
|
||||
version = cryptography.version;
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "15qfl3pnw2f11r0z0zhwl56f6pb60ysav8fxmpnz5p80cfwljdik";
|
||||
};
|
||||
|
||||
# No tests included
|
||||
doCheck = false;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Test vectors for the cryptography package";
|
||||
homepage = https://cryptography.io/en/latest/development/test-vectors/;
|
||||
# Source: https://github.com/pyca/cryptography/tree/master/vectors;
|
||||
license = with licenses; [ asl20 bsd3 ];
|
||||
maintainers = with maintainers; [ primeos ];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user