at 22.05-pre 1.2 kB view raw
1{ lib, buildPythonPackage, fetchPypi 2, coverage 3, mock 4, ply 5, pytest-runner 6, pytestCheckHook 7, six 8}: 9 10buildPythonPackage rec { 11 pname = "stone"; 12 version = "3.2.1"; 13 14 src = fetchPypi { 15 inherit pname version; 16 sha256 = "0xby5mpsms7b2rv8j6mvxzmzz5i9ii01brb9ylxz6kiv2i08piwv"; 17 }; 18 19 postPatch = '' 20 substituteInPlace setup.py \ 21 --replace "pytest-runner == 5.2.0" "pytest-runner" \ 22 --replace "pytest < 5" "pytest" 23 substituteInPlace test/requirements.txt \ 24 --replace "coverage==5.3" "coverage" 25 ''; 26 27 nativeBuildInputs = [ pytest-runner ]; 28 29 propagatedBuildInputs = [ ply six ]; 30 31 checkInputs = [ pytestCheckHook coverage mock ]; 32 33 # try to import from `test` directory, which is exported by the python interpreter 34 # and cannot be overriden without removing some py3 to py2 support 35 disabledTestPaths = [ 36 "test/test_tsd_types.py" 37 "test/test_js_client.py" 38 ]; 39 disabledTests = [ 40 "test_type_name_with_module" 41 ]; 42 43 pythonImportsCheck = [ "stone" ]; 44 45 meta = with lib; { 46 description = "Official Api Spec Language for Dropbox"; 47 homepage = "https://github.com/dropbox/stone"; 48 license = licenses.mit; 49 maintainers = with maintainers; [ jonringer ]; 50 }; 51}