diff --git a/pkgs/development/python-modules/asn1tools/default.nix b/pkgs/development/python-modules/asn1tools/default.nix index 89abcb152639..923736c0af28 100644 --- a/pkgs/development/python-modules/asn1tools/default.nix +++ b/pkgs/development/python-modules/asn1tools/default.nix @@ -1,29 +1,33 @@ { lib -, buildPythonPackage -, fetchFromGitHub , bitstruct +, buildPythonPackage , diskcache +, fetchFromGitHub , prompt-toolkit , pyparsing -, python -, pythonOlder , pytestCheckHook +, pythonOlder +, setuptools }: buildPythonPackage rec { pname = "asn1tools"; version = "0.166.0"; - format = "setuptools"; + pyproject = true; disabled = pythonOlder "3.8"; src = fetchFromGitHub { owner = "eerimoq"; repo = "asn1tools"; - rev = version; + rev = "refs/tags/${version}"; hash = "sha256-TWAOML6nsLX3TYqoQ9fcSjrUmC4byXOfczfkmSaSa0k="; }; + nativeBuildInputs = [ + setuptools + ]; + propagatedBuildInputs = [ bitstruct pyparsing @@ -42,14 +46,20 @@ buildPythonPackage rec { pytestCheckHook ] ++ lib.flatten (builtins.attrValues passthru.optional-depdendencies); - pythonImportsCheck = [ "asn1tools" ]; + disabledTests = [ + # assert exact error message of pyparsing which changed and no longer matches + # https://github.com/eerimoq/asn1tools/issues/167 + "test_parse_error" + ]; + meta = with lib; { description = "ASN.1 parsing, encoding and decoding"; homepage = "https://github.com/eerimoq/asn1tools"; + changelog = "https://github.com/eerimoq/asn1tools/releases/tag/${version}"; license = licenses.mit; maintainers = with maintainers; [ ]; };