Skip to content

python-version ignored when cache: 'pip' is set #1071

@nisbet-hubbard

Description

@nisbet-hubbard

Description:
We observed that when cache: 'pip' is set, the value of python-version is ignored & the latest version is used instead.

Action version:
v5

Platform:

  • Ubuntu
  • macOS
  • Windows
  • RHEL

Runner type:

  • Hosted
  • Self-hosted

Tools version:

3.10
Repro steps:

- uses: actions/setup-python@v5
   with:
     python-version: '3.10'
     cache: 'pip'

Expected behavior:
Is this the expected behaviour?

Actual behavior:

Run actions/setup-python@v5
  with:
    python-version: 3.13
    cache: pip
    check-latest: false
    token: ***
    update-environment: true
    allow-prereleases: false
    freethreaded: false
  env:
    GITHUB_PAGES: true
Installed versions
  Successfully set up CPython (3.13.2)

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