-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(ftn): add support for CRAY ftn fortran compiler (#109)
Add -fall-intrinsics compiler flag for MODFLOW 6 when compiling with gfortran (required to use call exit(returncode) when terminating the program). Split the github main.yml into several workflows to all smaller pieces to be rerun in the event of a failure.
- Loading branch information
1 parent
91ee4de
commit 353da75
Showing
7 changed files
with
387 additions
and
298 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,151 +9,6 @@ on: | |
|
||
jobs: | ||
|
||
pymake_lint: | ||
name: pymake linting | ||
runs-on: ubuntu-latest | ||
|
||
if: github.repository_owner == 'modflowpy' | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Setup Graphviz | ||
uses: ts-graphviz/setup-graphviz@v1 | ||
|
||
- name: Install packages | ||
run: | | ||
pip install requests pydotplus appdirs numpy matplotlib | ||
pip install https://github.com/modflowpy/flopy/zipball/develop | ||
pip install pylint flake8 black | ||
- name: Run isort | ||
run: | | ||
echo "if isort check fails update isort using" | ||
echo " pip install isort --upgrade" | ||
echo "and run" | ||
echo " isort ./flopy" | ||
echo "and then commit the changes." | ||
isort --verbose --check --diff ./pymake | ||
- name: Run black | ||
run: | | ||
echo "if black check fails update black using" | ||
echo " pip install black --upgrade" | ||
echo "and run" | ||
echo " black ./flopy" | ||
echo "and then commit the changes." | ||
black --check --diff ./pymake | ||
- name: Run flake8 | ||
run: flake8 --count --show-source ./pymake | ||
|
||
- name: Run pylint | ||
run: pylint --jobs=0 --errors-only ./pymake | ||
|
||
pymake_setup: | ||
name: standard installation | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
|
||
# check out repo | ||
- name: Checkout pymake repo | ||
uses: actions/[email protected] | ||
|
||
- name: Setup Python | ||
uses: actions/[email protected] | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Upgrade pip and install wheel | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install wheel | ||
- name: Base pymake installation | ||
run: | | ||
pip --verbose install . | ||
- name: Print pymake version | ||
run: | | ||
python -c "import pymake; print(pymake.__version__)" | ||
pymakeCI-os-gcc: | ||
name: pymake CI gcc on different OSs | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ ubuntu-latest, macos-latest, windows-latest ] | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Setup Graphviz | ||
if: runner.os == 'Linux' | ||
uses: ts-graphviz/setup-graphviz@v1 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install python packages | ||
run: | | ||
.github/common/install-python.sh | ||
- name: Setup symbolic link to gfortran on Linux | ||
if: runner.os == 'Linux' | ||
run: | | ||
sudo ln -fs /usr/bin/gfortran-10 /usr/local/bin/gfortran | ||
sudo ln -fs /usr/bin/gcc-10 /usr/local/bin/gcc | ||
sudo ln -fs /usr/bin/g++-10 /usr/local/bin/g++ | ||
- name: Setup symbolic link to gfortran on macOS | ||
if: runner.os == 'macOS' | ||
run: | | ||
sudo ln -fs /usr/local/bin/gfortran-10 /usr/local/bin/gfortran | ||
sudo ln -fs /usr/local/bin/gcc-10 /usr/local/bin/gcc | ||
sudo ln -fs /usr/local/bin/g++-10 /usr/local/bin/g++ | ||
- name: Print GNU compiler versions | ||
run: | | ||
gfortran --version | ||
gcc --version | ||
g++ --version | ||
- name: Download examples for pytest runs | ||
run: | | ||
.github/common/download-examples.sh | ||
- name: Run pytest | ||
run: | | ||
pytest -v --dist=loadfile -n=auto -m regression --durations=0 --cov=pymake --cov-report=xml autotest/ | ||
- name: Print coverage report before upload | ||
run: | | ||
coverage report | ||
- name: Upload coverage to Codecov | ||
uses: codecov/[email protected] | ||
with: | ||
file: ./coverage.xml | ||
|
||
pymakeCI-os-intel: | ||
name: pymake CI intel on different OSs | ||
runs-on: ${{ matrix.os }} | ||
|
@@ -277,155 +132,3 @@ jobs: | |
if: runner.os == 'Linux' && steps.cache-install-linux.outputs.cache-hit != 'true' | ||
run: | | ||
.github/intel-scripts/cache_exclude_linux.sh | ||
pymakeCI-gcc-prev: | ||
name: pymake CI GCC 9 and 8 | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
gcc-version: [ 9, 8 ] | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Setup Graphviz | ||
uses: ts-graphviz/setup-graphviz@v1 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install python packages | ||
run: | | ||
.github/common/install-python.sh | ||
- name: Setup symbolic link to gfortran on Linux | ||
run: | | ||
sudo ln -fs /usr/bin/gfortran-${{ matrix.gcc-version }} /usr/local/bin/gfortran | ||
sudo ln -fs /usr/bin/gcc-${{ matrix.gcc-version }} /usr/local/bin/gcc | ||
sudo ln -fs /usr/bin/g++-${{ matrix.gcc-version }} /usr/local/bin/g++ | ||
- name: Print GNU compiler versions | ||
run: | | ||
gfortran --version | ||
gcc --version | ||
g++ --version | ||
- name: Download examples for pytest runs | ||
run: | | ||
.github/common/download-examples.sh | ||
- name: Run pytest | ||
run: | | ||
pytest -v --dist=loadfile -n=auto -m base --durations=0 --cov=pymake --cov-report=xml autotest/ | ||
- name: Print coverage report before upload | ||
run: | | ||
coverage report | ||
- name: Upload coverage to Codecov | ||
uses: codecov/[email protected] | ||
with: | ||
file: ./coverage.xml | ||
|
||
pymakeCI-requests: | ||
name: pymake CI requests | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install python packages | ||
run: | | ||
.github/common/install-python.sh | ||
- name: Run pytest | ||
run: | | ||
pytest -v --dist=loadfile -n=auto -m requests --durations=0 --cov=pymake --cov-report=xml autotest/ | ||
- name: Print coverage report before upload | ||
run: | | ||
coverage report | ||
- name: Upload coverage to Codecov | ||
uses: codecov/[email protected] | ||
with: | ||
file: ./coverage.xml | ||
|
||
pymakeCI-python-prev: | ||
name: pymake CI with previous python versions | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: [ 3.8, 3.7 ] | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install python packages | ||
run: | | ||
.github/common/install-python.sh | ||
- name: Setup symbolic link to gfortran on Linux | ||
if: runner.os == 'Linux' | ||
run: | | ||
sudo ln -fs /usr/bin/gfortran-10 /usr/local/bin/gfortran | ||
sudo ln -fs /usr/bin/gcc-10 /usr/local/bin/gcc | ||
sudo ln -fs /usr/bin/g++-10 /usr/local/bin/g++ | ||
- name: Print GNU compiler versions | ||
run: | | ||
gfortran --version | ||
gcc --version | ||
g++ --version | ||
- name: Download examples for pytest runs | ||
run: | | ||
.github/common/download-examples.sh | ||
- name: Run pytest | ||
run: | | ||
pytest -v --dist=loadfile -n=auto -m base --durations=0 | ||
pymake_rtd: | ||
name: pymake rtd | ||
needs: pymakeCI-os-gcc | ||
runs-on: ubuntu-latest | ||
if: | ||
github.event_name == 'push' | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/[email protected] | ||
|
||
- name: Trigger RTDs build | ||
if: github.ref == 'refs/heads/master' | ||
uses: dfm/[email protected] | ||
with: | ||
webhook_url: ${{ secrets.RTDS_WEBHOOK_URL }} | ||
webhook_token: ${{ secrets.RTDS_WEBHOOK_TOKEN }} | ||
commit_ref: ${{ github.ref }} |
Oops, something went wrong.