class_docstr: The environment in which the ReST files are translated.
  Stores an inventory of cross-file targets and provides doctree
  transformations to resolve links to them.
class_docstr_tok: ["The","environment","in","which","the","ReST","files","are","translated",".","Stores","an","inventory","of","cross-file","targets","and","provides","doctree","transformations","to","resolve","links","to","them","."]
docstr: Do consistency checks.
code: def check_consistency(self) -> None:
      """Do consistency checks."""
      included = set().union(*self.included.values())
      for docname in sorted(self.all_docs):
          if docname not in self.files_to_rebuild:
              if docname == self.config.root_doc:
                  # the master file is not included anywhere ;)
                  continue
              if docname in included:
                  # the document is included from other documents
                  continue
              if "orphan" in self.metadata[docname]:
                  continue
              logger.warning(
                  __("document isn't included in any toctree"),
                  location=docname,
              )
  
      # call check-consistency for all extensions
      for domain in self.domains.values():
          domain.check_consistency()
      self.events.emit("env-check-consistency", self)
  
imports: from __future__ import annotations
  import functools
  import os
  import pickle
  import time
  from collections import defaultdict
  from copy import copy
  from os import path
  from typing import TYPE_CHECKING, Any, Callable, NoReturn
  from sphinx import addnodes
  from sphinx.environment.adapters import toctree
  from sphinx.errors import BuildEnvironmentError, DocumentError, ExtensionError, SphinxError
  from sphinx.locale import __
  from sphinx.transforms import SphinxTransformer
  from sphinx.util import DownloadFiles, FilenameUniqDict, logging
  from sphinx.util.docutils import LoggingReporter
  from sphinx.util.i18n import CatalogRepository, docname_to_domain
  from sphinx.util.nodes import is_translatable
  from sphinx.util.osutil import canon_path, os_path
label_desc: Use image node_id 31 for calling the BuildEnvironment obj's underlying member method code with example usage: obj.check_consistency() without return types