From 7de47da611fd94bb165abf0738c4a81053c06068 Mon Sep 17 00:00:00 2001 From: Arjaan Buijk Date: Thu, 21 Jan 2021 15:16:21 -0500 Subject: [PATCH] Do the ActionExecutionRejection independent if user rejected manually Fix for issue #7751 to avoid that a form will re-ask for the slot prior to switching to another form. --- rasa/core/actions/forms.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/rasa/core/actions/forms.py b/rasa/core/actions/forms.py index c7a9fa7ba311..de6c1f91df57 100644 --- a/rasa/core/actions/forms.py +++ b/rasa/core/actions/forms.py @@ -461,14 +461,7 @@ async def validate( # to be filled by the user. if isinstance(event, SlotSet) and not event.key == REQUESTED_SLOT ) - user_rejected_manually = any( - isinstance(event, ActionExecutionRejected) for event in validation_events - ) - if ( - slot_to_fill - and not some_slots_were_validated - and not user_rejected_manually - ): + if slot_to_fill and not some_slots_were_validated: # reject to execute the form action # if some slot was requested but nothing was extracted # it will allow other policies to predict another action