Skip to content

Commit 4c7baed

Browse files
authored
Merge branch 'main' into refactor/data_kind
2 parents 3258fc5 + 221e8d9 commit 4c7baed

File tree

3 files changed

+25
-1
lines changed

3 files changed

+25
-1
lines changed

.github/workflows/benchmarks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ jobs:
8787

8888
# Run the benchmark tests
8989
- name: Run benchmarks
90-
uses: CodSpeedHQ/action@v2.4.3
90+
uses: CodSpeedHQ/action@v3.0.0
9191
with:
9292
# 'bash -el -c' is needed to use the custom shell.
9393
# See https://github.com/CodSpeedHQ/action/issues/65.

doc/external_resources.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,16 @@ to submit a pull request with your recommended addition to the
1212

1313
:::::{grid} 1 2 2 3
1414

15+
::::{grid-item-card} 2024 PyGMT Webinar using Google Colab (in Portuguese)
16+
:link: https://github.com/andrebelem/Oficina_PyGMT
17+
:text-align: center
18+
:margin: 0 3 0 0
19+
20+
![](https://github.com/andrebelem/Oficina_PyGMT/raw/main/Datasets/3D_sample.png)
21+
+++
22+
Andre Belem
23+
::::
24+
1525
::::{grid-item-card} 2022 EGU SC5.2: Crafting beautiful maps with PyGMT
1626
:link: https://www.generic-mapping-tools.org/egu22pygmt/
1727
:text-align: center

pygmt/_show_versions.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,18 @@ def _check_ghostscript_version(gs_version: str) -> str | None:
9696
return None
9797

9898

99+
def _get_gdal_version():
100+
"""
101+
Get GDAL version.
102+
"""
103+
try:
104+
from osgeo import gdal
105+
106+
return gdal.__version__
107+
except ImportError:
108+
return None
109+
110+
99111
def show_versions(file=sys.stdout):
100112
"""
101113
Print various dependency versions which are useful when submitting bug reports.
@@ -120,6 +132,7 @@ def show_versions(file=sys.stdout):
120132
}
121133
deps = [Requirement(v).name for v in importlib.metadata.requires("pygmt")]
122134
gs_version = _get_ghostscript_version()
135+
gdal_version = _get_gdal_version()
123136

124137
lines = []
125138
lines.append("PyGMT information:")
@@ -128,6 +141,7 @@ def show_versions(file=sys.stdout):
128141
lines.extend([f" {key}: {val}" for key, val in sys_info.items()])
129142
lines.append("Dependency information:")
130143
lines.extend([f" {modname}: {_get_module_version(modname)}" for modname in deps])
144+
lines.append(f" gdal: {gdal_version}")
131145
lines.append(f" ghostscript: {gs_version}")
132146
lines.append("GMT library information:")
133147
lines.extend([f" {key}: {val}" for key, val in _get_clib_info().items()])

0 commit comments

Comments
 (0)