about summary refs log tree commit diff
path: root/pkgs/development/python-modules/cornice/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/cornice/default.nix')
-rw-r--r--pkgs/development/python-modules/cornice/default.nix45
1 files changed, 31 insertions, 14 deletions
diff --git a/pkgs/development/python-modules/cornice/default.nix b/pkgs/development/python-modules/cornice/default.nix
index ff6ede5dcf206..639ddcacd4876 100644
--- a/pkgs/development/python-modules/cornice/default.nix
+++ b/pkgs/development/python-modules/cornice/default.nix
@@ -1,26 +1,43 @@
-{ lib
-, buildPythonPackage
-, fetchPypi
-, pyramid
-, simplejson
-, six
-, venusian
+{
+  lib,
+  buildPythonPackage,
+  fetchFromGitHub,
+  setuptools,
+  setuptools-scm,
+  pyramid,
+  pytestCheckHook,
+  pytest-cache,
+  webtest,
+  marshmallow,
+  colander,
 }:
 
 buildPythonPackage rec {
   pname = "cornice";
   version = "6.1.0";
-  format = "setuptools";
+  pyproject = true;
 
-  src = fetchPypi {
-    inherit pname version;
-    sha256 = "sha256-v9G2wqmRp8yxsggrbenjuPGYtqK0oHqwgA4F3wWkU2E=";
+  src = fetchFromGitHub {
+    owner = "Cornices";
+    repo = "cornice";
+    rev = version;
+    hash = "sha256-jAf8unDPpr/ZAWkb9LhOW4URjwcRnaYVUKmfnYBStTg=";
   };
 
-  propagatedBuildInputs = [ pyramid simplejson six venusian ];
+  build-system = [
+    setuptools
+    setuptools-scm
+  ];
 
-  # tests not packaged with pypi release
-  doCheck = false;
+  dependencies = [ pyramid ];
+
+  nativeCheckInputs = [
+    pytestCheckHook
+    pytest-cache
+    webtest
+    marshmallow
+    colander
+  ];
   pythonImportsCheck = [ "cornice" ];
 
   meta = with lib; {