about summary refs log tree commit diff
diff options
context:
space:
mode:
authorFrederik Rietdijk <fridh@fridh.nl>2016-12-01 12:32:39 +0100
committerFrederik Rietdijk <fridh@fridh.nl>2016-12-01 21:07:33 +0100
commit49a313c395006ede63850f42c3887d2e1446b43a (patch)
tree366e5873ac1de0d31ec7f1775ecfff67f244a173
parentd69a25dfdedef3a8001f286bd7b0cecebe7c68e6 (diff)
downloadnixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar.gz
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar.bz2
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar.lz
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar.xz
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.tar.zst
nixlib-49a313c395006ede63850f42c3887d2e1446b43a.zip
pythonpackages.lti: rename to PyLTI and remove overriding
- rename to PyLTI to follow upstream
- remove overriding because it is not necessary; newer mock can be used,
and modules python packages should be fixed to not propagate pytest (see
separate commit).

cc maintainer @layus
-rw-r--r--pkgs/servers/inginious/default.nix2
-rw-r--r--pkgs/top-level/python-packages.nix21
2 files changed, 9 insertions, 14 deletions
diff --git a/pkgs/servers/inginious/default.nix b/pkgs/servers/inginious/default.nix
index c85d96100c3c..113b297787b3 100644
--- a/pkgs/servers/inginious/default.nix
+++ b/pkgs/servers/inginious/default.nix
@@ -38,7 +38,7 @@ in pythonPackages.buildPythonApplication rec {
 
   propagatedBuildInputs = with pythonPackages; [
     requests2
-    cgroup-utils docker_1_7_2 docutils lti mock pygments
+    cgroup-utils docker_1_7_2 docutils PyLTI mock pygments
     pymongo pyyaml rpyc sh simpleldap sphinx_rtd_theme tidylib
     websocket_client watchdog webpy-custom flup
   ];
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 9044288bad64..201c34f3a9a6 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -7981,26 +7981,21 @@ in {
     };
   };
 
-  lti = let
-    self' = (self.override {self = self';}) // {pytest = self.pytest_27;};
-    mock_1_0_1 = self'.mock.overrideDerivation (_: rec {
-      name = "mock-1.0.1";
-      propagatedBuildInputs = null;
-      src = pkgs.fetchurl {
-        url = "http://pypi.python.org/packages/source/m/mock/${name}.tar.gz";
-        sha256 = "0kzlsbki6q0awf89rc287f3aj8x431lrajf160a70z0ikhnxsfdq";
-      };
-    });
-  in buildPythonPackage rec {
+  PyLTI = buildPythonPackage rec {
     version = "0.4.1";
     name = "PyLTI-${version}";
 
     disabled = !isPy27;
 
+    # There is no need to fix mock. https://github.com/mitodl/pylti/pull/48
+    postPatch = ''
+      substituteInPlace setup.py --replace "mock==1.0.1" "mock"
+    '';
+
     propagatedBuildInputs = with self; [ httplib2 oauth oauth2 semantic-version ];
-    buildInputs = with self'; [
+    buildInputs = with self; [
       flask httpretty oauthlib pyflakes pytest pytestcache pytestcov covCore
-      pytestflakes pytestpep8 sphinx mock_1_0_1
+      pytestflakes pytestpep8 sphinx mock
     ];
 
     src = pkgs.fetchurl {