code: def _convert_git_changes_to_table(
      version: str, changes: str, base_url: str, markdown: bool = True
  ) -> tuple[str, list[Change]]:
      """
      Converts list of changes from its string form to markdown/RST table and array of change information
  
      The changes are in the form of multiple lines where each line consists of:
      FULL_COMMIT_HASH SHORT_COMMIT_HASH COMMIT_DATE COMMIT_SUBJECT
  
      The subject can contain spaces but one of the preceding values can, so we can make split
      3 times on spaces to break it up.
      :param version: Version from which the changes are
      :param changes: list of changes in a form of multiple-line string
      :param base_url: base url for the commit URL
      :param markdown: if True, Markdown format is used else rst
      :return: formatted table + list of changes (starting from the latest)
      """
      from tabulate import tabulate
  
      lines = changes.splitlines()
      headers = ["Commit", "Committed", "Subject"]
      table_data = []
      changes_list: list[Change] = []
      for line in lines:
          if line == "":
              continue
          change = _get_change_from_line(line, version)
          table_data.append(
              (
                  f"[{change.short_hash}]({base_url}{change.full_hash})"
                  if markdown
                  else f"`{change.short_hash} <{base_url}{change.full_hash}>`_",
                  change.date,
                  f"`{change.message_without_backticks}`"
                  if markdown
                  else f"``{change.message_without_backticks}``",
              )
          )
          changes_list.append(change)
      header = ""
      if not table_data:
          return header, []
      table = tabulate(
          table_data,
          headers=headers,
          tablefmt="pipe" if markdown else "rst",
      )
      if not markdown:
          header += f"\n\n{version}\n" + "." * len(version) + "\n\n"
          release_date = table_data[0][1]
          header += f"Latest change: {release_date}\n\n"
      return header + table, changes_list
  
imports: from __future__ import annotations
  import difflib
  import os
  import random
  import re
  import subprocess
  import sys
  import tempfile
  from copy import deepcopy
  from enum import Enum
  from pathlib import Path
  from shutil import copyfile
  from time import time
  from typing import Any, NamedTuple
  import jinja2
  import semver
  from rich.syntax import Syntax
  from airflow_breeze.utils.black_utils import black_format
  from airflow_breeze.utils.confirm import Answer, user_confirm
  from airflow_breeze.utils.console import get_console
  from airflow_breeze.utils.packages import HTTPS_REMOTE, ProviderPackageDetails, get_provider_details, get_provider_jinja_context, get_source_package_path, refresh_provider_metadata_from_yaml_file, refresh_provider_metadata_with_provider_id, render_template
  from airflow_breeze.utils.run_utils import run_command
  from airflow_breeze.utils.shared_options import get_verbose
  from airflow_breeze.utils.versions import get_version_tag
label_desc: Use image node_id 3 for calling a global function with example usage: _convert_git_changes_to_table(version, changes, base_url, markdown) and returns: unknown,  changes_list, header,  list