2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
2021-03-09 03:18:52 +00:00
|
|
|
, bleach
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, cmarkgfm
|
|
|
|
, docutils
|
2021-03-09 03:18:52 +00:00
|
|
|
, fetchPypi
|
|
|
|
, mock
|
2020-04-24 23:36:52 +00:00
|
|
|
, pygments
|
2021-03-09 03:18:52 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-01-07 04:07:37 +00:00
|
|
|
pname = "readme-renderer";
|
2022-04-27 09:35:20 +00:00
|
|
|
version = "35.0";
|
2022-01-07 04:07:37 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2022-01-07 04:07:37 +00:00
|
|
|
pname = "readme_renderer";
|
|
|
|
inherit version;
|
2022-04-27 09:35:20 +00:00
|
|
|
sha256 = "sha256-pyeZms/CIvwh2CoS7UjJV8SYl4XlhlgHxlpIfSFndJc=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2021-03-09 03:18:52 +00:00
|
|
|
bleach
|
|
|
|
cmarkgfm
|
|
|
|
docutils
|
|
|
|
pygments
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
mock
|
|
|
|
pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace "cmarkgfm>=0.5.0,<0.7.0" "cmarkgfm>=0.5.0,<1"
|
|
|
|
'';
|
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
disabledTests = [
|
|
|
|
# https://github.com/pypa/readme_renderer/issues/221
|
|
|
|
"test_GFM_"
|
2022-04-15 01:41:22 +00:00
|
|
|
# Relies on old distutils behaviour removed by setuptools (TypeError: dist must be a Distribution instance)
|
|
|
|
"test_valid_rst"
|
|
|
|
"test_invalid_rst"
|
|
|
|
"test_malicious_rst"
|
|
|
|
"test_invalid_missing"
|
|
|
|
"test_invalid_empty"
|
2022-02-10 20:34:41 +00:00
|
|
|
];
|
|
|
|
|
2022-01-07 04:07:37 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"readme_renderer"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python library for rendering readme descriptions";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/pypa/readme_renderer";
|
2021-03-09 03:18:52 +00:00
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|