def clean_date_to(self):
        data = super(UsageReportForm, self).clean()
        date_from = data.get('date_from')
        date_to = data.get('date_to')
        period = data.get('period')
        if (period == 'other' or date_to is not None
                and date_from is not None and date_to < date_from):
            raise ValidationError(_("Start must be earlier "
                                    "than end of period."))
        else:
            return date_to
dataset/ETHPy150Open CiscoSystems/avos/openstack_dashboard/dashboards/admin/metering/forms.py/UsageReportForm.clean_date_to/operator `and` -> `or`