From a7eef0ef08dd8c1f4c050b06062fddb045a448a9 Mon Sep 17 00:00:00 2001 From: Peter Law Date: Thu, 17 Nov 2022 10:00:40 +0000 Subject: [PATCH 1/3] Fix install of pygame on Python 3.11 See https://github.com/pygame/pygame/issues/3522#issuecomment-1293981862. --- .github/workflows/python-test.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index 14acf96..f7c9ecf 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -37,7 +37,10 @@ jobs: flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics - name: Check with mypy run: | - pip install pygame # Needed for examples + # --pre needed for Python 3.11 which doesn't have wheels (and may not be + # fully supported) in version 2.1.2. Once 2.1.3 is released the --pre + # can be removed. + pip install --pre pygame # Needed for examples mypy pythonosc examples - name: Test with pytest run: | From d8676ffa76998a9d1ea1f1f9fc530c6540d9fcc7 Mon Sep 17 00:00:00 2001 From: Peter Law Date: Thu, 17 Nov 2022 10:16:37 +0000 Subject: [PATCH 2/3] Pin a specific pygame version for Python 3.7 Works around https://github.com/pygame/pygame/issues/3572 --- .github/workflows/python-test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index f7c9ecf..6290470 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -40,7 +40,8 @@ jobs: # --pre needed for Python 3.11 which doesn't have wheels (and may not be # fully supported) in version 2.1.2. Once 2.1.3 is released the --pre # can be removed. - pip install --pre pygame # Needed for examples + # Version pin to 2.1.3-dev4 needed for Python 3.7 due to https://github.com/pygame/pygame/issues/3572 + pip install --pre pygame==2.1.3-dev4 # Needed for examples mypy pythonosc examples - name: Test with pytest run: | From 914efb0c7a696ceb6aad8aad257c6f02833332c5 Mon Sep 17 00:00:00 2001 From: Peter Law Date: Thu, 17 Nov 2022 13:01:16 +0000 Subject: [PATCH 3/3] Only use pygame pre-release on Python 3.11 Works around https://github.com/pygame/pygame/issues/3572 --- .github/workflows/python-test.yml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/python-test.yml b/.github/workflows/python-test.yml index 6290470..d387a55 100644 --- a/.github/workflows/python-test.yml +++ b/.github/workflows/python-test.yml @@ -37,11 +37,16 @@ jobs: flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics - name: Check with mypy run: | - # --pre needed for Python 3.11 which doesn't have wheels (and may not be - # fully supported) in version 2.1.2. Once 2.1.3 is released the --pre - # can be removed. - # Version pin to 2.1.3-dev4 needed for Python 3.7 due to https://github.com/pygame/pygame/issues/3572 - pip install --pre pygame==2.1.3-dev4 # Needed for examples + if [[ "${{ matrix.python-version }}" = "3.11" ]] + then + # --pre needed for Python 3.11 which doesn't have wheels (and may not + # be fully supported) in version 2.1.2. Once 2.1.3 is released this + # can be removed. Due to https://github.com/pygame/pygame/issues/3572 + # we can't apply this for all Python versions. + pip install --pre pygame # Needed for examples + else + pip install pygame # Needed for examples + fi mypy pythonosc examples - name: Test with pytest run: |