Remove Python 3.8 from tests #825
Workflow file for this run
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
# Check latest release of all implementations still function with new changes | |
name: FAIR CLI Implementation Testing | |
on: [push, workflow_dispatch] | |
jobs: | |
Python: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 # Clone Fair CLI | |
- name: Clone Python Implementation | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/pyDataPipeline # Clone pyDataPipeline | |
path: pyDataPipeline | |
- name: Checkout pySimpleModel | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/pySimpleModel # Clone pySimple Model | |
path: pySimpleModel | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.9" | |
architecture: "x64" | |
- name: Install memcached | |
run: sudo apt install -y libmemcached-dev | |
- name: Setup fair | |
run: | | |
# Create venv | |
python3 -m venv venv | |
# Activate venv | |
./venv/bin/activate | |
# Intall CLI | |
pip3 install ../ | |
# Install pyDataPipeline | |
pip3 install ../pyDataPipeline | |
# Install pySimple Model | |
pip3 install . | |
working-directory: pySimpleModel # Use the pySimpleModel Directory | |
- name: Install remote registry | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Install the remote registry | |
#fair registry install --directory ${GITHUB_WORKSPACE}/registry-rem | |
curl -fsSL https://data.fairdatapipeline.org/static/remoteregistry.sh | /bin/bash -s -- -d ${GITHUB_WORKSPACE}/registry-rem -s drams.test-remote-settings -u admin -p admin | |
# Start the remote registry | |
${GITHUB_WORKSPACE}/registry-rem/scripts/start_fair_registry -p 8001 -s drams.test-remote-settings | |
# Copy the remote token | |
cp ${GITHUB_WORKSPACE}/registry-rem/token $PWD/token | |
export DJANGO_SETTINGS_MODULE=drams.test-remote-settings | |
${GITHUB_WORKSPACE}/registry-rem/venv/bin/python ${GITHUB_WORKSPACE}/registry-rem/manage.py createsuperuser --username FAIRDataPipeline --noinput | |
working-directory: pySimpleModel | |
- name: Install the registry and init | |
run: | | |
# Install the local registry | |
fair registry install | |
# Initialise Repository | |
fair init --ci | |
# Start the local registry | |
fair registry start | |
working-directory: pySimpleModel # Use the pySimpleModel Directory | |
- name: Test Pull | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Pull (Register) the SEIRS Parameters | |
fair pull --debug simpleModel/ext/SEIRSconfig.yaml | |
working-directory: pySimpleModel # Use the pySimpleModel Directory | |
- name: Test Run | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Run the Model | |
fair run --debug simpleModel/ext/SEIRSconfig.yaml # Run the seirs model | |
working-directory: pySimpleModel # Use the pySimpleModel Directory | |
- name: Test Push | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Stage the SEIRS Parameters to be Pushed | |
fair add PSU:SEIRS_model/[email protected] | |
# Push the SEIRS parameters | |
fair push | |
working-directory: pySimpleModel # Use the pySimpleModel Directory | |
Java: | |
runs-on: ubuntu-latest | |
#if: False | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Clone Java Implementation | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/javaSimpleModel | |
path: java_example | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.9" | |
architecture: "x64" | |
- name: Install memcached | |
run: sudo apt install -y libmemcached-dev | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '11' | |
distribution: 'adopt' | |
server-id: github | |
settings-path: ${{ github.workspace }} | |
- name: Build with Gradle | |
run: gradle build | |
working-directory: java_example | |
- name: Setup fair | |
run: | | |
# Create venv | |
python3 -m venv venv | |
# Activate venv | |
./venv/bin/activate | |
# Intall CLI | |
pip3 install ../ | |
working-directory: java_example # Use the java_example Directory | |
- name: Install remote registry | |
run: | | |
./venv/bin/activate # Activate venv | |
# Install the remote registry | |
curl -fsSL https://data.fairdatapipeline.org/static/remoteregistry.sh | /bin/bash -s -- -d ${GITHUB_WORKSPACE}/registry-rem -s drams.test-remote-settings -u admin -p admin | |
# Start the remote registry | |
${GITHUB_WORKSPACE}/registry-rem/scripts/start_fair_registry -p 8001 -s drams.test-remote-settings | |
# Copy the remote token | |
cp ${GITHUB_WORKSPACE}/registry-rem/token $PWD/token | |
working-directory: java_example # Use the java_example Directory | |
- name: run javaSimpleModel with fair cli | |
run: | | |
./venv/bin/activate # Activate venv | |
# Install local registry | |
fair registry install | |
# Start local registry | |
fair registry start | |
# Initialise repository | |
fair init --ci | |
# Pull (Register) SEIRS Parameters | |
fair pull --debug src/main/resources/seirs-config.yaml # Pull SEIRS parameters | |
# Run the model dirty as venv is not in .gitignore (to do) | |
fair run --dirty --debug src/main/resources/seirs-config.yaml # Run the SEIRS Model | |
working-directory: java_example # Use the java_example Directory | |
R: | |
runs-on: ubuntu-latest | |
env: | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 # Clone FAIR CLI | |
- name: Install memcached | |
run: sudo apt install -y libmemcached-dev | |
- name: Clone R Data Pipeline | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/rDataPipeline | |
path: r_data_pipeline | |
ref: 'main' | |
- name: Clone R Implementation | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/rSimpleModel | |
path: r_example | |
ref: 'main' | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.9" | |
architecture: "x64" | |
- uses: r-lib/actions/setup-r@v2 | |
with: | |
r-version: release | |
use-public-rspm: true | |
- uses: r-lib/actions/setup-r-dependencies@v2 | |
with: | |
working-directory: r_data_pipeline | |
extra-packages: | | |
devtools | |
- uses: r-lib/actions/setup-r-dependencies@v2 | |
with: | |
working-directory: r_example | |
extra-packages: | | |
devtools | |
- name: Install implementation | |
run: | | |
devtools::install_github("FAIRDataPipeline/rDataPipeline") | |
library(rDataPipeline) | |
devtools::install_github("FAIRDataPipeline/rSimpleModel") | |
library(rSimpleModel) | |
shell: Rscript {0} | |
- name: Setup fair | |
run: | | |
# Create venv | |
python3 -m venv venv | |
# Activate venv | |
./venv/bin/activate | |
# Intall CLI | |
pip3 install ../ # Install CLI | |
working-directory: r_example # Use the r_example Directory | |
- name: Install remote registry | |
run: | | |
# Activate venv | |
./venv/bin/activate # Activate venv | |
# Install the remote registry | |
curl -fsSL https://data.fairdatapipeline.org/static/remoteregistry.sh | /bin/bash -s -- -d ${GITHUB_WORKSPACE}/registry-rem -s drams.test-remote-settings -u admin -p admin | |
# Start the remote registry | |
${GITHUB_WORKSPACE}/registry-rem/scripts/start_fair_registry -p 8001 -s drams.test-remote-settings | |
# Copy the remote token | |
cp ${GITHUB_WORKSPACE}/registry-rem/token $PWD/token | |
working-directory: r_example # Use the r_example Directory | |
- name: run rSimpleModel with fair cli | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Install local registry | |
fair registry install | |
# Start local registry | |
fair registry start | |
# Initialise repository | |
fair init --ci | |
# Pull (Register) SEIRS Parameters | |
fair pull --debug inst/extdata/SEIRSconfig.yaml | |
# Run the model dirty as venv is not in .gitignore (to do) | |
fair run --dirty --debug inst/extdata/SEIRSconfig.yaml | |
working-directory: r_example # Use the r_example Directory | |
Julia: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Clone Julia Implementation | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/DataPipeline.jl | |
path: julia_example | |
ref: 'main' | |
- name: Install memcached | |
run: sudo apt install -y libmemcached-dev | |
- name: Set up julia | |
uses: julia-actions/setup-julia@v1 | |
with: | |
version: "1.8.5" | |
arch: 'x64' | |
- name: Install Package | |
run: julia -e 'using Pkg; Pkg.instantiate()' | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.9" | |
architecture: "x64" | |
- name: Setup fair | |
run: | | |
# Create venv | |
python3 -m venv venv | |
# Activate venv | |
./venv/bin/activate | |
# Intall CLI | |
pip3 install ../ # Install CLI | |
working-directory: julia_example # Use the julia_example Directory | |
- name: Install remote registry | |
run: | | |
# Activate venv | |
./venv/bin/activate # Activate venv | |
# Install the remote registry | |
curl -fsSL https://data.fairdatapipeline.org/static/remoteregistry.sh | /bin/bash -s -- -d ${GITHUB_WORKSPACE}/registry-rem -s drams.test-remote-settings -u admin -p admin | |
# Start the remote registry | |
${GITHUB_WORKSPACE}/registry-rem/scripts/start_fair_registry -p 8001 -s drams.test-remote-settings | |
# Copy the remote token | |
cp ${GITHUB_WORKSPACE}/registry-rem/token $PWD/token | |
working-directory: julia_example # Use the julia_example Directory | |
- name: Run SEIRS Model with fair cli | |
run: | | |
# Activate venv | |
./venv/bin/activate | |
# Install local registry | |
fair registry install | |
# Start local registry | |
fair registry start | |
# Initialise repository | |
fair init --ci | |
# Pull (Register) SEIRS Parameters | |
fair pull --debug examples/fdp/SEIRSconfig.yaml | |
# Run the model dirty as venv is not in .gitignore (to do) | |
fair run --dirty --debug examples/fdp/SEIRSconfig.yaml | |
working-directory: julia_example # Use the julia_example Directory | |
CPlusPlus: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Clone CPlusPlus Model | |
uses: actions/checkout@v3 | |
with: | |
repository: FAIRDataPipeline/cppSimpleModel | |
path: cpp_example | |
ref: 'main' | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.9" | |
architecture: "x64" | |
- name: Install requirements | |
run: | | |
sudo apt-get update | |
sudo apt-get upgrade | |
sudo apt install -y libmemcached-dev graphviz gnuplot --fix-missing | |
sudo apt install -y libjsoncpp-dev curl libcurl4-openssl-dev --fix-missing | |
sudo apt install -y libyaml-cpp-dev libhdf5-dev --fix-missing | |
- name: Install Model | |
run: | | |
cmake -Bbuild | |
cmake --build build | |
working-directory: cpp_example | |
- name: Setup fair | |
run: | | |
# Create venv | |
python3 -m venv venv | |
# Activate venv | |
./venv/bin/activate | |
# Intall CLI | |
pip3 install ../ # Install CLI | |
working-directory: cpp_example # Use the cpp_example Directory | |
- name: Install remote registry | |
run: | | |
# Activate venv | |
./venv/bin/activate # Activate venv | |
# Install the remote registry | |
curl -fsSL https://data.fairdatapipeline.org/static/remoteregistry.sh | /bin/bash -s -- -d ${GITHUB_WORKSPACE}/registry-rem -s drams.test-remote-settings -u admin -p admin | |
# Start the remote registry | |
${GITHUB_WORKSPACE}/registry-rem/scripts/start_fair_registry -p 8001 -s drams.test-remote-settings | |
# Copy the remote token | |
cp ${GITHUB_WORKSPACE}/registry-rem/token $PWD/token | |
working-directory: cpp_example # Use the cpp_example Directory | |
- name: Run Example model with fair-cli | |
run: | | |
# Activate venv | |
./venv/bin/activate # Activate venv | |
# Install local registry | |
fair registry install | |
# Start local registry | |
fair registry start | |
# Initialise repository | |
fair init --ci | |
# Pull (Register) SEIRS Parameters | |
fair pull --debug data/seirs_config.yaml | |
# Run the model dirty as venv is not in .gitignore (to do) | |
fair run --dirty --debug data/seirs_config.yaml | |
working-directory: cpp_example # Use the cpp_example Directory |