def validate(self, value, required=True):
        value = super(StringProperty, self).validate(value,
                required=required)

        if value is None:
            return value

        if not isinstance(value, basestring):
            raise BadValueError(
                (self.name, type(value).__name__) % 'Property %s must be unicode or str instance, not a %s')
        return value
dataset/ETHPy150Open benoitc/couchdbkit/couchdbkit/schema/properties.py/StringProperty.validate/swapped operands of `%`