summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Schütz <nix@dotlambda.de>2022-05-05 04:20:19 +0000
committerRobert Schütz <github@dotlambda.de>2022-05-07 20:23:24 -0700
commit453590adec901a3f088b7c5090e6858255cc26e5 (patch)
tree19a9d13ae7038233ec61399f5aea24d790be3dae
parent3aef23986c605532f6e971463514413d40ce2aea (diff)
downloadnixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar.gz
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar.bz2
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar.lz
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar.xz
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.tar.zst
nixpkgs-453590adec901a3f088b7c5090e6858255cc26e5.zip
elasticsearch-curator: 5.8.1 -> 5.8.4
-rw-r--r--pkgs/tools/admin/elasticsearch-curator/default.nix90
-rw-r--r--pkgs/top-level/all-packages.nix4
2 files changed, 47 insertions, 47 deletions
diff --git a/pkgs/tools/admin/elasticsearch-curator/default.nix b/pkgs/tools/admin/elasticsearch-curator/default.nix
index 60a7e0586f5..576df67ad5f 100644
--- a/pkgs/tools/admin/elasticsearch-curator/default.nix
+++ b/pkgs/tools/admin/elasticsearch-curator/default.nix
@@ -1,63 +1,68 @@
-{ lib, fetchFromGitHub, python }:
+{ lib, fetchFromGitHub, python3 }:
 
 let
-py = python.override {
-  packageOverrides = self: super: {
-    click = super.click.overridePythonAttrs (oldAttrs: rec {
-      version = "6.7";
-      src = oldAttrs.src.override {
-        inherit version;
-        sha256 = "f15516df478d5a56180fbf80e68f206010e6d160fc39fa508b65e035fd75130b";
-      };
-      doCheck = false;
-      postPatch = "";
-    });
+  python = python3.override {
+    packageOverrides = self: super: {
+      click = super.click.overridePythonAttrs (old: rec {
+        version = "7.1.2";
+        src = old.src.override {
+          inherit version;
+          sha256 = "d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a";
+        };
+      });
+      requests-aws4auth = super.requests-aws4auth.overridePythonAttrs (old: {
+        doCheck = false; # requires click>=8.0
+      });
+    };
   };
-};
-in
-
-with py.pkgs;
-buildPythonApplication rec {
+in python.pkgs.buildPythonApplication rec {
   pname   = "elasticsearch-curator";
-  version = "5.8.1";
+  version = "5.8.4";
+
+  format = "setuptools";
 
   src = fetchFromGitHub {
     owner = "elastic";
     repo = "curator";
     rev = "v${version}";
-    sha256 = "1shr9jslirjnbvma3p19djsnamxl7f3m9c8zrlclk57zv8rnwpkr";
+    hash = "sha256-wSfd52jebUkgF5xhjcoUjI7j46eJF33pVb4Wrybq44g=";
   };
 
-  # The test hangs so we disable it.
-  doCheck = false;
+  postPatch = ''
+    substituteInPlace setup.cfg \
+      --replace "urllib3==1.26.4" "urllib3"
+    substituteInPlace setup.py \
+      --replace "urllib3==1.26.4" "urllib3" \
+      --replace "pyyaml==5.4.1" "pyyaml"
+  '';
 
-  propagatedBuildInputs = [
-    click
-    certifi
-    requests-aws4auth
-    pyopenssl
-    voluptuous
-    pyyaml
+  propagatedBuildInputs = with python.pkgs; [
     elasticsearch
+    urllib3
+    requests
     boto3
+    requests-aws4auth
+    click
+    pyyaml
+    voluptuous
+    certifi
+    six
   ];
 
-  checkInputs = [
-    nosexcover
-    coverage
-    nose
+  checkInputs = with python.pkgs; [
     mock
-    funcsigs
+    pytestCheckHook
   ];
 
-  postPatch = ''
-    sed -i s/pyyaml==3.13/pyyaml/g setup.cfg setup.py
-    sed -i s/pyyaml==3.12/pyyaml/g setup.cfg setup.py
-    substituteInPlace setup.py \
-      --replace "urllib3>=1.24.2,<1.25" "urllib3"
-    substituteInPlace setup.cfg \
-      --replace "urllib3>=1.24.2,<1.25" "urllib3"
-  '';
+  disabledTestPaths = [
+    "test/integration" # requires running elasticsearch
+  ];
+
+  disabledTests = [
+    # access network
+    "test_api_key_not_set"
+    "test_api_key_set"
+  ];
 
   meta = with lib; {
     homepage = "https://github.com/elastic/curator";
@@ -76,8 +81,5 @@ buildPythonApplication rec {
       * Perform various actions on the items which remain in the actionable list.
     '';
     maintainers = with maintainers; [ basvandijk ];
-
-    # https://github.com/elastic/curator/pull/1280
-    #broken = versionAtLeast click.version "7.0";
   };
 }
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index be01edf485b..a401ddd5836 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -5585,9 +5585,7 @@ with pkgs;
     elasticsearch = elasticsearch7;
   };
 
-  elasticsearch-curator = callPackage ../tools/admin/elasticsearch-curator {
-    python = python3;
-  };
+  elasticsearch-curator = callPackage ../tools/admin/elasticsearch-curator { };
 
   embree = callPackage ../development/libraries/embree { };
   embree2 = callPackage ../development/libraries/embree/2.x.nix { };