From 77fbc88655fc6f5cff1def31638adc0fbd6c1871 Mon Sep 17 00:00:00 2001 From: Will Benfold Date: Thu, 16 Dec 2021 17:50:49 +0000 Subject: [PATCH 1/3] Fix cartopy links --- docs/src/userguide/plotting_a_cube.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/src/userguide/plotting_a_cube.rst b/docs/src/userguide/plotting_a_cube.rst index c22ce043c9..969549e026 100644 --- a/docs/src/userguide/plotting_a_cube.rst +++ b/docs/src/userguide/plotting_a_cube.rst @@ -218,7 +218,7 @@ Plotting 2-Dimensional Cubes Creating Maps ------------- Whenever a 2D plot is created using an :class:`iris.coord_systems.CoordSystem`, -a cartopy :class:`~cartopy.mpl.GeoAxes` instance is created, which can be +a cartopy :class:`~cartopy.mpl.geoaxes.GeoAxes` instance is created, which can be accessed with the :func:`matplotlib.pyplot.gca` function. Given the current map, you can draw gridlines and coastlines amongst other @@ -226,8 +226,8 @@ things. .. seealso:: - :meth:`cartopy's gridlines() `, - :meth:`cartopy's coastlines() `. + :meth:`cartopy's gridlines() `, + :meth:`cartopy's coastlines() `. Cube Contour From 59276f7b768da5924daa37c51b507956f9eb4028 Mon Sep 17 00:00:00 2001 From: Will Benfold Date: Fri, 17 Dec 2021 10:59:12 +0000 Subject: [PATCH 2/3] Other broken cartopy links --- lib/iris/plot.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/lib/iris/plot.py b/lib/iris/plot.py index 1db60d0fae..0e9645c783 100644 --- a/lib/iris/plot.py +++ b/lib/iris/plot.py @@ -858,9 +858,9 @@ def _replace_axes_with_cartopy_axes(cartopy_proj): def _ensure_cartopy_axes_and_determine_kwargs(x_coord, y_coord, kwargs): """ - Replace the current non-cartopy axes with :class:`cartopy.mpl.GeoAxes` - and return the appropriate kwargs dict based on the provided coordinates - and kwargs. + Replace the current non-cartopy axes with + :class:`cartopy.mpl.geoaxes.GeoAxes` and return the appropriate kwargs dict + based on the provided coordinates and kwargs. """ # Determine projection. @@ -874,7 +874,7 @@ def _ensure_cartopy_axes_and_determine_kwargs(x_coord, y_coord, kwargs): else: cartopy_proj = ccrs.PlateCarree() - # Ensure the current axes are a cartopy.mpl.GeoAxes instance. + # Ensure the current axes are a cartopy.mpl.geoaxes.GeoAxes instance. axes = kwargs.get("axes") if axes is None: if ( @@ -1430,7 +1430,8 @@ def barbs(u_cube, v_cube, *args, **kwargs): :func:`iris.analysis.cartography.rotate_grid_vectors`. To transform coordinate grid points, you will need to create 2-dimensional arrays of x and y values. These can be transformed with - :meth:`cartopy.crs.CRS.transform_points`. + the :meth:`~cartopy.crs.CRS.transform_points` method of + :class:`cartopy.crs.CRS`. Kwargs: @@ -1478,7 +1479,8 @@ def quiver(u_cube, v_cube, *args, **kwargs): :func:`iris.analysis.cartography.rotate_grid_vectors`. To transform coordinate grid points, you will need to create 2-dimensional arrays of x and y values. These can be transformed with - :meth:`cartopy.crs.CRS.transform_points`. + the :meth:`~cartopy.crs.CRS.transform_points` method of + :class:`cartopy.crs.CRS`. Kwargs: From 4b400fa9b8278f24ff1d0f0ca75045f9ffe857bb Mon Sep 17 00:00:00 2001 From: Will Benfold Date: Tue, 4 Jan 2022 11:21:31 +0000 Subject: [PATCH 3/3] Updated whatsnew --- docs/src/whatsnew/latest.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/src/whatsnew/latest.rst b/docs/src/whatsnew/latest.rst index 63c96f8962..fcbafd0f42 100644 --- a/docs/src/whatsnew/latest.rst +++ b/docs/src/whatsnew/latest.rst @@ -197,6 +197,9 @@ This document explains the changes made to Iris for this release #. `@trexfeathers`_ encouraged contributors to include type hinting in code they are working on - :ref:`code_formatting`. (:pull:`4390`) +#. `@wjbenfold`_ updated Cartopy documentation links to point to the renamed + :class:`cartopy.mpl.geoaxes.GeoAxes`. (:pull:`4464`) + 💼 Internal ===========