Skip to content

Cache location /home/ubuntu/.cache/pypoetry/virtualenvs invalid when virtualenvs.create = false #1077

Closed
@pascalgulikers

Description

@pascalgulikers

Description:
The post step throws "Error: Cache folder path is retrieved for poetry but doesn't exist on disk: /home/ubuntu/.cache/pypoetry/virtualenvs. This likely indicates that there are no dependencies to cache. Consider removing the cache step if it is not needed."

But I've specified virtualenvs.create = false

Action version:
v5.5.0

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
3.13

Repro steps:
Run snok/install-poetry@v1.4.1
with:
version: 1.8.5
virtualenvs-create: false
virtualenvs-in-project: false
installer-parallel: true
virtualenvs-path: {cache-dir}/virtualenvs
env:
GITHUB_TOKEN: ***
VENV: .venv/bin/activate

Run actions/setup-python@v5
with:
python-version: 3.13
cache: poetry
check-latest: false
token: ***
update-environment: true
allow-prereleases: false
freethreaded: false
env:
GITHUB_TOKEN: ***
VENV: .venv/bin/activate

Expected behavior:
To succesfully install Python 3.13 with poetry as cache

Actual behavior:

Installed versions
Version 3.13 was not found in the local cache
Version 3.13 is available for downloading
Download from "https://github.com/actions/python-versions/releases/download/3.13.2-13708744326/python-3.13.2-linux-22.04-x64.tar.gz"
Extract downloaded archive
/usr/bin/tar xz --warning=no-unknown-keyword --overwrite -C /home/ubuntu/_work/_temp/*** -f /home/ubuntu/_work/_temp/***
Execute installation script
Check if Python hostedtoolcache folder exist...
Creating Python hostedtoolcache folder...
Create Python 3.13.2 folder
Copy Python binaries to hostedtoolcache folder
Create additional symlinks (Required for the UsePythonVersion Azure Pipelines task and the setup-python GitHub Action)
Upgrading pip...
Looking in links: /tmp/tmpiw8601l3
Requirement already satisfied: pip in /home/ubuntu/_work/_tool/Python/3.13.2/x64/lib/python3.13/site-packages (24.3.1)
Collecting pip
Downloading pip-25.0.1-py3-none-any.whl.metadata (3.7 kB)
Downloading pip-25.0.1-py3-none-any.whl (1.8 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.8/1.8 MB 58.6 MB/s eta 0:00:00

Installing collected packages: pip
Attempting uninstall: pip
Found existing installation: pip 24.3.1
Uninstalling pip-24.3.1:
Successfully uninstalled pip-24.3.1
Successfully installed pip-25.0.1
Create complete file
Successfully set up CPython (3.13.2)
/home/ubuntu/.local/bin/poetry config --list
cache-dir = "/home/ubuntu/.cache/pypoetry"
experimental.system-git-client = false
installer.max-workers = null
installer.modern-installation = true
installer.no-binary = null
installer.parallel = true
keyring.enabled = true
solver.lazy-wheel = true
virtualenvs.create = false
virtualenvs.in-project = false
virtualenvs.options.always-copy = false
virtualenvs.options.no-pip = false
virtualenvs.options.no-setuptools = false
virtualenvs.options.system-site-packages = false
virtualenvs.path = "{cache-dir}/virtualenvs" # /home/ubuntu/.cache/pypoetry/virtualenvs
virtualenvs.prefer-active-python = false
virtualenvs.prompt = "{project_name}-py{python_version}"
warnings.export = true
/home/ubuntu/.local/bin/poetry env use /home/ubuntu/_work/_tool/Python/3.13.2/x64/bin/python
Skipping virtualenv creation, as specified in config file.

[Errno 2] No such file or directory: '/home/ubuntu/.cache/pypoetry/virtualenvs/envs.toml'
Warning: Skipping virtualenv creation, as specified in config file.

[Errno 2] No such file or directory: '/home/ubuntu/.cache/pypoetry/virtualenvs/envs.toml'

poetry cache is not found

Post job cleanup.
Post job cleanup.
Error: Cache folder path is retrieved for poetry but doesn't exist on disk: /home/ubuntu/.cache/pypoetry/virtualenvs. This likely indicates that there are no dependencies to cache. Consider removing the cache step if it is not needed.

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