You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20-5Lines changed: 20 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ This action sets up a Python environment for use in actions by:
9
9
- optionally installing and adding to PATH a version of Python that is already installed in the tools cache.
10
10
- downloading, installing and adding to PATH an available version of Python from GitHub Releases ([actions/python-versions](https://github.com/actions/python-versions/releases)) if a specific version is not available in the tools cache.
11
11
- failing if a specific version of Python is not preinstalled or available for download.
12
-
- optionally caching dependencies for pipand pipenv.
12
+
- optionally caching dependencies for pip, pipenv and poetry.
13
13
- registering problem matchers for error output.
14
14
15
15
# What's new
@@ -19,7 +19,7 @@ This action sets up a Python environment for use in actions by:
19
19
- Automatic setup and download of Python packages if using a self-hosted runner.
20
20
- Support for pre-release versions of Python.
21
21
- Support for installing any version of PyPy on-flight
22
-
- Support for built-in caching of pipand pipenv dependencies
22
+
- Support for built-in caching of pip, pipenv and poetry dependencies
The action has built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/toolkit/tree/main/packages/cache) under the hood for caching dependencies but requires less configuration settings. Supported package managers are `pip`and `pipenv`. The `cache` input is optional, and caching is turned off by default.
212
+
The action has built-in functionality for caching and restoring dependencies. It uses [actions/cache](https://github.com/actions/toolkit/tree/main/packages/cache) under the hood for caching dependencies but requires less configuration settings. Supported package managers are `pip`, `pipenv` and `poetry`. The `cache` input is optional, and caching is turned off by default.
213
213
214
-
The action defaults to searching for a dependency file (`requirements.txt` for pip or `Pipfile.lock` for pipenv) in the repository, and uses its hash as a part of the cache key. Use `cache-dependency-path` for cases where multiple dependency files are used, they are located in different subdirectories or different files for the hash want to be used.
214
+
The action defaults to searching for a dependency file (`requirements.txt` for pip, `Pipfile.lock` for pipenv or `poetry.lock` for poetry) in the repository, and uses its hash as a part of the cache key. Use `cache-dependency-path` for cases where multiple dependency files are used, they are located in different subdirectories or different files for the hash want to be used.
215
215
216
216
- For pip, the action will cache global cache directory
217
217
- For pipenv, the action will cache virtualenv directory
218
+
- For poetry, the action will cache virtualenv directory
218
219
219
220
**Please Note:** Restored cache will not be used if the requirements.txt file is not updated for a long time and a newer version of the dependency is available that can lead to an increase in total build time.
220
221
221
222
The requirements file format allows to specify dependency versions using logical operators (for example chardet>=3.0.4) or specify dependencies without any versions. In this case the pip install -r requirements.txt command will always try to install the latest available package version. To be sure that the cache will be used, please stick to a specific dependency version and update it manually if necessary.
0 commit comments