Skip to content
Merged
Show file tree
Hide file tree
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
File renamed without changes.
29 changes: 29 additions & 0 deletions .github/workflows/master_cleaner.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Master Cleaner

on:
push:
branches:
- master

jobs:
formatter:
name: runner / black
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: psf/black@stable
with:
src: "./ezyrb"

- name: Create Pull Request
uses: peter-evans/create-pull-request@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
title: "Format Python code with psf/black push"
commit-message: ":art: Format Python code with psf/black"
body: |
There appear to be some python formatting errors in ${{ github.sha }}. This pull request
uses the [psf/black](https://github.com/psf/black) formatter to fix these issues.
base: ${{ github.head_ref }} # Creates pull request onto pull request or commit branch
branch: actions/black
46 changes: 46 additions & 0 deletions .github/workflows/monthly-tagger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: "Monthly Tagger"

on:
schedule:
- cron: '20 2 1 * *'

jobs:

test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install .[test]
- name: Test with pytest
run: |
python3 -m pytest

monthly_tag:
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.PAT_EZYRB_PUSH }}

- name: Create and push the tag
run: |
python utils/mathlab_versioning.py set --only-date "post$(date +%y%m)"
VERS=$(python utils/mathlab_versioning.py get)
git config --global user.name 'Monthly Tag bot'
git config --global user.email 'mtbot@noreply.github.com'
git add pyproject.toml
git commit -m "monthly version $VERS"
git tag -a "v$VERS" -m "Monthly version $VERS"
git push origin "v$VERS"
120 changes: 120 additions & 0 deletions .github/workflows/tester.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
name: "Testing Pull Request"

on:
pull_request:
branches:
- "master"

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]

env:
CFLAGS: "-Wno-error=implicit-function-declaration -Wno-error=incompatible-pointer-types"
CXXFLAGS: "-Wno-error=implicit-function-declaration -Wno-error=incompatible-pointer-types"

steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Install system dependencies (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y libboost-serialization-dev libprotobuf-dev protobuf-compiler libopenblas-dev liblapack-dev

- name: Set up Java for PyCOMPSs
if: runner.os == 'Linux'
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '11'

- name: Install Python dependencies
shell: bash
run: |
python3 -m pip install --upgrade pip
python3 -m pip install setuptools wheel
if [ "$RUNNER_OS" == "Linux" ]; then
python3 -m pip install pycompss --no-build-isolation
fi
python3 -m pip install .[test]

- name: Test with pytest
shell: bash
run: |
if [ "$RUNNER_OS" == "Linux" ]; then
python3 -m pytest
else
python3 -m pytest --ignore=tests/test_parallel/
fi

linter: ####################################################################
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Run Black formatter (check mode)
uses: psf/black@stable
with:
src: "./ezyrb"

testdocs: ##################################################################
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install system dependencies
run: sudo apt-get update && sudo apt-get install -y pandoc

- name: Install Python dependencies
run: python3 -m pip install .[docs]

- name: Build Documentation
run: |
make html
working-directory: docs/

coverage: ##################################################################
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write

steps:
- uses: actions/checkout@v4

- name: Install system dependencies (Linux)
run: |
sudo apt-get update
sudo apt-get install -y libboost-serialization-dev libprotobuf-dev protobuf-compiler libopenblas-dev liblapack-dev

- name: Install Python dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install setuptools wheel
python3 -m pip install pycompss --no-build-isolation
python3 -m pip install .[test]

- name: Generate coverage report
run: |
python3 -m pytest --cov-report term --cov-report xml:cobertura.xml --cov=ezyrb

- name: Produce the coverage report
if: github.event.pull_request.head.repo.full_name == github.repository
uses: insightsengineering/coverage-action@v2
with:
path: ./cobertura.xml
threshold: 80.00
fail: true
publish: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
coverage-summary-title: "Code Coverage Summary"
59 changes: 0 additions & 59 deletions .github/workflows/testing_pr.yml

This file was deleted.

Loading
Loading