actions/setup-python

Python3.9 on aarch64 for macOS 13.4.1.

tvorogme opened this issue ยท 23 comments

Description:
Error: The version '3.9' with architecture 'arm64' was not found for macOS 13.4.1.

Action version:
'actions/setup-python@v4' (SHA:bd6b4b6205c4dbad673328db7b31b7fab9e241c0)

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
(aarch64, macOS, Python3.9)

Repro steps:

      - uses: actions/setup-python@v4
        with:
          python-version: "3.9"

Expected behavior:
Successfully installed python

Actual behavior:
Error message

Hello, @tvorogme ! Thank you for creating this issue, we'll investigate it and see what can be done :)

@dusan-trickovic hey! When approximately can we expect a fix? I really need this container for cross-platform distribution of the package.

Hello @tvorogme ! Thank you for reaching out and I apologize for a later response. I will consult with the team regarding this and get back to you with our findings as soon as possible. Thank you for your patience and cooperation on this :)

EDIT: In case there were any recent developments / updates regarding this issue, please feel free to let us know about it

Hello again, @tvorogme ! I just wanted to check in with you and ask you if you could please try using Python version such as 3.10.11 in your workflow? From the description of your problem, it seems as though that version of Python just simply doesn't exist for your specific architecture in the versions repository (while there is an arm64 option for 3.10.11 for darwin).

Newer versions (such as 3.11 and 3.12 alpha and beta) also seem to have support for arm64, but I suggested 3.10.11 as it is the closest to the one you need. If it won't affect your own personal requirements for the project, I would suggest trying to use the suggested version and seeing if that fixes the error you've encountered.

If you encounter any more issues (similar to this or otherwise), please don't hesitate to reach out again. On the other hand, if this solved your issue, you can also let us know about it so that we can close it.

Thank you very much for your cooperation :)

@dusan-trickovic hey! Glad you right back.

Thanks for the idea, but it doesn't work for me. We are developing a package that should be available on: Windows / Linux / macOS. Since we work with pybind11 we are tied to the major python releases, so we support py3.9 / py3.10 / py3.11. If we make a package for py3.10 it means it won't work for py3.9.

As a temporary solution, I made a separate workflow just for macOS aarch64 / x86_64 that installs python3.9 from brew, because it's not working from actions/setup-python. But it's very ugly.

Your workflow works for all other versions, and it's very cool.

You also can look at status of python versions, the Python3.9 is not end-of-life status.

Screenshot 2023-07-15 at 11 01 42 AM

Hello again @tvorogme ! I just wanted to drop an update here and say that, at this time, we only have arm64 support for versions 3.10 and later. Therefore, although 3.10 and 3.11 fit this criteria, 3.9 unfortunately doesn't, though we will investigate that too in the future.

Thank you very much for your time and cooperation :)

I can't believe this is still a problem 3 years after Python started supporting the M1 architecture.

However, it's not just Apple hardware having problems as I have issues with major version numbers such as version '3.10' with architecture 'arm64' was not found for Debian 12.

at this time, we only have arm64 support for versions 3.10 and later

Is there a timeline on getting support for installing 3.8 and 3.9 in mac arm runners? We wanted to automate the build and upload of our Python package but doing it only for >= 3.10 and having to manually build and upload for lower versions wouldn't be of much value ๐Ÿฅฒ

i'm getting the same for 3.9 on Debian 12๐Ÿ˜ž

For anyone else with this problem, we resolved to drop setup-python and just install python, pip, and poetry manually. Full working example here: https://github.com/google/temporian/blob/main/.github/workflows/publish.yaml

build-macos-arm:
    runs-on: macos-13-xlarge
    strategy:
      matrix:
        python-version: ["3.8", "3.9", "3.10", "3.11"]
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Install Python
        run: |
          brew update
          brew install python@${{ matrix.python-version }}

      - name: Install pip
        run: |
          curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
          python${{ matrix.python-version }} get-pip.py

      - name: Install poetry
        run: pip install poetry

