depot/third_party/nixpkgs/pkgs/development/python-modules/python-swiftclient/default.nix
Default email ca5ab3a501 Project import generated by Copybara.
GitOrigin-RevId: 4a01ca36d6bfc133bc617e661916a81327c9bbc8
2022-07-14 08:49:19 -04:00

60 lines
1 KiB
Nix

{ lib
, buildPythonApplication
, fetchPypi
, installShellFiles
, mock
, openstacksdk
, pbr
, python-keystoneclient
, pythonOlder
, stestr
}:
buildPythonApplication rec {
pname = "python-swiftclient";
version = "4.0.0";
format = "setuptools";
disabled = pythonOlder "3.6";
src = fetchPypi {
inherit pname version;
hash = "sha256-V7bx/yO0ZoQ4AqaBb0trvGiWtq0F1ld6/udiK+OilTg=";
};
nativeBuildInputs = [
installShellFiles
];
propagatedBuildInputs = [
pbr
python-keystoneclient
];
checkInputs = [
mock
openstacksdk
stestr
];
postInstall = ''
installShellCompletion --cmd swift \
--bash tools/swift.bash_completion
installManPage doc/manpages/*
'';
checkPhase = ''
stestr run
'';
pythonImportsCheck = [
"swiftclient"
];
meta = with lib; {
homepage = "https://github.com/openstack/python-swiftclient";
description = "Python bindings to the OpenStack Object Storage API";
license = licenses.asl20;
maintainers = teams.openstack.members;
};
}