HumanbiOS / QA-module

1 stars 0 forks source link

Multiple question answer value is not a valid question id #2

Closed kittyandrew closed 4 years ago

kittyandrew commented 4 years ago
{'_lang': 'en', 'id': 'X0', 'text': 'Which of the following symptoms have you had in the past 24 hours? (multiple selection possible)', 'comment': 'The question relates to acute or exacerbated symptoms and excludes chronic complaints or seasonal or allergic complaints. If you have a chronic illness, compare your current symptoms with your previous problems to answer the question.\n\nIf you don\'t have any of the symptoms, don\'t select an entry and continue by choosing the "Next" button.', 'free': False, 'answers': {'Feeling tired or weak': 'S4', 'Body aches': 'S5', 'Diarrhea': 'S8', 'Headache': 'SA', 'Loss of taste and/or smell': 'SC'}, 'multi': True}

Answer (for example): 'Diarrhea': 'S8'

current_question = "S8"
response = get_next_question(sender_id, "en", current_question)
if response is False:
    raise Exception("why?")

Exception is raised.

What do the values of multiple-answer question mean, if they are not legit ids?