2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
pythonOlder,
|
2024-02-29 20:09:43 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# build-system
|
|
|
|
flit-core,
|
2024-02-29 20:09:43 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# dependencies
|
|
|
|
blinker,
|
|
|
|
click,
|
|
|
|
importlib-metadata,
|
|
|
|
itsdangerous,
|
|
|
|
jinja2,
|
|
|
|
werkzeug,
|
2024-02-29 20:09:43 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# optional-dependencies
|
|
|
|
asgiref,
|
|
|
|
python-dotenv,
|
2024-02-29 20:09:43 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# tests
|
|
|
|
greenlet,
|
|
|
|
pytestCheckHook,
|
2024-02-29 20:09:43 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# reverse dependencies
|
|
|
|
flask-limiter,
|
|
|
|
flask-restful,
|
|
|
|
flask-restx,
|
|
|
|
moto,
|
2021-06-28 23:13:55 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-08-12 12:06:08 +00:00
|
|
|
pname = "flask";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "3.0.3";
|
2023-11-16 04:20:00 +00:00
|
|
|
format = "pyproject";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2023-11-16 04:20:00 +00:00
|
|
|
inherit pname version;
|
2024-05-15 15:35:15 +00:00
|
|
|
hash = "sha256-zrJ7CvOCPqJzeSik2Z0SWgYXW4USxEXL2anOIA73aEI=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeBuildInputs = [ flit-core ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
2021-06-28 23:13:55 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
click
|
2023-11-16 04:20:00 +00:00
|
|
|
blinker
|
2021-06-28 23:13:55 +00:00
|
|
|
itsdangerous
|
|
|
|
jinja2
|
|
|
|
werkzeug
|
2024-06-05 15:53:02 +00:00
|
|
|
] ++ lib.optionals (pythonOlder "3.10") [ importlib-metadata ];
|
2024-02-29 20:09:43 +00:00
|
|
|
|
|
|
|
passthru.optional-dependencies = {
|
2024-06-05 15:53:02 +00:00
|
|
|
async = [ asgiref ];
|
|
|
|
dotenv = [ python-dotenv ];
|
2024-02-29 20:09:43 +00:00
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs =
|
|
|
|
[ pytestCheckHook ]
|
|
|
|
++ lib.optionals (pythonOlder "3.11") [ greenlet ]
|
|
|
|
++ lib.flatten (builtins.attrValues passthru.optional-dependencies);
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
passthru.tests = {
|
2024-06-05 15:53:02 +00:00
|
|
|
inherit
|
|
|
|
flask-limiter
|
|
|
|
flask-restful
|
|
|
|
flask-restx
|
|
|
|
moto
|
|
|
|
;
|
2022-09-09 14:08:57 +00:00
|
|
|
};
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2024-06-05 15:53:02 +00:00
|
|
|
changelog = "https://flask.palletsprojects.com/en/${versions.majorMinor version}.x/changes/#version-${
|
|
|
|
replaceStrings [ "." ] [ "-" ] version
|
|
|
|
}";
|
2022-03-30 09:31:56 +00:00
|
|
|
homepage = "https://flask.palletsprojects.com/";
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Python micro framework for building web applications";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "flask";
|
2021-06-28 23:13:55 +00:00
|
|
|
longDescription = ''
|
|
|
|
Flask is a lightweight WSGI web application framework. It is
|
|
|
|
designed to make getting started quick and easy, with the ability
|
|
|
|
to scale up to complex applications. It began as a simple wrapper
|
|
|
|
around Werkzeug and Jinja and has become one of the most popular
|
|
|
|
Python web application frameworks.
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd3;
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = with maintainers; [ nickcao ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|