'Tracker' object has no attribute '_reset'

(Julian Gerhard) #1

Hi,

I want to reset an executed Form programmatically. According to

the following has to be implemented:

def apply_to(self, tracker):
    from rasa.core.actions.action import ACTION_LISTEN_NAME

    tracker._reset()
    tracker.trigger_followup_action(ACTION_LISTEN_NAME)

If I do that, the AttributeError in the title is thrown. After investigating the method definitions - may it be the case, that the documentation is not up to date at this point?

I know that I could add the restart_functionality per intent in my stories but with growing size and amount of stories, that doesn’t seem to be the best way…

I there any other way to achieve this functionality? I have tried to return [Restarted()] but that didn’t help.

(Julian Gerhard) #2

I found it out myself: I could use self.deactivate() to achieve the desired functionality.