From 424082d2fbbdde0dbe4a77b9863e6f2259cf87a7 Mon Sep 17 00:00:00 2001 From: Chris Ostrouchov Date: Mon, 29 Oct 2018 12:21:46 -0400 Subject: [PATCH] pythonPackages.grequests: refactor move to python-modules --- .../python-modules/grequests/default.nix | 29 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 23 +-------------- 2 files changed, 30 insertions(+), 22 deletions(-) create mode 100644 pkgs/development/python-modules/grequests/default.nix diff --git a/pkgs/development/python-modules/grequests/default.nix b/pkgs/development/python-modules/grequests/default.nix new file mode 100644 index 00000000000..c42ace2e695 --- /dev/null +++ b/pkgs/development/python-modules/grequests/default.nix @@ -0,0 +1,29 @@ +{ stdenv +, buildPythonPackage +, fetchPypi +, requests +, gevent +}: + +buildPythonPackage rec { + pname = "grequests"; + version = "0.3.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "0lafzax5igbh8y4x0krizr573wjsxz7bhvwygiah6qwrzv83kv5c"; + }; + + # No tests in archive + doCheck = false; + + propagatedBuildInputs = [ requests gevent ]; + + meta = with stdenv.lib; { + description = "Asynchronous HTTP requests"; + homepage = https://github.com/kennethreitz/grequests; + license = with licenses; [ bsd2 ]; + maintainers = with maintainers; [ matejc ]; + }; + +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index ad57900d31f..16a1a0f0a6f 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -4330,28 +4330,7 @@ in { rpdb = callPackage ../development/python-modules/rpdb { }; - grequests = buildPythonPackage rec { - pname = "grequests"; - version = "0.3.0"; - name = "${pname}-${version}"; - - src = fetchPypi { - inherit pname version; - sha256 = "0lafzax5igbh8y4x0krizr573wjsxz7bhvwygiah6qwrzv83kv5c"; - }; - - # No tests in archive - doCheck = false; - - propagatedBuildInputs = with self; [ requests gevent ]; - - meta = { - description = "Asynchronous HTTP requests"; - homepage = https://github.com/kennethreitz/grequests; - license = with licenses; [ bsd2 ]; - maintainers = with maintainers; [ matejc ]; - }; - }; + grequests = callPackage ../development/python-modules/grequests { }; first = callPackage ../development/python-modules/first {};