setup.py 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. # Copyright 2021-2024 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. """The setup script for taipy-config package"""
  12. import json
  13. from pathlib import Path
  14. from setuptools import find_packages, setup
  15. root_folder = Path(__file__).parent
  16. package_desc = Path(root_folder / "package_desc.md").read_text("UTF-8")
  17. version_path = "taipy/config/version.json"
  18. setup_requirements = Path("taipy/config/setup.requirements.txt")
  19. with open(version_path) as version_file:
  20. version = json.load(version_file)
  21. version_string = f'{version.get("major", 0)}.{version.get("minor", 0)}.{version.get("patch", 0)}'
  22. if vext := version.get("ext"):
  23. version_string = f"{version_string}.{vext}"
  24. requirements = [r for r in (setup_requirements).read_text("UTF-8").splitlines() if r]
  25. test_requirements = ["pytest>=3.8"]
  26. setup(
  27. author="Avaiga",
  28. author_email="dev@taipy.io",
  29. python_requires=">=3.8",
  30. classifiers=[
  31. "Development Status :: 5 - Production/Stable",
  32. "Intended Audience :: Developers",
  33. "License :: OSI Approved :: Apache Software License",
  34. "Natural Language :: English",
  35. "Programming Language :: Python :: 3",
  36. "Programming Language :: Python :: 3.8",
  37. "Programming Language :: Python :: 3.9",
  38. "Programming Language :: Python :: 3.10",
  39. "Programming Language :: Python :: 3.11",
  40. "Programming Language :: Python :: 3.12",
  41. "Topic :: Software Development",
  42. "Topic :: Scientific/Engineering",
  43. "Operating System :: Microsoft :: Windows",
  44. "Operating System :: POSIX",
  45. "Operating System :: Unix",
  46. "Operating System :: MacOS",
  47. ],
  48. description="A Taipy package dedicated to easily configure a Taipy application.",
  49. install_requires=requirements,
  50. long_description=package_desc,
  51. long_description_content_type="text/markdown",
  52. include_package_data=True,
  53. license="Apache License 2.0",
  54. keywords="taipy-config",
  55. name="taipy-config",
  56. packages=find_packages(
  57. where=root_folder, include=[
  58. "taipy", "taipy.config", "taipy.config.*", "taipy.logger", "taipy.logger.*", "taipy._cli", "taipy._cli.*"
  59. ]
  60. ),
  61. test_suite="tests",
  62. tests_require=test_requirements,
  63. version=version_string,
  64. zip_safe=False,
  65. project_urls={
  66. "Homepage": "https://www.taipy.io",
  67. "Documentation": "https://docs.taipy.io",
  68. "Source": "https://github.com/Avaiga/taipy",
  69. "Download": "https://pypi.org/project/taipy/#files",
  70. "Tracker": "https://github.com/Avaiga/taipy/issues",
  71. "Release notes": "https://docs.taipy.io/en/latest/relnotes/",
  72. },
  73. )