From 3e2a26555e06145592d37938b723668510e2c0a2 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Tue, 3 Feb 2026 13:38:40 +0000 Subject: [PATCH 1/2] python3Packages.slither-analyzer: cleanup --- .../slither-analyzer/default.nix | 31 ++++++++++++------- 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/pkgs/development/python-modules/slither-analyzer/default.nix b/pkgs/development/python-modules/slither-analyzer/default.nix index 045574b56631..1681229f8a42 100644 --- a/pkgs/development/python-modules/slither-analyzer/default.nix +++ b/pkgs/development/python-modules/slither-analyzer/default.nix @@ -1,16 +1,27 @@ { lib, buildPythonPackage, - crytic-compile, fetchFromGitHub, + + # build-system hatchling, + + # nativeBuildInputs makeWrapper, + + # dependencies + crytic-compile, packaging, prettytable, - solc, - testers, - versionCheckHook, web3, + + # tests + versionCheckHook, + writableTmpDirAsHomeHook, + + # postFixup + solc, + withSolc ? false, }: @@ -37,18 +48,16 @@ buildPythonPackage (finalAttrs: { web3 ]; - nativeInstallCheckInputs = [ versionCheckHook ]; + nativeCheckInputs = [ + versionCheckHook + writableTmpDirAsHomeHook + ]; postFixup = lib.optionalString withSolc '' wrapProgram $out/bin/slither \ --prefix PATH : "${lib.makeBinPath [ solc ]}" ''; - # required for pythonImportsCheck - postInstall = '' - export HOME="$TEMP" - ''; - pythonImportsCheck = [ "slither" "slither.all_exceptions" @@ -66,8 +75,6 @@ buildPythonPackage (finalAttrs: { "slither.vyper_parsing" ]; - doInstallCheck = true; - meta = { description = "Static Analyzer for Solidity"; longDescription = '' From da269b0e31932977121800ee9496477c8cb1755d Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Tue, 3 Feb 2026 13:41:25 +0000 Subject: [PATCH 2/2] python3Packages.slither-analyzer: fix on darwin --- pkgs/development/python-modules/slither-analyzer/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/development/python-modules/slither-analyzer/default.nix b/pkgs/development/python-modules/slither-analyzer/default.nix index 1681229f8a42..2f53803f885c 100644 --- a/pkgs/development/python-modules/slither-analyzer/default.nix +++ b/pkgs/development/python-modules/slither-analyzer/default.nix @@ -52,6 +52,7 @@ buildPythonPackage (finalAttrs: { versionCheckHook writableTmpDirAsHomeHook ]; + versionCheckKeepEnvironment = [ "HOME" ]; postFixup = lib.optionalString withSolc '' wrapProgram $out/bin/slither \