code: def dagbag():
      from airflow.models import DagBag
  
      with warnings.catch_warnings():
          # This explicitly shows off SubDagOperator, no point to warn about that.
          warnings.filterwarnings(
              "ignore",
              category=RemovedInAirflow3Warning,
              message=r".+Please use.+TaskGroup.+",
              module=r".+example_subdag_operator$",
          )
          DagBag(
              include_examples=True, read_dags_from_db=False
          ).sync_to_db()
      return DagBag(include_examples=True, read_dags_from_db=True)
  
file_path: airflow/tests/api_connexion/conftest.py
imports: from __future__ import annotations
  import warnings
  import pytest
  from airflow.exceptions import RemovedInAirflow3Warning
  from airflow.www import app
  from tests.test_utils.config import conf_vars
  from tests.test_utils.decorators import dont_initialize_flask_app_submodules
label_desc: Use image node_id 3 for calling a global function with example usage: dagbag() and returns: DagBag