Are you all using v5 of the Action??

uses: actions/setup-python@v5

We were using v4 before switching to the manual installations, haven't tried v5 on arm

I also just got hit by this for all 3.7-3.9 versions after using macos-latest successfully for year or so in GHA.
I'm testing library that deals with some low level filesystem handling at times, hence why testing on multiple platforms on multiple python versions is essential and not optional.

I can understand python versions beyond EoL not working, but it is disappointing to see others stopped working as well.
To make matters worse, since my workflow uses multiple repositories and jobs, it seems I'm only seeing this error out on some, and not others, probably caused by incremental rollout of macos 14 .

I also test pypy3.9 and pypy3.10 - should I expect pypy3.9 to stop working on macos-latest any day now as well? Where can I find the support matrix?

We observe the same issue as @mjurbanski-reef - we've been running Python 3.8 + 3.9 successfully last year, but it appears the macos 14 rollout broke the CI together with the missing python arm builds last night.

  Version 3.8 was not found in the local cache
  Error: The version '3.8' with architecture 'arm64' was not found for macOS 14.4.1.
  The list of all available versions can be found here: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json

EDIT:
went for now with:

    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ ubuntu-latest, windows-latest, macos-13, macos-14]
        python-version: [ '3.8', '3.9', '3.10', '3.11' ]
        exclude:
          - os: macos-13
            python-version: '3.10'
          - os: macos-13
            python-version: '3.11'
          - os: macos-14
            python-version: '3.8'
          - os: macos-14
            python-version: '3.9'

Same here:
Error: The version '3.9' with architecture 'arm64' was not found for macOS 14.4.1.

EDIT:
I think they are removing 3.9 and 3.10 (UPDATE: 3.10 is supported) support for macos 14. They also removed 3.9 and 3.10 supports in the docs last week (1, 2.)

For now, @pd-nisse's solution seems to be working.

#3763 also refers to substituting macos-latest with macos-13.

Links:

EDIT:
I think they are removing 3.9 and 3.10 support for macos 14.

See upthread, macOS 14 never had 3.9 and 3.10: #696 (comment)

I just wanted to drop an update here and say that, at this time, we only have arm64 support for versions 3.10 and later. Therefore, although 3.10 and 3.11 fit this criteria, 3.9 unfortunately doesn't, though we will investigate that too in the future.


They also removed 3.9 and 3.10 supports in the docs last week (1, 2.)

I don't think think those docs every claimed 3.9 or 3.10 support? I don't see it in the Git log.

I don't think think those docs every claimed 3.9 or 3.10 support? I don't see it in the Git log.

Yes @hugovk, you are right. I misunderstood this with not supporting 3.10.

Also, is there going to be a support matrix?

This should be fixed by PR

see #808 (comment):

actions/python-versions#214 enabled 3.8 & 3.9 for macOS arm64. It's probably a matter of starting the builds there ?

The build for 3.8 & 3.9 was broken by actions/python-versions#223 I opened actions/python-versions#259 so it's now a matter for maintainers to review that PR then start a build.

Adding some more data to this conversation.
Looking at stats from the requests library: https://pypistats.org/packages/requests
There are still 1-2% of the downloads for python 2, somehow.
On the 3.x minor versions I see:

  • 3.10: 19.3%
  • 3.7: 18.4%
  • 3.8: 15.6%
  • 3.9: 14.8%
  • 3.11: 13.6%
  • 3.12: 7%
  • 3.6: 6%

There are still 30% of the downloads that come from python 3.8 and 3.9. While I agree that 3.7 and older can be considered obsolete since they are no longer getting security updates, the 3.8 and 3.9 versions should still be considered first class.

Hello Everyone, We have already added arm64 support for Python version 3.9. Please find the attached screenshot for reference. Please validate from your end and confirm.

Screenshot 2024-08-20 at 6 56 37โ€ฏPM

Thanks @hugovk for the confirmation and proceeding to close the issue as issue addressed and confirmed.