Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Pythran

Pythran #306

Workflow file for this run

name: Pythran
# Controls when the action will run.
on:
workflow_dispatch:
pull_request:
branches: [ main ]
paths:
- '.github/workflows/pythran.yml'
schedule:
# ┌───────────── minute (0 - 59)
# │ ┌───────────── hour (0 - 23)
# │ │ ┌───────────── day of the month (1 - 31)
# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC)
# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT)
# │ │ │ │ │
- cron: "0 2 * * 0"
jobs:
pythran-linux:
name: Test ubuntu ${{ matrix.python_version }} ${{ matrix.cpp-version }}
runs-on: ubuntu-22.04
timeout-minutes: 160
strategy:
fail-fast: false
matrix:
python-version: [pypy-3.11-nightly]
cpp-version: [g++-12, clang-13]
steps:
- uses: actions/[email protected]
with:
python-version: ${{ matrix.python-version }}
- uses: actions/[email protected]
with:
fetch-depth: 1
repository: serge-sans-paille/pythran
path: pythran
- name: Install dependencies
run: |
cd pythran
python -m pip install --upgrade pip
python -m pip install cython
pip install pytest-xdist
python -m pip install numpy -Csetup-args="-Dallow-noblas=true"
pip install -r requirements.txt
sudo apt install libopenblas-dev ${{ matrix.cpp-version }}
- name: Setup
run: |
cd pythran
python -m pip install .
python -m pip install . 'pythran[test]'
printf '[commpiler]\nblas=openblas\n' > ~/.config/.pythranrc
printf 'cflags=-std=c++11 -Wall -Werror -Wno-unknown-pragmas -Wno-unused-local-typedefs -Wno-cpp -Wno-deprecated-declarations' >> ~/.config/.pythranrc
if test "${{ matrix.cpp-version }}" = "clang-13" ; then printf -- " -Wno-absolute-value -Wno-parentheses-equality\n" ; else printf "\n" ; fi >> ~/.config/.pythranrc
- name: Testing minimal CLI
run: |
pythran --version
pythran --help
pythran-config -vvv
- name: Testing sequential
run: |
cd pythran
export CC=`echo ${{ matrix.cpp-version }} | sed -e 's/g++/gcc/'`
export CXX=`echo ${{ matrix.cpp-version }} | sed -e 's/clang/clang++/'`
pytest pythran/tests/test_*.py -v -x --numprocesses=auto $PYTEST_ARGS
pythran-windows:
runs-on: windows-latest
name: windows pypy3.10 clang
strategy:
matrix:
architectures: [x64]
steps:
- name: Setup Python
uses: actions/[email protected]
with:
python-version: pypy-3.10-nightly
architecture: ${{ matrix.architecture }}
- name: Install clang-cl
run: |
choco install llvm --yes
@("C:/Program Files/LLVM/bin") + (Get-Content $env:GITHUB_PATH) | Set-Content $env:GITHUB_PATH
- uses: actions/[email protected]
with:
fetch-depth: 1
repository: serge-sans-paille/pythran
path: pythran
- name: Install dependencies
run: |
cd pythran
python -m pip install --upgrade pip
python -m pip install cython
python -m pip install numpy --no-build-isolation -Csetup-args="-Dallow-noblase=true"
pip install -r requirements.txt -Csetup-args="--vsenv" -Csetup-args="-Dblas=none" -Csetup-args="-Dlapack=none" -Csetup-args="-Dallow-noblas=true"
pip install wheel pythran-openblas pytest pytest-timeout
# pip install scipy # no wheel availabe, compilation takes too long
- name: Setup
run: |
cd pythran
python setup.py install
- name: Testing sequential
run: |
cd pythran
pytest pythran/tests/test_ndarray.py -v --timeout 600
# pytest pythran/tests/test_scipy.py -v --timeout 600
pytest pythran/tests/test_base.py -v --timeout 600
pytest pythran/tests/test_advanced.py -v --timeout 600