From 539f3e80169e2c12a2d041c4bdfed80ec93e9899 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 24 Sep 2024 15:40:54 +0800 Subject: [PATCH 01/12] Drop support for GMT 6.3 --- pygmt/clib/session.py | 12 ++---------- pygmt/src/timestamp.py | 10 +++++----- pygmt/tests/test_accessor.py | 4 ---- pygmt/tests/test_clib.py | 3 ++- pygmt/tests/test_datasets_load_remote_datasets.py | 4 +--- pygmt/tests/test_grdfill.py | 9 +-------- pygmt/tests/test_grdfilter.py | 7 +------ pygmt/tests/test_grdlandmask.py | 7 +------ pygmt/tests/test_grdsample.py | 7 +------ pygmt/tests/test_sph2grd.py | 7 +------ 10 files changed, 15 insertions(+), 55 deletions(-) diff --git a/pygmt/clib/session.py b/pygmt/clib/session.py index 95ed8c19d76..97d25ad1c55 100644 --- a/pygmt/clib/session.py +++ b/pygmt/clib/session.py @@ -17,7 +17,6 @@ import numpy as np import pandas as pd import xarray as xr -from packaging.version import Version from pygmt.clib.conversion import ( array_to_datetime, as_c_contiguous, @@ -199,15 +198,8 @@ def info(self): "cores": self.get_default("API_CORES"), "grid layout": self.get_default("API_GRID_LAYOUT"), } - # For GMT<6.4.0, API_IMAGE_LAYOUT is not defined if GMT is not - # compiled with GDAL. Since GMT 6.4.0, GDAL is a required GMT - # dependency. The code block can be refactored after we bump - # the minimum required GMT version to 6.4.0. - with contextlib.suppress(GMTCLibError): - self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") - # API_BIN_VERSION is new in GMT 6.4.0. - if Version(self._info["version"]) >= Version("6.4.0"): - self._info["binary version"] = self.get_default("API_BIN_VERSION") + self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") + self._info["binary version"] = self.get_default("API_BIN_VERSION") return self._info def __enter__(self): diff --git a/pygmt/src/timestamp.py b/pygmt/src/timestamp.py index 39a6c25bf39..d09a86f446d 100644 --- a/pygmt/src/timestamp.py +++ b/pygmt/src/timestamp.py @@ -53,7 +53,7 @@ def timestamp( font Font of the timestamp and the optional label. Since the GMT logo has a fixed height, the font sizes are fixed to be 8-point for the timestamp and 7-point for - the label. The parameter can't change the font color for GMT<=6.4.0, only the + the label. The parameter can't change the font color for GMT 6.4.0, only the font style. timefmt Format string for the UNIX timestamp. The format string is parsed by the C @@ -83,8 +83,8 @@ def timestamp( kwdict["U"] += f"{label}" kwdict["U"] += f"+j{justify}" - if Version(__gmt_version__) <= Version("6.4.0") and "/" not in str(offset): - # Giving a single offset doesn't work in GMT <= 6.4.0. + if Version(__gmt_version__) < Version("6.5.0") and "/" not in str(offset): + # Giving a single offset doesn't work in GMT < 6.5.0. # See https://github.com/GenericMappingTools/gmt/issues/7107. offset = f"{offset}/{offset}" kwdict["U"] += f"+o{offset}" @@ -98,8 +98,8 @@ def timestamp( "The given text string will be truncated to 64 characters." ) warnings.warn(message=msg, category=RuntimeWarning, stacklevel=2) - if Version(__gmt_version__) <= Version("6.4.0"): - # workaround for GMT<=6.4.0 by overriding the 'timefmt' parameter + if Version(__gmt_version__) < Version("6.5.0"): + # Workaround for GMT<6.5.0 by overriding the 'timefmt' parameter timefmt = text[:64] else: kwdict["U"] += f"+t{text}" diff --git a/pygmt/tests/test_accessor.py b/pygmt/tests/test_accessor.py index e5e4534e1c3..2701d2a0b3a 100644 --- a/pygmt/tests/test_accessor.py +++ b/pygmt/tests/test_accessor.py @@ -73,10 +73,6 @@ def test_accessor_set_non_boolean(): grid.gmt.gtype = 2 -@pytest.mark.skipif( - Version(__gmt_version__) < Version("6.4.0"), - reason="Upstream bug fixed in https://github.com/GenericMappingTools/gmt/pull/6615", -) @pytest.mark.xfail( condition=sys.platform == "win32" and Version(__gmt_version__) < Version("6.5.0"), reason="Upstream bug fixed in https://github.com/GenericMappingTools/gmt/pull/7573", diff --git a/pygmt/tests/test_clib.py b/pygmt/tests/test_clib.py index 7591aff0729..7747c1551bc 100644 --- a/pygmt/tests/test_clib.py +++ b/pygmt/tests/test_clib.py @@ -11,6 +11,7 @@ import xarray as xr from packaging.version import Version from pygmt import Figure, clib +from pygmt.clib import required_gmt_version from pygmt.clib.conversion import dataarray_to_matrix from pygmt.clib.session import FAMILIES, VIAS from pygmt.exceptions import ( @@ -531,7 +532,7 @@ def test_get_default(): with clib.Session() as lib: assert lib.get_default("API_GRID_LAYOUT") in {"rows", "columns"} assert int(lib.get_default("API_CORES")) >= 1 - assert Version(lib.get_default("API_VERSION")) >= Version("6.3.0") + assert Version(lib.get_default("API_VERSION")) >= Version(required_gmt_version) assert lib.get_default("PROJ_LENGTH_UNIT") == "cm" diff --git a/pygmt/tests/test_datasets_load_remote_datasets.py b/pygmt/tests/test_datasets_load_remote_datasets.py index b46e21e2f94..b2de1ebddfa 100644 --- a/pygmt/tests/test_datasets_load_remote_datasets.py +++ b/pygmt/tests/test_datasets_load_remote_datasets.py @@ -32,10 +32,8 @@ def test_load_remote_dataset_benchmark_with_region(): assert data.attrs["horizontal_datum"] == "WGS84" assert data.gmt.registration == 0 assert data.shape == (11, 21) - # The cpt attribute was added since GMT 6.4.0 # Can't access the cpt attribute using virtual files - # if Version(__gmt_version__) >= Version("6.4.0"): - # assert data.attrs["cpt"] == "@earth_age.cpt" + # assert data.attrs["cpt"] == "@earth_age.cpt" def test_load_remote_dataset_invalid_resolutions(): diff --git a/pygmt/tests/test_grdfill.py b/pygmt/tests/test_grdfill.py index 35be47ebef4..f7c4730b744 100644 --- a/pygmt/tests/test_grdfill.py +++ b/pygmt/tests/test_grdfill.py @@ -7,9 +7,7 @@ import numpy as np import pytest import xarray as xr -from packaging.version import Version from pygmt import grdfill, load_dataarray -from pygmt.clib import __gmt_version__ from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile from pygmt.helpers.testing import load_static_earth_relief @@ -86,16 +84,11 @@ def test_grdfill_dataarray_out(grid, expected_grid): xr.testing.assert_allclose(a=result, b=expected_grid) -@pytest.mark.skipif( - Version(__gmt_version__) < Version("6.4.0"), - reason="Upstream bug/crash fixed in https://github.com/GenericMappingTools/gmt/pull/6418.", -) def test_grdfill_asymmetric_pad(grid, expected_grid): """ Test grdfill using a region that includes the edge of the grid. - Regression test for - https://github.com/GenericMappingTools/pygmt/issues/1745. + Regression test for https://github.com/GenericMappingTools/pygmt/issues/1745. """ result = grdfill(grid=grid, mode="c20", region=[-55, -50, -24, -16]) # check information of the output grid diff --git a/pygmt/tests/test_grdfilter.py b/pygmt/tests/test_grdfilter.py index a2604d8b00e..5cbe3574767 100644 --- a/pygmt/tests/test_grdfilter.py +++ b/pygmt/tests/test_grdfilter.py @@ -7,16 +7,11 @@ import numpy as np import pytest import xarray as xr -from packaging.version import Version from pygmt import grdfilter, load_dataarray -from pygmt.clib import __gmt_version__ from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile from pygmt.helpers.testing import load_static_earth_relief -# GMT 6.3 on conda-forge doesn't have OpenMP enabled. -cores = 2 if Version(__gmt_version__) > Version("6.3.0") else None - @pytest.fixture(scope="module", name="grid") def fixture_grid(): @@ -51,7 +46,7 @@ def test_grdfilter_dataarray_in_dataarray_out(grid, expected_grid): Test grdfilter with an input DataArray, and output as DataArray. """ result = grdfilter( - grid=grid, filter="g600", distance="4", region=[-53, -49, -20, -17], cores=cores + grid=grid, filter="g600", distance="4", region=[-53, -49, -20, -17], cores=2 ) # check information of the output grid assert isinstance(result, xr.DataArray) diff --git a/pygmt/tests/test_grdlandmask.py b/pygmt/tests/test_grdlandmask.py index d275da5cd4b..ae51ba2eda4 100644 --- a/pygmt/tests/test_grdlandmask.py +++ b/pygmt/tests/test_grdlandmask.py @@ -6,15 +6,10 @@ import pytest import xarray as xr -from packaging.version import Version from pygmt import grdlandmask, load_dataarray -from pygmt.clib import __gmt_version__ from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile -# GMT 6.3 on conda-forge doesn't have OpenMP enabled. -cores = 2 if Version(__gmt_version__) > Version("6.3.0") else None - @pytest.fixture(scope="module", name="expected_grid") def fixture_expected_grid(): @@ -55,7 +50,7 @@ def test_grdlandmask_no_outgrid(expected_grid): """ Test grdlandmask with no set outgrid. """ - result = grdlandmask(spacing=1, region=[125, 130, 30, 35], cores=cores) + result = grdlandmask(spacing=1, region=[125, 130, 30, 35], cores=2) # check information of the output grid assert isinstance(result, xr.DataArray) assert result.gmt.gtype == 1 # Geographic grid diff --git a/pygmt/tests/test_grdsample.py b/pygmt/tests/test_grdsample.py index 11812a1226a..4c9e64139c3 100644 --- a/pygmt/tests/test_grdsample.py +++ b/pygmt/tests/test_grdsample.py @@ -6,15 +6,10 @@ import pytest import xarray as xr -from packaging.version import Version from pygmt import grdsample, load_dataarray -from pygmt.clib import __gmt_version__ from pygmt.helpers import GMTTempFile from pygmt.helpers.testing import load_static_earth_relief -# GMT 6.3 on conda-forge doesn't have OpenMP enabled. -cores = 2 if Version(__gmt_version__) > Version("6.3.0") else None - @pytest.fixture(scope="module", name="grid") def fixture_grid(): @@ -80,7 +75,7 @@ def test_grdsample_dataarray_out(grid, expected_grid, region, spacing): """ Test grdsample with no outgrid set and the spacing is changed. """ - result = grdsample(grid=grid, spacing=spacing, region=region, cores=cores) + result = grdsample(grid=grid, spacing=spacing, region=region, cores=2) # check information of the output grid assert isinstance(result, xr.DataArray) assert result.gmt.gtype == 1 # Geographic grid diff --git a/pygmt/tests/test_sph2grd.py b/pygmt/tests/test_sph2grd.py index 820b8923240..89b4abeff25 100644 --- a/pygmt/tests/test_sph2grd.py +++ b/pygmt/tests/test_sph2grd.py @@ -6,14 +6,9 @@ import numpy.testing as npt import pytest -from packaging.version import Version from pygmt import sph2grd -from pygmt.clib import __gmt_version__ from pygmt.helpers import GMTTempFile -# GMT 6.3 on conda-forge doesn't have OpenMP enabled. -cores = 2 if Version(__gmt_version__) > Version("6.3.0") else None - def test_sph2grd_outgrid(): """ @@ -32,7 +27,7 @@ def test_sph2grd_no_outgrid(): """ Test sph2grd with no set outgrid. """ - temp_grid = sph2grd(data="@EGM96_to_36.txt", spacing=1, region="g", cores=cores) + temp_grid = sph2grd(data="@EGM96_to_36.txt", spacing=1, region="g", cores=2) assert temp_grid.dims == ("y", "x") assert temp_grid.gmt.gtype == 0 # Cartesian grid assert temp_grid.gmt.registration == 0 # Gridline registration From bd390eebd3117dbb35c059b0c50de805ae935b84 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 24 Sep 2024 18:15:42 +0800 Subject: [PATCH 02/12] Minor fix docstring of Figure.timestamp --- pygmt/src/timestamp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pygmt/src/timestamp.py b/pygmt/src/timestamp.py index d09a86f446d..9818a289974 100644 --- a/pygmt/src/timestamp.py +++ b/pygmt/src/timestamp.py @@ -53,7 +53,7 @@ def timestamp( font Font of the timestamp and the optional label. Since the GMT logo has a fixed height, the font sizes are fixed to be 8-point for the timestamp and 7-point for - the label. The parameter can't change the font color for GMT 6.4.0, only the + the label. The parameter can't change the font color for GMT<=6.4.0, only the font style. timefmt Format string for the UNIX timestamp. The format string is parsed by the C From b0e6c69443f1da34f8c59223b7c4239a18d58a95 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 24 Sep 2024 18:22:00 +0800 Subject: [PATCH 03/12] Add the GMT 6.3 compatibility codes back to pygmt/clib/session.py --- pygmt/clib/session.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/pygmt/clib/session.py b/pygmt/clib/session.py index 97d25ad1c55..a978ec52f98 100644 --- a/pygmt/clib/session.py +++ b/pygmt/clib/session.py @@ -198,8 +198,14 @@ def info(self): "cores": self.get_default("API_CORES"), "grid layout": self.get_default("API_GRID_LAYOUT"), } - self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") - self._info["binary version"] = self.get_default("API_BIN_VERSION") + # API_IMAGE_LAYOUT is only defined when GMT is linked with the GDAL library. + # GDAL is a optional dependency in GMT 6.3.0 and is required since 6.4.0. + # API_BIN_VERSION is available since GMT 6.4.0. + # Here, we suppress the GMTCLibError exception to provide GMT 6.3 support + # with mininal efforts. + with contextlib.suppress(GMTCLibError): + self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") + self._info["binary version"] = self.get_default("API_BIN_VERSION") return self._info def __enter__(self): From c6860b2a35c525bec022fbc13a44df478e4538f0 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 24 Sep 2024 19:46:26 +0800 Subject: [PATCH 04/12] Temporarily revert the changes in test_grdfill.py --- pygmt/tests/test_grdfill.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pygmt/tests/test_grdfill.py b/pygmt/tests/test_grdfill.py index f7c4730b744..35be47ebef4 100644 --- a/pygmt/tests/test_grdfill.py +++ b/pygmt/tests/test_grdfill.py @@ -7,7 +7,9 @@ import numpy as np import pytest import xarray as xr +from packaging.version import Version from pygmt import grdfill, load_dataarray +from pygmt.clib import __gmt_version__ from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile from pygmt.helpers.testing import load_static_earth_relief @@ -84,11 +86,16 @@ def test_grdfill_dataarray_out(grid, expected_grid): xr.testing.assert_allclose(a=result, b=expected_grid) +@pytest.mark.skipif( + Version(__gmt_version__) < Version("6.4.0"), + reason="Upstream bug/crash fixed in https://github.com/GenericMappingTools/gmt/pull/6418.", +) def test_grdfill_asymmetric_pad(grid, expected_grid): """ Test grdfill using a region that includes the edge of the grid. - Regression test for https://github.com/GenericMappingTools/pygmt/issues/1745. + Regression test for + https://github.com/GenericMappingTools/pygmt/issues/1745. """ result = grdfill(grid=grid, mode="c20", region=[-55, -50, -24, -16]) # check information of the output grid From 66e5c76d2c9f28fa1324d7173b6fdab47b5b1ac4 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 24 Sep 2024 20:20:36 +0800 Subject: [PATCH 05/12] Revert "Temporarily revert the changes in test_grdfill.py" This reverts commit c6860b2a35c525bec022fbc13a44df478e4538f0. --- pygmt/tests/test_grdfill.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/pygmt/tests/test_grdfill.py b/pygmt/tests/test_grdfill.py index 35be47ebef4..f7c4730b744 100644 --- a/pygmt/tests/test_grdfill.py +++ b/pygmt/tests/test_grdfill.py @@ -7,9 +7,7 @@ import numpy as np import pytest import xarray as xr -from packaging.version import Version from pygmt import grdfill, load_dataarray -from pygmt.clib import __gmt_version__ from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile from pygmt.helpers.testing import load_static_earth_relief @@ -86,16 +84,11 @@ def test_grdfill_dataarray_out(grid, expected_grid): xr.testing.assert_allclose(a=result, b=expected_grid) -@pytest.mark.skipif( - Version(__gmt_version__) < Version("6.4.0"), - reason="Upstream bug/crash fixed in https://github.com/GenericMappingTools/gmt/pull/6418.", -) def test_grdfill_asymmetric_pad(grid, expected_grid): """ Test grdfill using a region that includes the edge of the grid. - Regression test for - https://github.com/GenericMappingTools/pygmt/issues/1745. + Regression test for https://github.com/GenericMappingTools/pygmt/issues/1745. """ result = grdfill(grid=grid, mode="c20", region=[-55, -50, -24, -16]) # check information of the output grid From 33c1061b374e30f4cfa8bf756ea102a894762765 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Wed, 25 Sep 2024 07:54:24 +0800 Subject: [PATCH 06/12] Remove the GMT 6.3 CI matrix from the 'GMT Legacy Tests' workflow --- .github/workflows/ci_tests_legacy.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_tests_legacy.yaml b/.github/workflows/ci_tests_legacy.yaml index 94cb15bef51..b36b06e73f5 100644 --- a/.github/workflows/ci_tests_legacy.yaml +++ b/.github/workflows/ci_tests_legacy.yaml @@ -35,7 +35,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-20.04, macos-12, windows-2019] - gmt_version: ['6.3', '6.4'] + gmt_version: ['6.4'] timeout-minutes: 30 defaults: run: From 23a7a78c07b928eea827bea2f023b25421ba4538 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 26 Sep 2024 14:04:15 +0800 Subject: [PATCH 07/12] Improve the comments in pygmt/clib/session.py --- pygmt/clib/session.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pygmt/clib/session.py b/pygmt/clib/session.py index a978ec52f98..34a9bc1f9d3 100644 --- a/pygmt/clib/session.py +++ b/pygmt/clib/session.py @@ -198,11 +198,11 @@ def info(self): "cores": self.get_default("API_CORES"), "grid layout": self.get_default("API_GRID_LAYOUT"), } - # API_IMAGE_LAYOUT is only defined when GMT is linked with the GDAL library. - # GDAL is a optional dependency in GMT 6.3.0 and is required since 6.4.0. + # API_IMAGE_LAYOUT is available only if GMT is linked with the GDAL library. + # GDAL is a optional dependency in GMT 6.3.0 but is required since 6.4.0. # API_BIN_VERSION is available since GMT 6.4.0. - # Here, we suppress the GMTCLibError exception to provide GMT 6.3 support - # with mininal efforts. + # Here, we suppress the GMTCLibError exception to make PyGMT compatible with + # GMT 6.3.0 with minimal effort. with contextlib.suppress(GMTCLibError): self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") self._info["binary version"] = self.get_default("API_BIN_VERSION") From 71a0b36945bd2e8e437ca5a77d47cb8c220300d6 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Mon, 30 Sep 2024 13:29:41 +0800 Subject: [PATCH 08/12] Bump minimum required version to GMT>=6.4.0 --- pygmt/clib/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pygmt/clib/__init__.py b/pygmt/clib/__init__.py index 9f145716f0e..3d5d6b1a507 100644 --- a/pygmt/clib/__init__.py +++ b/pygmt/clib/__init__.py @@ -9,7 +9,7 @@ from pygmt.clib.session import Session, __gmt_version__ from pygmt.exceptions import GMTVersionError -required_gmt_version = "6.3.0" +required_gmt_version = "6.4.0" # Check if the GMT version is older than the required version. if Version(__gmt_version__) < Version(required_gmt_version): From 4abf4f5d4f0b112e57b46aff25454d866d450af1 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Mon, 30 Sep 2024 13:31:52 +0800 Subject: [PATCH 09/12] Refactor the Session.info method since we now requires GMT>=6.4.0 --- pygmt/clib/session.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/pygmt/clib/session.py b/pygmt/clib/session.py index 34a9bc1f9d3..376d441746a 100644 --- a/pygmt/clib/session.py +++ b/pygmt/clib/session.py @@ -197,15 +197,9 @@ def info(self): "library path": self.get_default("API_LIBRARY"), "cores": self.get_default("API_CORES"), "grid layout": self.get_default("API_GRID_LAYOUT"), + "image layout": self.get_default("API_IMAGE_LAYOUT"), + "binary version": self.get_default("API_BIN_VERSION"), } - # API_IMAGE_LAYOUT is available only if GMT is linked with the GDAL library. - # GDAL is a optional dependency in GMT 6.3.0 but is required since 6.4.0. - # API_BIN_VERSION is available since GMT 6.4.0. - # Here, we suppress the GMTCLibError exception to make PyGMT compatible with - # GMT 6.3.0 with minimal effort. - with contextlib.suppress(GMTCLibError): - self._info["image layout"] = self.get_default("API_IMAGE_LAYOUT") - self._info["binary version"] = self.get_default("API_BIN_VERSION") return self._info def __enter__(self): From 9a2983a668c2a0ee2e2dfb05b3eee33076a1c1e7 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Mon, 30 Sep 2024 13:33:25 +0800 Subject: [PATCH 10/12] Update one comment about GMT 6.3 --- pygmt/tests/test_subplot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pygmt/tests/test_subplot.py b/pygmt/tests/test_subplot.py index c6b2109d0fe..2de10bd02e3 100644 --- a/pygmt/tests/test_subplot.py +++ b/pygmt/tests/test_subplot.py @@ -104,7 +104,7 @@ def test_subplot_nrows_ncols_less_than_one_error(): pass -# Increase tolerance for compatibility with GMT 6.3 and 6.4, see +# Increase tolerance for compatibility with GMT 6.4, see # https://github.com/GenericMappingTools/pygmt/pull/2454 @pytest.mark.mpl_image_compare(tolerance=4.0) def test_subplot_outside_plotting_positioning(): From 770b0110dc8fe6aa8c7fb272779f456d11d45f3a Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Mon, 30 Sep 2024 13:34:44 +0800 Subject: [PATCH 11/12] Remove the sentence from doc/contributing.md --- doc/contributing.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/contributing.md b/doc/contributing.md index d5ac0ac1875..5dd93418f53 100644 --- a/doc/contributing.md +++ b/doc/contributing.md @@ -64,7 +64,7 @@ the problem: python .py 2>&1 | awk -F': ' '$2=="GMT_Call_Command string" {print $3}' - where `` is the name of your test script. Note that this script works only with GMT>=6.4 + where `` is the name of your test script. * If the bug is produced when passing an in-memory data object (e.g., a pandas.DataFrame or xarray.DataArray) to a PyGMT function, try writing the data to a file (e.g., a netCDF or ASCII txt file) and passing the data file From 5ab519c45ad53bd7ebee50696bf2075c17db9f72 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 1 Oct 2024 09:06:33 +0800 Subject: [PATCH 12/12] Fix the description about gs --- doc/install.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/install.md b/doc/install.md index e94b68ee914..b050f39d10a 100644 --- a/doc/install.md +++ b/doc/install.md @@ -308,5 +308,5 @@ especially regarding transparency. If the transparency doesn't work in your figu please check your GMT and Ghostscript versions (you can run `pygmt.show_versions()`). We recommend: -- Ghostscript 9.53-9.56 for GMT 6.3.0/6.4.0 +- Ghostscript 9.53-9.56 for GMT 6.4.0 (or below) - Ghostscript 10.03 or later for GMT 6.5.0