Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python with architecture 'arm64' was not found for Ubuntu #2053

Closed
fareshan opened this issue Oct 18, 2023 · 5 comments
Closed

Python with architecture 'arm64' was not found for Ubuntu #2053

fareshan opened this issue Oct 18, 2023 · 5 comments
Labels
kind/bug Something isn't working

Comments

@fareshan
Copy link

Bug report info

act version:            0.2.52
GOOS:                   darwin
GOARCH:                 arm64
NumCPU:                 8
Docker host:            DOCKER_HOST environment variable is not set
Sockets found:
        /var/run/docker.sock
        $HOME/.docker/run/docker.sock
Config files:           
        /Users/fareshantous/.actrc:
                -P ubuntu-latest=catthehacker/ubuntu:act-latest
                -P ubuntu-22.04=catthehacker/ubuntu:act-22.04
                -P ubuntu-20.04=catthehacker/ubuntu:act-20.04
                -P ubuntu-18.04=catthehacker/ubuntu:act-18.04
Build info:
        Go version:            go1.20.8
        Module path:           github.com/nektos/act
        Main version:          (devel)
        Main path:             github.com/nektos/act
        Main checksum:         
        Build settings:
                -buildmode:           exe
                -compiler:            gc
                -ldflags:             -s -w -X main.version=0.2.52 -X main.commit=44ea01c2097eaad1596f4dafd6ec84872bd00402 -X main.date=2023-10-01T02:15:30Z -X main.builtBy=goreleaser
                CGO_ENABLED:          0
                GOARCH:               arm64
                GOOS:                 darwin
                vcs:                  git
                vcs.revision:         44ea01c2097eaad1596f4dafd6ec84872bd00402
                vcs.time:             2023-10-01T02:15:05Z
                vcs.modified:         false
Docker Engine:
        Engine version:        24.0.6
        Engine runtime:        runc
        Cgroup version:        2
        Cgroup driver:         cgroupfs
        Storage driver:        overlay2
        Registry URI:          https://index.docker.io/v1/
        OS:                    Docker Desktop
        OS type:               linux
        OS version:            
        OS arch:               aarch64
        OS kernel:             6.4.16-linuxkit
        OS CPU:                8
        OS memory:             7851 MB
        Security options:
                name=seccomp,profile=unconfined
                name=cgroupns

Command used with act

act -j ci-workflow

Describe issue

I get this error :
The version '3.11.5%0A' with architecture 'arm64' was not found for Ubuntu 22.04.%0AThe list of all available versions can be found here: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json

I tried different versions of Python and Ubuntu with the same result.

I have an apple M1 chip.

Link to GitHub repository

No response

Workflow content

---
name: Top-level CI
on:
  workflow_dispatch:
  pull_request:
  push:
    branches: main  # Comment this line if you want to test the CI before opening a PR

jobs:
  ci-global:
    runs-on: ubuntu-22.04
    timeout-minutes: 10

    steps:
      - name: Checkout
        uses: actions/checkout@v3

      - name: Setup Python
        uses: actions/setup-python@v4
        timeout-minutes: 5
        with:
          python-version-file: .python-version
          cache: 'pip'
          cache-dependency-path: |
            pip-requirements.txt
            dev-requirements.txt

      - name: Install Python dependencies
        run: |
          pip install -r pip-requirements.txt
          pip install -r dev-requirements.txt

      # in order to test the template as well, we create a temporary library in the CI
      - name: Create library with template
        run: |
          cookiecutter --no-input templates/pylibrary --output-dir libs/
          git add libs/library_name  # So that checks below apply to generated library

      - name: Format Python imports
        run: |
          isort --check-only $(git ls-files "*.py")

      - name: Format Python
        run: |
          black --check $(git ls-files "*.py")

      - name: Lint Python
        run: |
          flake8 $(git ls-files "*.py")

      # Are all public symbols documented? (see top-level pyproject.toml configuration)
      - name: Lint Python doc
        run: |
          pylint $(git ls-files "*.py")

Relevant log output

[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.6.10 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.6.9 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.6.8 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.6.7 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.5.10 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.5.9 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.5.4 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.4.10 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.4.4 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.3.7 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.3.5 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.2.5 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.1.4 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::check 3.0.1 satisfies 3.11.5%0A
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   💬  ::debug::OS Name: Ubuntu, Version: 22.04
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   ❗  ::error::The version '3.11.5%0A' with architecture 'arm64' was not found for Ubuntu 22.04.%0AThe list of all available versions can be found here: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template]   ❌  Failure - Main Setup Python
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] exitcode '1': failure
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] Loading revision from git directory
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] Found revision: ab77e7f2f337c6264959ed1a66b5a6606d245fb3
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] HEAD points to 'ab77e7f2f337c6264959ed1a66b5a6606d245fb3'
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] using github ref: refs/heads/main
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] Found revision: ab77e7f2f337c6264959ed1a66b5a6606d245fb3
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] Loading revision from git directory
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] Found revision: ab77e7f2f337c6264959ed1a66b5a6606d245fb3
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] HEAD points to 'ab77e7f2f337c6264959ed1a66b5a6606d245fb3'
[ci-libs-activity-area-streamlit/Reusable Python library CI/local-ci-py-template] [DEBUG] using github ref: refs/heads/main

Additional information

Chip : Apple M1
OS : Ventura 13.4.1

@fareshan fareshan added the kind/bug Something isn't working label Oct 18, 2023
@Ancient123
Copy link

I think this problem might possibly be related to this bug. ( ::error::The version '3.11.5%0A' is very curious)
actions/setup-python#628

Try removing the newline from the end of your .python-version file and see if the issue goes away.

@fareshan
Copy link
Author

Thanks @Ancient123 , it fixes a part of the issue but it still does not find the 3.11.5 version. Now I get ::error::The version '3.11.5' with architecture 'arm64' was not found for Ubuntu 22.04.%0AThe list of all available versions can be found here: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json

@TimidRobot
Copy link

On Apple M1 Pro running macOS Sonoma 14.0 (23A344).

I have (https://github.com/creativecommons/ccos-scripts/tree/main/.github/workflows):

    - name: Install Python 3.11
      uses: actions/setup-python@v4
      with:
        python-version: '3.11'

and receive the error message excerpt:

❗  ::error::The version '3.11' with architecture 'arm64' was not found for
    Ubuntu 22.04.%0AThe list of all available versions can be found here:
    https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json

unfortunately, https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json does not contain 3.11 for linux/arm64 and act refuses to honor --container-architecture linux/x64:

Error: failed to create container: 'Error response from daemon: image with
       reference ghcr.io/catthehacker/ubuntu:act-latest was found but does not
       match the specified platform: wanted linux/x64, actual: linux/arm64'

@ChristopherHX
Copy link
Contributor

--container-architecture linux/x64

FYI x64 is windows slang use --container-architecture linux/amd64

No docker refuses not act.

@fareshan
Copy link
Author

Thanks to your comments, I understood that I had to add --container-architecture linux/amd64 to solve my issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants