#The name of the main class must match the file name in lowercase class example: def __init__(self): self.example='This is an example plugin' self.dbg=0 self.progress=0 #This dict defines wich package_type relies on what action self.pluginInfo={'example':'*'} #def __init__ def set_debug(self,dbg='1'): self.dbg=int(dbg) self.debug ("Debug enabled") #def set_debug def _debug(self,msg=''): if self.dbg==1: print ('DEBUG Example: '+msg) #def debug def register(self): #This function MUST return the dict with the action:package_type pair #In this example it return nothing #return(self.pluginInfo) return({}) def execute_action(self,action): if action=='example': self._exec_example() self.progress=100 return self.example def _callback(self): self.progress=self.progress+1 # <---- Put your code ----> # def _exec_example(self): self.example="Example executed" while (self.progress<100): self._callback()