From 8bd62d24493e25091f42938bfbfd5e297dda2736 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 29 Aug 2024 16:46:27 +0800 Subject: [PATCH 1/8] Add a separate job for testing geopandas v0.x --- .github/workflows/ci_tests.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 5b6410021cd..1de2169f6e0 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -79,6 +79,13 @@ jobs: pandas-version: '' xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' + - name: ubuntu-latest - Python 3.10 / GeoPandas v0.x + os: 'ubuntu-latest' + python-version: '3.10' + numpy-version: '1.24' + pandas-version: '' + xarray-version: '' + optional-packages: ' geopandas<1' timeout-minutes: 30 defaults: From 603fd7081303280f2274924197365dceac8ee99c Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 29 Aug 2024 17:05:16 +0800 Subject: [PATCH 2/8] Python 3.11 --- .github/workflows/ci_tests.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 1de2169f6e0..6a795fa1d12 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -79,10 +79,10 @@ jobs: pandas-version: '' xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' - - name: ubuntu-latest - Python 3.10 / GeoPandas v0.x + - name: ubuntu-latest - Python 3.11 / GeoPandas v0.x os: 'ubuntu-latest' - python-version: '3.10' - numpy-version: '1.24' + python-version: '3.11' + numpy-version: '' pandas-version: '' xarray-version: '' optional-packages: ' geopandas<1' From d862ff98b01a2b8a2c950a71d6e7c992a677665b Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 29 Aug 2024 17:12:24 +0800 Subject: [PATCH 3/8] Remove name and add comments --- .github/workflows/ci_tests.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 6a795fa1d12..61f703eafa4 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -79,10 +79,11 @@ jobs: pandas-version: '' xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' - - name: ubuntu-latest - Python 3.11 / GeoPandas v0.x - os: 'ubuntu-latest' + # The job below is for testing geopands v0.x on Ubuntu. Python 3.11 is used + # here, otherwise Python 3.10/3.12 jobs will be override by this one. + - os: 'ubuntu-latest' python-version: '3.11' - numpy-version: '' + numpy-version: '1.24' pandas-version: '' xarray-version: '' optional-packages: ' geopandas<1' From ff57e8794ea3ef4c2239359e9ba80d21460e9cd9 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Wed, 4 Sep 2024 10:33:23 +0800 Subject: [PATCH 4/8] Fix typos MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Yvonne Fröhlich <94163266+yvonnefroehlich@users.noreply.github.com> --- .github/workflows/ci_tests.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 61f703eafa4..2850a3c2395 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -79,8 +79,8 @@ jobs: pandas-version: '' xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' - # The job below is for testing geopands v0.x on Ubuntu. Python 3.11 is used - # here, otherwise Python 3.10/3.12 jobs will be override by this one. + # The job below is for testing geopandas v0.x on Ubuntu. Python 3.11 is used + # here, otherwise Python 3.10/3.12 jobs will be overwridden by this one. - os: 'ubuntu-latest' python-version: '3.11' numpy-version: '1.24' From 0fd06811dc8c8034e9b9264880c0f1ae9946779e Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Wed, 4 Sep 2024 11:35:14 +0800 Subject: [PATCH 5/8] Fix typo Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com> --- .github/workflows/ci_tests.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 2850a3c2395..6052ee2a8c8 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -80,7 +80,7 @@ jobs: xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' # The job below is for testing geopandas v0.x on Ubuntu. Python 3.11 is used - # here, otherwise Python 3.10/3.12 jobs will be overwridden by this one. + # here, otherwise Python 3.10/3.12 jobs will be overridden by this one. - os: 'ubuntu-latest' python-version: '3.11' numpy-version: '1.24' From 3dc8f2e5381f6fb5c249e4db92c465bddaf4779d Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Sat, 14 Sep 2024 07:46:55 +0800 Subject: [PATCH 6/8] Improve the comments --- .github/workflows/ci_tests.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 6052ee2a8c8..2078aa22280 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -79,8 +79,9 @@ jobs: pandas-version: '' xarray-version: '' optional-packages: ' contextily geopandas ipython pyarrow rioxarray sphinx-gallery' - # The job below is for testing geopandas v0.x on Ubuntu. Python 3.11 is used - # here, otherwise Python 3.10/3.12 jobs will be overridden by this one. + # The job below is for testing geopandas v0.x on Ubuntu. + # The python-version here can't be the versions in the matrix.python-version + # defined above. Otherwise, other jobs will be overridden by this one. - os: 'ubuntu-latest' python-version: '3.11' numpy-version: '1.24' From 63f1e74a183f21851e9c6a30f05c7ca87b88392f Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Wed, 25 Sep 2024 08:36:24 +0800 Subject: [PATCH 7/8] Explicitely convert the column with overflow issue --- pygmt/helpers/tempfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pygmt/helpers/tempfile.py b/pygmt/helpers/tempfile.py index 0177f17d435..57a1e370fbf 100644 --- a/pygmt/helpers/tempfile.py +++ b/pygmt/helpers/tempfile.py @@ -153,6 +153,7 @@ def tempfile_from_geojson(geojson): if dtype in {"int", "int64"}: overflow = geojson[col].abs().max() > 2**31 - 1 schema["properties"][col] = "float" if overflow else "int32" + geojson[col] = geojson[col].astype(schema["properties"][col]) ogrgmt_kwargs["schema"] = schema else: # GeoPandas v1.x. # The default engine "pyogrio" doesn't support the 'schema' parameter From 8b49046f264986c24aac2f329f5aafedd1b25cf9 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 26 Sep 2024 11:40:20 +0800 Subject: [PATCH 8/8] Add one more comment --- .github/workflows/ci_tests.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci_tests.yaml b/.github/workflows/ci_tests.yaml index 16b71cc7cca..0b0d3d20d79 100644 --- a/.github/workflows/ci_tests.yaml +++ b/.github/workflows/ci_tests.yaml @@ -83,7 +83,7 @@ jobs: # The python-version here can't be the versions in the matrix.python-version # defined above. Otherwise, other jobs will be overridden by this one. - os: 'ubuntu-latest' - python-version: '3.11' + python-version: '3.11' # Can't be 3.10 or 3.12. numpy-version: '1.24' pandas-version: '' xarray-version: ''