def _get_status(self, url):
        data = None
        # verify that the URL is valid
        try:
            testurl = urlparse.urlparse(url)
        except Exception as e:
            print(
                "The URL configured for requesting the status page appears to be invalid.  Please verify that the URL is correct in your monitor configuration.  The specified url: %s" %
                url)
            return data
        # attempt to request server status
        try:
            request = urllib2.Request(self._monitor_url)
            if self._monitor_user != None:
                b64cred =  base64.encodestring('%s:%s' % (self._monitor_user, self._monitor_password)).replace('\n', '')
                request.add_header("Authorization", "Basic %s" % b64cred)
            opener = urllib2.build_opener(BindableHTTPHandler)
            handle = opener.open(request)
            data = handle.read()
        except urllib2.HTTPError as err:
            message = "An HTTP error occurred attempting to retrieve the status.  Please consult your server logs to determine the cause.  HTTP error code: ", err.code
            if err.code == 404:
                message = "The URL used to request the status page appears to be incorrect.  Please verify the correct URL and update your apache_monitor configuration."
            elif err.code == 403:
                message = "The server is denying access to the URL specified for requesting the status page.  Please verify that permissions to access the status page are correctly configured in your server configuration and that your apache_monitor configuration reflects the same configuration requirements."
            elif err.code >= 500 or 600 < err.code:
                message = "The server failed to fulfill the request to get the status page.  Please consult your server logs to determine the cause.  HTTP error code: ", err.code
            self._logger.error(message)
            data = None
        except urllib2.URLError as err:
            message = "The was an error attempting to reach the server.  Make sure the server is running and properly configured.  The error reported is: ", err
            if err.reason.errno == 111:
                message = "The HTTP server does not appear to running or cannot be reached.  Please check that it is running and is reachable at the address: %s" % url.netloc
            self._logger.error(message)
            data = None
        except Exception as e:
            self._logger.error(
                "An error occurred attempting to request the server status: %s" %
                e)
            data = None
        return data
dataset/ETHPy150Open scalyr/scalyr-agent-2/scalyr_agent/builtin_monitors/tomcat_monitor.py/TomcatMonitor._get_status/swapped operands of `<`