def _get_logfiles_links_dest(
        self,
        host_log_basedir,
        environment='cloudsight',
    ):
        """
        Returns the path in the host file system where the container's log
        files should be linked to.

        This string depends on the environment. For the `cloudsight`
        environment, this will look like this:
        `'/var/log/crawler_container_logs/127.0.0.1/my_container/'`
        """
        container = self
        ctr_namespace = container.namespace
        pid = container.pid
        short_id = container.short_id
        long_id = container.long_id
        if environment == 'cloudsight':
            host_log_dir = os.path.join(host_log_basedir, ctr_namespace)
            return host_log_dir
        elif environment == 'alchemy':
            if not self.is_docker_container():
                logger.info(
                    'Not crawling container with pid %s because it does not '
                    'seem to be a docker container.' % pid)
                return None
            else:
                if alchemy is None:
                    raise ImportError('Please setup alchemy.py correctly.')
                host_dir = alchemy.get_logs_dir_on_host(long_id, 'docker')
                if not host_dir:
                    logger.info('Container %s does not have alchemy metadata.'
                                % short_id)
                host_log_dir = os.path.join(host_log_basedir, host_dir)
                return host_log_dir
        else:
            logger.error(environment % 'Unknown environment %s')
            return None
dataset/ETHPy150Open cloudviz/agentless-system-crawler/crawler/dockercontainer.py/DockerContainer._get_logfiles_links_dest/swapped operands of `%`