Skip to content

Commit b4bc87a

Browse files
committed
Bump project backend builder to setuptools with pyproject.toml
Signed-off-by: trafalgarzzz <trafalgarz@outlook.com>
1 parent a50593b commit b4bc87a

File tree

6 files changed

+47
-51
lines changed

6 files changed

+47
-51
lines changed

fluid/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
from __future__ import absolute_import
1515

16-
__version__ = "0.1"
16+
__version__ = "0.1.2"
1717

1818
# import apis into sdk package
1919

fluid/version.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

pyproject.toml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
[build-system]
2+
requires = ["setuptools>=61.0"]
3+
build-backend = "setuptools.build_meta"
4+
5+
[project]
6+
name = "fluid-pysdk"
7+
authors = [
8+
{ name = "Fluid Authors", email = "fluid.opensource.project@gmail.com" },
9+
]
10+
description = "Python SDK for fluid-cloudnative fluid to manage datasets"
11+
license = { file = "LICENSE" }
12+
requires-python = ">=3.7"
13+
classifiers = [
14+
'Development Status :: 3 - Alpha',
15+
'Intended Audience :: Developers',
16+
'License :: OSI Approved :: Apache Software License',
17+
'Operating System :: OS Independent',
18+
'Programming Language :: Python',
19+
'Programming Language :: Python :: 3',
20+
'Programming Language :: Python :: 3 :: Only',
21+
'Programming Language :: Python :: 3.7',
22+
'Programming Language :: Python :: 3.8',
23+
'Programming Language :: Python :: 3.9',
24+
'Programming Language :: Python :: 3.10',
25+
'Topic :: Scientific/Engineering',
26+
'Topic :: Scientific/Engineering :: Artificial Intelligence',
27+
'Topic :: Software Development',
28+
'Topic :: Software Development :: Libraries',
29+
'Topic :: Software Development :: Libraries :: Python Modules',
30+
]
31+
keywords = ["fluid", "kubernetes", "data-abstraction", "data-pipeline", "distributed-cache"]
32+
dynamic = ["version", "dependencies"]
33+
34+
[project.urls]
35+
Homepage = "https://github.com/fluid-cloudnative/fluid-client-python"
36+
Issues = "https://github.com/fluid-cloudnative/fluid-client-python/issues"
37+
38+
[tool.setuptools.dynamic]
39+
version = { attr = "fluid.__version__" }
40+
dependencies = { file = "requirements.txt" }
41+
42+

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ six >= 1.10
44
python_dateutil >= 2.5.3
55
setuptools >= 21.0.0
66
urllib3 >= 1.15.1
7-
kubernetes>=22.6.0
7+
kubernetes >= 18.20.0
88
fsspec~=2023.12.2
99
s3fs~=2023.12.2
1010
python-dateutil~=2.8.2

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1+
# Python lint
12
[flake8]
23
max-line-length=99

setup.py

Lines changed: 2 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -14,52 +14,6 @@
1414

1515
# coding: utf-8
1616

17-
from importlib.machinery import SourceFileLoader
18-
from setuptools import setup, find_packages # noqa: H301
17+
from setuptools import setup
1918

20-
NAME = "fluid"
21-
22-
def load_version(filename):
23-
loader = SourceFileLoader(filename, filename)
24-
return loader.load_module().VERSION
25-
26-
27-
def load_requirements(filename):
28-
with open(filename) as fd:
29-
return fd.readlines()
30-
31-
32-
requirements = load_requirements("requirements.txt")
33-
test_requirements = load_requirements("test-requirements.txt")
34-
35-
setup(
36-
name=NAME,
37-
description="Fluid Python SDK",
38-
version=load_version("fluid/version.py"),
39-
author="Fluid Authors",
40-
author_email="fluid.opensource.project@gmail.com",
41-
url="https://github.com/fluid-cloudnative/fluid-client-python",
42-
license="Apache License Version 2.0",
43-
packages=find_packages(exclude=("tests",)),
44-
classifiers=[
45-
'Intended Audience :: Developers',
46-
'Intended Audience :: Education',
47-
'License :: OSI Approved :: Apache Software License'
48-
'Operating System :: OS Independent',
49-
'Programming Language :: Python',
50-
'Programming Language :: Python :: 3',
51-
'Programming Language :: Python :: 3 :: Only',
52-
'Programming Language :: Python :: 3.7',
53-
'Programming Language :: Python :: 3.8',
54-
'Programming Language :: Python :: 3.9',
55-
'Programming Language :: Python :: 3.10',
56-
'Topic :: Scientific/Engineering',
57-
'Topic :: Scientific/Engineering :: Artificial Intelligence',
58-
'Topic :: Software Development',
59-
'Topic :: Software Development :: Libraries',
60-
'Topic :: Software Development :: Libraries :: Python Modules',
61-
],
62-
tests_require=test_requirements,
63-
install_requires=requirements,
64-
python_requires=">=3.7",
65-
)
19+
setup()

0 commit comments

Comments
 (0)