Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix upstream test action #333

Merged
merged 6 commits into from
Jul 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 19 additions & 20 deletions .github/workflows/test-upstream.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,17 @@ jobs:
strategy:
matrix:
os: [ ubuntu-latest, windows-latest ]
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
pydantic-version: [ "1", "2" ]
python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
exclude:
- os: windows-latest
python-version: "3.8"
python-version: "3.9"
- os: windows-latest
pydantic-version: "1"
- python-version: "3.8"
pydantic-version: "1"
- python-version: "3.9"
pydantic-version: "1"
- python-version: "3.10"
pydantic-version: "1"
python-version: "3.10"
- os: windows-latest
python-version: "3.11"
runs-on: ${{ matrix.os }}
env:
POETRY_VIRTUALENVS_IN_PROJECT: true

steps:

Expand All @@ -43,16 +40,23 @@ jobs:
path: linkml-runtime
fetch-depth: 0

- name: Ensure tags if not run from main repo
if: github.repository != 'linkml/linkml-runtime'
working-directory: linkml-runtime
run: |
git remote add upstream https://github.com/linkml/linkml-runtime
git fetch upstream --tags

- name: set up python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: install poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
- name: Install poetry
run: pipx install poetry

- name: Install dynamic versioning plugin
run: poetry self add "poetry-dynamic-versioning[plugin]"

- name: Load cached venv
id: cached-poetry-dependencies
Expand All @@ -72,11 +76,6 @@ jobs:
working-directory: linkml
run: poetry add ../linkml-runtime

# use correct pydantic version
- name: install pydantic
working-directory: linkml
run: poetry add pydantic@^${{ matrix.pydantic-version }}

# note that we run the installation step always, even if we restore a venv,
# the cache will restore the old version of linkml-runtime, but the lockfile
# will only store the directory dependency (and thus will reinstall it)
Expand Down
Loading