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

Version 3.10 with arch x64 not found #401

Closed
2 of 5 tasks
BlueskyFR opened this issue May 4, 2022 · 18 comments
Closed
2 of 5 tasks

Version 3.10 with arch x64 not found #401

BlueskyFR opened this issue May 4, 2022 · 18 comments
Assignees
Labels
bug Something isn't working

Comments

@BlueskyFR
Copy link

BlueskyFR commented May 4, 2022

Description:
Version 3.10 with arch x64 is not found when running on self-hosted runner.

Action version: latest

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:

3.10, altough it seems like all versions are affected

Repro steps:
A description with steps to reproduce the issue. If your have a public example or repo to share, please provide the link.

- name: Set up Python 3.10
        uses: actions/setup-python@v3
        with:
          python-version: "3.10"
          cache: "pip"

Expected behavior:
Version should be fetched correctly.

Actual behavior:
The 3.10 version for x64 exists but the error says otherwise.

@BlueskyFR BlueskyFR added bug Something isn't working needs triage labels May 4, 2022
@dsame
Copy link
Contributor

dsame commented May 5, 2022

hello @BlueskyFR , can you please provide addional info about the ubuntu version of self-hosted runner?

@BlueskyFR
Copy link
Author

Sure, it is actually not Ubuntu but Debian Buster

@dsame
Copy link
Contributor

dsame commented May 6, 2022

@BlueskyFR while i am reproducing the problem can please try quick solution of the setting AGENT_TOOLSDIRECTORY to /opt/hostedtoolcache (i assume you still use Debian), namely:

- name: Set up Python 3.10
        uses: actions/setup-python@v3
        with:
          python-version: "3.10"
          cache: "pip"
       env:
          AGENT_TOOLSDIRECTORY: /opt/hostedtoolcache

If this helps the original issue should be solved as soon as #394 merged

@TechDawg270
Copy link

TechDawg270 commented May 12, 2022

I am still experiencing the issue. Tried both with the env var mentioned above, and also without

- uses: actions/setup-python@v3
        with:
          python-version: '3.10'
          architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
        env:
          AGENT_TOOLSDIRECTORY: /opt/hostedtoolcache

@dsame
Copy link
Contributor

dsame commented May 17, 2022

@BlueskyFR @TechDawg270

It is confirmed the problem relates to Debian boosters

Succees on Ubuntu-20
Fail on Debian 10.12

We need a bit more time to investigate the problem with the specific distro

@deepankur797
Copy link

@dsame For me it is failing even on Ubuntu-20.04

Description:
Version 3.10 with arch x64 is not found when running on act locally.

Action version: latest

Platform:

  • Ubuntu

Runner type:

  • Locally

Tools version:

3.10, although it seems like all versions are affected

Repro steps:
A description with steps to reproduce the issue. If your have a public example or repo to share, please provide the link.

- name: setup python uses: actions/[email protected] with: python-version: "3.x" cache: "pip" env: AGENT_TOOLSDIRECTORY: /opt/hostedtoolcache

Expected behaviour:
The version should be fetched correctly.

Actual behaviour:
The 3.10 version for x64 exists but the error says otherwise.

@dsame
Copy link
Contributor

dsame commented Jun 7, 2022

@deepankur797 , thanks for you input, can you please add the exact step you use to setup python?

@deepankur797
Copy link

I have used the following code in my job


steps:
  -name: setup python
   uses: actions/setup-python@v3
   with:
     python-version: "3.x"
     cache: "pip"
   env:
     AGENT_TOOLSDIRECTORY: /opt/hostedtoolache

@dsame
Copy link
Contributor

dsame commented Jun 9, 2022

@BlueskyFR @TechDawg270

The short story: Debian is not supported, sorry

The only workaround is - either to use Ubuntu for self-hosted machine (any virtualisation works fine) or to install python from the Debian specific repositories.

Long story:
The exact reason is the parsing /etc/os-release and extracting VERSION_ID: while we expect one of "18.04", "20.04" or "22.04" the debian provides "10" and there's no python matched to this version id.

The worst part is we hardly can fix the code because the python from tool cache is built against the libraries specific to the distribution and there's no certainty that the python will work the libraries from the other distribution.

@dsame
Copy link
Contributor

dsame commented Jun 9, 2022

@deepankur797

The step works without problem on Ubuntu 20.04

      - name: Set up Python 3.10
        uses: actions/setup-python@v3
        with:
          python-version: "3.10"
          architecture: "x64"
        env:
          AGENT_TOOLSDIRECTORY: /opt/hostedtoolcache

Can you please confirm you created opt/hostedtoolcache folder and grant the write permission to the user of the runner on this folder?

@deepankur797
Copy link

@dsame thanks for the help it is working now. It was an issue created by some misconfig in the .actrc file as it was using the wrong image. It was overriding the ubuntu image using -P flag.

@dsame
Copy link
Contributor

