1{ lib
2, aiohttp
3, aioresponses
4, buildPythonPackage
5, fetchFromGitHub
6, expects
7, pytest-asyncio
8, pytest-mock
9, pytestCheckHook
10, yarl
11}:
12
13buildPythonPackage rec {
14 pname = "aiosyncthing";
15 version = "0.6.3";
16
17 src = fetchFromGitHub {
18 owner = "zhulik";
19 repo = pname;
20 rev = "v${version}";
21 sha256 = "sha256-vn8S2/kRW5C2Hbes9oLM4LGm1jWWK0zeLdujR14y6EI=";
22 };
23
24 propagatedBuildInputs = [
25 aiohttp
26 yarl
27 ];
28
29 checkInputs = [
30 aioresponses
31 expects
32 pytestCheckHook
33 pytest-asyncio
34 pytest-mock
35 ];
36
37 pytestFlagsArray = [
38 "--asyncio-mode=auto"
39 ];
40
41 postPatch = ''
42 substituteInPlace pyproject.toml \
43 --replace " --cov=aiosyncthing --cov-report=html" ""
44 '';
45
46 pythonImportsCheck = [ "aiosyncthing" ];
47
48 meta = with lib; {
49 description = "Python client for the Syncthing REST API";
50 homepage = "https://github.com/zhulik/aiosyncthing";
51 license = with licenses; [ mit ];
52 maintainers = with maintainers; [ fab ];
53 };
54}