File tree Expand file tree Collapse file tree 2 files changed +23
-1
lines changed Expand file tree Collapse file tree 2 files changed +23
-1
lines changed Original file line number Diff line number Diff line change @@ -217,6 +217,7 @@ def _dotv(version):
217217autopackage_name = ["iris" ]
218218autoclass_content = "both"
219219modindex_common_prefix = ["iris" ]
220+ # autodoc_suppress_warnings = ["index"]
220221
221222# -- apidoc extension ---------------------------------------------------------
222223# See https://github.com/sphinx-contrib/apidoc
Original file line number Diff line number Diff line change 2828
2929from .._deprecation import warn_deprecated
3030from ..ugrid .load import PARSE_UGRID_ON_LOAD , load_mesh , load_meshes
31- from ..ugrid .mesh import Connectivity , Mesh , MeshCoord
31+ from ..ugrid .mesh import Connectivity as _ConnectivityClass
32+ from ..ugrid .mesh import Mesh as _MeshClass
33+ from ..ugrid .mesh import MeshCoord as _MeshCoordClass
3234from ..ugrid .save import save_mesh
3335from ..ugrid .utils import recombine_submeshes
3436
37+
38+ # Generate own duplicate definitions of the duplicated classes,
39+ # purely because this prevents Sphinx from complaining about duplicate index items.
40+ # (e.g. "WARNING: duplicate object description of iris.ugrid.mesh.Mesh, other instance
41+ # in generated/api/iris.experimental.ugrid, use :no-index: for one of them"
42+ # )
43+ # For some reason, this only happens for classes, and not functions.
44+ class Connectivity (_ConnectivityClass ):
45+ pass
46+
47+
48+ class Mesh (_MeshClass ):
49+ pass
50+
51+
52+ class MeshCoord (_MeshCoordClass ):
53+ pass
54+
55+
3556__all__ = [
3657 "Connectivity" ,
3758 "Mesh" ,
You can’t perform that action at this time.
0 commit comments