2021-03-20 19:46:47 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, inflection
|
|
|
|
, ruamel_yaml
|
2021-06-03 11:09:11 +01:00
|
|
|
, setuptools-scm
|
2021-03-20 19:46:47 +00:00
|
|
|
, six
|
|
|
|
, coreapi
|
|
|
|
, djangorestframework
|
|
|
|
, pytestCheckHook
|
|
|
|
, pytest-django
|
|
|
|
, datadiff
|
2019-08-12 20:53:25 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "drf-yasg";
|
2020-10-28 08:35:44 +00:00
|
|
|
version = "1.20.0";
|
2019-08-12 20:53:25 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-10-28 08:35:44 +00:00
|
|
|
sha256 = "d50f197c7f02545d0b736df88c6d5cf874f8fea2507ad85ad7de6ae5bf2d9e5a";
|
2019-08-12 20:53:25 +01:00
|
|
|
};
|
|
|
|
|
2021-03-20 19:14:42 +00:00
|
|
|
postPatch = ''
|
|
|
|
# https://github.com/axnsan12/drf-yasg/pull/710
|
|
|
|
substituteInPlace requirements/base.txt --replace packaging ""
|
|
|
|
'';
|
|
|
|
|
2019-08-12 20:53:25 +01:00
|
|
|
nativeBuildInputs = [
|
2021-06-03 11:09:11 +01:00
|
|
|
setuptools-scm
|
2019-08-12 20:53:25 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
six
|
|
|
|
inflection
|
|
|
|
ruamel_yaml
|
|
|
|
coreapi
|
|
|
|
djangorestframework
|
|
|
|
];
|
|
|
|
|
2021-03-20 19:46:47 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
pytest-django
|
|
|
|
datadiff
|
|
|
|
];
|
|
|
|
|
|
|
|
# ImportError: No module named 'testproj.settings'
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "drf_yasg" ];
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-08-12 20:53:25 +01:00
|
|
|
description = "Generation of Swagger/OpenAPI schemas for Django REST Framework";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/axnsan12/drf-yasg";
|
2021-05-05 19:31:54 +01:00
|
|
|
maintainers = with maintainers; [ ];
|
2019-08-12 20:53:25 +01:00
|
|
|
license = licenses.bsd3;
|
|
|
|
};
|
|
|
|
}
|