Error: No registered action found

Hi,

I’m running the docker-compose version of Rasa X (v0.24.1) with Rasa (v1.6.0).

The custom actions are working fine in my local instance.

But, it isn’t on the server. This is the error message from the docker logs

INFO:sanic.root:Goin' Fast @ http://0.0.0.0:5055
INFO:sanic.root:Starting worker [1]
/app/rasa_sdk/utils.py:159: UserWarning: Your versions of rasa and rasa_sdk might not be compatible. You are currently running rasa version 1.6.0 and rasa_sdk version 1.5.1.
To ensure compatibility use the same version for both, modulo the last number, i.e. using version A.B.x the numbers A and B should be identical for both rasa and rasa_sdk.
  f"Your versions of rasa and "
DEBUG:rasa_sdk.executor:Received request to run 'action_default_ask_affirmation'
ERROR:rasa_sdk.endpoint:No registered action found for name 'action_default_ask_affirmation'.

Action server logs

2020-01-12 14:36:34 INFO     rasa_sdk.endpoint  - Starting action endpoint server...
2020-01-12 14:36:35 INFO     rasa_sdk.executor  - Registered function for 'action_default_ask_affirmation'.
2020-01-12 14:36:35 INFO     rasa_sdk.executor  - Registered function for 'action_default_fallback'.

The action - “action_default_ask_affirmation” is included in my domain.yml and actions.py file.

Also, not sure why I’m getting the rasa_sdk v1.5.1 warning. My custom action server is running on rasa_sdk v1.6.0.

Please send the output from a docker-compose ps. You should update the image version for rasa-sdk to 1.6.1. You should find this in your .env or docker-compose.yml. At the same time I would update the rasa image to 1.6.1.

@stephens Done. Updated to version 1.6.1.

Still no luck. Sharing the docker-compose logs

rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.tracker_store  - Recreating tracker from sender id 'fcbaf4795f914e4793355b52b47b1a48'
rasa-production_1  | 2020-01-14 11:27:37 WARNING  root  - Could not parse timestamp cf42927af8844bb7a47101512ff5b62c. Instead current UTC time will be passed to duckling. Error: invalid literal for int() with base 10: 'cf42927af8844bb7a47101512ff5b62c'
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Received user message 'tableau' with intent '{'name': 'Tableau.KBA002.Get_Started', 'confidence': 0.3640412390232086}' and entities '[]'
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Logged UserUtterance - tracker now has 9 events.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.form_policy  - There is no active form
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.memoization  - Current tracker state [{}, {'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_default_ask_affirmation': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_default_ask_affirmation': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}]
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.memoization  - There is no memorised next action
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.mapping_policy  - The predicted intent 'Tableau.KBA002.Get_Started' is mapped to  action 'utter_Tableau.KBA002.Get_Started' in the domain.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.fallback  - NLU confidence 0.3640412390232086 is lower than NLU threshold 0.60.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.ensemble  - Predicted next action using policy_4_TwoStageFallbackPolicy
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Predicted next action 'action_default_ask_affirmation' with confidence 1.00.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.actions.action  - Calling action endpoint to run action 'action_default_ask_affirmation'.
app_1              | DEBUG:rasa_sdk.executor:Received request to run 'action_default_ask_affirmation'
app_1              | ERROR:rasa_sdk.endpoint:No registered action found for name 'action_default_ask_affirmation'.
app_1              | DEBUG:sanic.root:CORS: Request to '/webhook' matches CORS resource '/*'. Using options: {'origins': ['.*'], 'methods': 'DELETE, GET, HEAD, OPTIONS, PATCH, POST, PUT', 'allow_headers': ['.*'], 'expose_headers': None, 'supports_credentials': False, 'max_age': None, 'send_wildcard': False, 'automatic_options': True, 'vary_header': True, 'resources': {'/*': {'origins': '*'}}, 'intercept_exceptions': True, 'always_send': True}
app_1              | INFO:sanic.access:
rasa-production_1  | 2020-01-14 11:27:37 ERROR    rasa.core.processor  - Encountered an exception while running action 'action_default_ask_affirmation'. Bot will continue, but the actions events are lost. Please check the logs of your action server for more information.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Failed to execute custom action.
rasa-production_1  | Traceback (most recent call last):
rasa-production_1  |   File "/build/lib/python3.6/site-packages/rasa/core/actions/action.py", line 541, in run
rasa-production_1  |     json=json_body, method="post", timeout=DEFAULT_REQUEST_TIMEOUT
rasa-production_1  |   File "/usr/local/lib/python3.6/asyncio/coroutines.py", line 110, in __next__
rasa-production_1  |     return self.gen.send(None)
rasa-production_1  |   File "/build/lib/python3.6/site-packages/rasa/utils/endpoints.py", line 150, in request
rasa-production_1  |     resp.status, resp.reason, await resp.content.read()
rasa-production_1  | rasa.utils.endpoints.ClientResponseError: 404, Not Found, body='b'{"error":"No registered action found for name \'action_default_ask_affirmation\'.","action_name":"action_default_ask_affirmation"}''
rasa-production_1  |
rasa-production_1  | The above exception was the direct cause of the following exception:
rasa-production_1  |
rasa-production_1  | Traceback (most recent call last):
rasa-production_1  |   File "/build/lib/python3.6/site-packages/rasa/core/processor.py", line 564, in _run_action
rasa-production_1  |     events = await action.run(output_channel, nlg, tracker, self.domain)
rasa-production_1  |   File "/usr/local/lib/python3.6/asyncio/coroutines.py", line 110, in __next__
rasa-production_1  |     return self.gen.send(None)
rasa-production_1  |   File "/build/lib/python3.6/site-packages/rasa/core/actions/action.py", line 564, in run
rasa-production_1  |     raise Exception("Failed to execute custom action.") from e
rasa-production_1  | Exception: Failed to execute custom action.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Action 'action_default_ask_affirmation' ended with events '[]'.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.form_policy  - There is no active form
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.memoization  - Current tracker state [{'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_default_ask_affirmation': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_default_ask_affirmation': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_listen': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}, {'prev_action_default_ask_affirmation': 1.0, 'intent_Tableau.KBA002.Get_Started': 1.0}]
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.memoization  - There is no memorised next action
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.mapping_policy  - There is no mapped action for the predicted intent, 'Tableau.KBA002.Get_Started'.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.policies.ensemble  - Predicted next action using policy_4_TwoStageFallbackPolicy
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Predicted next action 'action_listen' with confidence 1.00.
rasa-production_1  | 2020-01-14 11:27:37 DEBUG    rasa.core.processor  - Action 'action_listen' ended with events '[]'.

I suspect the action server is not running but I can’t tell from the log you’ve sent. Please send the output from the docker-compose ps command. Also, stop and re-start action server and I need to see the beginning log messages from the action server:

docker-compose down app
docker-compose up app

These commands will start the action server in the foreground but we will see the startup messages.

@KarthiAru @stephens I have a similar error but with forms. I posted about it Here , How did you fix the error @KarthiAru. Please help

@stephens Sorry for replying a bit late. Here are the logs.

Output of docker-compose ps

         Name                       Command               State                      Ports
-------------------------------------------------------------------------------------------------------------
rasa_action_server_1     ./entrypoint.sh start --ac ...   Up      5005/tcp, 5055/tcp
rasa_app_1               ./entrypoint.sh run python ...   Up      5055/tcp
rasa_db_1                /entrypoint.sh /run.sh           Up      5432/tcp
rasa_duckling_1          duckling-example-exe --no- ...   Up      8000/tcp
rasa_nginx_1             /opt/bitnami/entrypoint.sh ...   Up      0.0.0.0:80->8080/tcp, 0.0.0.0:443->8443/tcp
rasa_rabbit_1            /entrypoint.sh /run.sh           Up      15672/tcp, 25672/tcp, 4369/tcp, 5672/tcp
rasa_rasa-production_1   rasa x --no-prompt --produ ...   Up      5005/tcp
rasa_rasa-worker_1       rasa x --no-prompt --produ ...   Up      5005/tcp
rasa_rasa-x_1            sh -c user_id=$(id -u) &&  ...   Up      5002/tcp
rasa_redis_1             /entrypoint.sh /run.sh           Up      0.0.0.0:6379->6379/tcp

Output logs of docker-compose up app

rasa_db_1 is up-to-date
rasa_rabbit_1 is up-to-date
rasa_redis_1 is up-to-date
rasa_rasa-x_1 is up-to-date
rasa_rasa-production_1 is up-to-date
Starting rasa_app_1 ... done
Attaching to rasa_app_1
app_1              | INFO:rasa_sdk.endpoint:Starting action endpoint server...
app_1              | DEBUG:sanic.root:CORS: Configuring CORS with resources: {'/*': {'origins': ['.*'], 'methods': 'DELETE, GET, HEAD, OPTIONS, PATCH, POST, PUT', 'allow_headers': ['.*'], 'expose_headers': None, 'supports_credentials': False, 'max_age': None, 'send_wildcard': False, 'automatic_options': True, 'vary_header': True, 'resources': {'/*': {'origins': '*'}}, 'intercept_exceptions': True, 'always_send': True}}
app_1              | DEBUG:rasa_sdk.utils:Using the default number of Sanic workers (1).
app_1              | DEBUG:sanic.root:
app_1              |
app_1              |                  Sanic
app_1              |          Build Fast. Run Fast.
app_1              |
app_1              |
app_1              | INFO:sanic.root:Goin' Fast @ http://0.0.0.0:5055
app_1              | INFO:sanic.root:Starting worker [1]

@stephens Sorry. I found the issue in my docker-compose file. I had added a custom action-server block earlier.

It is working now with the config in docker-compose.override.yml. Thanks to the Rasa X Masterclass video on this.

version: '3.4'
services:
    app:
        restart: always
        image: 'rasa/rasa-sdk:${RASA_SDK_VERSION}'
        expose:
          - '5005'
        volumes:
          - './actions:/app/actions'
        depends_on:
          - rasa-production

Logs of docker-compose up app

rasa_rabbit_1 is up-to-date
rasa_redis_1 is up-to-date
rasa_db_1 is up-to-date
rasa_rasa-x_1 is up-to-date
rasa_rasa-production_1 is up-to-date
rasa_app_1 is up-to-date
Attaching to rasa_app_1
app_1              | 2020-01-25 16:58:55 INFO     rasa_sdk.endpoint  - Starting action endpoint server...
app_1              | 2020-01-25 16:58:56 INFO     rasa_sdk.executor  - Registered function for 'action_default_ask_affirmation'.
app_1              | 2020-01-25 16:58:56 INFO     rasa_sdk.executor  - Registered function for 'action_default_fallback'.
2 Likes

@cyberdroidmann You can refer to my answer in the thread below.

Thanks @KarthiAru I’ll try this now

@KarthiAru Thank you for the solution. I am bit confused about docker-compose.yml and docker-compose.override.yml can you show me your docker-compose file?

Thank you.