Skip to content

Migrate quizForge object references to composition API standard #8235

Migrate quizForge object references to composition API standard

Migrate quizForge object references to composition API standard #8235

Workflow file for this run

name: Static dependencies with and without C extensions
on:
push:
branches:
- develop
- 'release-v**'
pull_request:
branches:
- develop
- 'release-v**'
jobs:
pre_job:
name: Path match check
runs-on: ubuntu-latest
# Map a step output to a job output
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@master
with:
github_token: ${{ github.token }}
paths: '["**.py", "requirements/base.txt", "requirements/build.txt"]'
c_ext:
name: C Extensions
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-20.04
container:
image: python:2.7.18-buster
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
- name: pip cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-ext-${{ hashFiles('requirements/*.txt') }}
restore-keys: |
${{ runner.os }}-pip-ext
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements/base.txt
pip install -r requirements/build.txt
pip install -r requirements/test.txt
- name: Check C extensions build and run
run: |
# Ensure that for this Python version, we can actually compile ALL files
# in the kolibri directory
python -m compileall -q kolibri -x py2only
# Until we have staged builds, we will be running this in each and every
# environment even though builds should be done in Py 2.7
make staticdeps
make staticdeps-cext
pip install .
# Start and stop kolibri - disabled until we can move out of a container
# kolibri start --port=8081
# kolibri stop
# Run just tests in test/
py.test --cov=kolibri --cov-report= --cov-append --color=no test/
no_c_ext:
name: No C Extensions
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-20.04
container:
image: python:2.7.18-buster
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
- name: pip cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-no-ext-${{ hashFiles('requirements/*.txt') }}
restore-keys: |
${{ runner.os }}-pip-no-ext
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements/base.txt
pip install -r requirements/build.txt
pip install -r requirements/test.txt
- name: Check No C extensions build and run
run: |
# Ensure that for this Python version, we can actually compile ALL files
# in the kolibri directory
python -m compileall -q kolibri -x py2only
# Until we have staged builds, we will be running this in each and every
# environment even though builds should be done in Py 2.7
make staticdeps
pip install .
# Start and stop kolibri - disabled until we can move out of a container
# kolibri start --port=8081
# kolibri stop
# Run just tests in test/
py.test --cov=kolibri --cov-report= --cov-append --color=no test/