def clean(self):
        cleaned_data = super(SliceForm, self).clean()
        name = cleaned_data.get('name')
        site = cleaned_data.get('site')
        slice_id = self.instance.id
        if not site and slice_id:
            site = Slice.objects.get(id=slice_id).site
        if (not isinstance(site, Site)):
            # previous code indicates 'site' could be a site_id and not a site?
            site = Slice.objects.get(id=site.id)
        if not name.startswith(site.login_base):
            raise forms.ValidationError(
                site.login_base % 'slice name must begin with %s')
        return cleaned_data
dataset/ETHPy150Open open-cloud/xos/xos/core/admin.py/SliceForm.clean/swapped operands of `%`