1{
2 lib,
3 buildPythonPackage,
4 pythonOlder,
5 fetchFromGitHub,
6 pytestCheckHook,
7 setuptools,
8}:
9
10buildPythonPackage rec {
11 pname = "asn1";
12 version = "3.1.0";
13 pyproject = true;
14
15 disabled = pythonOlder "3.7";
16
17 src = fetchFromGitHub {
18 owner = "andrivet";
19 repo = "python-asn1";
20 tag = "v${version}";
21 hash = "sha256-yDX2TydMtqIE4A4QUmKPJKLM1UdXxp0qFBJx08Ri2YQ=";
22 };
23
24 build-system = [ setuptools ];
25
26 pythonRemoveDeps = [ "enum-compat" ];
27
28 nativeCheckInputs = [ pytestCheckHook ];
29
30 enabledTestPaths = [ "tests/test_asn1.py" ];
31
32 pythonImportsCheck = [ "asn1" ];
33
34 meta = with lib; {
35 description = "Python ASN.1 encoder and decoder";
36 homepage = "https://github.com/andrivet/python-asn1";
37 changelog = "https://github.com/andrivet/python-asn1/blob/${src.tag}/CHANGELOG.rst";
38 license = licenses.mit;
39 maintainers = with maintainers; [ fab ];
40 };
41}