1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 pythonAtLeast, 7 construct, 8 typing-extensions, 9 arrow, 10 cloudpickle, 11 numpy, 12 pytestCheckHook, 13 ruamel-yaml, 14}: 15 16buildPythonPackage rec { 17 pname = "construct-typing"; 18 version = "0.6.2"; 19 pyproject = true; 20 21 src = fetchFromGitHub { 22 owner = "timrid"; 23 repo = "construct-typing"; 24 tag = "v${version}"; 25 hash = "sha256-zXpxu+VUcepEoAPLQnSlMCZkt8fDsMCLS0HBKhaYD20="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 pythonRelaxDeps = [ "construct" ]; 31 32 dependencies = [ 33 construct 34 typing-extensions 35 ]; 36 37 pythonImportsCheck = [ 38 "construct-stubs" 39 "construct_typed" 40 ]; 41 42 nativeCheckInputs = [ 43 arrow 44 cloudpickle 45 numpy 46 pytestCheckHook 47 ruamel-yaml 48 ]; 49 50 disabledTests = [ 51 # tests fail with construct>=2.10.70 52 "test_bitsinteger" 53 "test_bytesinteger" 54 ] 55 ++ lib.optionals (pythonAtLeast "3.13") [ 56 # https://github.com/timrid/construct-typing/issues/31 57 "test_tenum_docstring" 58 "test_tenum_flags_docstring" 59 ]; 60 61 meta = { 62 changelog = "https://github.com/timrid/construct-typing/releases/tag/v${version}"; 63 description = "Extension for the python package 'construct' that adds typing features"; 64 homepage = "https://github.com/timrid/construct-typing"; 65 license = lib.licenses.mit; 66 maintainers = with lib.maintainers; [ dotlambda ]; 67 }; 68}