8000 `$pythonLocation/python` does not exist for pypy3.11 on ubuntu-latest · Issue #1138 · actions/setup-python · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
$pythonLocation/python does not exist for pypy3.11 on ubuntu-latest #1138
Open
@bkeryan

Description

@bkeryan

Description:
For most Python versions, $pythonLocation/python is a symlink to the Python binary, but it does not exist for pypy3.11 on ubuntu-latest.

Action version:
v5.6.0

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
pypy3.11

Repro steps:
https://github.com/ni/python-actions/blob/19f10ada84cc1b9a8ad848244dee3a39e67ccdec/.github/workflows/test_actions.yml#L215

  test_python_location:
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [windows-latest, ubuntu-latest]
        python-version: [3.11, pypy3.11]
    steps:
      - uses: actions/setup-python@v5.6.0
        with:
          python-version: ${{ matrix.python-version }}
      - run: ls -al "$pythonLocation"
        shell: bash
      - run: |
          "$pythonLocation/python" -V
        shell: bash

Expected behavior:
The directory contains the python symlink or stub and it successfully prints the Python version.

windows-latest, 3.11:

Run ls -al $pythonLocation
total 33396
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 .
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:17 ..
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 DLLs
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 Doc
-rw-r--r-- 1 runneradmin 197121    36874 Apr  2  2024 LICENSE.txt
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 Lib
-rw-r--r-- 1 runneradmin 197121  1563659 Apr  2  2024 NEWS.txt
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 Scripts
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 Tools
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 include
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 libs
-rwxr-xr-x 1 runneradmin 197121 26216840 Jul 15  2024 python-3.11.9-amd64.exe
-rwxr-xr-x 1 runneradmin 197121   103192 Apr  2  2024 python.exe
-rwxr-xr-x 1 runneradmin 197121    67352 Apr  2  2024 python3.dll
lrwxrwxrwx 1 runneradmin 197121       55 Jun  9 23:14 python3.exe -> /c/hostedtoolcache/windows/Python/3.11.9/x64/python.exe
-rwxr-xr-x 1 runneradmin 197121  5800216 Apr  2  2024 python311.dll
-rwxr-xr-x 1 runneradmin 197121   101656 Apr  2  2024 pythonw.exe
drwxr-xr-x 1 runneradmin 197121        0 Jun  9 23:14 tcl
-rwxr-xr-x 1 runneradmin 197121   119192 Apr  2  2024 vcruntime140.dll
-rwxr-xr-x 1 runneradmin 197121    49528 Apr  2  2024 vcruntime140_1.dll

windows-latest, pypy3.11:

Run ls -al $pythonLocation
total 46021
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 .
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 ..
-rw-r--r-- 1 runneradmin 197121    13385 Feb 26 13:04 LICENSE
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 Lib
-rw-r--r-- 1 runneradmin 197121        6 Jun 16 17:33 PYPY_VERSION
-rw-r--r-- 1 runneradmin 197121     1143 Feb 26 13:04 README.rst
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 Scripts
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 include
-rwxr-xr-x 1 runneradmin 197121    27648 Feb 26 13:04 libffi-8.dll
-rwxr-xr-x 1 runneradmin 197121 46200832 Feb 26 13:04 libpypy3.11-c.dll
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 libs
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pypy.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pypy3.11.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pypy3.11w.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pypy3.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pypyw.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 python.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 python3.11.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 python3.exe
-rwxr-xr-x 1 runneradmin 197121    81408 Feb 26 13:04 pythonw.exe
drwxr-xr-x 1 runneradmin 197121        0 Jun 16 17:33 tcl

ubuntu-latest, 3.11:

Run ls -al $pythonLocation
total 26968
drwxrwxrwx+ 6 runner runneradmin     4096 Jun  9 10:06 .
drwxrwxrwx+ 3 runner runneradmin     4096 Jun  9 10:06 ..
-rwxrwxrwx  1 runner runneradmin 26581523 Jun  9 10:06 Python-3.11.13.tgz
drwxrwxrwx+ 2 runner runneradmin     4096 Jun  9 10:06 bin
-rwxrwxrwx  1 runner runneradmin   358758 Jun  9 10:06 build_output.txt
drwxrwxrwx+ 3 runner runneradmin     4096 Jun  9 10:06 include
drwxrwxrwx+ 4 runner runneradmin     4096 Jun  9 10:06 lib
lrwxrwxrwx  1 runner runneradmin       16 Jun  9 10:06 python -> ./bin/python3.11
drwxrwxrwx+ 3 runner runneradmin     4096 Jun  9 10:06 share
-rwxrwxrwx  1 runner runneradmin   644183 Jun  9 10:06 tools_structure.txt

Actual behavior:

The directory does not contain the python symlink and running "$pythonLocation/python" -V fails with "no such file or directory".

ubuntu-latest, pypy3.11:

Run actions/setup-python@v5.6.0
Installed versions
  PyPy version 3.11 (x) was not found in the local cache
  Downloading PyPy from "https://downloads.python.org/pypy/pypy3.11-v7.3.19-linux64.tar.bz2" ...
  Extracting downloaded archive...
  /usr/bin/tar x --warning=no-unknown-keyword --overwrite -C /home/runner/work/_temp/5109c90c-7960-4345-a70e-f60d28f861f6 -f /home/runner/work/_temp/faa5f69f-d068-4dbb-86eb-edb3078d1b5d
  Creating symlinks...
  Installing and updating pip
  /opt/hostedtoolcache/PyPy/3.11.11/x64/bin/python -m ensurepip
  Looking in links: /tmp/tmp7d44vzhy
  Processing /tmp/tmp7d44vzhy/setuptools-65.5.0-py3-none-any.whl
  Processing /tmp/tmp7d44vzhy/pip-24.0-py3-none-any.whl
  Installing collected packages: setuptools, pip
  Successfully installed pip-24.0 setuptools-65.5.0
  /opt/hostedtoolcache/PyPy/3.11.11/x64/bin/python -m pip install --ignore-installed pip
  Collecting pip
    Downloading pip-25.1.1-py3-none-any.whl.metadata (3.6 kB)
  Downloading pip-25.1.1-py3-none-any.whl (1.8 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.8/1.8 MB 39.2 MB/s eta 0:00:00
  Installing collected packages: pip
  Successfully installed pip-25.1.1
  Successfully set up PyPy 7.3.19 with Python (3.11.11)
Run ls -al "$pythonLocation"
total 44
drwxrwxrwx+ 5 runner docker  4096 Jun 16 17:51 .
drwxrwxrwx+ 3 runner docker  4096 Jun 16 17:51 ..
-rw-r--r--+ 1 runner docker 12800 Jun 16 17:51 LICENSE
-rw-rw-rw-+ 1 runner docker     6 Jun 16 17:51 PYPY_VERSION
-rw-r--r--+ 1 runner docker  1143 Jun 16 17:51 README.rst
drwxr-xr-x+ 2 runner docker  4096 Jun 16 17:51 bin
drwxr-xr-x+ 3 runner docker  4096 Jun 16 17:51 include
drwxr-xr-x+ 5 runner docker  4096 Jun 16 17:51 lib
Run "$pythonLocation/python" -V
/home/runner/work/_temp/e346c099-c7a4-4c91-bc09-2ddd1d59b6ee.sh: line 1: /opt/hostedtoolcache/PyPy/3.11.11/x64/python: No such file or directory
Error: Process completed with exit code 127.

Workaround

  • Don't use $pythonLocation with PyPy
  • Use $pythonLocation/bin/python or $pythonLocation/Scripts/python depending on OS

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0