[Git][debian-gis-team/rasterio][master] Add upstream patch to fix test_warp.py with GDAL 3.6.0.

Bas Couwenberg (@sebastic) gitlab at salsa.debian.org
Thu Nov 10 18:23:15 GMT 2022



Bas Couwenberg pushed to branch master at Debian GIS Project / rasterio


Commits:
f0d1ba6f by Bas Couwenberg at 2022-11-10T19:12:23+01:00
Add upstream patch to fix test_warp.py with GDAL 3.6.0.

- - - - -


4 changed files:

- debian/changelog
- − debian/patches/gdal-3.6.0.patch
- + debian/patches/pr2641-test_warp.patch
- debian/patches/series


Changes:

=====================================
debian/changelog
=====================================
@@ -2,6 +2,7 @@ rasterio (1.3.3-3) UNRELEASED; urgency=medium
 
   * Team upload.
   * Add upstream patch to use GTiff driver with GDAL 3.6.0.
+  * Add upstream patch to fix test_warp.py with GDAL 3.6.0.
 
  -- Bas Couwenberg <sebastic at debian.org>  Tue, 08 Nov 2022 05:47:31 +0100
 


=====================================
debian/patches/gdal-3.6.0.patch deleted
=====================================
@@ -1,24 +0,0 @@
-Description: Use xfail for tests that fail with GDAL 3.6.0.
-Author: Bas Couwenberg <sebastic at debian.org>
-Bug: https://github.com/rasterio/rasterio/issues/2632
-Bug-Debian: https://bugs.debian.org/1023480
-Forwarded: not-needed
-
---- a/tests/test_warp.py
-+++ b/tests/test_warp.py
-@@ -1191,6 +1191,7 @@ def test_transform_geom__geo_interface__
-         assert all(round(x, 1) == x for x in flatten_coords(result["coordinates"]))
- 
- 
-+ at pytest.mark.xfail(strict=False, reason='Fails with GDAL 3.6.0')
- @pytest.mark.parametrize("method", SUPPORTED_RESAMPLING)
- def test_reproject_resampling(path_rgb_byte_tif, method):
-     # Expected count of nonzero pixels for each resampling method, based
-@@ -1283,6 +1284,7 @@ def test_reproject_masked(test3d, count_
-     assert np.count_nonzero(out[out != 99]) == count_nonzero
- 
- 
-+ at pytest.mark.xfail(strict=False, reason='Fails with GDAL 3.6.0')
- @pytest.mark.parametrize("method", SUPPORTED_RESAMPLING)
- def test_reproject_resampling_alpha(method):
-     """Reprojection of a source with alpha band succeeds"""


=====================================
debian/patches/pr2641-test_warp.patch
=====================================
@@ -0,0 +1,25 @@
+Description: TST: add expected values to test_reproject_resampling_alpha & test_reproject_resampling for GDAL 3.6
+Author: snowman2 <alansnow21 at gmail.com>
+Origin: https://github.com/rasterio/rasterio/pull/2641/commits/cdb7d3922e8b5039b731c5cf433d1395080580be
+Bug: https://github.com/rasterio/rasterio/issues/2632
+
+--- a/tests/test_warp.py
++++ b/tests/test_warp.py
+@@ -1208,7 +1208,7 @@ def test_reproject_resampling(path_rgb_b
+         Resampling.med: [437194],
+         Resampling.q1: [436397],
+         Resampling.q3: [438948],
+-        Resampling.sum: [439118],
++        Resampling.sum: [439118, 439142],  # 439142 for GDAL 3.6+
+         Resampling.rms: [439385],
+     }
+ 
+@@ -1301,7 +1301,7 @@ def test_reproject_resampling_alpha(meth
+         Resampling.med: [437194],
+         Resampling.q1: [436397],
+         Resampling.q3: [438948],
+-        Resampling.sum: [439118],
++        Resampling.sum: [439118, 439142],  # 439142 for GDAL 3.6+
+         Resampling.rms: [439385],
+     }
+ 


=====================================
debian/patches/series
=====================================
@@ -1,3 +1,3 @@
 0001-Rename-rio-to-rasterio-Closes-788463.patch
 pr2634-ensure-default-driver-for-tif-to-be-GTiff.patch
-gdal-3.6.0.patch
+pr2641-test_warp.patch



View it on GitLab: https://salsa.debian.org/debian-gis-team/rasterio/-/commit/f0d1ba6ffe963591c545e3c1b3a126d47d786432

-- 
View it on GitLab: https://salsa.debian.org/debian-gis-team/rasterio/-/commit/f0d1ba6ffe963591c545e3c1b3a126d47d786432
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20221110/6f4d360e/attachment-0001.htm>


More information about the Pkg-grass-devel mailing list