Module ImportFrom alias alias alias alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr If NameLoad body Expr Call NameLoad NameLoad Call NameLoad NameLoad NameLoad Return NameLoad If NameLoad body Assign NameStore Call NameLoad keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call NameLoad NameLoad NameLoad TryExcept body Expr Call NameLoad NameLoad NameLoad NameLoad NameLoad handlers ExceptHandler type NameLoad body Expr Call NameLoad NameLoad Expr Call NameLoad NameLoad Call NameLoad NameLoad NameLoad Return NameLoad orelse Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr If CompareGt NameLoad Num body For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Return TupleLoad NameLoad NameLoad Assign NameStore IfExp CompareEq NameLoad Num SubscriptLoad NameLoad Index Num NameLoad Return TupleLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameStore Call NameLoad NameLoad NameLoad NameLoad Assign NameStore Call NameLoad keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr If NameLoad body Assign NameStore Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad keyword NameLoad If Call NameLoad NameLoad body Expr Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad If CompareGt Call NameLoad NameLoad Num body Assign NameStore Call NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad keyword NameLoad orelse Expr Call NameLoad NameLoad Assign NameStore BinOpMod Str TupleLoad NameLoad AttributeLoad NameLoad attr Expr Call NameLoad NameLoad NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore NameLoad Assign NameStore Str If BoolOpAnd CompareEq NameLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str NameLoad body Return TupleLoad NameLoad NameLoad Call NameLoad NameLoad NameLoad If CompareEq AttributeLoad NameLoad attr Str body Assign NameStore Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Str If CompareIn NameLoad NameLoad body Assign NameStore Call NameLoad SubscriptLoad NameLoad Index NameLoad Assign NameStore NameLoad orelse TryExcept body Assign NameStore Call NameLoad NameLoad If BoolOpAnd CompareGtE NameLoad Num CompareLtE NameLoad Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Str body Assign NameStore NameLoad orelse Assign NameStore Call NameLoad NameLoad NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body Assign NameStore Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Str Assign NameStore Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Str Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Dict TryExcept body For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr If CompareIn NameLoad NameLoad body Assign SubscriptStore NameLoad Index Call NameLoad SubscriptLoad NameLoad Index NameLoad Str orelse Assign NameStore Call NameLoad NameLoad Assert BoolOpAnd CompareGtE NameLoad Num CompareLtE NameLoad NameLoad Assign SubscriptStore NameLoad Index Call NameLoad NameLoad Str Assign NameStore Call AttributeLoad Str attr Call AttributeLoad NameLoad attr Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body TryExcept body Expr Call NameLoad NameLoad Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body TryExcept body Expr Call NameLoad NameLoad Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body TryExcept body Expr Call NameLoad NameLoad Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body TryExcept body Assert CompareEq Call NameLoad NameLoad Num Expr Call NameLoad NameLoad Assign NameStore BinOpMod Str TupleLoad SubscriptLoad NameLoad Slice Num Num SubscriptLoad NameLoad Slice Num Num SubscriptLoad NameLoad Slice Num Expr Call NameLoad NameLoad Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body TryExcept body Assert CompareEq Call NameLoad NameLoad Num Assign NameStore Call NameLoad SubscriptLoad NameLoad Slice Num Num Assign NameStore Call NameLoad SubscriptLoad NameLoad Slice Num Assert BoolOpAnd CompareGtE NameLoad Num CompareLtE NameLoad Num Assert BoolOpAnd CompareGtE NameLoad Num CompareLtE NameLoad Num Assign NameStore BinOpMod Str TupleLoad NameLoad Call AttributeLoad Call NameLoad NameLoad attr Num Assign NameStore NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad orelse Assign NameStore NameLoad Return TupleLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Dict For TupleStore NameStore NameStore Call NameLoad NameLoad body Assign SubscriptStore NameLoad Index Call AttributeLoad Call AttributeLoad NameLoad attr attr BinOpAdd NameLoad Num Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body For NameStore NameLoad body If CompareEq AttributeLoad NameLoad attr Str body Return NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr decorator_list
N/A corehq.apps.sms.api MessageMetadata add_msg_tags send_sms_to_verified_number log_sms_exception corehq.apps.sms.messages * corehq.apps.sms.util format_message_list touchforms.formplayer.api current_question corehq.apps.smsforms.app _get_responses _responses_to_text dateutil.parser parse corehq.apps.smsforms.models SQLXFormsSession form_session_handler N/A N/A v text msg N/A N/A N/A 
    The form session handler will use the inbound text to answer the next question
    in the open SQLXformsSession for the associated contact. If no session is open,
    the handler passes. If multiple sessions are open, they are all closed and an
    error message is displayed to the user.
     N/A N/A multiple session N/A get_single_open_session_or_close_multiple N/A v domain N/A v owner_id N/A multiple N/A N/A N/A send_sms_to_verified_number v N/A get_message MSG_MULTIPLE_SESSIONS v N/A True N/A session N/A N/A inbound_metadata N/A MessageMetadata workflow N/A session workflow reminder_id N/A session reminder_id xforms_session_couch_id N/A session _id N/A N/A add_msg_tags msg inbound_metadata N/A N/A N/A N/A answer_next_question v text msg session N/A N/A N/A Exception N/A N/A N/A log_sms_exception msg N/A N/A send_sms_to_verified_number v N/A get_message MSG_TOUCHFORMS_DOWN v N/A True N/A N/A False N/A get_single_open_session_or_close_multiple N/A N/A domain contact_id N/A N/A N/A 
    Retrieves the current open SQLXFormsSession for the given contact.
    If multiple sessions are open, it closes all of them and returns
    None for the session.

    The return value is a tuple of (multiple, session), where multiple
    is True if there were multiple sessions, and session is the session if
    there was a single open session available.
     N/A sessions N/A N/A SQLXFormsSession get_all_open_sms_sessions domain contact_id N/A count N/A N/A sessions count N/A N/A count 1 N/A N/A session sessions N/A N/A N/A N/A session end False N/A N/A N/A session save N/A N/A True None N/A session N/A N/A count 1 N/A sessions N/A 0 None N/A N/A False session N/A answer_next_question N/A N/A v text msg session N/A N/A N/A resp N/A current_question N/A session session_id N/A event N/A resp event N/A N/A valid text error_msg N/A validate_answer event text v N/A outbound_metadata N/A MessageMetadata workflow N/A session workflow reminder_id N/A session reminder_id xforms_session_couch_id N/A session _id N/A valid N/A N/A responses N/A _get_responses N/A v domain N/A v owner_id text yield_responses True N/A N/A has_invalid_response responses N/A N/A N/A mark_as_invalid_response msg N/A text_responses N/A _responses_to_text responses N/A N/A N/A len text_responses 0 N/A N/A response_text N/A format_message_list text_responses N/A N/A send_sms_to_verified_number v response_text metadata outbound_metadata N/A N/A N/A mark_as_invalid_response msg N/A response_text N/A %s %s N/A error_msg N/A event text_prompt N/A N/A send_sms_to_verified_number v response_text metadata outbound_metadata N/A validate_answer N/A N/A event text v N/A N/A N/A text N/A N/A text strip N/A upper_text N/A N/A text upper N/A valid False N/A error_msg N/A N/A N/A text N/A N/A N/A event _dict get required False N/A N/A N/A False text N/A get_message MSG_FIELD_REQUIRED v N/A N/A N/A event datatype select N/A N/A choices N/A format_choices N/A N/A event _dict N/A choices N/A N/A upper_text choices N/A N/A text N/A str N/A choices N/A upper_text N/A valid True N/A N/A N/A N/A answer N/A int text N/A N/A N/A answer 1 N/A answer N/A len N/A N/A event _dict N/A choices N/A N/A valid True N/A N/A error_msg N/A get_message MSG_CHOICE_OUT_OF_RANGE v N/A N/A N/A ValueError N/A N/A error_msg N/A get_message MSG_INVALID_CHOICE v N/A N/A N/A N/A event datatype multiselect N/A N/A choices N/A format_choices N/A N/A event _dict N/A choices N/A max_index N/A len N/A N/A event _dict N/A choices N/A proposed_answers N/A N/A text split N/A final_answers N/A N/A N/A N/A answer proposed_answers N/A N/A upper_answer N/A N/A answer upper N/A N/A upper_answer choices N/A N/A N/A final_answers N/A N/A str N/A choices N/A upper_answer N/A N/A int_answer N/A int answer N/A N/A N/A int_answer 1 N/A int_answer max_index N/A N/A final_answers N/A N/A str int_answer N/A text N/A N/A join N/A N/A final_answers keys N/A valid True N/A N/A N/A Exception N/A N/A error_msg N/A get_message MSG_INVALID_CHOICE v N/A N/A N/A N/A event datatype int N/A N/A N/A N/A N/A int text N/A valid True N/A N/A N/A ValueError N/A N/A error_msg N/A get_message MSG_INVALID_INT v N/A N/A N/A N/A event datatype float N/A N/A N/A N/A N/A float text N/A valid True N/A N/A N/A ValueError N/A N/A error_msg N/A get_message MSG_INVALID_FLOAT v N/A N/A N/A N/A event datatype longint N/A N/A N/A N/A N/A long text N/A valid True N/A N/A N/A ValueError N/A N/A error_msg N/A get_message MSG_INVALID_LONG v N/A N/A N/A N/A event datatype date N/A N/A N/A N/A N/A N/A len text 8 N/A N/A int text N/A text N/A %s-%s-%s N/A N/A text N/A 0 4 N/A text N/A 4 6 N/A text N/A 6 N/A N/A parse text N/A valid True N/A N/A N/A Exception N/A N/A error_msg N/A get_message MSG_INVALID_DATE v N/A N/A N/A N/A event datatype time N/A N/A N/A N/A N/A N/A len text 4 N/A hour N/A int N/A text N/A 0 2 N/A minute N/A int N/A text N/A 2 N/A N/A N/A hour 0 N/A hour 23 N/A N/A N/A minute 0 N/A minute 59 N/A text N/A %s:%s N/A hour N/A N/A N/A str minute zfill 2 N/A valid True N/A N/A N/A Exception N/A N/A error_msg N/A get_message MSG_INVALID_TIME v N/A N/A valid True N/A N/A valid text error_msg N/A format_choices N/A N/A choices_list N/A N/A N/A choices N/A N/A N/A idx choice N/A enumerate choices_list N/A N/A N/A choices N/A N/A N/A N/A N/A choice strip upper N/A idx 1 N/A choices N/A has_invalid_response N/A N/A responses N/A N/A N/A r responses N/A N/A N/A N/A r status validation-error N/A N/A True N/A False N/A mark_as_invalid_response N/A N/A msg N/A N/A N/A N/A msg invalid_survey_response True N/A N/A N/A msg save N/A