1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5
6 # build-system
7 setuptools,
8
9 # dependencies
10 aiobotocore,
11 aiohttp,
12 fsspec,
13
14 # tests
15 flask,
16 flask-cors,
17 moto,
18 pytest-asyncio,
19 pytestCheckHook,
20}:
21
22buildPythonPackage rec {
23 pname = "s3fs";
24 version = "2025.9.0";
25 pyproject = true;
26
27 src = fetchFromGitHub {
28 owner = "fsspec";
29 repo = "s3fs";
30 tag = version;
31 hash = "sha256-Wb9y2l6/J0EQQwB4AqasqvSVSURylkoh2D2wvw4NjlE=";
32 };
33
34 build-system = [
35 setuptools
36 ];
37
38 pythonRelaxDeps = [ "fsspec" ];
39
40 dependencies = [
41 aiobotocore
42 fsspec
43 aiohttp
44 ];
45
46 optional-dependencies = {
47 awscli = aiobotocore.optional-dependencies.awscli;
48 boto3 = aiobotocore.optional-dependencies.boto3;
49 };
50
51 pythonImportsCheck = [ "s3fs" ];
52
53 nativeCheckInputs = [
54 flask
55 flask-cors
56 moto
57 pytest-asyncio
58 pytestCheckHook
59 ];
60
61 disabledTests = [
62 # require network access
63 "test_async_close"
64 ];
65
66 __darwinAllowLocalNetworking = true;
67
68 meta = {
69 description = "Pythonic file interface for S3";
70 homepage = "https://github.com/fsspec/s3fs";
71 changelog = "https://github.com/fsspec/s3fs/blob/${version}/docs/source/changelog.rst";
72 license = lib.licenses.bsd3;
73 maintainers = with lib.maintainers; [ teh ];
74 };
75}