Testing against Python 3.11 preview using GitHub Actions

I decided to run my CI tests against the Python 3.11 preview, to avoid the problem I had when Python 3.10 came out with a bug that affected Datasette.

I used the new GitHub Code Search to figure out how to do this. I searched for:

3.11 path:workflows/*.yml

And found this example from urllib3 which showed that the version tag to use is:

3.11-dev

Update 28th Noveber 2022: 3.12-dev now works for Python 3.12 preview

I added that to my test matrix like so:

jobs:
  test:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: ["3.7", "3.8", "3.9", "3.10", "3.11-dev"]
    steps:
    - uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v2
      with:
        python-version: ${{ matrix.python-version }}
    # ...

Here's the full workflow.

Created 2022-02-02T14:20:31-08:00, updated 2022-11-28T22:54:10-08:00 · History · Edit