Rasa X server: No registered action found

Hi there!

I followed the rasa master class tutorial to build my own rasa X server using google cloud. However, I have an issue when setting up the action server. The bot in rasa-x doesn’t reply when an action is triggered.

My current setup:

docker-compose.override.yml

version: '3.4'
services:
 app:
   restart: always
   build: .
   volumes:
   - './actions:/app/actions'
   expose:
   - '5055'
   depends_on:
   - rasa-production

The docker compose overwrite file builds from the following Dockerfile:

# Extend the official Rasa SDK image
FROM rasa/rasa-sdk:latest

# Change back to root user to install dependencies
USER root

# To install system dependencies
RUN apt-get update -qq && \
    apt-get clean && \
    rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

# To install packages from PyPI
RUN pip install --no-cache-dir pandas babel numpy

# Switch back to non-root to run code
USER 1001

My docker-compose ps output looks like this:

         Name                       Command                  State                                              Ports                                        
-------------------------------------------------------------------------------------------------------------------------------------------------------------
rasa_app_1               ./entrypoint.sh run python ...   Up             5055/tcp                                                                            
rasa_db-migration_1      python -m rasax.community. ...   Up (healthy)   8000/tcp                                                                            
rasa_db_1                /opt/bitnami/scripts/postg ...   Up             5432/tcp                                                                            
rasa_duckling_1          duckling-example-exe --no- ...   Up             8000/tcp                                                                            
rasa_nginx_1             /docker-entrypoint.sh ngin ...   Up             80/tcp, 0.0.0.0:80->8080/tcp,:::80->8080/tcp, 0.0.0.0:443->8443/tcp,:::443->8443/tcp
rasa_rabbit_1            /opt/bitnami/scripts/rabbi ...   Up             15671/tcp, 15672/tcp, 25672/tcp, 4369/tcp, 5671/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            /tini -g -- sh -c user_id= ...   Up             5002/tcp                                                                            
rasa_redis_1             /opt/bitnami/scripts/redis ...   Up             6379/tcp  

I checked the output log of the rasa_app_1 service. The error is that no registered action found for name action_tell_conditions:

INFO:rasa_sdk.endpoint:Starting action endpoint server...
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}}
INFO:rasa_sdk.endpoint:Action endpoint is up and running on http://0.0.0.0:5055
DEBUG:rasa_sdk.utils:Using the default number of Sanic workers (1).
DEBUG:sanic.root:

                 Sanic
         Build Fast. Run Fast.


INFO:sanic.root:Goin' Fast @ http://0.0.0.0:5055
INFO:sanic.root:Starting worker [1]
DEBUG:rasa_sdk.executor:Received request to run 'action_tell_conditions'
ERROR:rasa_sdk.endpoint:No registered action found for name 'action_tell_conditions'.
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}
INFO:sanic.access:

However, the action is defined in the actions.py file of the server: actions.py

class ActionTellConditions(Action):
    def name(self) -> Text:
        return "action_tell_conditions"

    def run(
        self,
        dispatcher: CollectingDispatcher,
        tracker: Tracker,
        domain: Dict[Text, Any],
    ) -> List[Dict[Text, Any]]:
        precio = piso1.get("precio")
        dispatcher.utter_message(
            template="utter_conditions",
            precio=precio
        )

        return []
1 Like

@Italosayan Hi, can you share the endpoints.yml file and domain.yml ?

endpoints:

# This file contains the different endpoints your bot can use.

# Server where the models are pulled from.
# https://rasa.com/docs/rasa/model-storage#fetching-models-from-a-server

#models:
#  url: http://my-server.com/models/default_core@latest
#  wait_time_between_pulls:  10   # [optional](default: 100)

# Server which runs your custom actions.
# https://rasa.com/docs/rasa/custom-actions

action_endpoint:
  url: "http://localhost:5055/webhook"

# Tracker store which is used to store the conversations.
# By default the conversations are stored in memory.
# https://rasa.com/docs/rasa/tracker-stores

#tracker_store:
#    type: redis
#    url: <host of the redis instance, e.g. localhost>
#    port: <port of your redis instance, usually 6379>
#    db: <number of your database within redis, e.g. 0>
#    password: <password used for authentication>
#    use_ssl: <whether or not the communication is encrypted, default false>

#tracker_store:
#    type: mongod
#    url: <url to your mongo instance, e.g. mongodb://localhost:27017>
#    db: <name of the db within your mongo instance, e.g. rasa>
#    username: <username used for authentication>
#    password: <password used for authentication>

# Event broker which all conversation events should be streamed to.
# https://rasa.com/docs/rasa/event-brokers

#event_broker:
#  url: localhost
#  username: username
#  password: password
#  queue: queue

domain.yml

version: "2.0"

intents:
  - greet
  - goodbye
  - affirm
  - deny
  - askconditions
  - askrentalavailability

...utters

actions:
  - action_tell_conditions
  - action_tell_rental_date_availability
  - action_tell_free_calendar

session_config:
  session_expiration_time: 60
  carry_over_slots_to_new_session: true


Change to:

action_endpoint:
  url: "http://app:5055/webhook"

and run the docker-compose

1 Like

Still not working.

I rebuilt the images and now it works:

sudo docker rmi $(sudo docker images -a -q)
sudo docker-compose up -d

@Italosayan Nice. :+1: Did you updated the endpoints and re-build. Please close this thread for others. Good Luck!

1 Like