Skip to content

Commit

Permalink
Change missing domain log level in rasa-sdk from ERROR to DEBUG
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksandarmijat committed Jun 26, 2024
1 parent 2247a58 commit c4b765a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion rasa_sdk/endpoint.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ async def webhook(request: Request) -> HTTPResponse:
body = {"error": e.message, "action_name": e.action_name}
return response.json(body, status=404)
except ActionMissingDomainException as e:
logger.error(e)
logger.debug(e)
body = {"error": e.message, "action_name": e.action_name}
return response.json(body, status=449)

Expand Down
4 changes: 3 additions & 1 deletion rasa_sdk/interfaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,9 @@ class ActionMissingDomainException(Exception):

def __init__(self, action_name: Text, message: Optional[Text] = None) -> None:
self.action_name = action_name
self.message = message or "Domain context is missing."
self.message = (
message or "Missing domain context, assistant will retry the request."
)

def __str__(self) -> Text:
return self.message

0 comments on commit c4b765a

Please sign in to comment.