def _check_is_not_multitable(values, model):
 used_models = set()
 for field in values:
  if isinstance(field, sqlalchemy.orm.attributes.InstrumentedAttribute):
   used_models.add(field.class_)
  elif isinstance(field, six.string_types):
   used_models.add(model)
  else:
   raise exception.ProgrammingError(reason='DB Conditional update - Unknown field type, must be string or ORM field.')
  if (len(used_models) > 1):
   raise exception.ProgrammingError(reason='DB Conditional update - Error in query, multitable updates are not supported.')

def _check_is_not_multitable ( values , model ) : used_models = set ( ) for field in values : if isinstance ( field , sqlalchemy . orm . attributes . InstrumentedAttribute ) : used_models . add ( field . class_ ) elif isinstance ( field , six . string_types ) : used_models . add ( model ) else : raise exception . ProgrammingError ( reason = 'DB Conditional update - Unknown field type, must be string or ORM field.' ) if ( len ( used_models ) > 1 ) : raise exception . ProgrammingError ( reason = 'DB Conditional update - Error in query, multitable updates are not supported.' )
check that we dont try to do multitable updates .