1{ lib 2, argparse-addons 3, bitstruct 4, buildPythonPackage 5, can 6, crccheck 7, diskcache 8, fetchPypi 9, matplotlib 10, parameterized 11, pytestCheckHook 12, pythonOlder 13, setuptools 14, setuptools-scm 15, textparser 16}: 17 18buildPythonPackage rec { 19 pname = "cantools"; 20 version = "39.4.0"; 21 pyproject = true; 22 23 disabled = pythonOlder "3.8"; 24 25 src = fetchPypi { 26 inherit pname version; 27 hash = "sha256-44zzlyOIQ2qo4Zq5hb+xnCy0ANm6iCpcBww0l2KWdMs="; 28 }; 29 30 postPatch = '' 31 substituteInPlace pyproject.toml \ 32 --replace "setuptools_scm>=8" "setuptools_scm" 33 ''; 34 35 nativeBuildInputs = [ 36 setuptools 37 setuptools-scm 38 ]; 39 40 propagatedBuildInputs = [ 41 argparse-addons 42 bitstruct 43 can 44 crccheck 45 diskcache 46 matplotlib 47 textparser 48 ]; 49 50 nativeCheckInputs = [ 51 parameterized 52 pytestCheckHook 53 ]; 54 55 pythonImportsCheck = [ 56 "cantools" 57 ]; 58 59 meta = with lib; { 60 description = "Tools to work with CAN bus"; 61 homepage = "https://github.com/cantools/cantools"; 62 changelog = "https://github.com/cantools/cantools/releases/tag/${version}"; 63 license = licenses.mit; 64 maintainers = with maintainers; [ gray-heron ]; 65 }; 66}