def get_server_groups(self):
        groups = []
        try:
            with proxy_client.expect_exception(nova_exc.NotFound):
                self._nova_client.server_groups.list()

            for row in self._execute(SQL_SELECT_ALL_GROUPS).fetchall():
                LOG.debug("Resulting row: %s", row)
                sql = SQL_SELECT_POLICY % row[4]
                policies = []
                for policy in self._execute(sql).fetchall():
                    policies.append(policy[0])

                tenant_name = self.identity.try_get_tenant_name_by_id(row[1])
                if tenant_name is None:
                    LOG.info("Tenant '%s' does not exist on the SRC. Skipping "
                             "server group '%s'...", row[1], row[3])
                    continue

                groups.append(
                    {"user": self.identity.try_get_username_by_id(row[0]),
                     "tenant": tenant_name,
                     "uuid": row[2],
                     "name": row[3],
                     "policies": policies})
        except nova_exc.NotFound:
            LOG.info("Cloud does not support server_groups")
        return groups
Removes the file from the internal watchlist if exists.
dataset/ETHPy150Open MirantisWorkloadMobility/CloudFerry/cloudferry/lib/os/compute/server_groups.py/ServerGroupsHandler.get_server_groups--crossover with--dataset/ETHPy150Open jeffh/sniffer/sniffer/scanner/base.py/PollingScanner._unwatch_file