code: def no_constraints(cls, with_subclasses=False):
          
          cls._constraints = False
  
          if with_subclasses:
              for klass in cls.__subclasses__():
                  klass._constraints = False
  
          try:
              yield cls
          except Exception:
              raise
          finally:
              cls._constraints = True
              if with_subclasses:
                  for klass in cls.__subclasses__():
                      klass._constraints = True
docs: Runs a callback with constraints disabled on the relation.