2021-12-06 16:07:01 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, lxml
|
|
|
|
, pytest-aiohttp
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2022-01-19 23:45:15 +00:00
|
|
|
, setuptools-scm
|
2021-12-06 16:07:01 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "afsapi";
|
2022-08-12 12:06:08 +00:00
|
|
|
version = "0.2.7";
|
2021-12-06 16:07:01 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2022-01-19 23:45:15 +00:00
|
|
|
owner = "wlcrs";
|
2021-12-06 16:07:01 +00:00
|
|
|
repo = "python-afsapi";
|
2022-05-18 14:49:53 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2022-08-12 12:06:08 +00:00
|
|
|
hash = "sha256-TTZk/8mfG5lBr8SyMbqSaYDskWKnUlMkAUp94DXPCKo=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2022-01-19 23:45:15 +00:00
|
|
|
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools-scm
|
|
|
|
];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
lxml
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest-aiohttp
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pytestFlagsArray = [
|
|
|
|
"async_tests.py"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"afsapi"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python implementation of the Frontier Silicon API";
|
2022-01-19 23:45:15 +00:00
|
|
|
homepage = "https://github.com/wlcrs/python-afsapi";
|
2021-12-06 16:07:01 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|