Slot value has been set but failed to validate

am trying to validate weight…the slot for weight has been set but when trying to validate in custom action it throws error TypeError: expected string or bytes-like object

In your custom actions validate_weight function can you add the following:

print(value,type(value))

on line number 189 by maintaining indentation and repeat what are you did last time.

Post your findings here. I will try to help you.

ow ya you are right i have to add srt()…thanks a lot

I marked as a solution

Great… Happy Coding

@ChikkaUdayaSai Have tried csv file as a lookup in nlu??

Nope. Just used txt file only…

Okay…

@ChikkaUdayaSai…i have phone extracted but the vaildation keep failing ,can you see it for me please

@faiza_conte, Kindly open a new post in case of any new issues in future. You can tag me if you need.

Coming to the problem, in the validation function add the function,

print(value)

to see what is being printed. I am assuming that the zero is not being captured in the validation function. That’s why it is failing. If that is the case you can change the validation function by doing some modifications as

if len(str(value)) == 9 instead of 10.