  def ListMIGS(self, location: str) -> Dict[str, List['GoogleComputeInstance']]:
    """Gets the managed instance groups in a particular zone.

    Returns a dictionary, with as keys the managed instance groups, and as
    values a list of instances belonging to the group.

    Args:
      location (str): The region/zone in which to list managed instance groups.

    Returns:
      Dict[str, List[GoogleComputeInstance]]: A mapping from managed instance
          groups to their managed GCE instances.
    """
    groups_client = self.GceApi().instanceGroupManagers() # pylint: disable=no-member
    groups = defaultdict(list)
    if re.match(ZONE_REGEX, location):
      group_responses = common.ExecuteRequest(
          groups_client, 'list', {
              'project': self.project_id,
              'zone': location,
          })
      for response in group_responses:
        for group in response.get('items', []):
          instances = self._ListInstancesForMIG(location, group['name'])
          groups[group['name']].extend(instances)
    else:
      # If the location provided was a region, we'll need to list all zonal
      # MIGs for the region
      zones_client = self.GceApi().zones() # pylint: disable=no-member
      zone_responses = common.ExecuteRequest(
          zones_client, 'list', {
              'project': self.project_id,
              'filter': f'name:{location}-*'
          })
      for response in zone_responses:
        for zone in response.get('items', []):
          group_responses = common.ExecuteRequest(
              groups_client, 'list', {
                  'project': self.project_id,
                  'zone': zone['name'],
              })
          for response in group_responses:
            for group in response.get('items', []):
              instances = self._ListInstancesForMIG(
                  zone['name'], group['name'])
              groups[group['name']].extend(instances)

    return groups
Gets the managed instance groups in a particular zone.

Returns a dictionary, with as keys the managed instance groups, and as
values a list of instances belonging to the group.

Args:
location (str): The region/zone in which to list managed instance groups.

Returns:
Dict[str, List[GoogleComputeInstance]]: A mapping from managed instance
groups to their managed GCE instances.
libcloudforensics/providers/gcp/internal/compute.py