Not able to utter a template using utter_template or any message just before "ActionExecutionRejection" is raised in form's validation()

I am trying to handle Unhappy-path using Forms so when a user does not provide Required_slot. Two messages should be printed:

  1. Please provide valid info. (uttering from validation() using utter_validinfo)

    – Then “ActionExecutionRejection” is raised as normal

  2. Don’t you want to continue? (Yes/No)(utter_ask_to_continue)

    -- as in this story: 
     * get_specific_info
            - specific_form
            - form{"name": "specific_form"}
     * reset_all    
            - utter_ask_to_continue    
     * negation
            - utter_restart
            - action_restart

When Form asks for a Required_slot and the user says reset_all then a utter_template should print utter_validinfo and utter_ask_to_continue should be shown.

What is really happening is, It does not show utter_validinfo message before raising “ActionExecutionRejection” but it shows utter_ask_to_continue after “ActionExecutionRejection” is raised.

Why utter_validinfo is not printed while it is being executed before “ActionExecutionRejection”. I have checked it.

Please help. Thanks

hi @Rohit - the general idea behind forms is that they only handle the happy paths. Check out section 6 of this tutorial Building contextual assistants with Rasa Forms

hi @amn41 - I handled the unhappy path using stories.

I was just wondering that I am not able to utter_template() just before “ActionExecutionRejection” is raised in validation().

while utter_template() works fine if “ActionExecutionRejection” is not raised.

Is this normal behavior?

yes that is expected, those utterances are only sent once the action executes correctly