1{ lib
2, aiocontextvars
3 #, aiocarbon
4, aiohttp
5 #, aiohttp-asgi
6, async-timeout
7, buildPythonPackage
8, colorlog
9, croniter
10, fastapi
11, fetchPypi
12, logging-journald
13, poetry-core
14, pytestCheckHook
15, pythonOlder
16, raven
17 #, raven-aiohttp
18, setproctitle
19, setuptools
20, uvloop
21}:
22
23buildPythonPackage rec {
24 pname = "aiomisc";
25 version = "17.3.25";
26 format = "pyproject";
27
28 disabled = pythonOlder "3.7";
29
30 src = fetchPypi {
31 inherit pname version;
32 hash = "sha256-EPEfBK/1nbwcajqyv5lFX+02WMvbyFnij2w5J91+UK8=";
33 };
34
35 nativeBuildInputs = [
36 poetry-core
37 ];
38
39 propagatedBuildInputs = [
40 colorlog
41 logging-journald
42 setuptools
43 ];
44
45 nativeCheckInputs = [
46 aiocontextvars
47 async-timeout
48 fastapi
49 pytestCheckHook
50 raven
51 setproctitle
52 ] ++ passthru.optional-dependencies.aiohttp
53 ++ passthru.optional-dependencies.cron
54 ++ passthru.optional-dependencies.uvloop;
55
56 passthru.optional-dependencies = {
57 aiohttp = [
58 aiohttp
59 ];
60 #asgi = [
61 # aiohttp-asgi
62 #];
63 cron = [
64 croniter
65 ];
66 #carbon = [
67 # aiocarbon
68 #];
69 #raven = [
70 # raven-aiohttp
71 #];
72 uvloop = [
73 uvloop
74 ];
75 };
76
77 pythonImportsCheck = [
78 "aiomisc"
79 ];
80
81 # Upstream stopped tagging with 16.2
82 doCheck = false;
83
84 # disabledTestPaths = [
85 # # Dependencies are not available at the moment
86 # "tests/test_entrypoint.py"
87 # "tests/test_raven_service.py"
88 # ];
89
90 meta = with lib; {
91 description = "Miscellaneous utils for asyncio";
92 homepage = "https://github.com/aiokitchen/aiomisc";
93 changelog = "https://github.com/aiokitchen/aiomisc/blob/master/CHANGELOG.md";
94 license = licenses.asl20;
95 maintainers = with maintainers; [ fab ];
96 };
97}