2017-07-28 16:47:39 +02:00
|
|
|
{ lib
|
|
|
|
, python
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, backports_abc
|
|
|
|
, backports_ssl_match_hostname
|
|
|
|
, certifi
|
|
|
|
, singledispatch
|
2018-01-24 14:00:42 +01:00
|
|
|
, pythonOlder
|
2018-04-04 20:17:46 +02:00
|
|
|
, futures
|
2017-07-28 16:47:39 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "tornado";
|
2018-04-08 08:34:46 +02:00
|
|
|
version = "5.0.2";
|
2018-04-04 20:17:46 +02:00
|
|
|
|
2017-07-28 16:47:39 +02:00
|
|
|
|
2018-01-24 14:00:42 +01:00
|
|
|
propagatedBuildInputs = [ backports_abc certifi singledispatch ]
|
2018-04-04 20:17:46 +02:00
|
|
|
++ lib.optional (pythonOlder "3.5") backports_ssl_match_hostname
|
|
|
|
++ lib.optional (pythonOlder "3.2") futures;
|
2017-07-28 16:47:39 +02:00
|
|
|
|
|
|
|
# We specify the name of the test files to prevent
|
|
|
|
# https://github.com/NixOS/nixpkgs/issues/14634
|
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} -m unittest discover *_test.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-04-08 08:34:46 +02:00
|
|
|
sha256 = "1b83d5c10550f2653380b4c77331d6f8850f287c4f67d7ce1e1c639d9222fbc7";
|
2018-04-04 20:17:46 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "A web framework and asynchronous networking library";
|
|
|
|
homepage = http://www.tornadoweb.org/;
|
|
|
|
license = lib.licenses.asl20;
|
2017-07-28 16:47:39 +02:00
|
|
|
};
|
|
|
|
}
|