diff --git a/pkgs/development/python-modules/snakemake-storage-plugin-s3/default.nix b/pkgs/development/python-modules/snakemake-storage-plugin-s3/default.nix new file mode 100644 index 000000000000..9f194eb25357 --- /dev/null +++ b/pkgs/development/python-modules/snakemake-storage-plugin-s3/default.nix @@ -0,0 +1,54 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, boto3 +, botocore +, poetry-core +, snakemake +, snakemake-interface-storage-plugins +, snakemake-interface-common +, urllib3 +}: + +buildPythonPackage rec { + pname = "snakemake-storage-plugin-s3"; + version = "0.2.10"; + format = "pyproject"; + + src = fetchFromGitHub { + owner = "snakemake"; + repo = pname; + rev = "refs/tags/v${version}"; + hash = "sha256-k21DRQdSUFkdwNb7MZJmClhIg+pdSc7H6FkDrbf4DT8="; + }; + + postPatch = '' + substituteInPlace pyproject.toml \ + --replace ">=2.0,<2.2" "*" + ''; + + nativeBuildInputs = [ + poetry-core + ]; + + propagatedBuildInputs = [ + boto3 + botocore + snakemake-interface-storage-plugins + snakemake-interface-common + urllib3 + ]; + + nativeCheckInputs = [ + snakemake + ]; + + pythonImportsCheck = [ "snakemake_storage_plugin_s3" ]; + + meta = with lib; { + description = "A Snakemake storage plugin for S3 API storage (AWS S3, MinIO, etc.)"; + homepage = "https://github.com/snakemake/snakemake-storage-plugin-s3"; + license = licenses.mit; + maintainers = with maintainers; [ veprbl ]; + }; +} diff --git a/pkgs/development/python-modules/snakemake-storage-plugin-xrootd/default.nix b/pkgs/development/python-modules/snakemake-storage-plugin-xrootd/default.nix new file mode 100644 index 000000000000..82d8c2928c3c --- /dev/null +++ b/pkgs/development/python-modules/snakemake-storage-plugin-xrootd/default.nix @@ -0,0 +1,51 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, poetry-core +, snakemake +, snakemake-interface-storage-plugins +, snakemake-interface-common +, xrootd +}: + +buildPythonPackage rec { + pname = "snakemake-storage-plugin-xrootd"; + version = "unstable-2023-12-16"; + format = "pyproject"; + + src = fetchFromGitHub { + owner = "snakemake"; + repo = pname; + rev = "408f1e956b5427c34b49eeca340492a438e8eccb"; + hash = "sha256-CcSG//D9kz0Q4LtaSngJpCtY0dbNFFuKMVmBxR1fcMo="; + }; + + # xrootd<6.0.0,>=5.6.4 not satisfied by version 5.7rc20240303 + postPatch = '' + substituteInPlace pyproject.toml \ + --replace 'xrootd = "^5.6.4"' "" + ''; + + nativeBuildInputs = [ + poetry-core + ]; + + propagatedBuildInputs = [ + snakemake-interface-storage-plugins + snakemake-interface-common + xrootd + ]; + + nativeCheckInputs = [ + snakemake + ]; + + pythonImportsCheck = [ "snakemake_storage_plugin_xrootd" ]; + + meta = with lib; { + description = "A Snakemake storage plugin for handling input and output via XRootD"; + homepage = "https://github.com/snakemake/snakemake-storage-plugin-xrootd"; + license = licenses.mit; + maintainers = with maintainers; [ veprbl ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2226189c0815..b9d9f61239b5 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -13914,6 +13914,10 @@ self: super: with self; { inherit (self) python; }); + snakemake = toPythonModule (pkgs.snakemake.override { + python3 = python; + }); + snakemake-executor-plugin-cluster-generic = callPackage ../development/python-modules/snakemake-executor-plugin-cluster-generic { }; snakemake-interface-common = callPackage ../development/python-modules/snakemake-interface-common { }; @@ -13924,6 +13928,10 @@ self: super: with self; { snakemake-interface-storage-plugins = callPackage ../development/python-modules/snakemake-interface-storage-plugins { }; + snakemake-storage-plugin-s3 = callPackage ../development/python-modules/snakemake-storage-plugin-s3 { }; + + snakemake-storage-plugin-xrootd = callPackage ../development/python-modules/snakemake-storage-plugin-xrootd { }; + snakebite = callPackage ../development/python-modules/snakebite { }; snakeviz = callPackage ../development/python-modules/snakeviz { };