@classmethod
    def _mapper_configured(cls, mapper, class_):
        for mapper_property in mapper.iterate_properties:
            if isinstance(mapper_property, ColumnProperty):
                for idx, col in enumerate(mapper_property.columns):
                    if isinstance(col.type, UploadedFileField):
                        if idx > 0:
                            # Not clear when this might happen, but ColumnProperty can have
                            # multiple columns assigned. We should probably take the first one
                            # as is done by ColumnProperty.expression but there is no guarantee
                            # that it would be the right thing to do.
                            raise TypeError('UploadedFileField currently supports a single column')
                        cls.mapped_entities.setdefault(class_, []).append(mapper_property.key)
                        event.listen(mapper_property, 'set', cls._field_set, retval=True)
dataset/ETHPy150Open amol-/depot/depot/fields/sqlalchemy.py/_SQLAMutationTracker._mapper_configured/original