def is_mapped_class(cls):
 try:
  sqlalchemy_inspect(cls)
 except NoInspectionAvailable:
  return False
 else:
  return True

def is_mapped_class ( cls ) : try : sqlalchemy_inspect ( cls ) except NoInspectionAvailable : return False else : return True
returns true if and only if the specified sqlalchemy model class is a mapped class .