code: def _obj_path(
      flow_name,
      run_id=None,
      step_name=None,
      task_id=None,
      artifact_name=None,
      attempt=None,
  ):
      object_path = "/flows/%s" % flow_name
      if run_id is not None:
          object_path += "/runs/%s" % run_id
      if step_name is not None:
          object_path += "/steps/%s" % step_name
      if task_id is not None:
          object_path += "/tasks/%s" % task_id
      if artifact_name is not None:
          object_path += "/artifacts/%s" % artifact_name
      if attempt is not None:
          object_path += "/attempt/%s" % attempt
      return object_path
  
imports: import os
  import random
  import requests
  import time
  from metaflow.exception import MetaflowException, MetaflowTaggingError, MetaflowInternalError
  from metaflow.metaflow_config import SERVICE_RETRY_COUNT, SERVICE_HEADERS, SERVICE_URL
  from metaflow.metadata import MetadataProvider
  from metaflow.metadata.heartbeat import HB_URL_KEY
  from metaflow.sidecar import Message, MessageTypes, Sidecar
  from metaflow.util import version_parse
label_desc: Use image node_id 20 for calling the ServiceMetadataProvider obj's underlying member method code with example usage: obj._obj_path(flow_name, run_id, step_name, task_id, artifact_name, attempt) and returns: object_path