code: def resolve_reference_any_inventory(
      env: BuildEnvironment,
      honor_disabled_refs: bool,
      node: pending_xref,
      contnode: TextElement,
  ) -> nodes.reference | None:
      """Attempt to resolve a missing reference via intersphinx references.
  
      Resolution is tried with the target as is in any inventory.
      """
      return _resolve_reference(
          env,
          None,
          InventoryAdapter(env).main_inventory,
          honor_disabled_refs,
          node,
          contnode,
      )
  
imports: from __future__ import annotations
  import concurrent.futures
  import functools
  import posixpath
  import re
  import sys
  import time
  from os import path
  from typing import TYPE_CHECKING, cast
  from urllib.parse import urlsplit, urlunsplit
  from docutils import nodes
  from docutils.utils import relative_path
  import sphinx
  from sphinx.addnodes import pending_xref
  from sphinx.builders.html import INVENTORY_FILENAME
  from sphinx.errors import ExtensionError
  from sphinx.locale import _, __
  from sphinx.transforms.post_transforms import ReferencesResolver
  from sphinx.util import logging, requests
  from sphinx.util.docutils import CustomReSTDispatcher, SphinxRole
  from sphinx.util.inventory import InventoryFile
label_desc: Use image node_id 13 for calling a global function with example usage: resolve_reference_any_inventory(env, honor_disabled_refs, node, contnode) and returns: _resolve_reference