2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiobotocore,
|
|
|
|
boto3,
|
|
|
|
buildPythonPackage,
|
|
|
|
dvc-objects,
|
|
|
|
fetchPypi,
|
|
|
|
flatten-dict,
|
|
|
|
s3fs,
|
|
|
|
setuptools-scm,
|
2024-01-02 11:29:13 +00:00
|
|
|
}:
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "dvc-s3";
|
2024-07-01 15:47:52 +00:00
|
|
|
version = "3.2.0";
|
2024-01-02 11:29:13 +00:00
|
|
|
pyproject = true;
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2024-07-01 15:47:52 +00:00
|
|
|
pname = "dvc_s3";
|
|
|
|
inherit version;
|
|
|
|
hash = "sha256-HQEqwdzkdlmYb5GBI7SJMc+bNCmrC0oi/UsCRIGFzrY=";
|
2023-05-24 13:37:59 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# Prevent circular dependency
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonRemoveDeps = [ "dvc" ];
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
# dvc-s3 uses boto3 directly, we add in propagatedBuildInputs
|
|
|
|
postPatch = ''
|
2024-07-01 15:47:52 +00:00
|
|
|
substituteInPlace pyproject.toml \
|
|
|
|
--replace-fail "aiobotocore[boto3]" "aiobotocore"
|
2023-05-24 13:37:59 +00:00
|
|
|
'';
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
build-system = [ setuptools-scm ];
|
2023-05-24 13:37:59 +00:00
|
|
|
|
2024-07-01 15:47:52 +00:00
|
|
|
dependencies = [
|
2024-01-02 11:29:13 +00:00
|
|
|
aiobotocore
|
|
|
|
boto3
|
|
|
|
dvc-objects
|
2024-06-05 15:53:02 +00:00
|
|
|
flatten-dict
|
|
|
|
s3fs
|
2023-05-24 13:37:59 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
# Network access is needed for tests
|
|
|
|
doCheck = false;
|
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
# Circular dependency
|
|
|
|
# pythonImportsCheck = [
|
|
|
|
# "dvc_s3"
|
|
|
|
# ];
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "s3 plugin for dvc";
|
|
|
|
homepage = "https://pypi.org/project/dvc-s3/${version}";
|
|
|
|
changelog = "https://github.com/iterative/dvc-s3/releases/tag/${version}";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ melling ];
|
|
|
|
};
|
|
|
|
}
|