summary refs log tree commit diff
path: root/pkgs/development/tools/aws-sam-cli/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/aws-sam-cli/default.nix')
-rw-r--r--pkgs/development/tools/aws-sam-cli/default.nix39
1 files changed, 9 insertions, 30 deletions
diff --git a/pkgs/development/tools/aws-sam-cli/default.nix b/pkgs/development/tools/aws-sam-cli/default.nix
index 39a68622056..f5a5d0e65d6 100644
--- a/pkgs/development/tools/aws-sam-cli/default.nix
+++ b/pkgs/development/tools/aws-sam-cli/default.nix
@@ -1,5 +1,6 @@
 { lib
 , python
+, enableTelemetry ? false
 }:
 
 let
@@ -13,17 +14,6 @@ let
         };
       });
 
-      jsonschema = super.jsonschema.overridePythonAttrs (oldAttrs: rec {
-        version = "3.1.1";
-        src = oldAttrs.src.override {
-          inherit version;
-          sha256 = "0grwi50v3vahvcijlw6g6q55yc5jyj0p1cmiq3rkycxnfr16i81g";
-        };
-        nativeBuildInputs = [ super.setuptools_scm ];
-        propagatedBuildInputs = with super; oldAttrs.propagatedBuildInputs ++ [ pyrsistent attrs importlib-metadata ];
-        doCheck = false;
-      });
-
       cookiecutter = super.cookiecutter.overridePythonAttrs (oldAttrs: rec {
         version = "1.6.0";
         src = oldAttrs.src.override {
@@ -31,22 +21,6 @@ let
           sha256 = "0glsvaz8igi2wy1hsnhm9fkn6560vdvdixzvkq6dn20z3hpaa5hk";
         };
       });
-
-      boto3 = super.boto3.overridePythonAttrs (oldAttrs: rec {
-        version = "1.10.50";
-        src = oldAttrs.src.override {
-          inherit version;
-          sha256 = "199nr61ivm4bychn3rxyzzyca5f8wlwags3s43rdv9yn048xa02w";
-        };
-      });
-
-      botocore = super.botocore.overridePythonAttrs (oldAttrs: rec {
-        version = "1.13.50";
-        src = oldAttrs.src.override {
-          inherit version;
-          sha256 = "1m3lbi13d9gcp6wfhv0pkwg8akasxlhv49y34ybj74ppgximqnkn";
-        };
-      });
     };
   };
 
@@ -56,11 +30,11 @@ with py.pkgs;
 
 buildPythonApplication rec {
   pname = "aws-sam-cli";
-  version = "0.40.0";
+  version = "0.41.0";
 
   src = fetchPypi {
     inherit pname version;
-    sha256 = "1vlg5fdkq5xr4v3a86gyxbbrx4rzdspbv62ki7q8yq8xdja1qz05";
+    sha256 = "1v21bhylys1mvrsvxqw88cvghl6s46hdni52xn661bbn4byrrv3b";
   };
 
   # Tests are not included in the PyPI package
@@ -83,6 +57,11 @@ buildPythonApplication rec {
     tomlkit
   ];
 
+  postFixup = if enableTelemetry then "echo aws-sam-cli TELEMETRY IS ENABLED" else ''
+    # Disable telemetry: https://github.com/awslabs/aws-sam-cli/issues/1272
+    wrapProgram $out/bin/sam --set  SAM_CLI_TELEMETRY 0
+  '';
+
   # fix over-restrictive version bounds
   postPatch = ''
     substituteInPlace requirements/base.txt \
@@ -97,6 +76,6 @@ buildPythonApplication rec {
     homepage = https://github.com/awslabs/aws-sam-cli;
     description = "CLI tool for local development and testing of Serverless applications";
     license = licenses.asl20;
-    maintainers = with maintainers; [ andreabedini dhkl ];
+    maintainers = with maintainers; [ andreabedini lo1tuma ];
   };
 }