forked from airbus/scikit-decide
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid installing prereleased dependencies in github action
The way the scikit-decide library was installed for tests was designed so that pip find scikit-decide (in prelease mode) in the "wheels" directory. However a side effect was that it also allowed pip to install preleased dependencies, which can lead to some bugs, see issue airbus#192. To avoid this we rather specify explicitely the path to the wheel (but unsing wildcards to get easily the exact name) and get rid of the "--pre" option. We do that in a separate step for better readibility. Fix airbus#192.
- Loading branch information
Showing
2 changed files
with
40 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -328,9 +328,13 @@ jobs: | |
with: | ||
name: wheels | ||
|
||
- name: Install scikit-decide | ||
run: | | ||
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*win*.whl) | ||
pip install ${wheelfile}[all] | ||
- name: Test with pytest | ||
run: | | ||
pip install --pre --find-links ./wheels/ "scikit-decide[all]" | ||
pytest -v -s tests/autocast | ||
pytest -v -s tests/solvers/cpp | ||
pytest -v -s tests/solvers/python | ||
|
@@ -366,10 +370,13 @@ jobs: | |
with: | ||
name: wheels | ||
|
||
- name: Install scikit-decide | ||
run: | | ||
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*macos*.whl) | ||
pip install ${wheelfile}[all] | ||
- name: Test with pytest | ||
run: | | ||
env | ||
pip install --pre --find-links ./wheels/ "scikit-decide[all]" | ||
pytest -v -s tests/autocast | ||
pytest -v -s tests/solvers/cpp | ||
pytest -v -s tests/solvers/python | ||
|
@@ -402,9 +409,13 @@ jobs: | |
with: | ||
name: wheels | ||
|
||
- name: Install scikit-decide | ||
run: | | ||
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*manylinux*.whl) | ||
pip install ${wheelfile}[all] | ||
- name: Test with pytest | ||
run: | | ||
pip install --pre --find-links ./wheels/ "scikit-decide[all]" | ||
pytest -v -s tests/autocast | ||
pytest -v -s tests/solvers/cpp | ||
pytest -v -s tests/solvers/python | ||
|
@@ -468,6 +479,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
env: | ||
DOCS_VERSION_PATH: / | ||
python_version: "3.7" | ||
|
||
steps: | ||
- name: Get scikit-decide release version and update online docs path | ||
|
@@ -517,7 +529,7 @@ jobs: | |
- name: Setup python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.7" | ||
python-version: ${{ env.python_version }} | ||
|
||
- name: Download artifacts | ||
uses: actions/[email protected] | ||
|
@@ -526,7 +538,8 @@ jobs: | |
|
||
- name: Install scikit-decide | ||
run: | | ||
pip install --pre --find-links ./wheels "scikit-decide[all]" | ||
wheelfile=$(ls ./wheels/scikit_decide*-cp${python_version/\./}-*manylinux*.whl) | ||
pip install ${wheelfile}[all] | ||
- name: generate documentation | ||
run: yarn global add vuepress && yarn install && yarn docs:build && touch docs/.vuepress/dist/.nojekyll | ||
|