Skip to content

added plotel flag #1747

added plotel flag

added plotel flag #1747

Workflow file for this run

# This is a basic workflow to help you get started with Actions
#
# things to fixa at some point
# - add in latest_pyside_gui
# - latest_pyqt_gui for python 3.9 (currently vtk is not on PyPi)
# - currently a duplicate build is running
name: CI
#--------------------------------------------------------------------------------------------
# ┌────────── minute (0 - 59)
# │ ┌────────── hour (0 - 23)
# │ │ ┌────────── day of the month (1 - 31)
# │ │ │ ┌────────── month (1 - 12)
# │ │ │ │ ┌────────── day of the week (0 - 6)
# │ │ │ │ │
# │ │ │ │ │
# │ │ │ │ │
# * * * * *
# this is a 15 minute schedule
# schedule:
# - cron: '*/15 * * * *'
#on:
# push:
# pull_request:
# schedule:
# - cron: '*/15 * * * *'
# Controls when the action will run.
#on: [push]
on:
push:
paths-ignore:
#- ".github/**"
- "*.md"
- "*.rst"
# branches:
# - main
pull_request:
branches: [ main ]
schedule:
# At the end of every day
- cron: '0 0 * * *'
#on:
# Triggers the workflow on push or pull request events but only for the main branch
#push:
# branches: [ main ]
#pull_request:
# branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
#workflow_dispatch:
#--------------------------------------------------------------------------------------------
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
strategy:
matrix:
# '3.9', '3.11-dev'
python-version: ['3.10', '3.11', '3.12', '3.13']
os: [ubuntu-latest]
# , macos-latest, windows-latest
mode: ['latest', 'latest_basic', 'old', 'latest_pyqt5_gui', 'latest_pyqt6_gui', 'latest_pyside2_gui', ]
# 'old_basic', 'old_pyside2_gui', 'old_pyqt5_gui', 'latest_pyside6_gui'
experimental: [false]
#include:
# - python: '3.11-dev'
# experimental: true
#include:
#- node: 13
# os: ubuntu-18.04
# experimental: true
exclude:
# Exclude all DB images except "mariadb_10.4" for all PHP versions except "7.3".
#- {python-version: '3.9', mode: 'latest_pyside6_gui'} # 'pip install imageio pillow' fails
#- {python-version: '3.9', mode: 'latest_pyqt5_gui'} # 'pip install imageio pillow' fails
#- {python-version: '3.9', mode: 'latest_pyqt6_gui'} # 'pip install imageio pillow' fails
- {python-version: '3.10', mode: 'old'} # redundant
- {python-version: '3.10', mode: 'latest_pyqt5_gui'} # 'pip install imageio pillow' fails
- {python-version: '3.10', mode: 'latest_pyqt6_gui'} # 'pip install imageio pillow' fails
#- {python-version: '3.11', mode: 'latest_pyside2_gui'}
#- {python-version: '3.11', mode: 'latest_pyside6_gui'}
- {python-version: '3.11', mode: 'old'} # redundant
#- {python-version: '3.11', mode: 'latest_pyqt5_gui'}
- {python-version: '3.11', mode: 'latest_pyqt6_gui'}
#- {python-version: '3.11', mode: 'latest_pyside2_gui'}
- {python-version: '3.11', mode: 'latest_pyside6_gui'} # DLL error
- {python-version: '3.12', mode: 'old'} # redundant
- {python-version: '3.12', mode: 'latest_pyqt5_gui'}
- {python-version: '3.12', mode: 'latest_pyqt6_gui'}
- {python-version: '3.12', mode: 'latest_pyside2_gui'}
#- {python-version: '3.11', mode: 'latest_pyside6_gui'}
- {python-version: '3.13', mode: 'old'} # redundant
- {python-version: '3.13', mode: 'latest_pyqt5_gui'}
- {python-version: '3.13', mode: 'latest_pyqt6_gui'}
- {python-version: '3.13', mode: 'latest_pyside2_gui'}
fail-fast: false
#- continue-on-error: ${{ matrix.experimental }}
#strategy:
# matrix:
#https://github.com/zopyx/xmldirector.connector/blob/master/.travis.yml#L15-L54
#python-version: [3.7, 3.8]
#env:
# - {COVERAGE_RUN='coverage run' CODECOV='codecov' NUMPY='numpy scipy matplotlib h5py vtk pyqt5 pandas>=0.25 imageio pillow>5.2,!=7.1.0' LIB='libblas-dev liblapack-dev'}
#python-version: 3.8
#env:
# COVERAGE_RUN='coverage run'
# CODECOV='codecov'
# NUMPY='numpy scipy matplotlib h5py vtk pyqt5 'pandas>=1.0' imageio pillow>5.2,!=7.1.0'
# LIB='libblas-dev liblapack-dev'
#--------------------------------------------------------------------------------------------------
# latest versions of package
#- name: "Python ${{ matrix.python-version }} (PyQt5)"
#python-version: [3.7, 3.8, 3.9]
#env:
#- COVERAGE_RUN='coverage run'
#- CODECOV='codecov'
#- NUMPY='numpy scipy matplotlib h5py vtk pyqt5 'pandas>=1.0' imageio pillow>5.2,!=7.1.0'
##- LIB='libblas-dev liblapack-dev'
#- LIBH5='libhdf5-dev'
#--------------------------------------------------------------------------------------------------
# oldest versions of package
#--------------------------------------------------------------------------------------------------
# Steps represent a sequence of tasks that will be executed as part of the job
#env: ${{ matrix.env }}
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: Print environment variables exposed by GitHub
run: |
echo "GITHUB_ACTOR=$GITHUB_ACTOR"
echo "GITHUB_REPOSITORY=$GITHUB_REPOSITORY"
echo "GITHUB_SHA=$GITHUB_SHA"
echo "GITHUB_REF=$GITHUB_REF"
echo "GITHUB_HEAD_REF=$GITHUB_HEAD_REF"
echo "GITHUB_BASE_REF=$GITHUB_BASE_REF"
echo "GITHUB_EVENT_NAME=$GITHUB_EVENT_NAME"
echo "GITHUB_RUN_ID=$GITHUB_RUN_ID"
echo "GITHUB_RUN_NUMBER=$GITHUB_RUN_NUMBER"
echo "GITHUB_WORKFLOW=$GITHUB_WORKFLOW"
echo "GITHUB_ACTION=$GITHUB_ACTION"
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies - ${{ matrix.mode }}
run: |
python -m pip install --upgrade pip
pip install flake8 coverage
#if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
pip list
#mode: ['latest', 'latest_basic',
# 'latest_pyside2_gui', 'latest_pyside6_gui',
# 'latest_pyqt5_gui', 'latest_pyqt6_gui',
# 'old', 'old_basic',
# 'old_pyside_gui', 'old_pyqt_gui']
#
- name: Install latest basic packages
if: ${{ matrix.mode == 'latest_basic' || matrix.mode == 'latest' ||
matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui' }}
run: |
pip install numpy scipy
#--no-binary :all:
- name: Install latest packages (pandas, matplotlib)
if: ${{ matrix.mode == 'latest' ||
matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui' }}
run: |
pip install 'pandas>=1.0' matplotlib
- name: Install latest packages (h5py)
if: ${{ matrix.python-version != '3.12' && (matrix.mode == 'latest' ||
matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
run: |
pip install h5py tables
- name: Install latest packages (imageio, pillow)
#if: ${{ (
#if: ${{ matrix.python-version != '3.12' && (
# matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
# matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
if: ${{ (matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
run: |
pip install imageio pillow>=10.1.0
- name: Install latest packages (vtk)
#if: ${{ matrix.python-version != '3.13' && (
# matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
# matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
if: ${{ (matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
run: |
pip install vtk qtpy
- if: ${{ matrix.mode == 'latest_pyside2_gui' && matrix.python-version != '3.13' }}
name: Install PySide2
run: |
pip install PySide2
- if: ${{ matrix.mode == 'latest_pyside6_gui' && matrix.python-version != '3.13' }}
name: Install PySide6
run: |
pip install PySide6
- if: ${{ matrix.mode == 'latest_pyqt5_gui' && matrix.python-version != '3.13' }}
name: Install PyQt5
run: |
pip install PyQt5
- if: ${{ matrix.mode == 'latest_pyqt6_gui' && matrix.python-version != '3.13' }}
name: Install PyQt6
run: |
pip install PyQt6
#-----------------------------------------------------------------------------------
# old
# pandas==1.1.3
#- name: Install old packages (3.9)
# if: ${{ matrix.mode == 'old' && matrix.python-version == '3.9' }}
# run: |
# pip install numpy==1.19.4 scipy==1.5.4 matplotlib==3.3.3 h5py==3.0.0 pandas==1.1.3 #--no-binary :all:
#-----------------------------------------------------------------------------------
# I'd like to make this step build a wheel and install it, but you need the wheel name
# or know how to use bash to pipe an ls into a pip command, so I can do:
# >>> python setup.py bdist_wheel
# >>> pip install dist/pyNastran*.whl <--- the * is a problem
#
# python 3.9 gets everything
# any python 3.8 test that can't be run in the previous block
- name: Install dependencies (bdist_wheel & develop)
#pip install dist/pyNastran*.whl
#python setup.py bdist_wheel
#if: ${{ (matrix.python-version == '3.9') || (matrix.python-version == '3.10') }}
run: |
pip install -e .
#python setup.py develop
- name: List dependencies
run: |
pip list
- name: Run No GUI 3.12
#if: ${{ matrix.python-version == '3.12' || (
# matrix.mode == 'latest' || matrix.mode == 'latest_basic' || matrix.mode == 'old') }}
if: ${{ (matrix.mode == 'latest' || matrix.mode == 'latest_basic' || matrix.mode == 'old') }}
#if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
run: |
python pyNastran/all_tests_no_gui.py
coverage run pyNastran/all_tests_no_gui.py
# 3.11 - No matching distribution found for vtk
- name: Run GUI
if: ${{ (matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
#if: ${{ matrix.python-version != '3.12' && (
# matrix.mode == 'latest_pyside2_gui' || matrix.mode == 'latest_pyside6_gui' ||
# matrix.mode == 'latest_pyqt5_gui' || matrix.mode == 'latest_pyqt6_gui') }}
#if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
run: |
python pyNastran/all_tests.py
coverage run pyNastran/all_tests.py
#- name: Upload coverage
# run: |
# codecov
- name: Upload coverage
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
#--------------------------------------------------------------------------------------------------
# https://docs.github.com/en/free-pro-team@latest/actions/guides/building-and-testing-python
# name: Python package
#
# on: [push]
#
# jobs:
# build:
#
# runs-on: ubuntu-latest
# strategy:
# matrix:
# python-version: [2.7, 3.5, 3.6, 3.7, 3.8]
# steps:
# - uses: actions/checkout@v2
# - name: Set up Python ${{ matrix.python-version }}
# uses: actions/setup-python@v2
# with:
# python-version: ${{ matrix.python-version }}
# - name: Install dependencies
# run: |
# python -m pip install --upgrade pip
# pip install flake8 pytest
# if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
# - name: Lint with flake8
# run: |
# # stop the build if there are Python syntax errors or undefined names
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
# - name: Test with pytest
# run: |
# pytest