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