Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into update-baseline-images-for-gmt-dev
Browse files Browse the repository at this point in the history
seisman authored Apr 14, 2022
2 parents 6cff4fb + 13ab551 commit b089189
Showing 112 changed files with 2,417 additions and 626 deletions.
11 changes: 7 additions & 4 deletions .github/ISSUE_TEMPLATE/release_checklist.md
Original file line number Diff line number Diff line change
@@ -21,8 +21,12 @@ assignees: ''
- [ ] Finish up 'Changelog entry for v0.x.x' Pull Request:
- [ ] Add a new entry in `doc/_static/version_switch.js` for documentation switcher
- [ ] Update `CITATION.cff` and BibTeX at https://github.com/GenericMappingTools/pygmt#citing-pygmt
- [ ] Add the documentation link https://github.com/GenericMappingTools/pygmt#documentation-for-other-versions
- [ ] Add compatibility information https://github.com/GenericMappingTools/pygmt#compatibility-with-gmt-and-pythonnumpy-versions
- [ ] Update authorship list
- [ ] Update DOI (and url for BibTeX)
- [ ] Update version
- [ ] Update date released
- [ ] Add the documentation link https://github.com/GenericMappingTools/pygmt#compatibility-with-gmtpythonnumpy-versions
- [ ] Add compatibility information https://github.com/GenericMappingTools/pygmt#compatibility-with-gmtpythonnumpy-versions
- [ ] Copy draft changelog from Release Drafter and edit it to look nice ([see maintainers guide for details](https://www.pygmt.org/dev/maintenance.html#updating-the-changelog))

**Release**:
@@ -33,11 +37,10 @@ assignees: ''
- [ ] Manually upload the pygmt-vX.Y.Z.zip and baseline-images.zip files to https://zenodo.org/deposit, ensure that it is filed under the correct reserved DOI

**After release**:
- [ ] Update conda-forge [pygmt-feedstock](https://github.com/conda-forge/pygmt-feedstock) [Usually done automatically by conda-forge's bot]
- [ ] Update conda-forge [pygmt-feedstock](https://github.com/conda-forge/pygmt-feedstock) [Done automatically by conda-forge's bot, but remember to pin NEP29 versions]
- [ ] Bump PyGMT version on https://github.com/GenericMappingTools/try-gmt (after conda-forge update)
- [ ] Announce the release on:
- [ ] GMT [forum](https://forum.generic-mapping-tools.org/c/news/) (do this announcement first! draft on https://hackmd.io/@pygmt. requires moderator status)
- [ ] [Major/Minor releases only] GMT [website](https://github.com/GenericMappingTools/website) (News)
- [ ] [ResearchGate](https://www.researchgate.net/project/PyGMT-A-Python-interface-for-the-Generic-Mapping-Tools) (after forum announcement)
- [ ] [Twitter](https://twitter.com/gmt_dev) (after forum announcement)
---
8 changes: 4 additions & 4 deletions .github/workflows/cache_data.yaml
Original file line number Diff line number Diff line change
@@ -38,13 +38,13 @@ jobs:
# Install GMT and other required dependencies from conda-forge
- name: Install dependencies
run: |
mamba install gmt=6.3.0 \
numpy pandas xarray netCDF4 packaging matplotlib
mamba install gmt=6.3.0 numpy pandas xarray netCDF4 packaging \
build
# Install the package that we want to test
- name: Install the package
run: |
python setup.py sdist --formats=zip
python -m build --sdist
pip install dist/*
# Download remote files
@@ -54,7 +54,7 @@ jobs:
# Upload the downloaded files as artifacts to GitHub
- name: Upload artifacts to GitHub
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: gmt-cache
path: |
8 changes: 5 additions & 3 deletions .github/workflows/check-links.yml
Original file line number Diff line number Diff line change
@@ -26,7 +26,7 @@ jobs:
path: documentation

- name: Link Checker
uses: lycheeverse/lychee-action@v1.3.2
uses: lycheeverse/lychee-action@v1.4.1
with:
# 429: Too many requests
args: >
@@ -41,7 +41,9 @@ jobs:
--exclude "^file://"
--exclude "^https://docs.generic-mapping-tools.org/latest/%s$"
--exclude "^https://docs.generic-mapping-tools.org/latest/%3Cmodule-name%3E.html$"
--exclude "https://hackmd.io/@pygmt"
--exclude "^https://www.generic-mapping-tools.org/remote-datasets/%s$"
--exclude "^https://hackmd.io/@pygmt"
--exclude "^https://doi.org"
--verbose
"repository/**/*.rst"
"repository/**/*.md"
@@ -55,7 +57,7 @@ jobs:
run: echo "::set-output name=date::$(date +'%Y-%m-%d')"

- name: Create Issue From File
uses: peter-evans/create-issue-from-file@v3
uses: peter-evans/create-issue-from-file@v4
with:
title: Link Checker Report on ${{ steps.date.outputs.date }}
content-filepath: ./lychee/out.md
8 changes: 4 additions & 4 deletions .github/workflows/ci_docs.yml
Original file line number Diff line number Diff line change
@@ -24,12 +24,12 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ['3.9']
python-version: ['3.10']
os: [ubuntu-latest, macOS-latest, windows-latest]
# Is it a draft Pull Request (true or false)?
isDraft:
- ${{ github.event.pull_request.draft }}
# Only run one job (Ubuntu + Python 3.9) for draft PRs
# Only run one job (Ubuntu + Python 3.10) for draft PRs
exclude:
- os: macOS-latest
isDraft: true
@@ -71,7 +71,7 @@ jobs:
- name: Install dependencies
run: |
mamba install gmt=6.3.0 numpy pandas xarray netCDF4 packaging \
ipython make myst-parser geopandas \
build ipython make myst-parser geopandas \
sphinx sphinx-copybutton sphinx-gallery sphinx_rtd_theme
# Show installed pkg information for postmortem diagnostic
@@ -99,7 +99,7 @@ jobs:
# Install the package that we want to test
- name: Install the package
run: |
python setup.py sdist --formats=zip
python -m build --sdist
pip install dist/*
# Build the documentation
20 changes: 10 additions & 10 deletions .github/workflows/ci_tests.yaml
Original file line number Diff line number Diff line change
@@ -29,12 +29,12 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ['3.8', '3.9']
python-version: ['3.8', '3.10']
os: [ubuntu-latest, macOS-latest, windows-latest]
# Is it a draft Pull Request (true or false)?
isDraft:
- ${{ github.event.pull_request.draft }}
# Only run one job (Ubuntu + Python 3.9) for draft PRs
# Only run one job (Ubuntu + Python 3.10) for draft PRs
exclude:
- os: macOS-latest
isDraft: true
@@ -43,13 +43,13 @@ jobs:
# - os: ubuntu-latest
# python-version: 3.7
# isDraft: true
# Pair Python 3.8 with NumPy 1.19 and Python 3.9 with NumPy 1.22
# Only install optional packages on Python 3.9/NumPy 1.22
# Pair Python 3.8 with NumPy 1.19 and Python 3.10 with NumPy 1.22
# Only install optional packages on Python 3.10/NumPy 1.22
include:
- python-version: '3.8'
numpy-version: '1.19'
optional-packages: ''
- python-version: '3.9'
- python-version: '3.10'
numpy-version: '1.22'
optional-packages: 'geopandas ipython'
timeout-minutes: 30
@@ -96,8 +96,8 @@ jobs:
mamba install gmt=6.3.0 numpy=${{ matrix.numpy-version }} \
pandas xarray netCDF4 packaging \
${{ matrix.optional-packages }} \
dvc make pytest>=6.0 \
pytest-cov pytest-mpl sphinx-gallery tomli
build dvc make pytest>=6.0 \
pytest-cov pytest-doctestplus pytest-mpl sphinx-gallery tomli
# Show installed pkg information for postmortem diagnostic
- name: List installed packages
@@ -130,7 +130,7 @@ jobs:
# Install the package that we want to test
- name: Install the package
run: |
python setup.py sdist --formats=zip
python -m build --sdist
pip install dist/*
# Run the tests
@@ -139,15 +139,15 @@ jobs:

# Upload diff images on test failure
- name: Upload diff images if any test fails
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
if: ${{ failure() }}
with:
name: artifact-${{ runner.os }}-${{ matrix.python-version }}
path: tmp-test-dir-with-unique-name

# Upload coverage to Codecov
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2.1.0
uses: codecov/codecov-action@v3.0.0
with:
file: ./coverage.xml # optional
env_vars: OS,PYTHON,NUMPY
32 changes: 17 additions & 15 deletions .github/workflows/ci_tests_dev.yaml
Original file line number Diff line number Diff line change
@@ -67,10 +67,18 @@ jobs:
with:
token: ${{ steps.generate-token.outputs.token }}
repository: ${{ github.event.client_payload.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.sha }}
ref: ${{ github.event.client_payload.pull_request.head.ref }}
# fecth all history so that setuptools-scm works
fetch-depth: 0

- name: Show job URL
uses: peter-evans/[email protected]
if: github.event_name == 'repository_dispatch' && (matrix.os == 'ubuntu-latest')
with:
token: ${{ steps.generate-token.outputs.token }}
repository: ${{ github.event.client_payload.github.payload.repository.full_name }}
comment-id: ${{ github.event.client_payload.github.payload.comment.id }}

# Install Mambaforge with conda-forge dependencies
- name: Setup Mambaforge
uses: conda-incubator/[email protected]
@@ -92,14 +100,18 @@ jobs:
geopandas ghostscript libnetcdf hdf5 zlib curl pcre make
pip install --pre --prefer-binary \
numpy pandas xarray netCDF4 packaging \
dvc ipython 'pytest>=6.0' pytest-cov \
pytest-mpl sphinx-gallery tomli
build dvc ipython 'pytest>=6.0' pytest-cov \
pytest-doctestplus pytest-mpl sphinx-gallery tomli
# Pull baseline image data from dvc remote (DAGsHub)
- name: Pull baseline image data from dvc remote
run: |
ORIGINAL_BRANCH=$(git branch --show-current)
# Pull down GMT 6.4 baseline images from the gmt-6.4 branch
git checkout gmt-6.4
dvc pull
ls -lhR pygmt/tests/baseline/
git checkout ${ORIGINAL_BRANCH}
# Build and install latest GMT from GitHub
- name: Install GMT ${{ matrix.gmt_git_ref }} branch (Linux/macOS)
@@ -131,11 +143,10 @@ jobs:
touch ~/.gmt/server/gmt_data_server.txt ~/.gmt/server/gmt_hash_server.txt
ls -lhR ~/.gmt
# Install the package that we want to test
- name: Install the package
run: |
python setup.py sdist --formats=zip
python -m build --sdist
pip install dist/*
- name: Add GMT's bin to PATH (Linux/macOS)
@@ -156,17 +167,8 @@ jobs:

# Upload diff images on test failure
- name: Upload diff images if any test fails
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
if: ${{ failure() }}
with:
name: artifact-GMT-${{ matrix.gmt_git_ref }}-${{ runner.os }}
path: tmp-test-dir-with-unique-name

- name: Add reaction
uses: peter-evans/create-or-update-comment@v1
if: github.event_name == 'repository_dispatch'
with:
token: ${{ steps.generate-token.outputs.token }}
repository: ${{ github.event.client_payload.github.payload.repository.full_name }}
comment-id: ${{ github.event.client_payload.github.payload.comment.id }}
reaction-type: hooray
6 changes: 3 additions & 3 deletions .github/workflows/dvc-diff.yml
Original file line number Diff line number Diff line change
@@ -95,7 +95,7 @@ jobs:
echo ::set-output name=report::$report
- name: Find comment with image diff report
uses: peter-evans/find-comment@v1.3.0
uses: peter-evans/find-comment@v2.0.0
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
@@ -104,14 +104,14 @@ jobs:

- name: Create comment with image diff report
if: steps.fc.outputs.comment-id == ''
uses: peter-evans/create-or-update-comment@v1.4.4
uses: peter-evans/create-or-update-comment@v2
with:
issue-number: ${{ github.event.pull_request.number }}
body: ${{ steps.image-diff.outputs.report }}

- name: Update comment with new image diff report
if: steps.fc.outputs.comment-id != ''
uses: peter-evans/create-or-update-comment@v1.4.4
uses: peter-evans/create-or-update-comment@v2
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
body: ${{ steps.image-diff.outputs.report }}
6 changes: 3 additions & 3 deletions .github/workflows/format-command.yml
Original file line number Diff line number Diff line change
@@ -18,10 +18,10 @@ jobs:
with:
token: ${{ steps.generate-token.outputs.token }}
repository: ${{ github.event.client_payload.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.sha }}
ref: ${{ github.event.client_payload.pull_request.head.ref }}

# Setup Python environment
- uses: actions/setup-python@v2.3.2
- uses: actions/setup-python@v3.1.0

# Install formatting tools
- name: Install formatting tools
@@ -43,7 +43,7 @@ jobs:
fi
- name: Add reaction
uses: peter-evans/create-or-update-comment@v1
uses: peter-evans/create-or-update-comment@v2
with:
token: ${{ steps.generate-token.outputs.token }}
repository: ${{ github.event.client_payload.github.payload.repository.full_name }}
6 changes: 3 additions & 3 deletions .github/workflows/publish-to-pypi.yml
Original file line number Diff line number Diff line change
@@ -29,12 +29,12 @@ jobs:
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v2.3.2
uses: actions/setup-python@v3.1.0
with:
python-version: '3.10'

- name: Install dependencies
run: python -m pip install setuptools wheel
run: python -m pip install build

# This step is only necessary for testing purposes and for TestPyPI
- name: Fix up version string for TestPyPI
@@ -43,7 +43,7 @@ jobs:
# Change setuptools-scm local_scheme to "no-local-version" so the
# local part of the version isn't included, making the version string
# compatible with PyPI.
sed --in-place "s/node-and-date/no-local-version/g" setup.py
sed --in-place "s/node-and-date/no-local-version/g" pyproject.toml
- name: Build source and wheel distributions
run: |
2 changes: 1 addition & 1 deletion .github/workflows/release-baseline-images.yml
Original file line number Diff line number Diff line change
@@ -34,7 +34,7 @@ jobs:
shasum -a 256 baseline-images.zip
- name: Upload baseline image as a release asset
uses: shogo82148/actions-upload-release-asset@v1.5.0
uses: shogo82148/actions-upload-release-asset@v1.6.2
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: baseline-images.zip
2 changes: 1 addition & 1 deletion .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
# Drafts your next Release notes as Pull Requests are merged into "main"
- uses: release-drafter/release-drafter@v5.18.1
- uses: release-drafter/release-drafter@v5.19.0
with:
# (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml
config-name: release-drafter.yml
2 changes: 1 addition & 1 deletion .github/workflows/slash-command-dispatch.yml
Original file line number Diff line number Diff line change
@@ -17,7 +17,7 @@ jobs:
private_key: ${{ secrets.APP_PRIVATE_KEY }}

- name: Slash Command Dispatch
uses: peter-evans/slash-command-dispatch@v2
uses: peter-evans/slash-command-dispatch@v3
with:
token: ${{ steps.generate-token.outputs.token }}
commands: |
2 changes: 1 addition & 1 deletion .github/workflows/style_checks.yaml
Original file line number Diff line number Diff line change
@@ -20,7 +20,7 @@ jobs:

# Setup Miniconda
- name: Set up Python
uses: actions/setup-python@v2.3.2
uses: actions/setup-python@v3.1.0
with:
python-version: '3.10'

24 changes: 12 additions & 12 deletions AUTHORS.md
Original file line number Diff line number Diff line change
@@ -9,16 +9,16 @@ The following people have contributed code and/or documentation to the project
(alphabetical by name) and are considered to be "PyGMT Developers":

* [Abhishek Anant](https://twitter.com/itsabhianant) | [0000-0002-5751-2010](https://orcid.org/0000-0002-5751-2010) | Unaffiliated
* [Dongdong Tian](https://seisman.info/) | [0000-0001-7967-1197](https://orcid.org/0000-0001-7967-1197) | China University of Geosciences
* [Jamie Quinn](http://jamiejquinn.com) | [0000-0002-0268-7032](https://orcid.org/0000-0002-0268-7032) | University College London
* [Jiayuan Yao](https://github.com/core-man) | [0000-0001-7036-4238](https://orcid.org/0000-0001-7036-4238) | Nanyang Technological University
* [Kathryn Materna](https://github.com/kmaterna) | [0000-0002-6687-980X](https://orcid.org/0000-0002-6687-980X) | US Geological Survey
* [Leonardo Uieda](http://www.leouieda.com/) | [0000-0001-6123-9515](https://orcid.org/0000-0001-6123-9515) | University of Liverpool
* [Liam Toney](https://liam.earth/) | [0000-0003-0167-9433](https://orcid.org/0000-0003-0167-9433) | University of Alaska Fairbanks
* [Malte Ziebarth](https://github.com/mjziebarth) | [0000-0002-5190-4478](https://orcid.org/0000-0002-5190-4478) | GFZ German Research Centre for Geosciences
* [Meghan Jones](https://github.com/meghanrjones) | [0000-0003-0180-8928](https://orcid.org/0000-0003-0180-8928) | University of Hawai'i at Mānoa
* [Michael Grund](https://github.com/michaelgrund) | [0000-0001-8759-2018](https://orcid.org/0000-0001-8759-2018) | Innoplexia GmbH
* [Tyler Newton](http://www.tnewton.com/) | [0000-0002-1560-6553](https://orcid.org/0000-0002-1560-6553) | University of Oregon
* [Wei Ji Leong](https://github.com/weiji14) | [0000-0003-2354-1988](https://orcid.org/0000-0003-2354-1988) | The Ohio State University
* [Dongdong Tian](https://seisman.info/) | [0000-0001-7967-1197](https://orcid.org/0000-0001-7967-1197) | China University of Geosciences, China
* [Jamie Quinn](http://jamiejquinn.com) | [0000-0002-0268-7032](https://orcid.org/0000-0002-0268-7032) | University College London, United Kingdom
* [Jiayuan Yao](https://github.com/core-man) | [0000-0001-7036-4238](https://orcid.org/0000-0001-7036-4238) | Nanyang Technological University, Singapore
* [Kathryn Materna](https://github.com/kmaterna) | [0000-0002-6687-980X](https://orcid.org/0000-0002-6687-980X) | US Geological Survey, USA
* [Leonardo Uieda](http://www.leouieda.com/) | [0000-0001-6123-9515](https://orcid.org/0000-0001-6123-9515) | University of Liverpool, United Kingdom
* [Liam Toney](https://liam.earth/) | [0000-0003-0167-9433](https://orcid.org/0000-0003-0167-9433) | University of Alaska Fairbanks, USA
* [Malte Ziebarth](https://github.com/mjziebarth) | [0000-0002-5190-4478](https://orcid.org/0000-0002-5190-4478) | GFZ German Research Centre for Geosciences, Germany
* [Meghan Jones](https://github.com/meghanrjones) | [0000-0003-0180-8928](https://orcid.org/0000-0003-0180-8928) | University of Hawai'i at Mānoa, USA
* [Michael Grund](https://github.com/michaelgrund) | [0000-0001-8759-2018](https://orcid.org/0000-0001-8759-2018) | Innoplexia GmbH, Germany
* [Tyler Newton](http://www.tnewton.com/) | [0000-0002-1560-6553](https://orcid.org/0000-0002-1560-6553) | University of Oregon, USA
* [Wei Ji Leong](https://github.com/weiji14) | [0000-0003-2354-1988](https://orcid.org/0000-0003-2354-1988) | The Ohio State University, USA
* [William Schlitzer](https://github.com/willschlitzer) | [0000-0002-5843-2282](https://orcid.org/0000-0002-5843-2282) | Unaffiliated
* [Yohai Magen](https://github.com/yohaimagen) | [0000-0002-4892-4013](https://orcid.org/0000-0002-4892-4013) | Tel Aviv University
* [Yohai Magen](https://github.com/yohaimagen) | [0000-0002-4892-4013](https://orcid.org/0000-0002-4892-4013) | Tel Aviv University, Israel
Loading

0 comments on commit b089189

Please sign in to comment.