Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to build with GDAL 3.8.0 #2965

Closed
sebastic opened this issue Nov 8, 2023 · 1 comment
Closed

Fails to build with GDAL 3.8.0 #2965

sebastic opened this issue Nov 8, 2023 · 1 comment
Assignees
Milestone

Comments

@sebastic
Copy link
Contributor

sebastic commented Nov 8, 2023

As reported in Debian Bug #1055594:

Your package FTBFS with GDAL 3.8.0 from experimental:

=================================== FAILURES ===================================
_____________________________ test_resampling_rms ______________________________

    @requires_gdal33
    def test_resampling_rms():
        """Test Resampling.rms method"""
        with rasterio.open('tests/data/float.tif') as s:
            out_shape = (2, 2)
            rms = s.read(1, out_shape=out_shape, resampling=Resampling.rms)
            expected = np.array([
                [1.35266399, 0.95388681],
                [0.29308701, 1.54074657]], dtype=np.float32)
>           assert (rms == expected).all()  # all True.
E           assert False
E            +  where False = <built-in method all of numpy.ndarray object at 0x7fc748dabe70>()
E            +    where <built-in method all of numpy.ndarray object at 0x7fc748dabe70> = array([[1.352... 1.54074657]]) == array([[1.352...dtype=float32)
E                 Use -v to get more diff.all

tests/test_read_resample.py:106: AssertionError
------------------------------ Captured log call -------------------------------
DEBUG    rasterio._env:env.py:326 GDAL data files are available at built-in paths.
DEBUG    rasterio._env:env.py:326 PROJ data files are available at built-in paths.
DEBUG    rasterio._env:env.py:326 Started GDALEnv: self=<rasterio._env.GDALEnv object at 0x7fc748e43fd0>.
DEBUG    rasterio._env:env.py:362 Stopped GDALEnv <rasterio._env.GDALEnv object at 0x7fc748e43fd0>.
DEBUG    rasterio._env:env.py:326 GDAL data files are available at built-in paths.
DEBUG    rasterio._env:env.py:326 PROJ data files are available at built-in paths.
DEBUG    rasterio._env:env.py:326 Started GDALEnv: self=<rasterio._env.GDALEnv object at 0x7fc748e43730>.
DEBUG    rasterio._env:env.py:362 Stopped GDALEnv <rasterio._env.GDALEnv object at 0x7fc748e43730>.
=============================== warnings summary ===============================
tests/test_cli_main.py:1
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/tests/test_cli_main.py:1: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
    from pkg_resources import iter_entry_points

rasterio/__init__.py:304: 1 warning
tests/test_blocks.py: 5 warnings
tests/test_boundless_read.py: 1 warning
tests/test_crs.py: 1 warning
tests/test_dataset.py: 6 warnings
tests/test_dataset_rw.py: 1 warning
tests/test_dtypes.py: 1 warning
tests/test_gdal_raster_io.py: 14 warnings
tests/test_mask_creation.py: 1 warning
tests/test_no_georef.py: 1 warning
tests/test_open_options.py: 1 warning
tests/test_overviews.py: 1 warning
tests/test_read.py: 1 warning
tests/test_rpcs.py: 1 warning
tests/test_subdatasets.py: 1 warning 
tests/test_tags.py: 1 warning
tests/test_write.py: 6 warnings
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/__init__.py:304: NotGeoreferencedWarning: Dataset has no geotransform, gcps, or rpcs. The identity matrix will be returned.
    dataset = DatasetReader(path, driver=driver, sharing=sharing, **kwargs)
         
tests/test_blocks.py: 5 warnings
tests/test_complex_dtypes.py: 3 warnings
tests/test_creation_options.py: 1 warning
tests/test_dataset.py: 6 warnings
tests/test_dataset_rw.py: 2 warnings
tests/test_descriptions.py: 4 warnings
tests/test_dtypes.py: 1 warning
tests/test_gdal_raster_io.py: 35 warnings
tests/test_no_georef.py: 2 warnings
tests/test_png.py: 1 warning
tests/test_profile.py: 1 warning 
tests/test_rpcs.py: 1 warning
tests/test_scale_offset.py: 8 warnings
tests/test_tags.py: 3 warnings
tests/test_units.py: 4 warnings
tests/test_write.py: 23 warnings
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/__init__.py:314: NotGeoreferencedWarning: Dataset has no geotransform, gcps, or rpcs. The identity matrix will be returned.
    dataset = writer(
 
tests/test_boundless_read.py::test_issue2382
tests/test_memoryfile.py::test_write_rpcs_to_memfile
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/io.py:141: NotGeoreferencedWarning: The given matrix is equal to Affine.identity or its flipped counterpart. GDAL may ignore this matrix and save no geotransform without raising an error. This behavior is somewhat driver-specific.
    return writer(

tests/test_dataset.py: 4 warnings
tests/test_features.py: 9 warnings
tests/test_mask.py: 21 warnings
tests/test_no_georef.py: 1 warning
tests/test_write.py: 2 warnings
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/__init__.py:314: NotGeoreferencedWarning: The given matrix is equal to Affine.identity or its flipped counterpart. GDAL may ignore this matrix and save no geotransform without raising an error. This behavior is somewhat driver-specific.
    dataset = writer(

tests/test_dtypes.py::test_cant_cast_dtype_nan[uint8]
tests/test_dtypes.py::test_cant_cast_dtype_nan[uint16]
tests/test_dtypes.py::test_cant_cast_dtype_nan[uint32]
tests/test_dtypes.py::test_cant_cast_dtype_nan[int32]
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/dtypes.py:224: RuntimeWarning: invalid value encountered in cast
    return np.allclose(values, values.astype(dtype), equal_nan=True)

tests/test_nodata.py::test_set_mem_inf_nodata
tests/test_nodata.py::test_set_mem_nan_nodata
tests/test_warnings.py::test_notgeoref_warning
tests/test_warnings.py::test_no_notgeoref_warning[None-gcps1-None]
tests/test_warnings.py::test_no_notgeoref_warning[None-None-rpcs2]
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/io.py:141: NotGeoreferencedWarning: Dataset has no geotransform, gcps, or rpcs. The identity matrix will be returned.
    return writer(

tests/test_show_versions.py::test_get_deps_info
tests/test_show_versions.py::test_show_versions_with_gdal
  /build/rasterio-1.3.9/.pybuild/cpython3_3.11_rasterio/build/rasterio/_show_versions.py:76: DeprecationWarning: Accessing attrs.__version__ is deprecated and will be removed in a future release. Use importlib.metadata directly to query for attrs's packaging metadata.
    return module.__version__

tests/test_warnings.py::test_no_notgeoref_warning[transform0-None-None]
tests/test_warnings.py::test_no_notgeoref_warning[None-gcps1-None]
tests/test_warnings.py::test_no_notgeoref_warning[None-None-rpcs2]
  /usr/lib/python3/dist-packages/_pytest/python.py:194: PytestRemovedIn8Warning: Passing None has been deprecated.
  See https://docs.pytest.org/en/latest/how-to/capture-warnings.html#additional-use-cases-of-warnings-in-tests for alternatives in common use cases.
    result = testfunction(**testargs)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
FAILED tests/test_read_resample.py::test_resampling_rms - assert False
= 1 failed, 1070 passed, 4 skipped, 6 xfailed, 6 xpassed, 198 warnings in 15.67s =

The full buildlog is attached.

rasterio_1.3.9-2_amd64.build

@sgillies sgillies self-assigned this Nov 9, 2023
@sgillies sgillies added this to the 1.4.0 milestone Nov 9, 2023
@sgillies
Copy link
Member

sgillies commented Nov 9, 2023

@sebastic thanks for the report! We've got the fix for it in #2959, just hasn't made it to a release yet.

@sgillies sgillies closed this as completed Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants