diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 284d1d8..cfc0f82 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -27,7 +27,7 @@ jobs: uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4 with: path: ~/.cache/pip - key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }} + key: ${{ runner.os }}-pip-${{ hashFiles('**/pyproject.toml') }} restore-keys: | ${{ runner.os }}-pip- diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a3a0842..09244cb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -35,7 +35,7 @@ jobs: with: token: ${{ secrets.ADYEN_AUTOMATION_BOT_ACCESS_TOKEN }} develop-branch: main - version-files: setup.py pyproject.toml Adyen/settings.py + version-files: pyproject.toml Adyen/settings.py release-title: Adyen Python API Library pre-release: ${{ inputs.pre-release || false }} github-release: ${{ inputs.github-release || false }} diff --git a/.gitignore b/.gitignore index ed819ce..9f1f798 100644 --- a/.gitignore +++ b/.gitignore @@ -10,4 +10,5 @@ venv/ .env test.py build/ -*.egg-info/ \ No newline at end of file +*.egg-info/ +.paw/ diff --git a/Makefile b/Makefile index 054ffaa..8d1a9c8 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ install: - @pip install requests pycurl mock coveralls ruff + @pip install -e ".[requests,test,dev]" lint: @ruff check Adyen test diff --git a/pyproject.toml b/pyproject.toml index 410b005..e8dbd84 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools>=45", "wheel"] +requires = ["setuptools>=61.0.0", "wheel"] build-backend = "setuptools.build_meta" [project] @@ -31,6 +31,11 @@ classifiers = [ "Programming Language :: Python :: 3.14", ] +[project.urls] +Homepage = "https://github.com/Adyen/adyen-python-api-library" +Repository = "https://github.com/Adyen/adyen-python-api-library" +Issues = "https://github.com/Adyen/adyen-python-api-library/issues" + [project.optional-dependencies] requests = ["requests>=2.25.0"] pycurl = ["pycurl>=7.43.0"] @@ -45,6 +50,9 @@ dev = [ "pre-commit>=3.0.0", ] +[tool.setuptools.packages.find] +include = ["Adyen*"] + [tool.ruff] line-length = 100 target-version = "py38" diff --git a/setup.py b/setup.py index 1640681..8bf1ba9 100644 --- a/setup.py +++ b/setup.py @@ -1,45 +1,2 @@ -from setuptools import find_packages, setup - -setup( - name="Adyen", - packages=find_packages(include=["Adyen*"], exclude=["tests", "tests.*"]), - version="15.0.0", - maintainer="Adyen", - maintainer_email="support@adyen.com", - description="Adyen Python Api", - long_description="A Python client library for accessing Adyen APIs", - author="Adyen", - author_email="support@adyen.com", - url="https://github.com/Adyen/adyen-python-api-library", - keywords=["payments", "adyen", "fintech"], - python_requires=">=3.8", - install_requires=[], - extras_require={ - "requests": ["requests>=2.25.0"], - "pycurl": ["pycurl>=7.43.0"], - "test": [ - "pytest>=7.0.0", - "pytest-cov>=4.0.0", - "mock>=4.0.0", - "requests>=2.25.0", - ], - "dev": [ - "ruff>=0.4.4", - "pre-commit>=3.0.0", - ], - }, - classifiers=[ - "Development Status :: 5 - Production/Stable", - "Intended Audience :: Developers", - "Topic :: Software Development :: Libraries", - "License :: OSI Approved :: MIT License", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.8", - "Programming Language :: Python :: 3.9", - "Programming Language :: Python :: 3.10", - "Programming Language :: Python :: 3.11", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: 3.13", - "Programming Language :: Python :: 3.14", - ], -) +from setuptools import setup +setup()