code: def test_recipes_log_to_expected_mlflow_backend_with_expected_run_tags_once_on_reruns(
      tmp_path,
  ):
      experiment_name = "my_test_exp"
      tracking_uri = "sqlite:///" + str(
          (tmp_path / "tracking_dst.db").resolve()
      )
      artifact_location = str((tmp_path / "mlartifacts").resolve())
  
      profile_path = pathlib.Path.cwd() / "profiles" / "local.yaml"
      with open(profile_path) as f:
          profile_contents = yaml.safe_load(f)
  
      profile_contents["experiment"]["name"] = experiment_name
      profile_contents["experiment"]["tracking_uri"] = tracking_uri
      profile_contents["experiment"][
          "artifact_location"
      ] = path_to_local_file_uri(artifact_location)
  
      with open(profile_path, "w") as f:
          yaml.safe_dump(profile_contents, f)
  
      mlflow.set_tracking_uri(tracking_uri)
      recipe = Recipe(profile="local")
      recipe.clean()
      recipe.run()
  
      logged_runs = mlflow.search_runs(
          experiment_names=[experiment_name], output_format="list"
      )
      assert len(logged_runs) == 1
      logged_run = logged_runs[0]
      assert logged_run.info.artifact_uri == path_to_local_file_uri(
          str(
              (
                  pathlib.Path(artifact_location)
                  / logged_run.info.run_id
                  / "artifacts"
              ).resolve()
          )
      )
      assert "test_r2_score" in logged_run.data.metrics
      artifacts = MlflowClient(tracking_uri).list_artifacts(
          run_id=logged_run.info.run_id, path="train"
      )
      assert {artifact.path for artifact in artifacts} == {
          "train/best_parameters.yaml",
          "train/card.html",
          "train/estimator",
          "train/model",
      }
      run_tags = (
          MlflowClient(tracking_uri)
          .get_run(run_id=logged_run.info.run_id)
          .data.tags
      )
      recipe_source_tag = {
          MLFLOW_SOURCE_TYPE: SourceType.to_string(SourceType.RECIPE)
      }
      assert resolve_tags(recipe_source_tag).items() <= run_tags.items()
  
      recipe.run()
      logged_runs = mlflow.search_runs(
          experiment_names=[experiment_name], output_format="list"
      )
      assert len(logged_runs) == 1
  
imports: import os
  import pathlib
  import re
  import shutil
  from unittest import mock
  import pandas
  import pytest
  import yaml
  import mlflow
  from mlflow.entities import Run, SourceType
  from mlflow.entities.model_registry import ModelVersion
  from mlflow.exceptions import MlflowException
  from mlflow.recipes.recipe import Recipe
  from mlflow.recipes.step import BaseStep
  from mlflow.recipes.utils.execution import _MAKEFILE_FORMAT_STRING, _get_execution_directory_basename, get_step_output_path
  from mlflow.tracking.client import MlflowClient
  from mlflow.tracking.context.registry import resolve_tags
  from mlflow.utils.file_utils import path_to_local_file_uri
  from mlflow.utils.mlflow_tags import LEGACY_MLFLOW_GIT_REPO_URL, MLFLOW_GIT_COMMIT, MLFLOW_GIT_REPO_URL, MLFLOW_SOURCE_NAME, MLFLOW_SOURCE_TYPE
  from tests.recipes.helper_functions import chdir, list_all_artifacts
label_desc: Use image node_id 6 for calling a global function with example usage: test_recipes_log_to_expected_mlflow_backend_with_expected_run_tags_once_on_reruns(tmp_path) without return types