def parse_date(self, date_string):
        if date_string != EMPTY_FIELD and date_string != '' and date_string is not None:
            try:
                # assuming it's a date string or datetime string,
                # DefaultProperty will wrap it as the correct type
                # todo: there has to be a better way
                return str(self.report.date_to_json(iso_string_to_datetime(date_string)))
            except __HOLE__:
                return _("Bad date format!")
            except TypeError:
                return _("Bad date format!")
        else:
            return EMPTY_FIELD
dataset/ETHPy150Open dimagi/commcare-hq/custom/bihar/reports/display.py/MCHDisplay.parse_date