1{ lib 2, bleach 3, buildPythonPackage 4, cmarkgfm 5, docutils 6, fetchPypi 7, mock 8, pygments 9, pytestCheckHook 10, pythonOlder 11}: 12 13buildPythonPackage rec { 14 pname = "readme-renderer"; 15 version = "37.3"; 16 format = "setuptools"; 17 18 disabled = pythonOlder "3.6"; 19 20 src = fetchPypi { 21 pname = "readme_renderer"; 22 inherit version; 23 sha256 = "sha256-zWUxht/HMFVlbwkPIn9csioEbX9xqEHfowX1XJpRMnM="; 24 }; 25 26 propagatedBuildInputs = [ 27 bleach 28 cmarkgfm 29 docutils 30 pygments 31 ]; 32 33 checkInputs = [ 34 mock 35 pytestCheckHook 36 ]; 37 38 postPatch = '' 39 substituteInPlace setup.py \ 40 --replace "cmarkgfm>=0.5.0,<0.7.0" "cmarkgfm>=0.5.0,<1" 41 ''; 42 43 disabledTests = [ 44 # https://github.com/pypa/readme_renderer/issues/221 45 "test_GFM_" 46 # Relies on old distutils behaviour removed by setuptools (TypeError: dist must be a Distribution instance) 47 "test_valid_rst" 48 "test_invalid_rst" 49 "test_malicious_rst" 50 "test_invalid_missing" 51 "test_invalid_empty" 52 ]; 53 54 pythonImportsCheck = [ 55 "readme_renderer" 56 ]; 57 58 meta = with lib; { 59 description = "Python library for rendering readme descriptions"; 60 homepage = "https://github.com/pypa/readme_renderer"; 61 license = with licenses; [ asl20 ]; 62 maintainers = with maintainers; [ fab ]; 63 }; 64}