diff --git a/.editorconfig b/.editorconfig index ce35108..9aea56f 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product # # EditorConfig Configuration file, for more details see: # https://EditorConfig.org @@ -12,7 +12,7 @@ root = true -[*] # For All Files +[*] # Unix-style newlines with a newline ending every file end_of_line = lf insert_final_newline = true diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index cf37dd3..892c4fd 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product name: pre-commit on: @@ -21,7 +21,7 @@ jobs: name: linting runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - uses: actions/setup-python@v6 with: python-version: '3.13' diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0fe597d..2872872 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product name: tests on: @@ -35,12 +35,12 @@ jobs: if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name name: ${{ matrix.config[1] }} steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 with: persist-credentials: false - name: Install uv + caching - # astral/setup-uv@7.1.3 - uses: astral-sh/setup-uv@5a7eac68fb9809dea845d802897dc5c723910fa3 + # astral/setup-uv@7.1.4 + uses: astral-sh/setup-uv@1e862dfacbd1d6d858c55d9b792c756523627244 with: enable-cache: true cache-dependency-glob: | diff --git a/.gitignore b/.gitignore index ce7f677..2237713 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product *.dll *.egg-info/ *.profraw diff --git a/.meta.toml b/.meta.toml index b1b0576..cdfbb78 100644 --- a/.meta.toml +++ b/.meta.toml @@ -1,8 +1,8 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product [meta] template = "zope-product" -commit-id = "9fcd3d67" +commit-id = "446e9797" [python] with-pypy = false diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cdeaf6c..de48184 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product minimum_pre_commit_version: '3.6' repos: - repo: https://github.com/pycqa/isort diff --git a/CHANGES.rst b/CHANGES.rst index ac3826c..9106bd2 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -4,6 +4,8 @@ Changelog 5.3 (unreleased) ---------------- +- Move package metadata from setup.py to pyproject.toml. + 5.2 (2025-11-20) ---------------- diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ce446a6..67fe1fb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,6 @@ # Contributing to zopefoundation projects diff --git a/MANIFEST.in b/MANIFEST.in index 920b11d..7336ddf 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product include *.md include *.rst include *.txt diff --git a/pyproject.toml b/pyproject.toml index 09d7075..bebcb57 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,5 @@ -# -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product - +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product [build-system] requires = [ "setuptools >= 78.1.1,< 81", @@ -9,6 +7,52 @@ requires = [ ] build-backend = "setuptools.build_meta" + +[project] +name = "Products.PythonScripts" +version = "5.3.dev0" +description = "Provides support for restricted execution of Python scripts in Zope." +license = "ZPL-2.1" +classifiers = [ + "Development Status :: 6 - Mature", + "Environment :: Web Environment", + "Framework :: Zope", + "Framework :: Zope :: 5", + "Operating System :: OS Independent", + "Programming Language :: Python", + "Programming Language :: Python :: 3", + "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", + "Programming Language :: Python :: Implementation :: CPython", +] +dynamic = ["readme"] +requires-python = ">=3.10" +authors = [ + {name = "Zope Foundation and contributors",email = "zope-dev@zope.dev"}, +] +maintainers = [ + {name = "Plone Foundation and contributors",email = "zope-dev@zope.dev"}, +] +dependencies = [ + "AccessControl", + "Acquisition", + "DateTime", + "DocumentTemplate", + "RestrictedPython >= 4.0b5", + "zExceptions", + "Zope >= 5", +] + +[project.entry-points."zodbupdate.decode"] +decodes = "Products.PythonScripts:zodbupdate_decode_dict" + +[project.urls] +Source = "https://github.com/zopefoundation/Products.PythonScripts" +Issues = "https://github.com/zopefoundation/Products.PythonScripts/issues" + [tool.coverage.run] branch = true source = ["Products.PythonScripts"] @@ -31,3 +75,7 @@ exclude_lines = [ [tool.coverage.html] directory = "parts/htmlcov" + +[tool.setuptools.dynamic] +readme = {file = ["README.rst", "CHANGES.rst"]} + diff --git a/setup.cfg b/setup.cfg index a7bfdb4..5ea5623 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product [flake8] doctests = 1 diff --git a/setup.py b/setup.py index 16d00d4..3a960de 100644 --- a/setup.py +++ b/setup.py @@ -15,52 +15,5 @@ from setuptools import setup -setup(name='Products.PythonScripts', - version='5.3.dev0', - url='https://github.com/zopefoundation/Products.PythonScripts', - project_urls={ - 'Issue Tracker': ('https://github.com/zopefoundation/' - 'Products.PythonScripts/issues'), - 'Sources': ('https://github.com/zopefoundation/' - 'Products.PythonScripts'), - }, - license='ZPL-2.1', - description='Provides support for restricted execution of Python ' - 'scripts in Zope.', - author='Zope Foundation and Contributors', - author_email='zope-dev@zope.dev', - long_description=('{}\n{}'.format(open('README.rst').read(), - open('CHANGES.rst').read())), - classifiers=[ - 'Development Status :: 6 - Mature', - 'Environment :: Web Environment', - 'Framework :: Zope', - 'Framework :: Zope :: 5', - 'License :: OSI Approved :: Zope Public License', - 'Operating System :: OS Independent', - 'Programming Language :: Python', - 'Programming Language :: Python :: 3', - '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', - 'Programming Language :: Python :: Implementation :: CPython', - ], - python_requires='>=3.10', - install_requires=[ - 'AccessControl', - 'Acquisition', - 'DateTime', - 'DocumentTemplate', - 'RestrictedPython >= 4.0b5', - 'zExceptions', - 'Zope >= 4.1.2', - ], - entry_points={ - 'zodbupdate.decode': [ - 'decodes = Products.PythonScripts:zodbupdate_decode_dict', - ], - }, - include_package_data=True, - ) +# See pyproject.toml for package metadata +setup() diff --git a/tox.ini b/tox.ini index a4481a9..0f2cd88 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ -# Generated from: -# https://github.com/zopefoundation/meta/tree/master/config/zope-product +# Generated with zope.meta (https://zopemeta.readthedocs.io/) from: +# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/zope-product [tox] minversion = 3.18 envlist =