2024-01-02 11:29:13 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2024-01-13 08:15:51 +00:00
|
|
|
, pythonOlder
|
|
|
|
, pythonRelaxDepsHook
|
2024-01-02 11:29:13 +00:00
|
|
|
|
|
|
|
# build-system
|
|
|
|
, hatchling
|
|
|
|
|
|
|
|
# dependencies
|
|
|
|
, django
|
|
|
|
, pydantic
|
|
|
|
, typing-extensions
|
|
|
|
|
|
|
|
# tests
|
|
|
|
, django-stubs
|
|
|
|
, pytestCheckHook
|
|
|
|
, pytest-asyncio
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pyngo";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "2.0.0";
|
2024-01-02 11:29:13 +00:00
|
|
|
pyproject = true;
|
|
|
|
|
2024-01-13 08:15:51 +00:00
|
|
|
disabled = pythonOlder "3.10";
|
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "yezz123";
|
|
|
|
repo = "pyngo";
|
|
|
|
rev = "refs/tags/${version}";
|
2024-01-13 08:15:51 +00:00
|
|
|
hash = "sha256-jHPZjS/J1VLpsLN2wg5UJCgavoSEs4Uogo4GI6bZMuY=";
|
2024-01-02 11:29:13 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
hatchling
|
2024-01-13 08:15:51 +00:00
|
|
|
pythonRelaxDepsHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonRelaxDeps = [
|
|
|
|
"pydantic"
|
2024-01-02 11:29:13 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
django
|
|
|
|
pydantic
|
|
|
|
typing-extensions
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "pyngo" ];
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
django-stubs
|
|
|
|
pytestCheckHook
|
|
|
|
pytest-asyncio
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
changelog = "https://github.com/yezz123/pyngo/releases/tag/${version}";
|
|
|
|
description = "Pydantic model support for Django & Django-Rest-Framework";
|
|
|
|
homepage = "https://github.com/yezz123/pyngo";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ hexa ];
|
|
|
|
};
|
|
|
|
}
|