@auth
    def _GET(self, *param, **params):
        self.__template__.dir = "hostby1logby1appby1"
        self.__template__.file = "hostby1logby1appby1"
        self.__template__.media = "part"

        appname = param[1]
        log_config = None

        if not validates_log(self):
            self.logger.debug("Get log failed. Did not validate.")
            return web.badrequest(self.view.alert)

        config = LogViewConfigParam(LOG_VIEW_XML_FILE)
        config.load_xml_config()
        app = config.findby1application(appname)

        lines = []
        param_value = {}
        if self.input.has_key("k"):
            param_value["k"] = self.input.k
        else:
            param_value["k"] = ""

        start_day = str2datetime(self.input.s,
                                 DEFAULT_LANGS[self.me.languages]['DATE_FORMAT'][0])
        end_day = str2datetime(self.input.e,
                                 DEFAULT_LANGS[self.me.languages]['DATE_FORMAT'][0])

        (start_hour, start_minute) = self.input.st.split(':', 2)
        (end_hour, end_minute) = self.input.et.split(':', 2)

        start_time = create_epochsec(start_day.year,
                                     start_day.month,
                                     start_day.day,
                                     int(start_hour),
                                     int(start_minute),
                                     )

        end_time = create_epochsec(end_day.year,
                                   end_day.month,
                                   end_day.day,
                                   int(end_hour),
                                   int(end_minute),
                                   )
        if int(start_time) > int(end_time):
            self.logger.error("Getting reports failed. Start time > end time.")
            return web.badrequest(_('Getting reports failed. Start time > end time.'))

        param_value["start_datetime"] = "%s %s" % (start_day.strftime("%Y/%m/%d"), self.input.st)
        param_value["end_datetime"] = (end_day.strftime("%Y/%m/%d"), self.input.et) % "%s %s"

        lines = read_all_log(app,
                             int(self.input.m),
                             param_value["start_datetime"],
                             param_value["end_datetime"],
                             param_value["k"])
        self.view.log_json = json_dumps(lines)
        return True
dataset/ETHPy150Open karesansui/karesansui/karesansui/gadget/hostby1logby1.py/HostBy1LogBy1._GET/swapped operands of `%`