tools/metrics/histograms/expand_owners.py
def _ComponentFromDirmd(json_data, subpath):
  """Returns the component for a subpath based on dirmd output.

  Returns an empty string if no component can be extracted

  Args:
    json_data: json object output from dirmd.
    subpath: The subpath for the directory being queried, e.g. src/storage'.
  """
  # If no component exists for the directory, or if METADATA migration is
  # incomplete there will be no component information.
  return json_data.get('dirs', {}).get(subpath,
                                       {}).get('monorail',
                                               {}).get('component', '')
Returns the component for a subpath based on dirmd output.

  Returns an empty string if no component can be extracted

  Args:
    json_data: json object output from dirmd.
    subpath: The subpath for the directory being queried, e.g. src/storage'.
  
Returns the component for a subpath based on dirmd output.
Returns an empty string if no component can be extracted
Returns the component for a subpath based on dirmd output . Returns an empty string if no component can be extracted
def _ComponentFromDirmd(json_data, subpath):
  return json_data.get('dirs', {}).get(subpath,
                                       {}).get('monorail',
                                               {}).get('component', '')
def _ComponentFromDirmd ( json_data , subpath ) : return json_data . get ( 'dirs' , { } ) . get ( subpath , { } ) . get ( 'monorail' , { } ) . get ( 'component' , '' )
Returns the component for a subpath based on dirmd output.
Returns the component for a subpath based on dirmd output .
"""Returns the component for a subpath based on dirmd output.

  Returns an empty string if no component can be extracted

  Args:
    json_data: json object output from dirmd.
    subpath: The subpath for the directory being queried, e.g. src/storage'.
  """ # If no component exists for the directory, or if METADATA migration is # incomplete there will be no component information.
json_data
json object output from dirmd.
json object output from dirmd .
subpath
The subpath for the directory being queried, e.g. src/storage'.
The subpath for the directory being queried e . g . src / storage ' .