Unverified Commit 52b77727 authored by Fabian Affolter's avatar Fabian Affolter Committed by GitHub
Browse files

python313Packages.*-secrets: migrate to writableTmpDirAsHomeHook (#433234)

parents 6b78f91c d3f78bf0
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -13,6 +13,7 @@
  responses,
  setuptools,
  unidiff,
  writableTmpDirAsHomeHook,
}:

buildPythonPackage rec {
@@ -47,13 +48,10 @@ buildPythonPackage rec {
    pkgs.gitMinimal
    pytestCheckHook
    responses
    writableTmpDirAsHomeHook
  ]
  ++ lib.flatten (builtins.attrValues optional-dependencies);

  preCheck = ''
    export HOME=$(mktemp -d);
  '';

  disabledTests = [
    # Tests are failing for various reasons (missing git repo, missing test data, etc.)
    "test_baseline_filters_out_known_secrets"
+8 −6
Original line number Diff line number Diff line
@@ -11,13 +11,15 @@
  pyyaml,
  requests,
  responses,
  setuptools,
  unidiff,
  writableTmpDirAsHomeHook,
}:

buildPythonPackage rec {
  pname = "detect-secrets";
  version = "1.5.0";
  format = "setuptools";
  pyproject = true;

  disabled = pythonOlder "3.7";

@@ -29,7 +31,9 @@ buildPythonPackage rec {
    leaveDotGit = true;
  };

  propagatedBuildInputs = [
  build-system = [ setuptools ];

  dependencies = [
    gibberish-detector
    pyyaml
    pyahocorasick
@@ -42,12 +46,9 @@ buildPythonPackage rec {
    responses
    unidiff
    pkgs.gitMinimal
    writableTmpDirAsHomeHook
  ];

  preCheck = ''
    export HOME=$(mktemp -d);
  '';

  disabledTests = [
    # Tests are failing for various reasons. Needs to be adjusted with the next update
    "test_basic"
@@ -66,6 +67,7 @@ buildPythonPackage rec {
  meta = with lib; {
    description = "Enterprise friendly way of detecting and preventing secrets in code";
    homepage = "https://github.com/Yelp/detect-secrets";
    changelog = "https://github.com/Yelp/detect-secrets/releases/tag/${src.tag}";
    license = licenses.asl20;
    maintainers = [ ];
  };