Hi All,
I have downloaded Rasa help desk assitant from
here
.
It was working earlier smoothly with proper integration with Service Now.
But now when I tried it is giving me below error.
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
and I dont have any idea about where it is going wrong .
Kindly help.
Please find below my error log :-
D:\Python\Pratik_python\Rasa_Chatbot_Ticket\Helpdesk_version_1\actions>rasa run actions
2020-09-10 15:14:27 INFO rasa_sdk.endpoint - Starting action endpoint server…
2020-09-10 15:14:27 INFO rasa_sdk.executor - Registered function for ‘open_incident_form’.
2020-09-10 15:14:27 INFO rasa_sdk.executor - Registered function for ‘incident_status_form’.
Status code of the result 200
Exception occurred while handling uri: ‘
http://localhost:5055/webhook
’
Traceback (most recent call last):
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\sanic\app.py”, line 976, in handle_request
response = await response
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\endpoint.py”, line 102, in webhook
result = await executor.run(action_call)
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\executor.py”, line 385, in run
events = await action(dispatcher, tracker, domain)
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\forms.py”, line 584, in run
events.extend(await self._validate_if_required(dispatcher, tracker, domain))
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\forms.py”, line 551, in _validate_if_required
return await self.validate(dispatcher, tracker, domain)
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\forms.py”, line 414, in validate
return await self.validate_slots(slot_values, dispatcher, tracker, domain)
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\rasa_sdk\forms.py”, line 371, in validate_slots
validation_output = validate_func(value, dispatcher, tracker, domain)
File “D:\Python\Pratik_python\Rasa_Chatbot_Ticket\Helpdesk_version_1\actions\actions.py”, line 156, in validate_email
return _validate_email(value, dispatcher, tracker, domain)
File “D:\Python\Pratik_python\Rasa_Chatbot_Ticket\Helpdesk_version_1\actions\actions.py”, line 61, in
validate_email
results = snow.email_to_sysid(value)
File “D:\Python\Pratik_python\Rasa_Chatbot_Ticket\Helpdesk_version_1\actions\snow.py”, line 66, in email_to_sysid
result = self.handle_request(requests.get, request_args)
File “D:\Python\Pratik_python\Rasa_Chatbot_Ticket\Helpdesk_version_1\actions\snow.py”, line 42, in handle_request
result[“content”] = response.json()
File “c:\users\pratik\appdata\local\programs\python\python36\lib\site-packages\requests\models.py”, line 898, in json
return complexjson.loads(self.text, **kwargs)
File "c:\users\pratik\appdata\local\programs\python\python36\lib\json_
init
.py", line 354, in loads
return _default_decoder.decode(s)
File “c:\users\pratik\appdata\local\programs\python\python36\lib\json\decoder.py”, line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “c:\users\pratik\appdata\local\programs\python\python36\lib\json\decoder.py”, line 357, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
from the log, it looks like the custom action is calling the service now API and expecting a JSON response. It is getting something else (probably an error message) which can’t be decoded as JSON.
I’d recommend adding some debug statements to the action code, right before and after the request is sent, to see what the request and response look like