Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix to report incorrect entity value #11388

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix to report incorrect entity value
  • Loading branch information
rgstephens committed Jul 22, 2022
commit 804cbb4c9de3ac8b009f5a53c21f07f949571829
1 change: 1 addition & 0 deletions changelog/11385.fix.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
`rasa test` command did not report incorrect entity value in `failed_test_stories.yml`.
5 changes: 4 additions & 1 deletion rasa/core/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,10 @@ def inline_comment_for_entity(
predicted: Dict[Text, Any], entity: Dict[Text, Any]
) -> Optional[Text]:
"""Returns the predicted entity which is then printed as a comment."""
if predicted["entity"] != entity["entity"]:
if (
predicted["entity"] != entity["entity"]
or predicted["value"] != entity["value"]
):
return "predicted: " + predicted["entity"] + ": " + predicted["value"]
else:
return None
Expand Down