Skip to content

MacOS self hosted runner using sudo to install Python? #1306

@dnwillia-work

Description

@dnwillia-work

Description:
I'm using setup-python@v5 on a MacOS self hosted runner and when configuring a Python interpreter not previously cached already I'm getting this:

Image

So it's trying to use sudo and interactively asking me for a password to create the new version. I have the cache directory configured properly with write permissions as described in the documentation:

dnwillia@snps-wcvmpdkkvosy Python % pwd
/Users/runner/hostedtoolcache/Python
dnwillia@snps-wcvmpdkkvosy Python % ls -al
total 0
drwxr-xr-x  4 dnwillia  staff  128 Apr 23 14:49 ./
drwxr-xr-x  3 dnwillia  staff   96 Apr 23 13:27 ../
drwxr-xr-x  4 dnwillia  staff  128 Apr 23 14:42 3.10.11/
drwxr-xr-x  4 dnwillia  staff  128 Apr 23 14:49 3.13.13/

I managed to get 3.13 installing by interactively starting the runner and typing in the password manually when the action was executed. This allowed things to proceed correctly after the 3.13.13 area was created.

Looking at the issues this kind of smells like #1301 too. The symlinks are created in my case though once I type a password.

Action version:
v5

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
See above, Python 3.13.

Repro steps:
Just create a basic action using setup-python@v5 to install a Python interpreter.

Expected behavior:
The interpreter installs correctly.

Actual behavior:
The interpreter does not get installed and the workflow stops execution.

Metadata

Metadata

Assignees

No one assigned

    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