Use local install-poetry.py
on CI for tests and test against Python 3.10.0-rc.2 on all platforms
#4476
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.
Pull Request Check List
Added tests for changed code.Not applicableUpdated documentation for changed code.Not applicableContext
When working on #4424 and its associated PR #4425, I unfortunately broke installer for Python 3.6, because
capture_output
is not available in Python 3.6.First of all, sorry about that, I should have been more careful.
The fact that there's no tests for
install-poetry.py
script couldn't prevent the mistake from happening.Proposal
This pull request updates the CI workflow that runs tests so that we install poetry using the installer from the current branch, rather than the one on
master
branch.While this would not replace full functional tests, this could be a quick win to ensure that poetry is still installable on all supported Python versions and OSes on pull requests that update
install-poetry.py
.To showcase this, I've reintroduced the change that made the installer fail on Python 3.6 here, which correctly makes the workflow fail for Python 3.6 jobs on the CI.
Alternatively, if we have other reasons to install poetry from
master
branch, we could add a dedicated job that specifically tests the installation of poetry throughinstall-poetry.py
, and keep installing poetry frommaster
branch when running unit tests.This PR also updates the matrix so that we run the tests on Python 3.10.0-rc.2, and make sure that it makes the workflow fail if the tests don't pass, as the RC2 is IMO stable enough to be worth having green tests.
If this part should stay as is, I'd be happy to revert the commit, or make necessary changes.
Note that quotes have been added for versions because it avoid YAML to interpret them as floats (see actions/setup-python#175 and actions/setup-python#198).