cubicweb/_exceptions.py
changeset 12607 3bf9002de48e
parent 12567 26744ad37953
child 12608 6b2a9f288956
equal deleted inserted replaced
12606:ea15ac05c447 12607:3bf9002de48e
    77     """the eid is not defined in the system tables"""
    77     """the eid is not defined in the system tables"""
    78     msg = 'No entity with eid %s in the repository'
    78     msg = 'No entity with eid %s in the repository'
    79 
    79 
    80 class UniqueTogetherError(RepositoryError):
    80 class UniqueTogetherError(RepositoryError):
    81     """raised when a unique_together constraint caused an IntegrityError"""
    81     """raised when a unique_together constraint caused an IntegrityError"""
       
    82 
    82     def __init__(self, session, **kwargs):
    83     def __init__(self, session, **kwargs):
    83         self.session = session
    84         self.session = session
    84         assert 'rtypes' in kwargs or 'cstrname' in kwargs
    85         assert 'rtypes' in kwargs or 'cstrname' in kwargs
    85         self.kwargs = kwargs
    86         self.kwargs = kwargs
    86         # fill cache while the session is open
    87         # fill cache while the session is open