1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 libev,
6 python,
7}:
8
9buildPythonPackage rec {
10 pname = "bjoern";
11 version = "3.2.1";
12 format = "setuptools";
13
14 # tests are not published to pypi anymore
15 src = fetchFromGitHub {
16 owner = "jonashaag";
17 repo = pname;
18 rev = version;
19 hash = "sha256-d7u/lEh2Zr5NYWYu4Zr7kgyeOIQuHQLYrZeiZMHbpio=";
20 fetchSubmodules = true; # fetch http-parser and statsd-c-client submodules
21 };
22
23 buildInputs = [ libev ];
24
25 checkPhase = ''
26 ${python.interpreter} tests/keep-alive-behaviour.py 2>/dev/null
27 ${python.interpreter} tests/test_wsgi_compliance.py
28 '';
29
30 meta = with lib; {
31 homepage = "https://github.com/jonashaag/bjoern";
32 description = "Screamingly fast Python 2/3 WSGI server written in C";
33 license = licenses.bsd2;
34 maintainers = with maintainers; [ cmcdragonkai ];
35 };
36}