dsame commented Jun 9, 2022

@BlueskyFR @TechDawg270

PR actions/toolkit#1112 adds the debug message to clarify the reason the action fails. It is the best we can do for now according to the issue.

@dsame
Copy link
Contributor

dsame commented Jun 27, 2022

Hello @BlueskyFR i am going to close this issue because it seems to be resolved and there's no other comments so far. Feel free to open new issue or reopen this one in case of any problem

@Yarden-zamir
Copy link

To be clear, other distros are officially NOT supported?

@dsame
Copy link
Contributor

dsame commented Aug 10, 2022

Hello @Yarden-zmr ,

You are right. All the binaries are built against Ubuntu provided packages.

min-xu-ai pushed a commit to facebookresearch/fairscale that referenced this issue Dec 5, 2022
* Fix gradient accumulation

Add ``is_scaled_loss`` flag to support both scaled / unscaled loss
Fix ``test_grad_accum`` and``test_set_num_gradients_to_accumulate``

* Add a method to scale grad for grad_accum using unscaled loss

- Revert the changes in `step` method
- Add a method `scale_grad_by_num_grads_to_accum`to handle gradient accumulation using unscaled loss more explicitly
- Add gradient tests

* Implement _compute_corr_mean_between_grads

* Improve tests and comments

* Use ubuntu-20.04 instead of latest

Use ubuntu-20.04 to fix the `arch x64 not found` issue
[Version 3.10 with arch x64 not found actions/setup-python#401](actions/setup-python#401)

* Switch flake8 from gitlab to github

Flake8 was moved to Github
See discussions https://www.reddit.com/r/Python/comments/yvfww8/flake8_took_down_the_gitlab_repository_in_favor/

* Fix scikit-learn package

* Update PyTorch versions

* Resolve comments from Min

* Minor fix

* Disable broken tests for new versions of PyTorch
MerkulovDaniil added a commit to MerkulovDaniil/merkulovdaniil.github.io that referenced this issue Dec 6, 2022
Use ubuntu-20.04 to fix the `arch x64 not found` issue
[Version 3.10 with arch x64 not found actions/setup-python#401](actions/setup-python#401)
hussein-awala added a commit to hussein-awala/airflow that referenced this issue Aug 13, 2023
hussein-awala added a commit to hussein-awala/airflow that referenced this issue Aug 13, 2023
This reverts commit f31ddba3e56b019939094fe6559ae5f0eda22d92.
@floptical
Copy link

floptical commented Sep 14, 2023

This is currently failing with Python3.10 and trying to use the latest ubuntu version (which I'm reading is 22.04) from Github-hosted runners. Tried the following:

With v3:

jobs:
  deploy:
    name: deploy
    runs-on: ubuntu-latest
    steps:
      - name: Setup Python 3.10
        uses: actions/setup-python@v3
        with:
          python-version: 3.10

Error:

Version 3.1 was not found in the local cache
Error: Version 3.1 with arch x[6](repo_url)4 not found
The list of all available versions can be found here: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json

With v4:

jobs:
  deploy:
    name: deploy
    runs-on: ubuntu-latest
    steps:
      - name: Setup Python 3.10
        uses: actions/setup-python@v4
        with:
          python-version: 3.10

Error:

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

Edit:

Fixed by using ubuntu-20.04 and specifying my full python version, "3.10.12" instead of "3.10"

ExtremeMachine12 added a commit to tanmaypardeshi/CSC-510-Project2-TeachersPetBot that referenced this issue Oct 16, 2023
Downgrading to python 3.9 since 3.10 literally does not work on the latest ubuntu. See this link if you don't believe it: actions/setup-python#401
@francesco-ballarin
Copy link

This is currently failing with Python3.10 and trying to use the latest ubuntu version (which I'm reading is 22.04) from Github-hosted runners. Tried the following:
...

jobs:
  deploy:
    name: deploy
    runs-on: ubuntu-latest
    steps:
      - name: Setup Python 3.10
        uses: actions/setup-python@v4
        with:
          python-version: 3.10

Error:

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

The solution is to quote 3.10, i.e.

       - name: Setup Python 3.10
         uses: actions/setup-python@v4
         with:
           python-version: "3.10"

otherwise it gets interpreted as a floating point number, and 3.10 (or 3.100, for that matter) becomes 3.1.

Answering a few months later, because I had the same issue and searching on google for "Version 3.1 was not found in the local cache" has the above post as the first link in the results.

achantavy added a commit to cartography-cncf/cartography that referenced this issue Feb 22, 2024
Similar issue as this:
actions/setup-python#401 (comment)

`3.10` gets interpreted as `3.1` when I want it to be `"3.10"`.
t-chito added a commit to t-chito/Carrier-Owl that referenced this issue Mar 2, 2024
@rwader-swi
Copy link

why is this issue closed? It is still not supported for debian even when python versions are available

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

No branches or pull requests

9 participants