diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8497af7..5ba25ad 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -92,24 +92,26 @@ jobs: # with `test`, and `docs` must use a subset. runs-on: ${{ matrix.os }} strategy: + fail-fast: false matrix: python-version: - - 2.7 - - 3.5 - - pypy-2.7 - - pypy-3.6 - - 3.6 - - 3.7 - - 3.8 - - 3.9 + - "2.7" + - "3.5" + - "pypy-2.7" + - "pypy-3.7" + - "3.6" + - "3.7" + - "3.8" + - "3.9" + - "3.10" os: [ubuntu-20.04, macos-latest] exclude: - os: macos-latest - python-version: pypy-2.7 + python-version: "pypy-2.7" - os: macos-latest - python-version: pypy-3.6 + python-version: "pypy-3.7" - os: macos-latest - python-version: 3.5 + python-version: "3.5" steps: - name: checkout @@ -141,7 +143,6 @@ jobs: run: | pip install -U pip pip install -U setuptools wheel twine cffi - pip install -U coveralls coverage - name: Build zope.index run: | @@ -150,7 +151,6 @@ jobs: python setup.py build_ext -i python setup.py bdist_wheel # Also install it, so that we get dependencies in the (pip) cache. - pip install -U coverage pip install -U 'faulthandler; python_version == "2.7" and platform_python_implementation == "CPython"' pip install .[test] @@ -167,7 +167,11 @@ jobs: # We cannot 'uses: pypa/gh-action-pypi-publish@v1.4.1' because # that's apparently a container action, and those don't run on # the Mac. - if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') && startsWith(runner.os, 'Mac') + if: > + github.event_name == 'push' + && startsWith(github.ref, 'refs/tags') + && startsWith(runner.os, 'Mac') + && !startsWith(matrix.python-version, 'pypy') env: TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} run: | @@ -177,24 +181,26 @@ jobs: needs: build-package runs-on: ${{ matrix.os }} strategy: + fail-fast: false matrix: python-version: - - 2.7 - - 3.5 - - pypy-2.7 - - pypy-3.6 - - 3.6 - - 3.7 - - 3.8 - - 3.9 + - "2.7" + - "3.5" + - "pypy-2.7" + - "pypy-3.7" + - "3.6" + - "3.7" + - "3.8" + - "3.9" + - "3.10" os: [ubuntu-20.04, macos-latest] exclude: - os: macos-latest - python-version: pypy-2.7 + python-version: "pypy-2.7" - os: macos-latest - python-version: pypy-3.6 + python-version: "pypy-3.7" - os: macos-latest - python-version: 3.5 + python-version: "3.5" steps: - name: checkout @@ -229,8 +235,8 @@ jobs: path: dist/ - name: Install zope.index run: | - pip install -U wheel - pip install -U coverage coverage-python-version + pip install -U wheel setuptools + pip install -U coverage pip install -U 'faulthandler; python_version == "2.7" and platform_python_implementation == "CPython"' # Unzip into src/ so that testrunner can find the .so files # when we ask it to load tests from that directory. This @@ -270,7 +276,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - python-version: [3.9] + python-version: ["3.9"] os: [ubuntu-20.04] steps: @@ -309,21 +315,18 @@ jobs: pip install -U wheel pip install -U coverage pip install -U "`ls dist/zope.index-*.whl`[docs]" - # Until repoze.sphinx.autointerface supports Sphinx 4.x we cannot use it: - pip install -U "Sphinx < 4" - name: Build docs env: ZOPE_INTERFACE_STRICT_IRO: 1 run: | sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html - sphinx-build -b doctest -d docs/_build/doctrees docs docs/_build/doctest lint: needs: build-package runs-on: ${{ matrix.os }} strategy: matrix: - python-version: [3.9] + python-version: ["3.9"] os: [ubuntu-20.04] steps: @@ -375,7 +378,7 @@ jobs: # We use a regular Python matrix entry to share as much code as possible. strategy: matrix: - python-version: [3.9] + python-version: ["3.9"] image: [manylinux2010_x86_64, manylinux2010_i686, manylinux2014_aarch64] steps: @@ -442,7 +445,9 @@ jobs: run: sudo chown -R $(whoami) ${{ steps.pip-cache.outputs.dir }} - name: Publish package to PyPI uses: pypa/gh-action-pypi-publish@v1.4.1 - if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') + if: > + github.event_name == 'push' + && startsWith(github.ref, 'refs/tags') with: user: __token__ password: ${{ secrets.TWINE_PASSWORD }} diff --git a/.manylinux-install.sh b/.manylinux-install.sh index 6436dc3..5c0fe25 100755 --- a/.manylinux-install.sh +++ b/.manylinux-install.sh @@ -23,21 +23,26 @@ fi ls -ld /cache ls -ld /cache/pip +# We need some libraries because we build wheels from scratch: +yum -y install libffi-devel + # Compile wheels for PYBIN in /opt/python/*/bin; do - if [[ "${PYBIN}" == *"cp27"* ]] || \ + if \ + [[ "${PYBIN}" == *"cp27"* ]] || \ [[ "${PYBIN}" == *"cp35"* ]] || \ [[ "${PYBIN}" == *"cp36"* ]] || \ [[ "${PYBIN}" == *"cp37"* ]] || \ [[ "${PYBIN}" == *"cp38"* ]] || \ - [[ "${PYBIN}" == *"cp39"* ]]; then + [[ "${PYBIN}" == *"cp39"* ]] || \ + [[ "${PYBIN}" == *"cp310"* ]] ; then "${PYBIN}/pip" install -e /io/ "${PYBIN}/pip" wheel /io/ -w wheelhouse/ if [ `uname -m` == 'aarch64' ]; then - cd /io/ - "${PYBIN}/pip" install tox - "${PYBIN}/tox" -e py - cd .. + cd /io/ + "${PYBIN}/pip" install tox + "${PYBIN}/tox" -e py + cd .. fi rm -rf /io/build /io/*.egg-info fi diff --git a/.meta.toml b/.meta.toml index 8b6acba..ad11e6a 100644 --- a/.meta.toml +++ b/.meta.toml @@ -2,7 +2,7 @@ # https://github.com/zopefoundation/meta/tree/master/config/c-code [meta] template = "c-code" -commit-id = "4a880af151662e1e39b3dc9b4cb924f2af019e1f" +commit-id = "efa4b7532073de2e151785892b48ac95bc72981b" [python] with-appveyor = true diff --git a/CHANGES.rst b/CHANGES.rst index bf90618..7413ab7 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -5,7 +5,7 @@ 5.1.1 (unreleased) ================== -- Nothing changed yet. +- Add support for Python 3.10. 5.1.0 (2021-07-19) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..e6d84b8 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,23 @@ + +# Contributing to zopefoundation projects + +The projects under the zopefoundation GitHub organization are open source and +welcome contributions in different forms: + +* bug reports +* code improvements and bug fixes +* documentation improvements +* pull request reviews + +For any changes in the repository besides trivial typo fixes you are required +to sign the contributor agreement. See +https://www.zope.dev/developer/becoming-a-committer.html for details. + +Please visit our [Developer +Guidelines](https://www.zope.dev/developer/guidelines.html) if you'd like to +contribute code changes and our [guidelines for reporting +bugs](https://www.zope.dev/developer/reporting-bugs.html) if you want to file a +bug report. diff --git a/MANIFEST.in b/MANIFEST.in index 2faa807..0741033 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,5 +1,6 @@ # Generated from: # https://github.com/zopefoundation/meta/tree/master/config/c-code +include *.md include *.rst include *.txt include buildout.cfg diff --git a/appveyor.yml b/appveyor.yml index 35d5044..7212fe3 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -22,6 +22,8 @@ environment: - python: 38-x64 - python: 39 - python: 39-x64 + - python: 310 + - python: 310-x64 install: - "SET PYTHONVERSION=%PYTHON%" diff --git a/setup.py b/setup.py index cdfda3b..9e9db55 100644 --- a/setup.py +++ b/setup.py @@ -93,6 +93,7 @@ def _unavailable(self, e): 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', 'Programming Language :: Python :: Implementation :: CPython', 'Programming Language :: Python :: Implementation :: PyPy', 'Natural Language :: English', diff --git a/tox.ini b/tox.ini index 2d5f99b..1033531 100644 --- a/tox.ini +++ b/tox.ini @@ -10,6 +10,7 @@ envlist = py37,py37-pure py38,py38-pure py39,py39-pure + py310,py310-pure pypy pypy3 docs @@ -45,7 +46,8 @@ basepython = python3 skip_install = true deps = check-manifest - check-python-versions + check-python-versions >= 0.19.1 + wheel commands = check-manifest check-python-versions @@ -53,8 +55,6 @@ commands = [testenv:docs] basepython = python3 skip_install = false -# Until repoze.sphinx.autointerface supports Sphinx 4.x we cannot use it: -deps = Sphinx < 4 extras = docs commands_pre =