2021-01-25 09:26:54 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, pythonOlder, isPy27, six
|
2021-06-03 12:09:11 +02:00
|
|
|
, pytest, backports_unittest-mock, keyring, setuptools-scm, toml
|
2018-05-13 23:20:59 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "keyrings.alt";
|
2021-01-18 06:03:15 +01:00
|
|
|
version = "4.0.2";
|
2019-12-24 10:24:42 +01:00
|
|
|
disabled = isPy27;
|
2018-05-13 23:20:59 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-01-18 06:03:15 +01:00
|
|
|
sha256 = "cc475635099d6edd7e475c5a479e5b4da5e811a3af04495a1e9ada488d16fe25";
|
2018-05-13 23:20:59 +02:00
|
|
|
};
|
2018-05-27 18:51:54 +02:00
|
|
|
|
2018-08-30 21:09:05 +02:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace pytest.ini \
|
|
|
|
--replace "--flake8" ""
|
|
|
|
'';
|
|
|
|
|
2021-06-03 12:09:11 +02:00
|
|
|
nativeBuildInputs = [ setuptools-scm toml ];
|
2018-05-13 23:20:59 +02:00
|
|
|
propagatedBuildInputs = [ six ];
|
|
|
|
|
2021-01-24 01:29:22 +01:00
|
|
|
checkInputs = [ pytest keyring ] ++ lib.optional (pythonOlder "3.3") backports_unittest-mock;
|
2018-05-27 19:30:53 +02:00
|
|
|
|
2019-12-22 02:30:49 +01:00
|
|
|
# heavily relies on importing tests from keyring package
|
|
|
|
doCheck = false;
|
2018-05-27 19:30:53 +02:00
|
|
|
checkPhase = ''
|
|
|
|
py.test
|
|
|
|
'';
|
2018-05-13 23:20:59 +02:00
|
|
|
|
2019-12-22 02:30:49 +01:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"keyrings.alt"
|
|
|
|
];
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2018-05-13 23:20:59 +02:00
|
|
|
license = licenses.mit;
|
|
|
|
description = "Alternate keyring implementations";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://github.com/jaraco/keyrings.alt";
|
2018-05-13 23:20:59 +02:00
|
|
|
maintainers = with maintainers; [ nyarly ];
|
|
|
|
};
|
|
|
|
}
|