Skip to content

bump version v4.6.3 -> v4.6.4 #311

bump version v4.6.3 -> v4.6.4

bump version v4.6.3 -> v4.6.4 #311

Workflow file for this run

name: ci
on: [push, pull_request, workflow_dispatch]
jobs:
examples:
runs-on: ubuntu-20.04
strategy:
fail-fast: False
matrix:
python-version:
- "3.6"
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt-get install libpython2.7 # required by paup
python -m pip install --upgrade pip
- name: Install paup
run: |
temp_dir=$(mktemp -d)
wget -P ${temp_dir} http://phylosolutions.com/paup-test/paup4a168_ubuntu64.gz
gunzip ${temp_dir}/paup4a168_ubuntu64.gz
chmod +x ${temp_dir}/paup4a168_ubuntu64
sudo mv ${temp_dir}/paup4a168_ubuntu64 /usr/local/bin/paup
echo "export DENDROPY_PAUP_EXECUTABLE_PATH=/usr/local/bin/paup" >> "${GITHUB_ENV}"
- name: Install dendropy
run: |
python -m pip install .
- name: Run examples
run: |
cd docs/source/examples
# only allow known failures
# and enforce removal of working examples from known failures
for f in *.py; do
echo "${f}"
if timeout 60 python "${f}" && ! grep -q "${f}" backlogged-fail-whitelist.txt; then
:
elif grep -q "${f}" backlogged-fail-whitelist.txt; then
:
else
echo FAIL "${f}"
exit 1
fi
done
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install ruff==0.0.292
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with ruff
run: |
# stop the build if there are Python syntax errors or undefined names
./lint.sh
tests:
runs-on: ubuntu-20.04
strategy:
fail-fast: False
matrix:
python-version:
- "2.7"
- "3.5"
- "3.6"
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
continue-on-error: true
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install python2 libpython2.7 # required by paup
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Install paup
run: |
temp_dir=$(mktemp -d)
wget -P ${temp_dir} http://phylosolutions.com/paup-test/paup4a168_ubuntu64.gz
gunzip ${temp_dir}/paup4a168_ubuntu64.gz
chmod +x ${temp_dir}/paup4a168_ubuntu64
sudo mv ${temp_dir}/paup4a168_ubuntu64 /usr/local/bin/paup
echo "export DENDROPY_PAUP_EXECUTABLE_PATH=/usr/local/bin/paup" >> "${GITHUB_ENV}"
- name: Python2 compatibility workaround # TODO remove when Python2 compatibility dropped
if: matrix.python-version == '2.7'
run: |
rm tests/dendropy
curl --silent --show-error --retry 5 https://bootstrap.pypa.io/pip/2.7/get-pip.py | sudo python2
python2 -m pip install setuptools --upgrade
python2 setup.py test
- name: Test with setup.py
if: matrix.python-version != '2.7'
run: |
python setup.py test
entrypoints:
runs-on: ubuntu-latest
strategy:
fail-fast: False
matrix:
python-version:
- "2.7"
- "3.5"
- "3.6"
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
continue-on-error: true
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install python2 libpython2.7 # required by paup
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
python -m pip install .
- name: Test sumtrees
run: |
which sumtrees
sumtrees --help
sumtrees 2>&1 | grep sumtrees || exit 1
- name: Test sumlabels
run: |
which sumlabels
sumlabels --help
sumlabels 2>&1 | grep sumlabels || exit 1
- name: Test dendropy-format
run: |
which dendropy-format
dendropy-format --help
dendropy-format 2>&1 | grep dendropy-format || exit 1
- name: Test deprecated entrypoints
run: |
which sumtrees.py
sumtrees.py --help
sumtrees.py 2>&1 | grep sumtrees.py || exit 1
which sumlabels.py
sumlabels.py --help
sumlabels.py 2>&1 | grep sumlabels.py || exit 1
coverage:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@master
- name: Setup Python
uses: actions/setup-python@master
with:
python-version: 3.8
- name: Install paup
run: |
sudo apt-get install libpython2.7 # required by paup
temp_dir=$(mktemp -d)
wget -P ${temp_dir} http://phylosolutions.com/paup-test/paup4a168_ubuntu64.gz
gunzip ${temp_dir}/paup4a168_ubuntu64.gz
chmod +x ${temp_dir}/paup4a168_ubuntu64
sudo mv ${temp_dir}/paup4a168_ubuntu64 /usr/local/bin/paup
echo "export DENDROPY_PAUP_EXECUTABLE_PATH=/usr/local/bin/paup" >> "${GITHUB_ENV}"
- name: Install coverage dependencies
run: |
python3 -m pip install pytest
python3 -m pip install pytest-cov
- name: Generate coverage report
run: |
python3 -m pytest tests --cov=tests/dendropy --cov-report=xml
- uses: codecov/codecov-action@v4
with:
token: ae13d715-bae4-4e6d-9dce-f47e7d7c7c01
flags: unittests # optional
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (default = false)
packaging-bdist:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install build tools
run: python3 -m pip install pip setuptools wheel --upgrade
- name: Build bdist
run: |
python3 setup.py bdist_wheel
tree dist
- name: Upgrade pip
run: python3 -m pip install pip --upgrade
- name: Install from bdist
run: python3 -m pip install dist/*.whl
- name: Test install
run: |
find . -type f -name '*.py' -exec rm {} \;
python3 -c "import dendropy; print(dendropy.__version__)"
packaging-sdist:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install build tools
run: python3 -m pip install pip setuptools wheel --upgrade
- name: Build sdist
run: |
python3 setup.py sdist
tree dist
- name: Install from sdist
run: python3 -m pip install dist/*.tar.gz
- name: Test install
run: |
find . -type f -name '*.py' -exec rm {} \;
python3 -c "import dendropy; print(dendropy.__version__)"
packaging-source:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Upgrade pip
run: python3 -m pip install pip --upgrade
- name: Install from source
run: python3 -m pip install .
- name: Test install
run: |
find . -type f -name '*.py' -exec rm {} \;
python3 -c "import dendropy; print(dendropy.__version__)"
docs:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v4
continue-on-error: true
with:
python-version: 3.9
- name: Upgrade pip
run: python3 -m pip install pip --upgrade
- name: Install from source
run: python3 -m pip install .
- name: Install documentation build dependencies
run: python3 -m pip install -r docs/requirements.txt
- name: Build documentation
run: make -C docs html
- name: Deploy docs
if: github.ref == 'refs/heads/main'
uses: actions/upload-pages-artifact@v3
with:
path: docs/build/html # The folder the action should deploy.
# uses: JamesIves/github-pages-deploy-action@v4
# with:
# folder: docs/build/html # The folder the action should deploy.
# uses: jsmrcaga/[email protected]
# with:
# NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
# NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
# NETLIFY_DEPLOY_MESSAGE: "Prod deploy v${{ github.ref }}"
# NETLIFY_DEPLOY_TO_PROD: true
# install_command: "echo Skipping installing the dependencies"
# build_command: "echo Skipping building the web files"
# build_directory: docs/build/html
deploy-docs:
if: github.ref == 'refs/heads/main'
# Add a dependency to the build job
needs: docs
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source
# Deploy to the github-pages environment
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4 # or specific "vX.X.X" version tag for this
deploy:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v')
needs:
- examples
- lint
- tests
steps:
- uses: actions/checkout@v1
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- run: python setup.py sdist bdist_wheel
- name: Publish package
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}