I've been researching how to do this and I can't figure out what I am doing wrong, I want to use import to import a class and then instantiate it and am doing it as so:
the class, from a file called "action_1", I have already imported / appended the path to this)
class Action_1 ():
def __init__ (self):
pass
how I am trying to import then instantiate it
imprtd_class = __import__('action_1', globals(), locals(), ['Action_1'], -1)
#instantiate the imported class:
inst_imprtd_class = imprtd_class()
>>>> 'module' object is not callable