Adding support for more PyPy versions and installing them on-flight#168
Merged
konradpabjan merged 7 commits intoDec 17, 2020
Merged
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull-request adds support for specifying PyPy via PyPy version and Python version.
Closes #136 and #17
Supported input syntax
The new supported syntax:
Also, we keep old syntax for backward compatibility:
We don't have plans to deprecate and we are going to keep them for now.
Technical points
The list of available versions
Current implementation uses the list of available versions from https://downloads.python.org/pypy/versions.json
It was discussed and confirmed with PyPy team: https://foss.heptapod.net/pypy/pypy/-/issues/3354
Storing exact version of PyPy in "PYPY_VERSION" file in PyPy folder
Currently, PyPy versions are saved in toolcache. Toolcache has the following structure
<toolcache_root>/PyPy/<python_version>/x64.So it is not possible to determine from path what version of PyPy is located in folder. For example, on machine, we have PyPy 7.3.1 with python 3.6 in toolcache on path
<toolcache_root>/PyPy/3.6/x64. We need some way to determine what version of PyPy in this folder.We have consider calling
pypy --versionand parsing output but this approach doesn't work for RC versions becausepypy --versiondoesn't show exact RC number in output.We have decided to write exact installed version in file and put it to PyPy folder. This approach works perfectly and it is faster than parsing output. These files will be added to Hosted images in a few weeks.
The single drawback, action won't consume PyPy that was installed manually without this action.
Installation time
Support of RC and nightly versions
Self-hosted agents
This action also supports self-hosted agents and works on them