from T_A import A from T_A import * __all__ = [] for name in dir(A): globals()[name] = getattr(A, name) __all__+= [name]