Hello, I’m new to the rasa. I developed a custom action and tried to pass data through slots. but it shows an error while running. It shows variable is the NoneType object. I think data is not passing through the slots. is there any wrong with my code?
itsjhonny
(João Pedro Guimarães)
May 11, 2022, 6:20pm
2
Hi!
I think your code is right. I think this action are trigger before set any value in amount slot
and trying make split in null value
Can you check it using print(UserReply)
before the for loop?
If you prefer, you can use rasa FormValidationAction
from typing import Text, List, Any, Dict
from rasa_sdk import Tracker, FormValidationAction
from rasa_sdk.executor import CollectingDispatcher
from rasa_sdk.types import DomainDict
class ValidateNameForm(FormValidationAction):
def name(self) -> Text:
return "validate_name_form"
def validate_first_name(
self,
slot_value: Any,
dispatcher: CollectingDispatcher,
tracker: Tracker,
domain: DomainDict,
) -> Dict[Text, Any]:
Thank you very much. I will try it
I tried print(UserReply). it shows none. now what I can do? is there any solution?