Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, fetchPypi 3, buildPythonPackage 4, protobuf 5, types-protobuf 6, grpcio-tools 7, pytestCheckHook 8, pythonOlder 9}: 10 11buildPythonPackage rec { 12 pname = "mypy-protobuf"; 13 version = "3.4.0"; 14 format = "pyproject"; 15 16 disabled = pythonOlder "3.6"; 17 18 src = fetchPypi { 19 inherit pname version; 20 hash = "sha256-fXWgeWUbEFB2d2o1pUBeP6dzuKFnEY8bcS5EPppsGKI="; 21 }; 22 23 propagatedBuildInputs = [ 24 protobuf 25 types-protobuf 26 grpcio-tools 27 ]; 28 29 doCheck = false; # ModuleNotFoundError: No module named 'testproto' 30 31 nativeCheckInputs = [ 32 pytestCheckHook 33 ]; 34 35 pythonImportsCheck = [ 36 "mypy_protobuf" 37 ]; 38 39 meta = with lib; { 40 description = "Generate mypy stub files from protobuf specs"; 41 homepage = "https://github.com/dropbox/mypy-protobuf"; 42 license = licenses.asl20; 43 maintainers = with maintainers; [ lnl7 ]; 44 }; 45}