2022-08-12 12:06:08 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
|
|
|
, auth0-python
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, poetry-core
|
|
|
|
, pyjwt
|
|
|
|
, pytest-aiohttp
|
|
|
|
, pytestCheckHook
|
|
|
|
, python-dateutil
|
|
|
|
, pythonOlder
|
2023-04-29 16:46:19 +00:00
|
|
|
, pythonRelaxDepsHook
|
2022-08-12 12:06:08 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aiobiketrax";
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "1.1.1";
|
2022-08-12 12:06:08 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.9";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "basilfx";
|
|
|
|
repo = pname;
|
2023-04-29 16:46:19 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-10-09 19:29:22 +00:00
|
|
|
hash = "sha256-YvPWvdA4BslkOLt3IkzSgUgex8h1CjCOVZC6oxNf3ZA=";
|
2022-08-12 12:06:08 +00:00
|
|
|
};
|
|
|
|
|
2023-04-29 16:46:19 +00:00
|
|
|
postPatch = ''
|
|
|
|
# https://github.com/basilfx/aiobiketrax/pull/63
|
|
|
|
substituteInPlace aiobiketrax/api.py \
|
|
|
|
--replace "auth0.v3" "auth0"
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonRelaxDeps = [
|
|
|
|
"auth0-python"
|
|
|
|
];
|
|
|
|
|
2022-08-12 12:06:08 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
poetry-core
|
2023-04-29 16:46:19 +00:00
|
|
|
pythonRelaxDepsHook
|
2022-08-12 12:06:08 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
auth0-python
|
|
|
|
python-dateutil
|
|
|
|
pyjwt
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-08-12 12:06:08 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"aiobiketrax"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Library for interacting with the PowUnity BikeTrax GPS tracker";
|
|
|
|
homepage = "https://github.com/basilfx/aiobiketrax";
|
2022-12-17 10:02:37 +00:00
|
|
|
changelog = "https://github.com/basilfx/aiobiketrax/blob/v${version}/CHANGELOG.md";
|
2022-08-12 12:06:08 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|