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

Handle empty reply text #212

Open
MrOrz opened this issue Jul 21, 2020 · 0 comments
Open

Handle empty reply text #212

MrOrz opened this issue Jul 21, 2020 · 0 comments
Labels
good first issue Picked for newcomers

Comments

@MrOrz
Copy link
Member

MrOrz commented Jul 21, 2020

Inputting this will break staging chatbot:

πŸ“ƒ ζŸ₯ηœ‹ι€™η―‡ηš„ε›žζ‡‰:
https://dev.cofacts.org/article/AV1vp0l4yCdS-nWhuc4e

The error in console says:

{
  "message": "A message (messages[2]) in the request body is invalid",
  "details": [
    {
      "message": "must be non-empty text",
      "property": "/contents/5/body/contents/0/text"
    },
    {
      "message": "must be non-empty text",
      "property": "/contents/6/body/contents/0/text"
    },
    {
      "message": "must be non-empty text",
      "property": "/contents/7/body/contents/0/text"
    }
  ]
}

This is because there are some replies with empty text (probably caused by a previous bug.)
The reply sending mechanism should prevent empty text from being sent as an option.

@MrOrz MrOrz added the good first issue Picked for newcomers label Jul 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Picked for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant