a19cd4ffb1
This reverts commit65a333600d. This wasn't tested for correctness with something like fodwatch [0], and should not have been (self-)merged so quickly, especially without further review. It also resulted in the breakage of at least one package [1] (and that's the one we know of and was caught). A few packages that were updated in between this commit and this revert were not reverted back to using `rev`, but other than that, this is a 1:1 revert. [0]: https://codeberg.org/raphaelr/fodwatch [1]: https://github.com/NixOS/nixpkgs/pull/396904 /758551e458
61 lines
1.1 KiB
Nix
61 lines
1.1 KiB
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
pythonOlder,
|
|
fetchFromGitHub,
|
|
requests,
|
|
pyyaml,
|
|
setuptools,
|
|
pytestCheckHook,
|
|
pytest-asyncio,
|
|
uvloop,
|
|
hypercorn,
|
|
starlette,
|
|
pydantic_1,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "openapi3";
|
|
version = "1.8.2";
|
|
pyproject = true;
|
|
|
|
disabled = pythonOlder "3.8";
|
|
src = fetchFromGitHub {
|
|
owner = "Dorthu";
|
|
repo = "openapi3";
|
|
rev = version;
|
|
hash = "sha256-Crn+nRbptRycnWJzH8Tm/BBLcBSRCcNtLX8NoKnSDdA=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
|
|
propagatedBuildInputs = [
|
|
requests
|
|
pyyaml
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
pytest-asyncio
|
|
pydantic_1
|
|
uvloop
|
|
hypercorn
|
|
starlette
|
|
];
|
|
|
|
disabledTestPaths = [
|
|
# tests old fastapi behaviour
|
|
"tests/fastapi_test.py"
|
|
];
|
|
|
|
pythonImportsCheck = [ "openapi3" ];
|
|
|
|
meta = with lib; {
|
|
changelog = "https://github.com/Dorthu/openapi3/releases/tag/${version}";
|
|
description = "Python3 OpenAPI 3 Spec Parser";
|
|
homepage = "https://github.com/Dorthu/openapi3";
|
|
license = licenses.bsd3;
|
|
maintainers = with maintainers; [ techknowlogick ];
|
|
};
|
|
}
|