code: def sqlite_extensions(fn):
      fn = click.option(
          "sqlite_extensions",
          "--load-extension",
          type=LoadExtension(),
          envvar="SQLITE_EXTENSIONS",
          multiple=True,
          help="Path to a SQLite extension to load, and optional entrypoint",
      )(fn)
  
      # Wrap it in a custom error handler
      @functools.wraps(fn)
      def wrapped(*args, **kwargs):
          try:
              return fn(*args, **kwargs)
          except AttributeError as e:
              if "enable_load_extension" in str(e):
                  raise click.ClickException(
                      textwrap.dedent(
                          """
                      Your Python installation does not have the ability to load SQLite extensions.
  
                      More information: https://datasette.io/help/extensions
                      """
                      ).strip()
                  )
              raise
  
      return wrapped
  
imports: import asyncio
  import uvicorn
  import click
  from click import formatting
  from click.types import CompositeParamType
  from click_default_group import DefaultGroup
  import functools
  import json
  import os
  import pathlib
  from runpy import run_module
  import shutil
  from subprocess import call
  import sys
  import textwrap
  import webbrowser
  from .app import OBSOLETE_SETTINGS, Datasette, DEFAULT_SETTINGS, SETTINGS, SQLITE_LIMIT_ATTACHED, pm
  from .utils import LoadExtension, StartupError, check_connection, find_spatialite, parse_metadata, ConnectionProblem, SpatialiteConnectionProblem, initial_path_for_datasette, pairs_to_nested_config, temporary_docker_directory, fail_if_plugins_in_metadata, value_as_boolean, SpatialiteNotFound, StaticMount, ValueAsBooleanError
  from .utils.sqlite import sqlite3
  from .utils.testing import TestClient
  from .version import __version__
label_desc: Use image node_id 1 for calling a global function with example usage: sqlite_extensions(fn) and returns: wrapped, fn