Skip to content

Commit

Permalink
python3Packages.ripe-atlas-sagan: add optional dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
fabaff committed Aug 23, 2022
1 parent 6f1e8c3 commit 19c8149
Showing 1 changed file with 21 additions and 8 deletions.
29 changes: 21 additions & 8 deletions pkgs/development/python-modules/ripe-atlas-sagan/default.nix
Original file line number Diff line number Diff line change
@@ -1,38 +1,51 @@
{ lib
, buildPythonPackage
, python-dateutil
, pytz
, cryptography
, pytest
, pytestCheckHook
, fetchFromGitHub
, pytestCheckHook
, python-dateutil
, pythonOlder
, pytz
, ujson
}:

buildPythonPackage rec {
pname = "ripe-atlas-sagan";
version = "1.3.1";
format = "setuptools";

disabled = pythonOlder "3.7";

src = fetchFromGitHub {
owner = "RIPE-NCC";
repo = pname;
rev = "v${version}";
sha256 = "sha256-xIBIKsQvDmVBa/C8/7Wr3WKeepHaGhoXlgatXSUtWLA=";
hash = "sha256-xIBIKsQvDmVBa/C8/7Wr3WKeepHaGhoXlgatXSUtWLA=";
};

propagatedBuildInputs = [
cryptography
python-dateutil
pytz
cryptography
];

passthru.optional-dependencies = {
fast = [
ujson
];
};

checkInputs = [
pytestCheckHook
];

pytestFlagsArray = [ "tests/*.py" ];
pytestFlagsArray = [
"tests/*.py"
];

disabledTests = [
"test_invalid_country_code" # This test fail for unknown reason, I suspect it to be flaky.
# This test fail for unknown reason, I suspect it to be flaky.
"test_invalid_country_code"
];

pythonImportsCheck = [
Expand Down

0 comments on commit 19c8149

Please sign in to comment.