depot/third_party/nixpkgs/pkgs/development/python-modules/flask-marshmallow/default.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

58 lines
1.2 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
flask,
flask-sqlalchemy,
flit-core,
marshmallow,
marshmallow-sqlalchemy,
pytestCheckHook,
pythonOlder,
}:
buildPythonPackage rec {
pname = "flask-marshmallow";
version = "1.2.1";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "marshmallow-code";
repo = "flask-marshmallow";
rev = "refs/tags/${version}";
hash = "sha256-GQLkt/CJf/QI8emvlW8xSRziGnncwfMSxBccW0Bb8I0=";
};
nativeBuildInputs = [ flit-core ];
propagatedBuildInputs = [
flask
marshmallow
];
passthru.optional-dependencies = {
sqlalchemy = [
flask-sqlalchemy
marshmallow-sqlalchemy
];
};
nativeCheckInputs = [ pytestCheckHook ] ++ passthru.optional-dependencies.sqlalchemy;
pythonImportsCheck = [ "flask_marshmallow" ];
pytestFlagsArray = [
"-W"
"ignore::DeprecationWarning"
];
meta = {
description = "Flask + marshmallow for beautiful APIs";
homepage = "https://github.com/marshmallow-code/flask-marshmallow";
changelog = "https://github.com/marshmallow-code/flask-marshmallow/releases/tag/${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ nickcao ];
};
}