From b707a6ca7b33eafd6644eff7ef8c3824a4a1b87f Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 11:36:51 -0400 Subject: [PATCH 01/14] GitHub Actions: do not install vcpython27 Microsoft seems to have pulled the compiler download. --- .github/workflows/ci.yml | 27 --------------------------- 1 file changed, 27 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c45ceaa63..6bec373f8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,15 +27,6 @@ jobs: steps: - # Get vcpython27 on Windows + Python 2.7, to build netifaces - # extension. See https://chocolatey.org/packages/vcpython27 and - # https://github.com/crazy-max/ghaction-chocolatey - - name: Install MSVC 9.0 for Python 2.7 [Windows] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' - uses: crazy-max/ghaction-chocolatey@v1 - with: - args: install vcpython27 - # See https://github.com/actions/checkout. A fetch-depth of 0 # fetches all tags and branches. - name: Check out Tahoe-LAFS sources @@ -164,15 +155,6 @@ jobs: steps: - # Get vcpython27 for Windows + Python 2.7, to build netifaces - # extension. See https://chocolatey.org/packages/vcpython27 and - # https://github.com/crazy-max/ghaction-chocolatey - - name: Install MSVC 9.0 for Python 2.7 [Windows] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' - uses: crazy-max/ghaction-chocolatey@v1 - with: - args: install vcpython27 - - name: Install Tor [Ubuntu] if: matrix.os == 'ubuntu-latest' run: sudo apt install tor @@ -242,15 +224,6 @@ jobs: steps: - # Get vcpython27 for Windows + Python 2.7, to build netifaces - # extension. See https://chocolatey.org/packages/vcpython27 and - # https://github.com/crazy-max/ghaction-chocolatey - - name: Install MSVC 9.0 for Python 2.7 [Windows] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' - uses: crazy-max/ghaction-chocolatey@v1 - with: - args: install vcpython27 - - name: Check out Tahoe-LAFS sources uses: actions/checkout@v2 with: From 196ce5103dd203fd7cc59310fa55d3bd851a14d5 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 12:00:11 -0400 Subject: [PATCH 02/14] GitHub Actions: test with 32-bit Python 2.7 on Windows --- .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6bec373f8..9f0515f86 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,10 +35,22 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} + if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} + # We use netifaces, which does not ship a 64-bit wheel for + # Windows, but it ships a 32-bit wheel. Since MS has pulled + # vcpython27 compiler, building a netifaces wheel is not an + # option anymore, so let us test on 32-bit Windows. + - name: Set up Python ${{ matrix.python-version }} [Windows x86] + if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + uses: actions/setup-python@v1 + with: + python-version: ${{ matrix.python-version }} + architecture: x64 + # To use pip caching with GitHub Actions in an OS-independent # manner, we need `pip cache dir` command, which became # available since pip v20.1+. At the time of writing this, @@ -175,10 +187,19 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} + if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} + # See this step under coverage job. + - name: Set up Python ${{ matrix.python-version }} [Windows x86] + if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + uses: actions/setup-python@v1 + with: + python-version: ${{ matrix.python-version }} + architecture: x64 + - name: Get pip cache directory id: pip-cache run: | @@ -230,10 +251,19 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} + if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} + # See this step under coverage job. + - name: Set up Python ${{ matrix.python-version }} [Windows x86] + if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + uses: actions/setup-python@v1 + with: + python-version: ${{ matrix.python-version }} + architecture: x64 + - name: Get pip cache directory id: pip-cache run: | From f4b8780ba7c2ef136f60635c0c9fa56f41197f7c Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 12:00:37 -0400 Subject: [PATCH 03/14] Add newsfragment --- newsfragments/3681.installations | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 newsfragments/3681.installations diff --git a/newsfragments/3681.installations b/newsfragments/3681.installations new file mode 100644 index 000000000..a697e6c60 --- /dev/null +++ b/newsfragments/3681.installations @@ -0,0 +1,3 @@ +Tahoe-LAFS CI now runs tests only on 32-bit Windows. Microsoft has +removed vcpython27 compiler downloads from their site, and Tahoe-LAFS +needs vcpython27 to build and install netifaces on 64-bit Windows. From 106976e8cc8d119025b1dc307bb9a722e26da87d Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 12:17:25 -0400 Subject: [PATCH 04/14] GitHub Actions: use expression syntax Per GitHub documentation: When you use expressions in an if conditional, you may omit the expression syntax (${{ }}) because GitHub automatically evaluates the if conditional as an expression, unless the expression contains any operators. If the expression contains any operators, the expression must be contained within ${{ }} to explicitly mark it for evaluation. https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions --- .github/workflows/ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9f0515f86..61e40fcd0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,7 +35,7 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' + if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -45,7 +45,7 @@ jobs: # vcpython27 compiler, building a netifaces wheel is not an # option anymore, so let us test on 32-bit Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -187,14 +187,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' + if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -251,14 +251,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: matrix.os != 'windows-latest' && matrix.python-version != '2.7' + if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: matrix.os == 'windows-latest' && matrix.python-version == '2.7' + if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} From ed82119f32af602c21201e572a4b2c705d892038 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 13:14:28 -0400 Subject: [PATCH 05/14] GitHub Actions: when in doubt, throw in more parens --- .github/workflows/ci.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 61e40fcd0..b82f3cbda 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,7 +35,7 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} + if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -45,7 +45,7 @@ jobs: # vcpython27 compiler, building a netifaces wheel is not an # option anymore, so let us test on 32-bit Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} + if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -187,14 +187,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} + if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - # See this step under coverage job. + # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} + if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -251,14 +251,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ matrix.os != 'windows-latest' && matrix.python-version != '2.7' }} + if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} + if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} From dec97b3aa119e6f242459d2d188d4c44598778cb Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 13:35:37 -0400 Subject: [PATCH 06/14] GitHub Actions: when in doubt, drop some curly braces --- .github/workflows/ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b82f3cbda..2fe6bf9b0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,7 +35,7 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} + if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -45,7 +45,7 @@ jobs: # vcpython27 compiler, building a netifaces wheel is not an # option anymore, so let us test on 32-bit Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} + if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -187,14 +187,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} + if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} + if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -251,14 +251,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ${{ ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) }} + if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) }} + if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} From 68603fc015898a06d23052735b2059fb880323f6 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 13:41:17 -0400 Subject: [PATCH 07/14] GitHub Actions: just use x86 Python to test on Windows I can't figure out the correct GitHub Actions magic incantation^w^w expression syntax that is needed to isolate (Windows && Python 2.7), so let's just run also run x86 Python 3.6 on Windows. --- .github/workflows/ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2fe6bf9b0..ab0ba3f08 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,7 +35,7 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) + if: ${{ matrix.os != 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -45,7 +45,7 @@ jobs: # vcpython27 compiler, building a netifaces wheel is not an # option anymore, so let us test on 32-bit Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) + if: ${{ matrix.os == 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -187,14 +187,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) + if: ${{ matrix.os != 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) + if: ${{ matrix.os == 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -251,14 +251,14 @@ jobs: fetch-depth: 0 - name: Set up Python ${{ matrix.python-version }} - if: ( matrix.os != 'windows-latest' && matrix.python-version != '2.7' ) + if: ${{ matrix.os != 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} # See this step under coverage job. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ( matrix.os == 'windows-latest' && matrix.python-version == '2.7' ) + if: ${{ matrix.os == 'windows-latest' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} From 1a05fb21de203c9b3c31e8a6143da12a6cd48157 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 14:02:26 -0400 Subject: [PATCH 08/14] Name newsfragment correctly --- newsfragments/{3681.installations => 3681.installation} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename newsfragments/{3681.installations => 3681.installation} (100%) diff --git a/newsfragments/3681.installations b/newsfragments/3681.installation similarity index 100% rename from newsfragments/3681.installations rename to newsfragments/3681.installation From e46e4409c2649dc4549ab256d3dee618fd99dbf7 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 16:39:23 -0400 Subject: [PATCH 09/14] GitHub Actions: really use x86 Python on Windows In a prior commit, I mistakenly used "architecture: x64" instead of "architecture: x86", and tests actually passed. That was surprising, because netifaces do not have amd64_win will on PyPI. But mystery was solved when itamarst pointed out that netifaces wheel (that we previously built) is present on pip cache. But pip cache might be purged one day, and tests will fail again that day. We can't have that, so we will try to stick with x86 for now. --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ab0ba3f08..bfa705d28 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,7 +49,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x64 + architecture: x86 # To use pip caching with GitHub Actions in an OS-independent # manner, we need `pip cache dir` command, which became @@ -198,7 +198,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x64 + architecture: x86 - name: Get pip cache directory id: pip-cache @@ -262,7 +262,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x64 + architecture: x86 - name: Get pip cache directory id: pip-cache From 1531bea63fda3851ed988ac2b97574c413741cbb Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 16:58:24 -0400 Subject: [PATCH 10/14] GitHub Actions: update note about Windows [skip ci] --- .github/workflows/ci.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bfa705d28..2adb22bc8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,10 +40,11 @@ jobs: with: python-version: ${{ matrix.python-version }} - # We use netifaces, which does not ship a 64-bit wheel for - # Windows, but it ships a 32-bit wheel. Since MS has pulled - # vcpython27 compiler, building a netifaces wheel is not an - # option anymore, so let us test on 32-bit Windows. + # We use netifaces, which does not ship a 64-bit wheel for the + # Python 2.7 + Windows combination, but it ships a 32-bit wheel. + # Since MS has removed vcpython27 compiler downloads from their + # usual site, building a netifaces wheel is not an option + # anymore. So let us just test with 32-bit Python on Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] if: ${{ matrix.os == 'windows-latest' }} uses: actions/setup-python@v1 From 65398a2d63bea5e70ec65d767a7d9969d204ea82 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Mon, 26 Apr 2021 17:06:34 -0400 Subject: [PATCH 11/14] GitHub Actions: update note about Windows again --- .github/workflows/ci.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2adb22bc8..eeb6bbe5b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,8 +43,14 @@ jobs: # We use netifaces, which does not ship a 64-bit wheel for the # Python 2.7 + Windows combination, but it ships a 32-bit wheel. # Since MS has removed vcpython27 compiler downloads from their - # usual site, building a netifaces wheel is not an option - # anymore. So let us just test with 32-bit Python on Windows. + # usual download site, building a netifaces wheel locally is not + # an option anymore. So let us just test with 32-bit Python on + # Windows. + # + # It seems that GitHub Actions' expression syntax is not + # expressive enough to select just the (32-bit Python 2.7, + # Windows) combination, so we'd also be switching to (32-bit + # Python 3.6, Windows). - name: Set up Python ${{ matrix.python-version }} [Windows x86] if: ${{ matrix.os == 'windows-latest' }} uses: actions/setup-python@v1 From 73d3295a6ae75de170f629821d315510208c6231 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Tue, 27 Apr 2021 15:49:25 -0400 Subject: [PATCH 12/14] GitHub Actions: use 64-bit Python 3.6 to test on Windows --- .github/workflows/ci.yml | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index eeb6bbe5b..aa128d4ef 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,19 +40,25 @@ jobs: with: python-version: ${{ matrix.python-version }} + # See note below about need for using 32-bit Python 2.7 on + # Windows. The extra handling here for Python 3.6 on Windows is + # because I could not figure out the right GitHub Actions + # expression to do this in a better way. + - name: Set up Python ${{ matrix.python-version }} [Windows x64] + if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '3.6' }} + uses: actions/setup-python@v1 + with: + python-version: ${{ matrix.python-version }} + architecture: x64 + # We use netifaces, which does not ship a 64-bit wheel for the # Python 2.7 + Windows combination, but it ships a 32-bit wheel. # Since MS has removed vcpython27 compiler downloads from their # usual download site, building a netifaces wheel locally is not # an option anymore. So let us just test with 32-bit Python on # Windows. - # - # It seems that GitHub Actions' expression syntax is not - # expressive enough to select just the (32-bit Python 2.7, - # Windows) combination, so we'd also be switching to (32-bit - # Python 3.6, Windows). - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ matrix.os == 'windows-latest' }} + if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} From 3722b8f628472a4c509a78267ae259438046c749 Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Tue, 27 Apr 2021 15:52:28 -0400 Subject: [PATCH 13/14] GitHub Actions: quote architecture Docs for actions/setup-python seem to do that, although inconsistently. --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aa128d4ef..73294b730 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,7 +49,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x64 + architecture: 'x64' # We use netifaces, which does not ship a 64-bit wheel for the # Python 2.7 + Windows combination, but it ships a 32-bit wheel. @@ -62,7 +62,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x86 + architecture: 'x86' # To use pip caching with GitHub Actions in an OS-independent # manner, we need `pip cache dir` command, which became @@ -211,7 +211,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x86 + architecture: 'x86' - name: Get pip cache directory id: pip-cache @@ -275,7 +275,7 @@ jobs: uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - architecture: x86 + architecture: 'x86' - name: Get pip cache directory id: pip-cache From 6d1b95b965f16f7a15a238f8431fa60cb68f9cdf Mon Sep 17 00:00:00 2001 From: Sajith Sasidharan Date: Tue, 27 Apr 2021 16:21:22 -0400 Subject: [PATCH 14/14] GitHub Actions: add more parenthesis https://github.community/t/and-operator-in-if-condition/154825 suggests that adding more parens might work. --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 73294b730..f70432267 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,7 @@ jobs: # because I could not figure out the right GitHub Actions # expression to do this in a better way. - name: Set up Python ${{ matrix.python-version }} [Windows x64] - if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '3.6' }} + if: ${{ ( matrix.os == 'windows-latest' ) && ( matrix.python-version == '3.6' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} @@ -58,7 +58,7 @@ jobs: # an option anymore. So let us just test with 32-bit Python on # Windows. - name: Set up Python ${{ matrix.python-version }} [Windows x86] - if: ${{ matrix.os == 'windows-latest' && matrix.python-version == '2.7' }} + if: ${{ ( matrix.os == 'windows-latest' ) && ( matrix.python-version == '2.7' ) }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }}