2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
attrs,
|
|
|
|
botocore,
|
|
|
|
buildPythonPackage,
|
|
|
|
click,
|
|
|
|
fetchFromGitHub,
|
|
|
|
hypothesis,
|
|
|
|
inquirer,
|
|
|
|
jmespath,
|
|
|
|
mock,
|
|
|
|
mypy-extensions,
|
|
|
|
pip,
|
|
|
|
pytest7CheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
pyyaml,
|
|
|
|
requests,
|
|
|
|
setuptools,
|
|
|
|
six,
|
|
|
|
typing-extensions,
|
|
|
|
watchdog,
|
|
|
|
websocket-client,
|
|
|
|
wheel,
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "chalice";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "1.28.0";
|
2023-01-20 10:41:00 +00:00
|
|
|
format = "setuptools";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "aws";
|
|
|
|
repo = pname;
|
2023-01-20 10:41:00 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2023-05-24 13:37:59 +00:00
|
|
|
hash = "sha256-m3pSD4fahBW6Yt/w07Co4fTZD7k6as5cPwoK5QSry6M=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-08-21 13:32:41 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
2023-01-20 10:41:00 +00:00
|
|
|
--replace "inquirer>=2.7.0,<3.0.0" "inquirer" \
|
2023-05-24 13:37:59 +00:00
|
|
|
--replace "pip>=9,<23.1" "pip" \
|
2022-08-21 13:32:41 +00:00
|
|
|
'';
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
attrs
|
|
|
|
botocore
|
|
|
|
click
|
2021-05-20 23:08:51 +00:00
|
|
|
inquirer
|
2020-04-24 23:36:52 +00:00
|
|
|
jmespath
|
2020-09-25 04:45:31 +00:00
|
|
|
mypy-extensions
|
2020-04-24 23:36:52 +00:00
|
|
|
pip
|
2020-09-25 04:45:31 +00:00
|
|
|
pyyaml
|
2020-04-24 23:36:52 +00:00
|
|
|
setuptools
|
|
|
|
six
|
2023-05-24 13:37:59 +00:00
|
|
|
typing-extensions
|
2020-04-24 23:36:52 +00:00
|
|
|
wheel
|
2021-08-22 07:53:02 +00:00
|
|
|
watchdog
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-08-22 07:53:02 +00:00
|
|
|
hypothesis
|
|
|
|
mock
|
2024-04-21 15:54:59 +00:00
|
|
|
pytest7CheckHook
|
2021-08-22 07:53:02 +00:00
|
|
|
requests
|
|
|
|
websocket-client
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# Don't check the templates and the sample app
|
|
|
|
"chalice/templates"
|
|
|
|
"docs/source/samples/todo-app/code/tests/test_db.py"
|
|
|
|
# Requires credentials
|
|
|
|
"tests/aws/test_features.py"
|
|
|
|
# Requires network access
|
|
|
|
"tests/aws/test_websockets.py"
|
|
|
|
"tests/integration/test_package.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Requires network access
|
|
|
|
"test_update_domain_name_failed"
|
|
|
|
"test_can_reload_server"
|
|
|
|
# Content for the tests is missing
|
|
|
|
"test_can_import_env_vars"
|
|
|
|
"test_stack_trace_printed_on_error"
|
|
|
|
# Don't build
|
|
|
|
"test_can_generate_pipeline_for_all"
|
|
|
|
"test_build_wheel"
|
2021-12-26 17:43:05 +00:00
|
|
|
# https://github.com/aws/chalice/issues/1850
|
|
|
|
"test_resolve_endpoint"
|
|
|
|
"test_endpoint_from_arn"
|
2023-05-24 13:37:59 +00:00
|
|
|
# Tests require dist
|
|
|
|
"test_setup_tar_gz_hyphens_in_name"
|
|
|
|
"test_both_tar_gz"
|
|
|
|
"test_both_tar_bz2"
|
2021-08-22 07:53:02 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "chalice" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python Serverless Microframework for AWS";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "chalice";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/aws/chalice";
|
2023-05-24 13:37:59 +00:00
|
|
|
changelog = "https://github.com/aws/chalice/blob/${version}/CHANGELOG.rst";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.asl20;
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|