actions / actions/setup-python
Difference between env.pythonLocation on macOS in Python 3.11+
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.2k
- Forks
- 739
- Avg merge
- 6d 18h
- Merged PRs (30d)
- 1
Description
Description:
I'm encountering a strange issue related to caching the Python installation. I'm using actions/setup-python@v5.0.0 to install Python, then actions/cache@v4.0.0 to cache the env.pythonLocation directory, similar to this blog.
This works fantastically, except on macOS in Python 3.11 and 3.12, and I have no idea why. For some reason, the cache is empty, but only for those specific versions. Did anything change in the installation layout or env.pythonLocation variable that could explain this?
Action version:
5.0.0
Platform:
- Ubuntu
- macOS
- Windows
Runner type:
- Hosted
- Self-hosted
Tools version:
Python 3.11, 3.12
Repro steps:
The full workflow can be seen here.
Expected behavior:
I would expect this to work for all platforms/Python versions and cache the installed Python packages.
Actual behavior:
The cache is empty. See https://github.com/actions/cache/issues/1176 for the cross-referenced bug report.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the referenced .github/workflows/tests.yaml workflow and compare env.pythonLocation and cache contents for macOS with Python 3.11 and 3.12. Read the cross-referenced actions/cache issue 1176 alongside this report; done means the platform/version-specific behavior is explained and the affected caching behavior has a verified resolution.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, python, typescript
- Domain
- ci-cd, devops
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100