Repository: tahoe-lafs/zfec (language: python)

Issue:
add Python 3.11 support
It works fine for me with 3.10.6, but with python 3.11 it doesn't install. Edit: see exarkuns comment. I did change the Issue name.
Update GA workflow actions
Splitting #75 into three separate issues. This is part 1:

- Many workflow actions are considered outdated because of https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/.
- Since v1. 9.0, cibuildwheel itself has a GitHub Action (https://cibuildwheel.readthedocs.io/en/stable/changelog/#v190), using which we can reduce some boilerplate.
- OS versions used in test and build workflows have diverged.
- Relatedly, maybe we should not be using GitHub's interpretation of `-latest` versions of OSes (which can change over time, although with enough warning), and should be more explicit about which version of an OS we're using: `ubuntu-22.04` instead of `ubuntu-latest` etc.  Since zfec development moves at a slower rate than GitHub's development, we will not get a surprise breakage when occasionally revisiting zfec.


Discussion / hints:
This is expected.  zfec is not yet tested against Python 3.11.  This ticket could be retitled to "add Python 3.11 support" and someone could do the necessary CI setup, fix any issues, and make a release happen.

@MironBodewes It may interest you that `zfex`, a fork of `zfec` which I maintain, builds and installs with cpython 3.11.
Did a quick test on macOS (arm64) and Fedora 37 (x86_64). With Python 3.11, `pip install zfec` does install from the sdist package when a C compiler is available, so the issue must be that there are no wheel packages for Python 3.11?

I suppose can can do some things:

- Add Python 3.10 and Python 3.11 to the "test" workflow.
- Update cibuildwheel in the "build" workflow (they're now at 2.x releases, and we're pinned at 1.6.4) and until it magically makes py310 and py311 wheels.  There's also a `pypa/cibuildwheel@version` action now, which simplifies things.

We could also look into abi3 wheels again (#49), now that cibuildwheel has support for it.


Fix patch:
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 01c5292..42313ae 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -43,8 +43,10 @@ jobs:
           - "cp38-*"
           - "cp39-*"
           - "cp310-*"
+          - "cp311-*"
           - "pp37-*"
           - "pp38-*"
+          - "pp39-*"
 
     steps:
       - name: Check out zfec sources
@@ -55,7 +57,7 @@ jobs:
           fetch-depth: 0
 
       - name: Build wheels
-        uses: pypa/cibuildwheel@v2.3.1
+        uses: pypa/cibuildwheel@v2.11.3
         with:
           output-dir: wheelhouse
         env:


Test patch:
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 0feafa0..4a51f14 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -25,8 +25,10 @@ jobs:
           - "3.8"
           - "3.9"
           - "3.10"
+          - "3.11"
           - "pypy-3.7"
           - "pypy-3.8"
+          - "pypy-3.9"
 
     steps: