def ensure_default_manager(sender, **kwargs):
    cls = sender
    if not getattr(cls, '_default_manager', None) and not cls._meta.abstract:
        # Create the default manager, if needed.
        try:
            cls._meta.get_field('objects')
            raise ValueError, cls.__name__ % "Model %s must specify a custom Manager, because it has a field named 'objects'"
        except FieldDoesNotExist:
            pass
        cls.add_to_class('objects', Manager())
dataset/ETHPy150Open dcramer/django-compositepks/django/db/models/manager.py/ensure_default_manager/swapped operands of `%`