I’ve started Rasa action server under debugging under Visual Studio Code. I’ve set a breakpoint, and started rasa shell to connect to it. After a couple of seconds, rasa shell raises a timeout error. Can I disable it?
I’ve tried to start the shell after setting the environment variable DEFAULT_STREAM_READING_TIMEOUT_IN_SECONDS to a high value, the the timeout persists. I believe there must be another way tho prevent the timeout
This may sound silly, but are you sure your breakpoint isn’t holding up your RASA action server and preventing it from responding? What happens if you remove the breakpoint and make both components work normally?
Yes, it is exactly what it is doing and what I want it to do. I want to be able to go step by step through the code while the robot is preparing its response.
During the step by step debugging I can change the behavior of the response, and would like to see how the flow of the dialog changes.
Usually it is possible to change the timeout value, but I just found the DEFAULT_STREAM_READING_TIMEOUT_IN_SECONDS configuration and it isn’t working.
Unfortunately, it didn’t work.
I tried to pass the --response-timeout 3600 while starting rasa actions and it complained that the parameter didn’t exist. I’ve successfully ran rasa shell with it:
rasa shell \
but I’m still getting the timeout error in shell after some seconds. Here is the stack trace:
2020-04-22 15:47:41 DEBUG rasa.core.actions.action - Calling action endpoint to run action 'action_session_start'.
2020-04-22 15:47:50 ERROR asyncio - Task exception was never retrieved
future: <Task finished coro=<configure_app.<locals>.run_cmdline_io() done, defined at c:\anaconda3\envs\rasa\lib\site-packages\rasa\core\run.py:128> exception=TimeoutError()>
Traceback (most recent call last):
File "c:\anaconda3\envs\rasa\lib\site-packages\rasa\core\run.py", line 134, in run_cmdline_io
File "c:\anaconda3\envs\rasa\lib\site-packages\rasa\core\channels\console.py", line 139, in record_messages
async for response in bot_responses:
File "c:\anaconda3\envs\rasa\lib\site-packages\rasa\core\channels\console.py", line 105, in send_message_receive_stream
async for line in resp.content:
File "c:\anaconda3\envs\rasa\lib\site-packages\aiohttp\streams.py", line 39, in __anext__
rv = await self.read_func()
File "c:\anaconda3\envs\rasa\lib\site-packages\aiohttp\streams.py", line 328, in readline
File "c:\anaconda3\envs\rasa\lib\site-packages\aiohttp\streams.py", line 296, in _wait
File "c:\anaconda3\envs\rasa\lib\site-packages\aiohttp\helpers.py", line 596, in __exit__
raise asyncio.TimeoutError from None
Transport closed @ ('127.0.0.1', 57052) and exception experienced during error handling
I searched the code and saw that the value is harcoded:
DEFAULT_STREAM_READING_TIMEOUT_IN_SECONDS = 10
I’ve changed it to
DEFAULT_STREAM_READING_TIMEOUT_IN_SECONDS = int(
I’ll test it and if it works, I’ll clone the repo and send a pull request.
Hi, I exported RASA_SHELL_STREAM_READING_TIMEOUT_IN_SECONDS and ran rasa shell. It worked for me.
NOTE: I am using Rasa 1.10.2