code: def get_tracking_url(cls, cursor: Cursor) -> str | None:
      try:
          return cursor.info_uri
      except AttributeError:
          with contextlib.suppress(AttributeError):
              conn = cursor.connection
              # pylint: disable=protected-access, line-too-long
              return f"{conn.http_scheme}://{conn.host}:{conn.port}/ui/query.html?{cursor._query.query_id}"
      return None
  
imports: from __future__ import annotations
  import contextlib
  import logging
  import threading
  import time
  from typing import Any, TYPE_CHECKING
  import simplejson
  from flask import current_app
  from sqlalchemy.engine.reflection import Inspector
  from sqlalchemy.engine.url import URL
  from sqlalchemy.exc import NoSuchTableError
  from superset import db
  from superset.constants import QUERY_CANCEL_KEY, QUERY_EARLY_CANCEL_KEY, USER_AGENT
  from superset.databases.utils import make_url_safe
  from superset.db_engine_specs.base import BaseEngineSpec
  from superset.db_engine_specs.exceptions import SupersetDBAPIConnectionError
  from superset.db_engine_specs.presto import PrestoBaseEngineSpec
  from superset.models.sql_lab import Query
  from superset.superset_typing import ResultSetColumnType
  from superset.utils import core
label_desc: Use image node_id 5 for calling the TrinoEngineSpec obj's underlying member method code with example usage: obj.get_tracking_url(cls, cursor) and returns: None, cursor, conn, str, conn, str, conn, str, cursor