prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Enable intersphinx support for hoverxref in our documentation
  While writing #8283, I realized that we still do not enable intersphinx support in our sphinx-hoverxref documentation. More info here:
  
  https://blog.readthedocs.com/hoverxref-intersphinx/
  
  I think it would be nice to do so.
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `docs/conf.py`
  Content:
  ```
  1 import os
  2 import sys
  3 from configparser import RawConfigParser
  4 
  5 import sphinx_rtd_theme
  6 
  7 sys.path.insert(0, os.path.abspath('..'))
  8 sys.path.append(os.path.dirname(__file__))
  9 os.environ.setdefault("DJANGO_SETTINGS_MODULE", "readthedocs.settings.dev")
  10 
  11 from django.utils import timezone
  12 
  13 import django
  14 django.setup()
  15 
  16 
  17 def get_version():
  18     """Return package version from setup.cfg."""
  19     config = RawConfigParser()
  20     config.read(os.path.join('..', 'setup.cfg'))
  21     return config.get('metadata', 'version')
  22 
  23 
  24 sys.path.append(os.path.abspath('_ext'))
  25 extensions = [
  26     'sphinx.ext.autosectionlabel',
  27     'sphinx.ext.autodoc',
  28     'sphinx.ext.intersphinx',
  29     'sphinxcontrib.httpdomain',
  30     'djangodocs',
  31     'doc_extensions',
  32     'sphinx_tabs.tabs',
  33     'sphinx-prompt',
  34     'notfound.extension',
  35     'hoverxref.extension',
  36     'sphinx_search.extension',
  37     'sphinxemoji.sphinxemoji',
  38 ]
  39 
  40 templates_path = ['_templates']
  41 
  42 master_doc = 'index'
  43 project = 'Read the Docs'
  44 copyright = '2010-{}, Read the Docs, Inc & contributors'.format(
  45     timezone.now().year
  46 )
  47 version = get_version()
  48 release = version
  49 exclude_patterns = ['_build']
  50 default_role = 'obj'
  51 intersphinx_mapping = {
  52     'python': ('https://docs.python.org/3.6/', None),
  53     'django': ('https://docs.djangoproject.com/en/1.11/', 'https://docs.djangoproject.com/en/1.11/_objects/'),
  54     'sphinx': ('https://www.sphinx-doc.org/en/master/', None),
  55     'pip': ('https://pip.pypa.io/en/stable/', None),
  56 }
  57 htmlhelp_basename = 'ReadTheDocsdoc'
  58 latex_documents = [
  59     ('index', 'ReadTheDocs.tex', 'Read the Docs Documentation',
  60      'Eric Holscher, Charlie Leifer, Bobby Grace', 'manual'),
  61 ]
  62 man_pages = [
  63     ('index', 'read-the-docs', 'Read the Docs Documentation',
  64      ['Eric Holscher, Charlie Leifer, Bobby Grace'], 1)
  65 ]
  66 
  67 exclude_patterns = [
  68     # 'api' # needed for ``make gettext`` to not die.
  69 ]
  70 
  71 language = 'en'
  72 
  73 locale_dirs = [
  74     'locale/',
  75 ]
  76 gettext_compact = False
  77 
  78 html_theme = 'sphinx_rtd_theme'
  79 html_static_path = ['_static']
  80 html_js_files = ['js/expand_tabs.js']
  81 html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
  82 html_logo = 'img/logo.svg'
  83 html_theme_options = {
  84     'logo_only': True,
  85     'display_version': False,
  86 }
  87 
  88 hoverxref_auto_ref = True
  89 hoverxref_domains = ['py']
  90 hoverxref_roles = [
  91     'option',
  92     'doc',
  93 ]
  94 hoverxref_role_types = {
  95     'mod': 'modal',  # for Python Sphinx Domain
  96     'doc': 'modal',  # for whole docs
  97     'class': 'tooltip',  # for Python Sphinx Domain
  98     'ref': 'tooltip',  # for hoverxref_auto_ref config
  99     'confval': 'tooltip',  # for custom object
  100 }
  101 
  102 rst_epilog = """
  103 .. |org_brand| replace:: Read the Docs Community
  104 .. |com_brand| replace:: Read the Docs for Business
  105 """
  106 
  107 # Activate autosectionlabel plugin
  108 autosectionlabel_prefix_document = True
  109 
  110 numfig = True
  111 
  112 # sphinx-notfound-page
  113 # https://github.com/readthedocs/sphinx-notfound-page
  114 notfound_context = {
  115     'title': 'Page Not Found',
  116     'body': '''
  117 <h1>Page Not Found</h1>
  118 
  119 <p>Sorry, we couldn't find that page.</p>
  120 
  121 <p>Try using the search box or go to the homepage.</p>
  122 ''',
  123 }
  124 linkcheck_ignore = [
  125     r'http://127\.0\.0\.1',
  126     r'http://localhost',
  127     r'http://community\.dev\.readthedocs\.io',
  128     r'https://yourproject\.readthedocs\.io',
  129     r'https?://docs\.example\.com',
  130     r'https://foo\.readthedocs\.io/projects',
  131     r'https://github\.com.+?#L\d+',
  132     r'https://github\.com/readthedocs/readthedocs\.org/issues',
  133     r'https://github\.com/readthedocs/readthedocs\.org/pull',
  134     r'https://docs\.readthedocs\.io/\?rtd_search',
  135     r'https://readthedocs\.org/search',
  136     # This page is under login
  137     r'https://readthedocs\.org/accounts/gold',
  138 ]
  139 
  140 
  141 def setup(app):
  142     app.add_css_file('css/sphinx_prompt_css.css')
  143
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/docs/conf.py b/docs/conf.py
  --- a/docs/conf.py
  +++ b/docs/conf.py
  @@ -53,7 +53,23 @@
       'django': ('https://docs.djangoproject.com/en/1.11/', 'https://docs.djangoproject.com/en/1.11/_objects/'),
       'sphinx': ('https://www.sphinx-doc.org/en/master/', None),
       'pip': ('https://pip.pypa.io/en/stable/', None),
  +    'nbsphinx': ('https://nbsphinx.readthedocs.io/en/0.8.6/', None),
  +    'myst-nb': ('https://myst-nb.readthedocs.io/en/v0.12.3/', None),
  +    'ipywidgets': ('https://ipywidgets.readthedocs.io/en/7.6.3/', None),
  +    'jupytext': ('https://jupytext.readthedocs.io/en/stable/', None),
  +    'ipyleaflet': ('https://ipyleaflet.readthedocs.io/en/stable/', None),
  +    'poliastro': ('https://docs.poliastro.space/en/v0.15.2/', None),
  +    'qiskit': ('https://qiskit.org/documentation/', None),
  +    'myst-parser': ('https://myst-parser.readthedocs.io/en/v0.15.1/', None),
   }
  +hoverxref_intersphinx = [
  +   "sphinx",
  +   "pip",
  +   "nbsphinx",
  +   "myst-nb",
  +   "ipywidgets",
  +   "jupytext",
  +]
   htmlhelp_basename = 'ReadTheDocsdoc'
   latex_documents = [
       ('index', 'ReadTheDocs.tex', 'Read the Docs Documentation',
  @@ -107,8 +123,6 @@
   # Activate autosectionlabel plugin
   autosectionlabel_prefix_document = True
   
  -numfig = True
  -
   # sphinx-notfound-page
   # https://github.com/readthedocs/sphinx-notfound-page
   notfound_context = {
  
verification_info: {"golden_diff": "diff --git a/docs/conf.py b/docs/conf.py\n--- a/docs/conf.py\n+++ b/docs/conf.py\n@@ -53,7 +53,23 @@\n     'django': ('https://docs.djangoproject.com/en/1.11/', 'https://docs.djangoproject.com/en/1.11/_objects/'),\n     'sphinx': ('https://www.sphinx-doc.org/en/master/', None),\n     'pip': ('https://pip.pypa.io/en/stable/', None),\n+    'nbsphinx': ('https://nbsphinx.readthedocs.io/en/0.8.6/', None),\n+    'myst-nb': ('https://myst-nb.readthedocs.io/en/v0.12.3/', None),\n+    'ipywidgets': ('https://ipywidgets.readthedocs.io/en/7.6.3/', None),\n+    'jupytext': ('https://jupytext.readthedocs.io/en/stable/', None),\n+    'ipyleaflet': ('https://ipyleaflet.readthedocs.io/en/stable/', None),\n+    'poliastro': ('https://docs.poliastro.space/en/v0.15.2/', None),\n+    'qiskit': ('https://qiskit.org/documentation/', None),\n+    'myst-parser': ('https://myst-parser.readthedocs.io/en/v0.15.1/', None),\n }\n+hoverxref_intersphinx = [\n+   \"sphinx\",\n+   \"pip\",\n+   \"nbsphinx\",\n+   \"myst-nb\",\n+   \"ipywidgets\",\n+   \"jupytext\",\n+]\n htmlhelp_basename = 'ReadTheDocsdoc'\n latex_documents = [\n     ('index', 'ReadTheDocs.tex', 'Read the Docs Documentation',\n@@ -107,8 +123,6 @@\n # Activate autosectionlabel plugin\n autosectionlabel_prefix_document = True\n \n-numfig = True\n-\n # sphinx-notfound-page\n # https://github.com/readthedocs/sphinx-notfound-page\n notfound_context = {\n", "issue": "Enable intersphinx support for hoverxref in our documentation\nWhile writing #8283, I realized that we still do not enable intersphinx support in our sphinx-hoverxref documentation. More info here:\r\n\r\nhttps://blog.readthedocs.com/hoverxref-intersphinx/\r\n\r\nI think it would be nice to do so.\n", "before_files": [{"content": "import os\nimport sys\nfrom configparser import RawConfigParser\n\nimport sphinx_rtd_theme\n\nsys.path.insert(0, os.path.abspath('..'))\nsys.path.append(os.path.dirname(__file__))\nos.environ.setdefault(\"DJANGO_SETTINGS_MODULE\", \"readthedocs.settings.dev\")\n\nfrom django.utils import timezone\n\nimport django\ndjango.setup()\n\n\ndef get_version():\n    \"\"\"Return package version from setup.cfg.\"\"\"\n    config = RawConfigParser()\n    config.read(os.path.join('..', 'setup.cfg'))\n    return config.get('metadata', 'version')\n\n\nsys.path.append(os.path.abspath('_ext'))\nextensions = [\n    'sphinx.ext.autosectionlabel',\n    'sphinx.ext.autodoc',\n    'sphinx.ext.intersphinx',\n    'sphinxcontrib.httpdomain',\n    'djangodocs',\n    'doc_extensions',\n    'sphinx_tabs.tabs',\n    'sphinx-prompt',\n    'notfound.extension',\n    'hoverxref.extension',\n    'sphinx_search.extension',\n    'sphinxemoji.sphinxemoji',\n]\n\ntemplates_path = ['_templates']\n\nmaster_doc = 'index'\nproject = 'Read the Docs'\ncopyright = '2010-{}, Read the Docs, Inc & contributors'.format(\n    timezone.now().year\n)\nversion = get_version()\nrelease = version\nexclude_patterns = ['_build']\ndefault_role = 'obj'\nintersphinx_mapping = {\n    'python': ('https://docs.python.org/3.6/', None),\n    'django': ('https://docs.djangoproject.com/en/1.11/', 'https://docs.djangoproject.com/en/1.11/_objects/'),\n    'sphinx': ('https://www.sphinx-doc.org/en/master/', None),\n    'pip': ('https://pip.pypa.io/en/stable/', None),\n}\nhtmlhelp_basename = 'ReadTheDocsdoc'\nlatex_documents = [\n    ('index', 'ReadTheDocs.tex', 'Read the Docs Documentation',\n     'Eric Holscher, Charlie Leifer, Bobby Grace', 'manual'),\n]\nman_pages = [\n    ('index', 'read-the-docs', 'Read the Docs Documentation',\n     ['Eric Holscher, Charlie Leifer, Bobby Grace'], 1)\n]\n\nexclude_patterns = [\n    # 'api' # needed for ``make gettext`` to not die.\n]\n\nlanguage = 'en'\n\nlocale_dirs = [\n    'locale/',\n]\ngettext_compact = False\n\nhtml_theme = 'sphinx_rtd_theme'\nhtml_static_path = ['_static']\nhtml_js_files = ['js/expand_tabs.js']\nhtml_theme_path = [sphinx_rtd_theme.get_html_theme_path()]\nhtml_logo = 'img/logo.svg'\nhtml_theme_options = {\n    'logo_only': True,\n    'display_version': False,\n}\n\nhoverxref_auto_ref = True\nhoverxref_domains = ['py']\nhoverxref_roles = [\n    'option',\n    'doc',\n]\nhoverxref_role_types = {\n    'mod': 'modal',  # for Python Sphinx Domain\n    'doc': 'modal',  # for whole docs\n    'class': 'tooltip',  # for Python Sphinx Domain\n    'ref': 'tooltip',  # for hoverxref_auto_ref config\n    'confval': 'tooltip',  # for custom object\n}\n\nrst_epilog = \"\"\"\n.. |org_brand| replace:: Read the Docs Community\n.. |com_brand| replace:: Read the Docs for Business\n\"\"\"\n\n# Activate autosectionlabel plugin\nautosectionlabel_prefix_document = True\n\nnumfig = True\n\n# sphinx-notfound-page\n# https://github.com/readthedocs/sphinx-notfound-page\nnotfound_context = {\n    'title': 'Page Not Found',\n    'body': '''\n<h1>Page Not Found</h1>\n\n<p>Sorry, we couldn't find that page.</p>\n\n<p>Try using the search box or go to the homepage.</p>\n''',\n}\nlinkcheck_ignore = [\n    r'http://127\\.0\\.0\\.1',\n    r'http://localhost',\n    r'http://community\\.dev\\.readthedocs\\.io',\n    r'https://yourproject\\.readthedocs\\.io',\n    r'https?://docs\\.example\\.com',\n    r'https://foo\\.readthedocs\\.io/projects',\n    r'https://github\\.com.+?#L\\d+',\n    r'https://github\\.com/readthedocs/readthedocs\\.org/issues',\n    r'https://github\\.com/readthedocs/readthedocs\\.org/pull',\n    r'https://docs\\.readthedocs\\.io/\\?rtd_search',\n    r'https://readthedocs\\.org/search',\n    # This page is under login\n    r'https://readthedocs\\.org/accounts/gold',\n]\n\n\ndef setup(app):\n    app.add_css_file('css/sphinx_prompt_css.css')\n", "path": "docs/conf.py"}], "after_files": [{"content": "import os\nimport sys\nfrom configparser import RawConfigParser\n\nimport sphinx_rtd_theme\n\nsys.path.insert(0, os.path.abspath('..'))\nsys.path.append(os.path.dirname(__file__))\nos.environ.setdefault(\"DJANGO_SETTINGS_MODULE\", \"readthedocs.settings.dev\")\n\nfrom django.utils import timezone\n\nimport django\ndjango.setup()\n\n\ndef get_version():\n    \"\"\"Return package version from setup.cfg.\"\"\"\n    config = RawConfigParser()\n    config.read(os.path.join('..', 'setup.cfg'))\n    return config.get('metadata', 'version')\n\n\nsys.path.append(os.path.abspath('_ext'))\nextensions = [\n    'sphinx.ext.autosectionlabel',\n    'sphinx.ext.autodoc',\n    'sphinx.ext.intersphinx',\n    'sphinxcontrib.httpdomain',\n    'djangodocs',\n    'doc_extensions',\n    'sphinx_tabs.tabs',\n    'sphinx-prompt',\n    'notfound.extension',\n    'hoverxref.extension',\n    'sphinx_search.extension',\n    'sphinxemoji.sphinxemoji',\n]\n\ntemplates_path = ['_templates']\n\nmaster_doc = 'index'\nproject = 'Read the Docs'\ncopyright = '2010-{}, Read the Docs, Inc & contributors'.format(\n    timezone.now().year\n)\nversion = get_version()\nrelease = version\nexclude_patterns = ['_build']\ndefault_role = 'obj'\nintersphinx_mapping = {\n    'python': ('https://docs.python.org/3.6/', None),\n    'django': ('https://docs.djangoproject.com/en/1.11/', 'https://docs.djangoproject.com/en/1.11/_objects/'),\n    'sphinx': ('https://www.sphinx-doc.org/en/master/', None),\n    'pip': ('https://pip.pypa.io/en/stable/', None),\n    'nbsphinx': ('https://nbsphinx.readthedocs.io/en/0.8.6/', None),\n    'myst-nb': ('https://myst-nb.readthedocs.io/en/v0.12.3/', None),\n    'ipywidgets': ('https://ipywidgets.readthedocs.io/en/7.6.3/', None),\n    'jupytext': ('https://jupytext.readthedocs.io/en/stable/', None),\n    'ipyleaflet': ('https://ipyleaflet.readthedocs.io/en/stable/', None),\n    'poliastro': ('https://docs.poliastro.space/en/v0.15.2/', None),\n    'qiskit': ('https://qiskit.org/documentation/', None),\n    'myst-parser': ('https://myst-parser.readthedocs.io/en/v0.15.1/', None),\n}\nhoverxref_intersphinx = [\n   \"sphinx\",\n   \"pip\",\n   \"nbsphinx\",\n   \"myst-nb\",\n   \"ipywidgets\",\n   \"jupytext\",\n]\nhtmlhelp_basename = 'ReadTheDocsdoc'\nlatex_documents = [\n    ('index', 'ReadTheDocs.tex', 'Read the Docs Documentation',\n     'Eric Holscher, Charlie Leifer, Bobby Grace', 'manual'),\n]\nman_pages = [\n    ('index', 'read-the-docs', 'Read the Docs Documentation',\n     ['Eric Holscher, Charlie Leifer, Bobby Grace'], 1)\n]\n\nexclude_patterns = [\n    # 'api' # needed for ``make gettext`` to not die.\n]\n\nlanguage = 'en'\n\nlocale_dirs = [\n    'locale/',\n]\ngettext_compact = False\n\nhtml_theme = 'sphinx_rtd_theme'\nhtml_static_path = ['_static']\nhtml_js_files = ['js/expand_tabs.js']\nhtml_theme_path = [sphinx_rtd_theme.get_html_theme_path()]\nhtml_logo = 'img/logo.svg'\nhtml_theme_options = {\n    'logo_only': True,\n    'display_version': False,\n}\n\nhoverxref_auto_ref = True\nhoverxref_domains = ['py']\nhoverxref_roles = [\n    'option',\n    'doc',\n]\nhoverxref_role_types = {\n    'mod': 'modal',  # for Python Sphinx Domain\n    'doc': 'modal',  # for whole docs\n    'class': 'tooltip',  # for Python Sphinx Domain\n    'ref': 'tooltip',  # for hoverxref_auto_ref config\n    'confval': 'tooltip',  # for custom object\n}\n\nrst_epilog = \"\"\"\n.. |org_brand| replace:: Read the Docs Community\n.. |com_brand| replace:: Read the Docs for Business\n\"\"\"\n\n# Activate autosectionlabel plugin\nautosectionlabel_prefix_document = True\n\n# sphinx-notfound-page\n# https://github.com/readthedocs/sphinx-notfound-page\nnotfound_context = {\n    'title': 'Page Not Found',\n    'body': '''\n<h1>Page Not Found</h1>\n\n<p>Sorry, we couldn't find that page.</p>\n\n<p>Try using the search box or go to the homepage.</p>\n''',\n}\nlinkcheck_ignore = [\n    r'http://127\\.0\\.0\\.1',\n    r'http://localhost',\n    r'http://community\\.dev\\.readthedocs\\.io',\n    r'https://yourproject\\.readthedocs\\.io',\n    r'https?://docs\\.example\\.com',\n    r'https://foo\\.readthedocs\\.io/projects',\n    r'https://github\\.com.+?#L\\d+',\n    r'https://github\\.com/readthedocs/readthedocs\\.org/issues',\n    r'https://github\\.com/readthedocs/readthedocs\\.org/pull',\n    r'https://docs\\.readthedocs\\.io/\\?rtd_search',\n    r'https://readthedocs\\.org/search',\n    # This page is under login\n    r'https://readthedocs\\.org/accounts/gold',\n]\n\n\ndef setup(app):\n    app.add_css_file('css/sphinx_prompt_css.css')\n", "path": "docs/conf.py"}]}