1{
2 lib,
3 bitstruct,
4 buildPythonPackage,
5 fetchFromGitHub,
6 jinja2,
7 jsonschema,
8 lark,
9 pytestCheckHook,
10 pythonOlder,
11 setuptools,
12}:
13
14buildPythonPackage rec {
15 pname = "ldfparser";
16 version = "0.26.0";
17 pyproject = true;
18
19 disabled = pythonOlder "3.7";
20
21 src = fetchFromGitHub {
22 owner = "c4deszes";
23 repo = "ldfparser";
24 tag = "v${version}";
25 hash = "sha256-SVl/O0/2k1Y4lta+3BFkddyBZfYO2vqh4Xx1ZXNwXN4=";
26 };
27
28 build-system = [ setuptools ];
29
30 dependencies = [
31 bitstruct
32 jinja2
33 lark
34 ];
35
36 nativeCheckInputs = [
37 jsonschema
38 pytestCheckHook
39 ];
40
41 pythonImportsCheck = [ "ldfparser" ];
42
43 disabledTestPaths = [
44 # We don't care about benchmarks
45 "tests/test_performance.py"
46 ];
47
48 meta = with lib; {
49 description = "LIN Description File parser written in Python";
50 homepage = "https://github.com/c4deszes/ldfparser";
51 changelog = "https://github.com/c4deszes/ldfparser/blob/${version}/CHANGELOG.md";
52 license = licenses.mit;
53 maintainers = with maintainers; [ fab ];
54 mainProgram = "ldfparser";
55 };
56}