1{ 2 lib, 3 argon2-cffi, 4 buildPythonPackage, 5 fetchFromGitHub, 6 setuptools, 7 keyring, 8 pycryptodome, 9 pytestCheckHook, 10 pytest-cov-stub, 11 pythonOlder, 12}: 13 14buildPythonPackage rec { 15 pname = "keyrings-cryptfile"; 16 version = "1.4.1"; 17 pyproject = true; 18 19 disabled = pythonOlder "3.5"; 20 21 src = fetchFromGitHub { 22 owner = "frispete"; 23 repo = "keyrings.cryptfile"; 24 tag = "v${version}"; 25 hash = "sha256-cDXx0s3o8hNqgzX4oNkjGhNcaUX5vi1uN2d9sdbiZwk="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 dependencies = [ 31 argon2-cffi 32 keyring 33 pycryptodome 34 ]; 35 36 pythonImportsCheck = [ "keyrings.cryptfile" ]; 37 38 nativeCheckInputs = [ 39 pytestCheckHook 40 pytest-cov-stub 41 ]; 42 43 disabledTests = [ 44 # correct raise `ValueError`s which pytest fails to catch for some reason: 45 "test_empty_username" 46 # TestEncryptedFileKeyring::test_file raises 'ValueError: Incorrect Password' for some reason, maybe mock related: 47 "TestEncryptedFileKeyring" 48 ]; 49 50 meta = with lib; { 51 description = "Encrypted file keyring backend"; 52 mainProgram = "cryptfile-convert"; 53 homepage = "https://github.com/frispete/keyrings.cryptfile"; 54 changelog = "https://github.com/frispete/keyrings.cryptfile/blob/v${version}/CHANGES.md"; 55 license = licenses.mit; 56 maintainers = [ maintainers.bbjubjub ]; 57 }; 58}