From cce6f178d2dd1f179a57b514d07280bb4d2a8164 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sat, 2 Nov 2024 18:08:45 +0900 Subject: [PATCH 1/4] python312Packages.fsspec: 2024.3.0 -> 2024.12.0 Diff: https://github.com/fsspec/filesystem_spec/compare/refs/tags/2024.3.0...2024.12.0 Changelog: https://github.com/fsspec/filesystem_spec/raw/2024.12.0/docs/source/changelog.rst --- pkgs/development/python-modules/fsspec/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/fsspec/default.nix b/pkgs/development/python-modules/fsspec/default.nix index a3b1e9c3461e5..79db1b7f43bdb 100644 --- a/pkgs/development/python-modules/fsspec/default.nix +++ b/pkgs/development/python-modules/fsspec/default.nix @@ -30,7 +30,7 @@ buildPythonPackage rec { pname = "fsspec"; - version = "2024.3.0"; + version = "2024.12.0"; format = "setuptools"; disabled = pythonOlder "3.8"; @@ -39,7 +39,7 @@ buildPythonPackage rec { owner = "fsspec"; repo = "filesystem_spec"; tag = version; - hash = "sha256-C+47BcIELZTEARXW8fAMHMjyKUWxU1tNKWGoPPtt/fQ="; + hash = "sha256-Vc0vBayPg6zZ4+pxJsHChSGg0kjA0Q16+Gk0bO0IEpI="; }; propagatedBuildInputs = [ From e132c131d966ee3abed7d614a7fe2e63186a24b8 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sun, 3 Nov 2024 12:17:59 +0900 Subject: [PATCH 2/4] python312Packages.fsspec: refactor --- .../python-modules/fsspec/default.nix | 52 +++++++++++++------ 1 file changed, 36 insertions(+), 16 deletions(-) diff --git a/pkgs/development/python-modules/fsspec/default.nix b/pkgs/development/python-modules/fsspec/default.nix index 79db1b7f43bdb..f50260858afdb 100644 --- a/pkgs/development/python-modules/fsspec/default.nix +++ b/pkgs/development/python-modules/fsspec/default.nix @@ -4,6 +4,8 @@ aiohttp, buildPythonPackage, fetchFromGitHub, + hatchling, + hatch-vcs, numpy, paramiko, pytest-asyncio, @@ -31,7 +33,7 @@ buildPythonPackage rec { pname = "fsspec"; version = "2024.12.0"; - format = "setuptools"; + pyproject = true; disabled = pythonOlder "3.8"; @@ -42,18 +44,15 @@ buildPythonPackage rec { hash = "sha256-Vc0vBayPg6zZ4+pxJsHChSGg0kjA0Q16+Gk0bO0IEpI="; }; - propagatedBuildInputs = [ - aiohttp - paramiko - requests - smbprotocol - tqdm + build-system = [ + hatchling + hatch-vcs ]; optional-dependencies = { - entrypoints = [ ]; abfs = [ adlfs ]; adl = [ adlfs ]; + arrow = [ pyarrow ]; dask = [ dask distributed @@ -63,28 +62,49 @@ buildPythonPackage rec { requests dropbox ]; + entrypoints = [ ]; + full = [ + adlfs + aiohttp + dask + distributed + dropbox + # dropboxdrivefs + fusepy + gcsfs + libarchive-c + ocifs + panel + paramiko + pyarrow + pygit2 + requests + s3fs + smbprotocol + tqdm + ]; + fuse = [ fusepy ]; gcs = [ gcsfs ]; git = [ pygit2 ]; github = [ requests ]; gs = [ gcsfs ]; + gui = [ panel ]; hdfs = [ pyarrow ]; - arrow = [ pyarrow ]; http = [ aiohttp requests ]; - sftp = [ paramiko ]; - s3 = [ s3fs ]; + libarchive = [ libarchive-c ]; oci = [ ocifs ]; + s3 = [ s3fs ]; + sftp = [ paramiko ]; smb = [ smbprotocol ]; ssh = [ paramiko ]; - fuse = [ fusepy ]; - libarchive = [ libarchive-c ]; - gui = [ panel ]; tqdm = [ tqdm ]; }; nativeCheckInputs = [ + aiohttp numpy pytest-asyncio pytest-mock @@ -127,11 +147,11 @@ buildPythonPackage rec { pythonImportsCheck = [ "fsspec" ]; - meta = with lib; { + meta = { description = "Specification that Python filesystems should adhere to"; homepage = "https://github.com/fsspec/filesystem_spec"; changelog = "https://github.com/fsspec/filesystem_spec/raw/${version}/docs/source/changelog.rst"; - license = licenses.bsd3; + license = lib.licenses.bsd3; maintainers = [ ]; }; } From 1b21df1f3390d0e04a7ff0d93fd3523f771b3421 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sat, 2 Nov 2024 19:17:33 +0900 Subject: [PATCH 3/4] python312Packages.s3fs: 2024.9.0 -> 2024.12.0 Changelog: https://github.com/fsspec/s3fs/raw/2024.12.0/docs/source/changelog.rst --- pkgs/development/python-modules/s3fs/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/s3fs/default.nix b/pkgs/development/python-modules/s3fs/default.nix index 7035c15615e7c..9bdcd48677614 100644 --- a/pkgs/development/python-modules/s3fs/default.nix +++ b/pkgs/development/python-modules/s3fs/default.nix @@ -11,14 +11,14 @@ buildPythonPackage rec { pname = "s3fs"; - version = "2024.9.0"; + version = "2024.12.0"; format = "setuptools"; - disabled = pythonOlder "3.7"; + disabled = pythonOlder "3.8"; src = fetchPypi { inherit pname version; - hash = "sha256-ZJNwWrtQN01reZT5YW0nrb3YohnIY1EAvcKGOC79kfU="; + hash = "sha256-Gw86j1lGzKW6KYcdZ5KrHkUo7XYjJ9iu+vyBtzuZ/VY="; }; postPatch = '' From 18667eeb8c9435464f667ae1050dad071fd29ee4 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sun, 3 Nov 2024 12:12:08 +0900 Subject: [PATCH 4/4] python312Packages.s3fs: refactor --- .../python-modules/s3fs/default.nix | 40 ++++++++++++------- 1 file changed, 25 insertions(+), 15 deletions(-) diff --git a/pkgs/development/python-modules/s3fs/default.nix b/pkgs/development/python-modules/s3fs/default.nix index 9bdcd48677614..8586914416eba 100644 --- a/pkgs/development/python-modules/s3fs/default.nix +++ b/pkgs/development/python-modules/s3fs/default.nix @@ -5,46 +5,56 @@ buildPythonPackage, docutils, fetchPypi, + flask, + flask-cors, fsspec, + moto, + pytestCheckHook, pythonOlder, + setuptools, }: buildPythonPackage rec { pname = "s3fs"; version = "2024.12.0"; - format = "setuptools"; + pyproject = true; - disabled = pythonOlder "3.8"; + disabled = pythonOlder "3.9"; src = fetchPypi { inherit pname version; hash = "sha256-Gw86j1lGzKW6KYcdZ5KrHkUo7XYjJ9iu+vyBtzuZ/VY="; }; - postPatch = '' - sed -i 's/fsspec==.*/fsspec/' requirements.txt - ''; - buildInputs = [ docutils ]; - propagatedBuildInputs = [ + build-system = [ setuptools ]; + + dependencies = [ aiobotocore aiohttp fsspec ]; - # Depends on `moto` which has a long dependency chain with exact - # version requirements that can't be made to work with current - # pythonPackages. - doCheck = false; - pythonImportsCheck = [ "s3fs" ]; - meta = with lib; { + nativeCheckInputs = [ + flask + flask-cors + moto + pytestCheckHook + ]; + + disabledTests = [ + # require network access + "test_async_close" + ]; + + meta = { description = "Pythonic file interface for S3"; homepage = "https://github.com/fsspec/s3fs"; changelog = "https://github.com/fsspec/s3fs/raw/${version}/docs/source/changelog.rst"; - license = licenses.bsd3; - maintainers = with maintainers; [ teh ]; + license = lib.licenses.bsd3; + maintainers = with lib.maintainers; [ teh ]; }; }