Skip to content
Draft
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
47 changes: 30 additions & 17 deletions .github/workflows/ci.yml → .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
name: ci
name: pr

on: [push, pull_request]
on:
push:
branches: [develop, main]
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
X_PYTHON_MIN_VERSION: "3.10"
Expand All @@ -19,6 +26,8 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: "pip"
cache-dependency-path: "./check_python_versions_requirements.txt"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -53,7 +62,7 @@ jobs:
# that you want to use to test the serialization adapter against.
# Currently, we need to update this manually, however I'm afraid this is not possible to automatically infer,
# since it's heavily dependant of the version of the AAS specification we support.
AAS_SPECS_RELEASE_TAG: "IDTA-01001-3-1-2"
AAS_SPECS_RELEASE_TAG: "v3.1.2"
services:
couchdb:
image: couchdb:3
Expand All @@ -77,11 +86,13 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Collect schema files from aas-specs
run: |
mkdir -p ./test/adapter/schema
curl -sSL -o ./test/adapter/schema/aasJSONSchema.json https://raw.githubusercontent.com/admin-shell-io/aas-specs/${{ env.AAS_SPECS_RELEASE_TAG }}/schemas/json/aas.json
curl -sSL -o ./test/adapter/schema/aasXMLSchema.xsd https://raw.githubusercontent.com/admin-shell-io/aas-specs/${{ env.AAS_SPECS_RELEASE_TAG }}/schemas/xml/AAS.xsd
curl -sSLf -o ./test/adapter/schema/aasJSONSchema.json https://raw.githubusercontent.com/admin-shell-io/aas-specs-metamodel/refs/tags/${{ env.AAS_SPECS_RELEASE_TAG }}/schemas/json/aas.json
curl -sSLf -o ./test/adapter/schema/aasXMLSchema.xsd https://raw.githubusercontent.com/admin-shell-io/aas-specs-metamodel/refs/tags/${{ env.AAS_SPECS_RELEASE_TAG }}/schemas/xml/AAS.xsd
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -109,6 +120,8 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand All @@ -132,6 +145,8 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -159,6 +174,8 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MAX_VERSION }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -215,17 +232,14 @@ jobs:

steps:
- uses: actions/checkout@v4
with:
# TODO(#592): revisit when the sdk<->compliance_tool version pinning is fixed.
# Need tags so setuptools_scm builds the local sdk as >=1.0.0, else the loose
# `basyx-python-sdk>=1.0.0` pin lets pip replace it with the PyPI release.
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
# install the local sdk first so its version satisfies the >=1.0.0 pin and pip keeps it instead of PyPI
# install the local sdk in editable mode so it does not get overwritten
run: |
python -m pip install --upgrade pip
python -m pip install ../sdk
Expand All @@ -247,17 +261,14 @@ jobs:
working-directory: ./compliance_tool
steps:
- uses: actions/checkout@v4
with:
# TODO(#592): revisit when the sdk<->compliance_tool version pinning is fixed.
# Need tags so setuptools_scm builds the local sdk as >=1.0.0, else the loose
# `basyx-python-sdk>=1.0.0` pin lets pip replace it with the PyPI release.
fetch-depth: 0
- name: Set up Python ${{ env.X_PYTHON_MIN_VERSION }}
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
# install the local sdk first so its version satisfies the >=1.0.0 pin and pip keeps it instead of PyPI
# install the local sdk in editable mode so it does not get overwritten
run: |
python -m pip install --upgrade pip
python -m pip install ../sdk
Expand Down Expand Up @@ -308,6 +319,8 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: "pip"
cache-dependency-path: "**/pyproject.toml"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
Expand Down
Loading