1{ lib 2, buildPythonPackage 3, pythonOlder 4, fetchPypi 5, importlib-resources 6, pydsdl 7, pyyaml 8}: 9 10 buildPythonPackage rec { 11 pname = "nunavut"; 12 version = "2.3.1"; 13 format = "setuptools"; 14 15 disabled = pythonOlder "3.7"; 16 17 src = fetchPypi { 18 inherit pname version; 19 hash = "sha256-23C3biUUs10Po5qzn3EFaq4+HeWCXIC6WzxOKy59VgM="; 20 }; 21 22 postPatch = '' 23 substituteInPlace setup.cfg \ 24 --replace "pydsdl ~= 1.16" "pydsdl" 25 ''; 26 27 propagatedBuildInputs = [ 28 importlib-resources 29 pydsdl 30 pyyaml 31 ]; 32 33 # allow for writable directory for darwin 34 preBuild = '' 35 export HOME=$TMPDIR 36 ''; 37 38 # No tests in pypy package and no git tags yet for release versions, see 39 # https://github.com/UAVCAN/nunavut/issues/182 40 doCheck = false; 41 42 pythonImportsCheck = [ 43 "nunavut" 44 ]; 45 46 meta = with lib; { 47 description = "A UAVCAN DSDL template engine"; 48 longDescription = '' 49 It exposes a pydsdl abstract syntax tree to Jinja2 templates allowing 50 authors to generate code, schemas, metadata, documentation, etc. 51 ''; 52 homepage = "https://nunavut.readthedocs.io/"; 53 changelog = "https://github.com/OpenCyphal/nunavut/releases/tag/${version}"; 54 maintainers = with maintainers; [ wucke13 ]; 55 license = with licenses; [ bsd3 mit ]; 56 }; 57}