setup.py 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. # Copyright 2023 Avaiga Private Limited
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
  4. # the License. You may obtain a copy of the License at
  5. #
  6. # http://www.apache.org/licenses/LICENSE-2.0
  7. #
  8. # Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
  9. # an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
  10. # specific language governing permissions and limitations under the License.
  11. import json
  12. from pathlib import Path
  13. from setuptools import find_namespace_packages, find_packages, setup
  14. root_folder = Path(__file__).parent.parent.parent.parent
  15. readme = Path(root_folder / "README.md").read_text("UTF-8")
  16. with open(root_folder / "taipy" / "rest" / "version.json") as version_file:
  17. version = json.load(version_file)
  18. version_string = f'{version.get("major", 0)}.{version.get("minor", 0)}.{version.get("patch", 0)}'
  19. if vext := version.get("ext"):
  20. version_string = f"{version_string}.{vext}"
  21. setup(
  22. author="Avaiga",
  23. name="taipy-rest",
  24. keywords="taipy-rest",
  25. python_requires=">=3.8",
  26. version=version_string,
  27. author_email="dev@taipy.io",
  28. package_dir = {"" : "../../.."},
  29. packages=find_packages(where=root_folder, include=["taipy", "taipy.rest", "taipy.rest.*"]),
  30. include_package_data=True,
  31. long_description=readme,
  32. long_description_content_type="text/markdown",
  33. description="Library to expose taipy-core REST APIs.",
  34. license="Apache License 2.0",
  35. classifiers=[
  36. "Intended Audience :: Developers",
  37. "License :: OSI Approved :: Apache Software License",
  38. "Natural Language :: English",
  39. "Programming Language :: Python :: 3",
  40. "Programming Language :: Python :: 3.8",
  41. "Programming Language :: Python :: 3.9",
  42. "Programming Language :: Python :: 3.10",
  43. "Programming Language :: Python :: 3.11",
  44. ],
  45. install_requires=[
  46. "flask>=3.0.0,<3.1",
  47. "flask-restful>=0.3.9,<0.4",
  48. "passlib>=1.7.4,<1.8",
  49. "marshmallow>=3.20.1,<3.30",
  50. "apispec[yaml]>=6.3,<7.0",
  51. "apispec-webframeworks>=0.5.2,<0.6",
  52. "taipy-core@git+https://git@github.com/Avaiga/taipy-core.git@develop",
  53. ],
  54. )