Description
Description:
When collecting Poetry projects for caching, a **/poetry.lock
glob is used, meaning the action supports Poetry projects in subfolders.
However, in order to process the Poetry configuration, getPoetryConfiguration
runs the poetry
command from the repo's root directory; this causes Poetry to return an invalid configuration when there is a Poetry project inside an inner directory.
setup-python/src/cache-distributions/poetry-cache.ts
Lines 45 to 48 in ffcd000
Action version:
v4
Platform:
- Ubuntu
- macOS
- Windows
Runner type:
- Hosted
- Self-hosted
Tools version:
All Poetry versions
Repro steps:
Create a repository with a Poetry project inside a subfolder; use the default action configuration. Matter of fact, even if a specific cache-dependency-path
is provided, the resulting Poetry config will still be invalid.
Expected behavior:
The correct pyproject.toml and poetry.toml (inside the subfolder) are used.
Actual behavior:
The read configuration uses pyproject.toml and poetry.toml from the repository root directory.