Fix doctest on pygmt.datasets.tile_map.load_tile_map in ci_tests_legacy #3642
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of proposed changes
Fix doctest failure on
ci_tests_legacy.yamlcaused by the changes made in #3575/#3576 that made it incompatible with older versions of rasterio<1.4.2_______________ [doctest] pygmt.datasets.tile_map.load_tile_map ________________ 118 >>> raster.sizes 119 Frozen({'band': 3, 'y': 256, 'x': 512}) 120 >>> raster.coords # doctest: +ELLIPSIS, +NORMALIZE_WHITESPACE 121 Coordinates: 122 * band (band) uint8... 1 2 3 123 * y (y) float64... -7.081e-10 -7.858e+04 ... -1.996e+07 -2.004e+07 124 * x (x) float64... -2.004e+07 -1.996e+07 ... 1.996e+07 2.004e+07 125 spatial_ref int... 0 126 >>> # CRS is set only if rioxarray is available 127 >>> if hasattr(raster, "rio"): Expected: CRS.from_wkt(...) Got: CRS.from_epsg(3857) /home/runner/work/pygmt/pygmt/pygmt/datasets/tile_map.py:127: DocTestFailureFixes ##3641 (comment), patches #3576
Preview:
Reminders
make formatandmake checkto make sure the code follows the style guide.doc/api/index.rst.Slash Commands
You can write slash commands (
/command) in the first line of a comment to performspecific operations. Supported slash command is:
/format: automatically format and lint the code