Hi everyone,

We create a chatbot with rasa last August. We have a problem with last releases / updates of Rasa. In my file, We created differents slot but when we restarted my bot this month, the setting slot dosn’t work anymore.

Any Help ? :slight_smile:

1 Like

Could you please more specific what is happening, Paste some code here which is not working?

Thanks for your answer :slight_smile: In the conversation, le bot has to get entities like : name_room, day, hour_start, duration. and return at the end “You want to book the {} room is booked on {} at {} for {}. Is it correct ?” (with filled blanks). But with the last version of rasa, it looks like get_slot doesn’t work anymore.

We have : rasa-core==0.12.0 rasa-nlu==0.13.7

Here is our code :wink:

from future import absolute_import from future import division from future import unicode_literals

from rasa_core_sdk import Action from import SlotSet

from booking import make_a_booking import mysql.connector

class ActionRoom(Action):

def name(self):
    return 'action_room'

def run(self, dispatcher, tracker, domain):
    name_room = tracker.get_slot('name_room')
    day = tracker.get_slot('day')
    hour_start = tracker.get_slot('hour_start')
    duration = tracker.get_slot('duration')
    booking_answer = make_a_booking(name_room, day, hour_start, duration)
    if booking_answer:
        booking_answer = 'The reservation has been made'
        booking_answer = 'The room is taken at this hour'
    response = """You want to book the {} room is booked on {} at {} for {}. Is it correct ?""".format(name_room, day, hour_start, duration)
    name_room = str(name_room)
    day = str(day)
    hour_start = str(hour_start)
    duration = str(duration)
    #SQL queries#
    cnx = mysql.connector.connect(host='***', password='***', user="***", database="***")

    dispatch = dispatcher.utter_message(response)
    dispatch = dispatcher.utter_message(str(booking_answer))
    return dispatch

can you please uplaod your other releated files?