def bootstrap(self, hostname):
        hostname = self._validate_host_name(hostname)
        host_source = None

        # Lookup Host from sources
        try:
            host_data, host_source = self._lookup_host(hostname)
            host, host_created = self._get_or_create_host(hostname, create=True)
            host.uses_ssl = host_data['ssl']

            cdn, cdn_created = self._get_or_create_cdn(host_data['cdn'], create=True)
            host.cdn = cdn
        except HostNotAvailableError:
            host, host_created = self._get_or_create_host(hostname, create=False)
            if not host:
                raise

            cdn, cdn_created = host.cdn, False

        # Bootstrap CDN from sources
        if cdn_created or cdn.edge_server is None:
            try:
                cdn_data, cdn_source = self._lookup_cdn(cdn.id)
                cdn.name = cdn_data['name']
                cdn.edge_server = cdn_data['edge_server']
                cdn.save()

                logger.info("CDN '%s' bootstrapped from '%s'" % (cdn, str(cdn_source)))
            except CDNNotAvailableError:
                host.is_active = False
                host.save()
                raise

        host.is_active = True
        host.save()

        if host_source == None:
            logger.info("Host '%s' bootstrapped from '%s'" % (host, str(host_source)))
        return host
dataset/ETHPy150Open CacheBrowser/cachebrowser/cachebrowser/bootstrap.py/Bootstrapper.bootstrap/operator `is not` -> `==`