sequence
stringlengths
1.37k
35.1k
docstring
stringlengths
17
102
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'sam2fastq'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'singles'}; {'id': '7', 'type': 'False', 'children': []}; {'id': '8', 'type': 'default_parameter', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'force'}; {'id': '10', 'type': 'False', 'children': []}; {'id': '11', 'type': 'block', 'children': ['12', '20']}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '17']}; {'id': '14', 'type': 'pattern_list', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '17', 'type': 'expression_list', 'children': ['18', '19']}; {'id': '18', 'type': 'None', 'children': []}; {'id': '19', 'type': 'None', 'children': []}; {'id': '20', 'type': 'for_statement', 'children': ['21', '22', '23']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '23', 'type': 'block', 'children': ['24', '35', '47', '82', '97', '109', '126', '170', '258']}; {'id': '24', 'type': 'if_statement', 'children': ['25', '33']}; {'id': '25', 'type': 'comparison_operator', 'children': ['26', '32'], 'value': 'is'}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'string', 'children': [], 'value': "'@'"}; {'id': '32', 'type': 'True', 'children': []}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'continue_statement', 'children': []}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '38', 'type': 'call', 'children': ['39', '46']}; {'id': '39', 'type': 'attribute', 'children': ['40', '45']}; {'id': '40', 'type': 'call', 'children': ['41', '44']}; {'id': '41', 'type': 'attribute', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '44', 'type': 'argument_list', 'children': []}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '46', 'type': 'argument_list', 'children': []}; {'id': '47', 'type': 'expression_statement', 'children': ['48']}; {'id': '48', 'type': 'assignment', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '50', 'type': 'list_comprehension', 'children': ['51', '57', '58']}; {'id': '51', 'type': 'conditional_expression', 'children': ['52', '53', '56'], 'value': 'if'}; {'id': '52', 'type': 'True', 'children': []}; {'id': '53', 'type': 'comparison_operator', 'children': ['54', '55'], 'value': '=='}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '55', 'type': 'string', 'children': [], 'value': "'1'"}; {'id': '56', 'type': 'False', 'children': []}; {'id': '57', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '58', 'type': 'for_in_clause', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '60', 'type': 'subscript', 'children': ['61', '77']}; {'id': '61', 'type': 'subscript', 'children': ['62', '76']}; {'id': '62', 'type': 'call', 'children': ['63', '74']}; {'id': '63', 'type': 'attribute', 'children': ['64', '73']}; {'id': '64', 'type': 'call', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'bin'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'call', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '69', 'type': 'argument_list', 'children': ['70']}; {'id': '70', 'type': 'subscript', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '72', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '74', 'type': 'argument_list', 'children': ['75']}; {'id': '75', 'type': 'string', 'children': [], 'value': "'b'"}; {'id': '76', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '77', 'type': 'slice', 'children': ['78', '79', '80']}; {'id': '78', 'type': 'colon', 'children': []}; {'id': '79', 'type': 'colon', 'children': []}; {'id': '80', 'type': 'unary_operator', 'children': ['81'], 'value': '-'}; {'id': '81', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '82', 'type': 'while_statement', 'children': ['83', '89']}; {'id': '83', 'type': 'comparison_operator', 'children': ['84', '88'], 'value': '<'}; {'id': '84', 'type': 'call', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '86', 'type': 'argument_list', 'children': ['87']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '88', 'type': 'integer', 'children': [], 'value': '8'}; {'id': '89', 'type': 'block', 'children': ['90']}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'call', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '95', 'type': 'argument_list', 'children': ['96']}; {'id': '96', 'type': 'False', 'children': []}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '108']}; {'id': '99', 'type': 'pattern_list', 'children': ['100', '101', '102', '103', '104', '105', '106', '107']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'proper'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'na'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'nap'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'rev'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'mrev'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'left'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'right'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '109', 'type': 'if_statement', 'children': ['110', '113']}; {'id': '110', 'type': 'comparison_operator', 'children': ['111', '112'], 'value': 'is'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '112', 'type': 'False', 'children': []}; {'id': '113', 'type': 'block', 'children': ['114', '125']}; {'id': '114', 'type': 'if_statement', 'children': ['115', '118']}; {'id': '115', 'type': 'comparison_operator', 'children': ['116', '117'], 'value': 'is'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'singles'}; {'id': '117', 'type': 'True', 'children': []}; {'id': '118', 'type': 'block', 'children': ['119']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'print_single'}; {'id': '122', 'type': 'argument_list', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'rev'}; {'id': '125', 'type': 'continue_statement', 'children': []}; {'id': '126', 'type': 'if_statement', 'children': ['127', '130', '156']}; {'id': '127', 'type': 'comparison_operator', 'children': ['128', '129'], 'value': 'is'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'rev'}; {'id': '129', 'type': 'True', 'children': []}; {'id': '130', 'type': 'block', 'children': ['131', '144']}; {'id': '131', 'type': 'expression_statement', 'children': ['132']}; {'id': '132', 'type': 'assignment', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '134', 'type': 'subscript', 'children': ['135', '143']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'rc'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'list', 'children': ['139', '140'], 'value': "['', line[9]]"}; {'id': '139', 'type': 'string', 'children': [], 'value': "''"}; {'id': '140', 'type': 'subscript', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '142', 'type': 'integer', 'children': [], 'value': '9'}; {'id': '143', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'qual'}; {'id': '147', 'type': 'subscript', 'children': ['148', '151']}; {'id': '148', 'type': 'subscript', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '150', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '151', 'type': 'slice', 'children': ['152', '153', '154']}; {'id': '152', 'type': 'colon', 'children': []}; {'id': '153', 'type': 'colon', 'children': []}; {'id': '154', 'type': 'unary_operator', 'children': ['155'], 'value': '-'}; {'id': '155', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '156', 'type': 'else_clause', 'children': ['157']}; {'id': '157', 'type': 'block', 'children': ['158', '164']}; {'id': '158', 'type': 'expression_statement', 'children': ['159']}; {'id': '159', 'type': 'assignment', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '161', 'type': 'subscript', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '163', 'type': 'integer', 'children': [], 'value': '9'}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'qual'}; {'id': '167', 'type': 'subscript', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '169', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '170', 'type': 'if_statement', 'children': ['171', '174']}; {'id': '171', 'type': 'comparison_operator', 'children': ['172', '173'], 'value': 'is'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'left'}; {'id': '173', 'type': 'True', 'children': []}; {'id': '174', 'type': 'block', 'children': ['175', '213', '223', '239']}; {'id': '175', 'type': 'if_statement', 'children': ['176', '183']}; {'id': '176', 'type': 'boolean_operator', 'children': ['177', '180'], 'value': 'and'}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '179'], 'value': 'is'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '179', 'type': 'None', 'children': []}; {'id': '180', 'type': 'comparison_operator', 'children': ['181', '182'], 'value': 'is'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'force'}; {'id': '182', 'type': 'False', 'children': []}; {'id': '183', 'type': 'block', 'children': ['184', '194', '209']}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '187', 'type': 'argument_list', 'children': ['188', '189']}; {'id': '188', 'type': 'string', 'children': [], 'value': "'sam file is not sorted'"}; {'id': '189', 'type': 'keyword_argument', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'call', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '197', 'type': 'argument_list', 'children': ['198', '204']}; {'id': '198', 'type': 'binary_operator', 'children': ['199', '200'], 'value': '%'}; {'id': '199', 'type': 'string', 'children': [], 'value': "'\\te.g.: %s'"}; {'id': '200', 'type': '()', 'children': ['201']}; {'id': '201', 'type': 'subscript', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '203', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '204', 'type': 'keyword_argument', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '206', 'type': 'attribute', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '209', 'type': 'expression_statement', 'children': ['210']}; {'id': '210', 'type': 'call', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '212', 'type': 'argument_list', 'children': []}; {'id': '213', 'type': 'if_statement', 'children': ['214', '217']}; {'id': '214', 'type': 'comparison_operator', 'children': ['215', '216'], 'value': 'is'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '216', 'type': 'None', 'children': []}; {'id': '217', 'type': 'block', 'children': ['218', '222']}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'assignment', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '221', 'type': 'None', 'children': []}; {'id': '222', 'type': 'continue_statement', 'children': []}; {'id': '223', 'type': 'expression_statement', 'children': ['224']}; {'id': '224', 'type': 'assignment', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '226', 'type': 'list', 'children': ['227', '232', '233', '238'], 'value': "['@%s' % line[0], seq, '+%s' % line[0], qual]"}; {'id': '227', 'type': 'binary_operator', 'children': ['228', '229'], 'value': '%'}; {'id': '228', 'type': 'string', 'children': [], 'value': "'@%s'"}; {'id': '229', 'type': 'subscript', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '231', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '233', 'type': 'binary_operator', 'children': ['234', '235'], 'value': '%'}; {'id': '234', 'type': 'string', 'children': [], 'value': "'+%s'"}; {'id': '235', 'type': 'subscript', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '237', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'qual'}; {'id': '239', 'type': 'if_statement', 'children': ['240', '243']}; {'id': '240', 'type': 'comparison_operator', 'children': ['241', '242'], 'value': 'is'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '242', 'type': 'None', 'children': []}; {'id': '243', 'type': 'block', 'children': ['244', '247', '250']}; {'id': '244', 'type': 'expression_statement', 'children': ['245']}; {'id': '245', 'type': 'yield', 'children': ['246']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'yield', 'children': ['249']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '250', 'type': 'expression_statement', 'children': ['251']}; {'id': '251', 'type': 'assignment', 'children': ['252', '255']}; {'id': '252', 'type': 'pattern_list', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '255', 'type': 'expression_list', 'children': ['256', '257']}; {'id': '256', 'type': 'None', 'children': []}; {'id': '257', 'type': 'None', 'children': []}; {'id': '258', 'type': 'if_statement', 'children': ['259', '262']}; {'id': '259', 'type': 'comparison_operator', 'children': ['260', '261'], 'value': 'is'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'right'}; {'id': '261', 'type': 'True', 'children': []}; {'id': '262', 'type': 'block', 'children': ['263', '301', '311', '327']}; {'id': '263', 'type': 'if_statement', 'children': ['264', '271']}; {'id': '264', 'type': 'boolean_operator', 'children': ['265', '268'], 'value': 'and'}; {'id': '265', 'type': 'comparison_operator', 'children': ['266', '267'], 'value': 'is'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '267', 'type': 'None', 'children': []}; {'id': '268', 'type': 'comparison_operator', 'children': ['269', '270'], 'value': 'is'}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'force'}; {'id': '270', 'type': 'False', 'children': []}; {'id': '271', 'type': 'block', 'children': ['272', '282', '297']}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'call', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '275', 'type': 'argument_list', 'children': ['276', '277']}; {'id': '276', 'type': 'string', 'children': [], 'value': "'sam file is not sorted'"}; {'id': '277', 'type': 'keyword_argument', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '279', 'type': 'attribute', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '282', 'type': 'expression_statement', 'children': ['283']}; {'id': '283', 'type': 'call', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '285', 'type': 'argument_list', 'children': ['286', '292']}; {'id': '286', 'type': 'binary_operator', 'children': ['287', '288'], 'value': '%'}; {'id': '287', 'type': 'string', 'children': [], 'value': "'\\te.g.: %s'"}; {'id': '288', 'type': '()', 'children': ['289']}; {'id': '289', 'type': 'subscript', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '291', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '292', 'type': 'keyword_argument', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '297', 'type': 'expression_statement', 'children': ['298']}; {'id': '298', 'type': 'call', 'children': ['299', '300']}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '300', 'type': 'argument_list', 'children': []}; {'id': '301', 'type': 'if_statement', 'children': ['302', '305']}; {'id': '302', 'type': 'comparison_operator', 'children': ['303', '304'], 'value': 'is'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '304', 'type': 'None', 'children': []}; {'id': '305', 'type': 'block', 'children': ['306', '310']}; {'id': '306', 'type': 'expression_statement', 'children': ['307']}; {'id': '307', 'type': 'assignment', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '309', 'type': 'None', 'children': []}; {'id': '310', 'type': 'continue_statement', 'children': []}; {'id': '311', 'type': 'expression_statement', 'children': ['312']}; {'id': '312', 'type': 'assignment', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '314', 'type': 'list', 'children': ['315', '320', '321', '326'], 'value': "['@%s' % line[0], seq, '+%s' % line[0], qual]"}; {'id': '315', 'type': 'binary_operator', 'children': ['316', '317'], 'value': '%'}; {'id': '316', 'type': 'string', 'children': [], 'value': "'@%s'"}; {'id': '317', 'type': 'subscript', 'children': ['318', '319']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '319', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '321', 'type': 'binary_operator', 'children': ['322', '323'], 'value': '%'}; {'id': '322', 'type': 'string', 'children': [], 'value': "'+%s'"}; {'id': '323', 'type': 'subscript', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '325', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'qual'}; {'id': '327', 'type': 'if_statement', 'children': ['328', '331']}; {'id': '328', 'type': 'comparison_operator', 'children': ['329', '330'], 'value': 'is'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '330', 'type': 'None', 'children': []}; {'id': '331', 'type': 'block', 'children': ['332', '335', '338']}; {'id': '332', 'type': 'expression_statement', 'children': ['333']}; {'id': '333', 'type': 'yield', 'children': ['334']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '335', 'type': 'expression_statement', 'children': ['336']}; {'id': '336', 'type': 'yield', 'children': ['337']}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '338', 'type': 'expression_statement', 'children': ['339']}; {'id': '339', 'type': 'assignment', 'children': ['340', '343']}; {'id': '340', 'type': 'pattern_list', 'children': ['341', '342']}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'L'}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '343', 'type': 'expression_list', 'children': ['344', '345']}; {'id': '344', 'type': 'None', 'children': []}; {'id': '345', 'type': 'None', 'children': []}
convert sam to fastq
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '12']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'crossmap'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8', '9', '10', '11']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'fas'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'reads'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'no_shrink'}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'keepDB'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'cluster'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'nodes'}; {'id': '12', 'type': 'block', 'children': ['13', '22', '26', '213']}; {'id': '13', 'type': 'if_statement', 'children': ['14', '17']}; {'id': '14', 'type': 'comparison_operator', 'children': ['15', '16'], 'value': 'is'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'cluster'}; {'id': '16', 'type': 'True', 'children': []}; {'id': '17', 'type': 'block', 'children': ['18']}; {'id': '18', 'type': 'expression_statement', 'children': ['19']}; {'id': '19', 'type': 'assignment', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '21', 'type': 'string', 'children': [], 'value': "'48'"}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'btc'}; {'id': '25', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '26', 'type': 'for_statement', 'children': ['27', '28', '29']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'fa'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'fas'}; {'id': '29', 'type': 'block', 'children': ['30', '38', '45']}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'btd'}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'bowtiedb'}; {'id': '35', 'type': 'argument_list', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'fa'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'keepDB'}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '44']}; {'id': '40', 'type': 'pattern_list', 'children': ['41', '42', '43']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'F'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'reads'}; {'id': '45', 'type': 'if_statement', 'children': ['46', '49', '142']}; {'id': '46', 'type': 'comparison_operator', 'children': ['47', '48'], 'value': 'is'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'F'}; {'id': '48', 'type': 'False', 'children': []}; {'id': '49', 'type': 'block', 'children': ['50', '59']}; {'id': '50', 'type': 'if_statement', 'children': ['51', '54']}; {'id': '51', 'type': 'comparison_operator', 'children': ['52', '53'], 'value': 'is'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '53', 'type': 'False', 'children': []}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '58', 'type': 'False', 'children': []}; {'id': '59', 'type': 'for_statement', 'children': ['60', '63', '67']}; {'id': '60', 'type': 'pattern_list', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '63', 'type': 'call', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'F'}; {'id': '67', 'type': 'block', 'children': ['68', '74', '85', '125']}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '71', 'type': 'subscript', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'R'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '74', 'type': 'if_statement', 'children': ['75', '78']}; {'id': '75', 'type': 'comparison_operator', 'children': ['76', '77'], 'value': 'is'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '77', 'type': 'False', 'children': []}; {'id': '78', 'type': 'block', 'children': ['79']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '82', 'type': 'subscript', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'assignment', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '88', 'type': 'binary_operator', 'children': ['89', '90'], 'value': '%'}; {'id': '89', 'type': 'string', 'children': [], 'value': "'%s/%s-vs-%s'"}; {'id': '90', 'type': 'tuple', 'children': ['91', '96', '97', '107']}; {'id': '91', 'type': 'call', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'getcwd'}; {'id': '95', 'type': 'argument_list', 'children': []}; {'id': '96', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '97', 'type': 'subscript', 'children': ['98', '105']}; {'id': '98', 'type': 'call', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'fa'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '102', 'type': 'argument_list', 'children': ['103', '104']}; {'id': '103', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '104', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '105', 'type': 'unary_operator', 'children': ['106'], 'value': '-'}; {'id': '106', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '107', 'type': 'subscript', 'children': ['108', '124']}; {'id': '108', 'type': 'call', 'children': ['109', '121']}; {'id': '109', 'type': 'attribute', 'children': ['110', '120']}; {'id': '110', 'type': 'subscript', 'children': ['111', '118']}; {'id': '111', 'type': 'call', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '115', 'type': 'argument_list', 'children': ['116', '117']}; {'id': '116', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '117', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '118', 'type': 'unary_operator', 'children': ['119'], 'value': '-'}; {'id': '119', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '121', 'type': 'argument_list', 'children': ['122', '123']}; {'id': '122', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '123', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '124', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'call', 'children': ['127', '130']}; {'id': '127', 'type': 'attribute', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'btc'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '130', 'type': 'argument_list', 'children': ['131']}; {'id': '131', 'type': 'call', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'bowtie'}; {'id': '133', 'type': 'argument_list', 'children': ['134', '135', '136', '137', '138', '139', '140', '141']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'btd'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'no_shrink'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '142', 'type': 'else_clause', 'children': ['143']}; {'id': '143', 'type': 'block', 'children': ['144', '148', '152']}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '147', 'type': 'False', 'children': []}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '151', 'type': 'False', 'children': []}; {'id': '152', 'type': 'for_statement', 'children': ['153', '154', '155']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '155', 'type': 'block', 'children': ['156', '196']}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'assignment', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '159', 'type': 'binary_operator', 'children': ['160', '161'], 'value': '%'}; {'id': '160', 'type': 'string', 'children': [], 'value': "'%s/%s-vs-%s'"}; {'id': '161', 'type': 'tuple', 'children': ['162', '167', '168', '178']}; {'id': '162', 'type': 'call', 'children': ['163', '166']}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'getcwd'}; {'id': '166', 'type': 'argument_list', 'children': []}; {'id': '167', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '168', 'type': 'subscript', 'children': ['169', '176']}; {'id': '169', 'type': 'call', 'children': ['170', '173']}; {'id': '170', 'type': 'attribute', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'fa'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '173', 'type': 'argument_list', 'children': ['174', '175']}; {'id': '174', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '175', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '176', 'type': 'unary_operator', 'children': ['177'], 'value': '-'}; {'id': '177', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '178', 'type': 'subscript', 'children': ['179', '195']}; {'id': '179', 'type': 'call', 'children': ['180', '192']}; {'id': '180', 'type': 'attribute', 'children': ['181', '191']}; {'id': '181', 'type': 'subscript', 'children': ['182', '189']}; {'id': '182', 'type': 'call', 'children': ['183', '186']}; {'id': '183', 'type': 'attribute', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '186', 'type': 'argument_list', 'children': ['187', '188']}; {'id': '187', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '188', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '189', 'type': 'unary_operator', 'children': ['190'], 'value': '-'}; {'id': '190', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '192', 'type': 'argument_list', 'children': ['193', '194']}; {'id': '193', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '194', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '195', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'call', 'children': ['198', '201']}; {'id': '198', 'type': 'attribute', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'btc'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '201', 'type': 'argument_list', 'children': ['202']}; {'id': '202', 'type': 'call', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'bowtie'}; {'id': '204', 'type': 'argument_list', 'children': ['205', '206', '207', '208', '209', '210', '211', '212']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'sam'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'btd'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'no_shrink'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '213', 'type': 'if_statement', 'children': ['214', '217', '240']}; {'id': '214', 'type': 'comparison_operator', 'children': ['215', '216'], 'value': 'is'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'cluster'}; {'id': '216', 'type': 'False', 'children': []}; {'id': '217', 'type': 'block', 'children': ['218']}; {'id': '218', 'type': 'for_statement', 'children': ['219', '220', '221']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'btc'}; {'id': '221', 'type': 'block', 'children': ['222', '234']}; {'id': '222', 'type': 'expression_statement', 'children': ['223']}; {'id': '223', 'type': 'assignment', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '225', 'type': 'call', 'children': ['226', '229']}; {'id': '226', 'type': 'attribute', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'subprocess'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'Popen'}; {'id': '229', 'type': 'argument_list', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '231', 'type': 'keyword_argument', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'shell'}; {'id': '233', 'type': 'True', 'children': []}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'call', 'children': ['236', '239']}; {'id': '236', 'type': 'attribute', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'communicate'}; {'id': '239', 'type': 'argument_list', 'children': []}; {'id': '240', 'type': 'else_clause', 'children': ['241']}; {'id': '241', 'type': 'block', 'children': ['242', '273']}; {'id': '242', 'type': 'expression_statement', 'children': ['243']}; {'id': '243', 'type': 'assignment', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '245', 'type': 'call', 'children': ['246', '249']}; {'id': '246', 'type': 'attribute', 'children': ['247', '248']}; {'id': '247', 'type': 'string', 'children': [], 'value': "''"}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '249', 'type': 'generator_expression', 'children': ['250', '267']}; {'id': '250', 'type': 'call', 'children': ['251', '254']}; {'id': '251', 'type': 'attribute', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'random'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'choice'}; {'id': '254', 'type': 'argument_list', 'children': ['255']}; {'id': '255', 'type': 'list_comprehension', 'children': ['256', '260']}; {'id': '256', 'type': 'call', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '258', 'type': 'argument_list', 'children': ['259']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '260', 'type': 'for_in_clause', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '262', 'type': 'call', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '264', 'type': 'argument_list', 'children': ['265', '266']}; {'id': '265', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '266', 'type': 'integer', 'children': [], 'value': '9'}; {'id': '267', 'type': 'for_in_clause', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': '_'}; {'id': '269', 'type': 'call', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '271', 'type': 'argument_list', 'children': ['272']}; {'id': '272', 'type': 'integer', 'children': [], 'value': '5'}; {'id': '273', 'type': 'for_statement', 'children': ['274', '277', '286']}; {'id': '274', 'type': 'pattern_list', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '277', 'type': 'call', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '279', 'type': 'argument_list', 'children': ['280', '285']}; {'id': '280', 'type': 'call', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'chunks'}; {'id': '282', 'type': 'argument_list', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'btc'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'nodes'}; {'id': '285', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '286', 'type': 'block', 'children': ['287', '304', '317', '323', '342']}; {'id': '287', 'type': 'expression_statement', 'children': ['288']}; {'id': '288', 'type': 'assignment', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'bs'}; {'id': '290', 'type': 'call', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '292', 'type': 'argument_list', 'children': ['293', '303']}; {'id': '293', 'type': 'binary_operator', 'children': ['294', '295'], 'value': '%'}; {'id': '294', 'type': 'string', 'children': [], 'value': "'%s/crossmap-qsub.%s.%s.sh'"}; {'id': '295', 'type': 'tuple', 'children': ['296', '301', '302']}; {'id': '296', 'type': 'call', 'children': ['297', '300']}; {'id': '297', 'type': 'attribute', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'getcwd'}; {'id': '300', 'type': 'argument_list', 'children': []}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '303', 'type': 'string', 'children': [], 'value': "'w'"}; {'id': '304', 'type': 'expression_statement', 'children': ['305']}; {'id': '305', 'type': 'call', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '307', 'type': 'argument_list', 'children': ['308', '314']}; {'id': '308', 'type': 'call', 'children': ['309', '312']}; {'id': '309', 'type': 'attribute', 'children': ['310', '311']}; {'id': '310', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '312', 'type': 'argument_list', 'children': ['313']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '314', 'type': 'keyword_argument', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'bs'}; {'id': '317', 'type': 'expression_statement', 'children': ['318']}; {'id': '318', 'type': 'call', 'children': ['319', '322']}; {'id': '319', 'type': 'attribute', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'bs'}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '322', 'type': 'argument_list', 'children': []}; {'id': '323', 'type': 'expression_statement', 'children': ['324']}; {'id': '324', 'type': 'assignment', 'children': ['325', '326']}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '326', 'type': 'call', 'children': ['327', '330']}; {'id': '327', 'type': 'attribute', 'children': ['328', '329']}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'subprocess'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'Popen'}; {'id': '330', 'type': 'argument_list', 'children': ['331', '338', '339']}; {'id': '331', 'type': 'binary_operator', 'children': ['332', '333', '334'], 'value': '%'}; {'id': '332', 'type': 'string', 'children': [], 'value': "'qsub -V -N crossmap %s'"}; {'id': '333', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '334', 'type': '()', 'children': ['335']}; {'id': '335', 'type': 'attribute', 'children': ['336', '337']}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'bs'}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '338', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '339', 'type': 'keyword_argument', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'shell'}; {'id': '341', 'type': 'True', 'children': []}; {'id': '342', 'type': 'expression_statement', 'children': ['343']}; {'id': '343', 'type': 'call', 'children': ['344', '347']}; {'id': '344', 'type': 'attribute', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'communicate'}; {'id': '347', 'type': 'argument_list', 'children': []}
map all read sets against all fasta files
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'parse_ggKbase_tables'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'tables'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'id_type'}; {'id': '6', 'type': 'block', 'children': ['7', '11', '232']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '10', 'type': 'dictionary', 'children': []}; {'id': '11', 'type': 'for_statement', 'children': ['12', '13', '14']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'tables'}; {'id': '14', 'type': 'block', 'children': ['15']}; {'id': '15', 'type': 'for_statement', 'children': ['16', '17', '21']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '17', 'type': 'call', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '19', 'type': 'argument_list', 'children': ['20']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '21', 'type': 'block', 'children': ['22', '35', '62', '76', '87']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '25', 'type': 'call', 'children': ['26', '33']}; {'id': '26', 'type': 'attribute', 'children': ['27', '32']}; {'id': '27', 'type': 'call', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '31', 'type': 'argument_list', 'children': []}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '35', 'type': 'if_statement', 'children': ['36', '44']}; {'id': '36', 'type': 'call', 'children': ['37', '42']}; {'id': '37', 'type': 'attribute', 'children': ['38', '41']}; {'id': '38', 'type': 'subscript', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '40', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '42', 'type': 'argument_list', 'children': ['43']}; {'id': '43', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '44', 'type': 'block', 'children': ['45', '49', '55', '61']}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'assignment', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '49', 'type': 'expression_statement', 'children': ['50']}; {'id': '50', 'type': 'assignment', 'children': ['51', '54']}; {'id': '51', 'type': 'subscript', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '53', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '54', 'type': 'string', 'children': [], 'value': "'genome size (bp)'"}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '60']}; {'id': '57', 'type': 'subscript', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '59', 'type': 'integer', 'children': [], 'value': '12'}; {'id': '60', 'type': 'string', 'children': [], 'value': "'\n header[13] = '"}; {'id': '61', 'type': 'continue_statement', 'children': []}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '68']}; {'id': '64', 'type': 'pattern_list', 'children': ['65', '66', '67']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '68', 'type': 'expression_list', 'children': ['69', '72', '75']}; {'id': '69', 'type': 'subscript', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '71', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '72', 'type': 'subscript', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '74', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '79', 'type': 'list_comprehension', 'children': ['80', '84']}; {'id': '80', 'type': 'call', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'to_int'}; {'id': '82', 'type': 'argument_list', 'children': ['83']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '84', 'type': 'for_in_clause', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '87', 'type': 'if_statement', 'children': ['88', '91', '167']}; {'id': '88', 'type': 'comparison_operator', 'children': ['89', '90'], 'value': 'is'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'id_type'}; {'id': '90', 'type': 'False', 'children': []}; {'id': '91', 'type': 'block', 'children': ['92', '105', '144']}; {'id': '92', 'type': 'if_statement', 'children': ['93', '100']}; {'id': '93', 'type': 'boolean_operator', 'children': ['94', '97'], 'value': 'or'}; {'id': '94', 'type': 'comparison_operator', 'children': ['95', '96'], 'value': 'in'}; {'id': '95', 'type': 'string', 'children': [], 'value': "'UNK'"}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '97', 'type': 'comparison_operator', 'children': ['98', '99'], 'value': 'in'}; {'id': '98', 'type': 'string', 'children': [], 'value': "'unknown'"}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '100', 'type': 'block', 'children': ['101']}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'assignment', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '105', 'type': 'if_statement', 'children': ['106', '117', '143']}; {'id': '106', 'type': 'boolean_operator', 'children': ['107', '111'], 'value': 'and'}; {'id': '107', 'type': '()', 'children': ['108']}; {'id': '108', 'type': 'comparison_operator', 'children': ['109', '110'], 'value': '!='}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '111', 'type': '()', 'children': ['112']}; {'id': '112', 'type': 'boolean_operator', 'children': ['113', '114'], 'value': 'and'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '114', 'type': 'comparison_operator', 'children': ['115', '116'], 'value': 'in'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '117', 'type': 'ERROR', 'children': ['118', '123', '130']}; {'id': '118', 'type': 'call', 'children': ['119', '120', '122']}; {'id': '119', 'type': 'string', 'children': [], 'value': "'\n print('"}; {'id': '120', 'type': 'ERROR', 'children': ['121']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '122', 'type': 'argument_list', 'children': []}; {'id': '123', 'type': 'ERROR', 'children': ['124', '127']}; {'id': '124', 'type': 'comparison_operator', 'children': ['125', '126'], 'value': 'not'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '127', 'type': 'subscript', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '130', 'type': 'dictionary_comprehension', 'children': ['131', '134']}; {'id': '131', 'type': 'pair', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '134', 'type': 'for_in_clause', 'children': ['135', '138']}; {'id': '135', 'type': 'pattern_list', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '138', 'type': 'call', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '140', 'type': 'argument_list', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '143', 'type': 'block', 'children': [], 'value': ''}; {'id': '144', 'type': 'if_statement', 'children': ['145', '148']}; {'id': '145', 'type': 'comparison_operator', 'children': ['146', '147'], 'value': 'not'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '148', 'type': 'block', 'children': ['149']}; {'id': '149', 'type': 'expression_statement', 'children': ['150']}; {'id': '150', 'type': 'assignment', 'children': ['151', '154']}; {'id': '151', 'type': 'subscript', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '154', 'type': 'dictionary_comprehension', 'children': ['155', '158']}; {'id': '155', 'type': 'pair', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '158', 'type': 'for_in_clause', 'children': ['159', '162']}; {'id': '159', 'type': 'pattern_list', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '162', 'type': 'call', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '164', 'type': 'argument_list', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '167', 'type': 'else_clause', 'children': ['168']}; {'id': '168', 'type': 'block', 'children': ['169']}; {'id': '169', 'type': 'if_statement', 'children': ['170', '173', '178', '187']}; {'id': '170', 'type': 'comparison_operator', 'children': ['171', '172'], 'value': '=='}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'id_type'}; {'id': '172', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '173', 'type': 'block', 'children': ['174']}; {'id': '174', 'type': 'expression_statement', 'children': ['175']}; {'id': '175', 'type': 'assignment', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '178', 'type': 'elif_clause', 'children': ['179', '182']}; {'id': '179', 'type': 'comparison_operator', 'children': ['180', '181'], 'value': '=='}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'id_type'}; {'id': '181', 'type': 'string', 'children': [], 'value': "'code'"}; {'id': '182', 'type': 'block', 'children': ['183']}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'assignment', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '187', 'type': 'else_clause', 'children': ['188', '231']}; {'id': '188', 'type': 'ERROR', 'children': ['189', '204', '217', '230']}; {'id': '189', 'type': 'ERROR', 'children': ['190', '193', '194', '201']}; {'id': '190', 'type': 'call', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '192', 'type': 'argument_list', 'children': []}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '194', 'type': 'call', 'children': ['195', '198']}; {'id': '195', 'type': 'attribute', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '198', 'type': 'argument_list', 'children': ['199', '200']}; {'id': '199', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '200', 'type': 'string', 'children': [], 'value': "''"}; {'id': '201', 'type': 'subscript', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '204', 'type': 'dictionary_comprehension', 'children': ['205', '208']}; {'id': '205', 'type': 'pair', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '208', 'type': 'for_in_clause', 'children': ['209', '212']}; {'id': '209', 'type': 'pattern_list', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'stat'}; {'id': '212', 'type': 'call', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '214', 'type': 'argument_list', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '217', 'type': 'ERROR', 'children': ['218', '225']}; {'id': '218', 'type': 'comparison_operator', 'children': ['219', '224'], 'value': '=='}; {'id': '219', 'type': 'subscript', 'children': ['220', '223']}; {'id': '220', 'type': 'subscript', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '223', 'type': 'string', 'children': [], 'value': "'genome size (bp)'"}; {'id': '224', 'type': 'string', 'children': [], 'value': "''"}; {'id': '225', 'type': 'subscript', 'children': ['226', '229']}; {'id': '226', 'type': 'subscript', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'g2info'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '229', 'type': 'string', 'children': [], 'value': "'genome size (bp)'"}; {'id': '230', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '231', 'type': 'block', 'children': [], 'value': ''}; {'id': '232', 'type': 'return_statement', 'children': ['233']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'g2info'}
convert ggKbase genome info tables to dictionary
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'top_hits'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'hits'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'num'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'column'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'reverse'}; {'id': '8', 'type': 'block', 'children': ['9', '24']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'call', 'children': ['11', '14']}; {'id': '11', 'type': 'attribute', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'hits'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'sort'}; {'id': '14', 'type': 'argument_list', 'children': ['15', '21']}; {'id': '15', 'type': 'keyword_argument', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '17', 'type': 'call', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'itemgetter'}; {'id': '19', 'type': 'argument_list', 'children': ['20']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'column'}; {'id': '21', 'type': 'keyword_argument', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'reverse'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'reverse'}; {'id': '24', 'type': 'for_statement', 'children': ['25', '26', '32']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'hit'}; {'id': '26', 'type': 'subscript', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'hits'}; {'id': '28', 'type': 'slice', 'children': ['29', '30', '31']}; {'id': '29', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '30', 'type': 'colon', 'children': []}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'num'}; {'id': '32', 'type': 'block', 'children': ['33']}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'yield', 'children': ['35']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'hit'}
get top hits after sorting by column number
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'numBlast_sort'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'blast'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'numHits'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'evalueT'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'bitT'}; {'id': '8', 'type': 'block', 'children': ['9', '32', '35', '45', '136', '145']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '12', 'type': 'list', 'children': ['13', '30'], 'value': "['\n 'qstart', 'qend', 'tstart', 'tend', 'evalue', 'bitscore']"}; {'id': '13', 'type': 'concatenated_string', 'children': ['14', '15', '17', '18', '20', '21', '23', '24', '26', '27', '29']}; {'id': '14', 'type': 'string', 'children': [], 'value': "'\n '"}; {'id': '15', 'type': 'ERROR', 'children': ['16']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'qstart'}; {'id': '17', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '18', 'type': 'ERROR', 'children': ['19']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'qend'}; {'id': '20', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '21', 'type': 'ERROR', 'children': ['22']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'tstart'}; {'id': '23', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '24', 'type': 'ERROR', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'tend'}; {'id': '26', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '27', 'type': 'ERROR', 'children': ['28']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'evalue'}; {'id': '29', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '30', 'type': 'ERROR', 'children': ['31']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'bitscore'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'yield', 'children': ['34']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'hmm'}; {'id': '38', 'type': 'dictionary_comprehension', 'children': ['39', '42']}; {'id': '39', 'type': 'pair', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '41', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '42', 'type': 'for_in_clause', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '45', 'type': 'for_statement', 'children': ['46', '47', '48']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'blast'}; {'id': '48', 'type': 'block', 'children': ['49', '107', '117']}; {'id': '49', 'type': 'if_statement', 'children': ['50', '53', '105']}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '53', 'type': 'ERROR', 'children': ['54', '56', '72', '76', '82', '88', '90', '95', '98']}; {'id': '54', 'type': 'ERROR', 'children': ['55']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'continue'}; {'id': '56', 'type': 'keyword_argument', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '58', 'type': 'subscript', 'children': ['59', '69', '71']}; {'id': '59', 'type': 'call', 'children': ['60', '67']}; {'id': '60', 'type': 'attribute', 'children': ['61', '66']}; {'id': '61', 'type': 'call', 'children': ['62', '65']}; {'id': '62', 'type': 'attribute', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '65', 'type': 'argument_list', 'children': []}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '67', 'type': 'argument_list', 'children': ['68']}; {'id': '68', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '69', 'type': 'ERROR', 'children': ['70']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '71', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '72', 'type': 'ERROR', 'children': ['73']}; {'id': '73', 'type': 'subscript', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '75', 'type': 'integer', 'children': [], 'value': '11'}; {'id': '76', 'type': 'call', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'subscript', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '81', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '82', 'type': 'call', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'subscript', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '87', 'type': 'integer', 'children': [], 'value': '11'}; {'id': '88', 'type': 'ERROR', 'children': ['89']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'evalue'}; {'id': '90', 'type': 'keyword_argument', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '92', 'type': 'subscript', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '94', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '95', 'type': 'subscript', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '97', 'type': 'integer', 'children': [], 'value': '11'}; {'id': '98', 'type': 'boolean_operator', 'children': ['99', '102'], 'value': 'and'}; {'id': '99', 'type': 'comparison_operator', 'children': ['100', '101'], 'value': 'is'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'evalueT'}; {'id': '101', 'type': 'False', 'children': []}; {'id': '102', 'type': 'comparison_operator', 'children': ['103', '104'], 'value': '>'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'evalue'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'evalueT'}; {'id': '105', 'type': 'block', 'children': ['106']}; {'id': '106', 'type': 'continue_statement', 'children': []}; {'id': '107', 'type': 'if_statement', 'children': ['108', '115']}; {'id': '108', 'type': 'boolean_operator', 'children': ['109', '112'], 'value': 'and'}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '111'], 'value': 'is'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'bitT'}; {'id': '111', 'type': 'False', 'children': []}; {'id': '112', 'type': 'comparison_operator', 'children': ['113', '114'], 'value': '<'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'bitT'}; {'id': '115', 'type': 'block', 'children': ['116']}; {'id': '116', 'type': 'continue_statement', 'children': []}; {'id': '117', 'type': 'for_statement', 'children': ['118', '121', '126']}; {'id': '118', 'type': 'pattern_list', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '121', 'type': 'call', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '123', 'type': 'argument_list', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '126', 'type': 'block', 'children': ['127']}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'call', 'children': ['129', '134']}; {'id': '129', 'type': 'attribute', 'children': ['130', '133']}; {'id': '130', 'type': 'subscript', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'hmm'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '136', 'type': 'expression_statement', 'children': ['137']}; {'id': '137', 'type': 'assignment', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'hmm'}; {'id': '139', 'type': 'call', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'pd'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'DataFrame'}; {'id': '143', 'type': 'argument_list', 'children': ['144']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'hmm'}; {'id': '145', 'type': 'for_statement', 'children': ['146', '149', '177']}; {'id': '146', 'type': 'pattern_list', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '149', 'type': 'comparison_operator', 'children': ['150', '164', '167'], 'value': 'in'}; {'id': '150', 'type': 'call', 'children': ['151', '154']}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'hmm'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'groupby'}; {'id': '154', 'type': 'argument_list', 'children': ['155', '161']}; {'id': '155', 'type': 'keyword_argument', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'by'}; {'id': '157', 'type': 'list', 'children': ['158', '159'], 'value': "['\n df = df.sort_values(by = ['bitscore']"}; {'id': '158', 'type': 'string', 'children': [], 'value': "'\n df = df.sort_values(by = ['"}; {'id': '159', 'type': 'ERROR', 'children': ['160']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'bitscore'}; {'id': '161', 'type': 'keyword_argument', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'ascending'}; {'id': '163', 'type': 'False', 'children': []}; {'id': '164', 'type': 'ERROR', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'hit'}; {'id': '167', 'type': 'subscript', 'children': ['168', '173']}; {'id': '168', 'type': 'attribute', 'children': ['169', '172']}; {'id': '169', 'type': 'subscript', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '173', 'type': 'slice', 'children': ['174', '175', '176']}; {'id': '174', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '175', 'type': 'colon', 'children': []}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'numHits'}; {'id': '177', 'type': 'block', 'children': ['178']}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'yield', 'children': ['180']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'hit'}
parse b6 output with sorting
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'compare_clades'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'pw'}; {'id': '5', 'type': 'block', 'children': ['6', '20']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'names'}; {'id': '9', 'type': 'call', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '11', 'type': 'argument_list', 'children': ['12']}; {'id': '12', 'type': 'call', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '14', 'type': 'argument_list', 'children': ['15']}; {'id': '15', 'type': 'list_comprehension', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '17', 'type': 'for_in_clause', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'pw'}; {'id': '20', 'type': 'for_statement', 'children': ['21', '22', '27']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '22', 'type': 'call', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '24', 'type': 'argument_list', 'children': ['25', '26']}; {'id': '25', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '26', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '27', 'type': 'block', 'children': ['28', '36', '218', '260', '264', '310']}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '33']}; {'id': '30', 'type': 'pattern_list', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'wi'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '33', 'type': 'expression_list', 'children': ['34', '35']}; {'id': '34', 'type': 'dictionary', 'children': []}; {'id': '35', 'type': 'dictionary', 'children': []}; {'id': '36', 'type': 'for_statement', 'children': ['37', '38', '39']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'names'}; {'id': '39', 'type': 'block', 'children': ['40']}; {'id': '40', 'type': 'for_statement', 'children': ['41', '42', '45']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '42', 'type': 'subscript', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'pw'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '45', 'type': 'block', 'children': ['46', '56', '64', '86', '154']}; {'id': '46', 'type': 'if_statement', 'children': ['47', '54']}; {'id': '47', 'type': 'boolean_operator', 'children': ['48', '51'], 'value': 'or'}; {'id': '48', 'type': 'comparison_operator', 'children': ['49', '50'], 'value': 'not'}; {'id': '49', 'type': 'string', 'children': [], 'value': "';'"}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '51', 'type': 'comparison_operator', 'children': ['52', '53'], 'value': 'not'}; {'id': '52', 'type': 'string', 'children': [], 'value': "';'"}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'continue_statement', 'children': []}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'pident'}; {'id': '59', 'type': 'subscript', 'children': ['60', '63']}; {'id': '60', 'type': 'subscript', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'pw'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '64', 'type': 'expression_statement', 'children': ['65']}; {'id': '65', 'type': 'assignment', 'children': ['66', '69']}; {'id': '66', 'type': 'pattern_list', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '69', 'type': 'expression_list', 'children': ['70', '78']}; {'id': '70', 'type': 'subscript', 'children': ['71', '77']}; {'id': '71', 'type': 'call', 'children': ['72', '75']}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'string', 'children': [], 'value': "';'"}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '78', 'type': 'subscript', 'children': ['79', '85']}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '83', 'type': 'argument_list', 'children': ['84']}; {'id': '84', 'type': 'string', 'children': [], 'value': "';'"}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '86', 'type': 'if_statement', 'children': ['87', '98', '123']}; {'id': '87', 'type': 'boolean_operator', 'children': ['88', '95'], 'value': 'and'}; {'id': '88', 'type': 'boolean_operator', 'children': ['89', '92'], 'value': 'and'}; {'id': '89', 'type': 'comparison_operator', 'children': ['90', '91'], 'value': '=='}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '91', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '92', 'type': 'comparison_operator', 'children': ['93', '94'], 'value': 'in'}; {'id': '93', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '95', 'type': 'comparison_operator', 'children': ['96', '97'], 'value': 'in'}; {'id': '96', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '98', 'type': 'block', 'children': ['99', '111']}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'assignment', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '102', 'type': 'subscript', 'children': ['103', '110']}; {'id': '103', 'type': 'call', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109']}; {'id': '108', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '109', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '110', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '114', 'type': 'subscript', 'children': ['115', '122']}; {'id': '115', 'type': 'call', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '119', 'type': 'argument_list', 'children': ['120', '121']}; {'id': '120', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '121', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '122', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '123', 'type': 'elif_clause', 'children': ['124', '131']}; {'id': '124', 'type': 'boolean_operator', 'children': ['125', '128'], 'value': 'or'}; {'id': '125', 'type': 'comparison_operator', 'children': ['126', '127'], 'value': 'in'}; {'id': '126', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '128', 'type': 'comparison_operator', 'children': ['129', '130'], 'value': 'in'}; {'id': '129', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '131', 'type': 'block', 'children': ['132', '143']}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'assignment', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '135', 'type': 'subscript', 'children': ['136', '142']}; {'id': '136', 'type': 'call', 'children': ['137', '140']}; {'id': '137', 'type': 'attribute', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '140', 'type': 'argument_list', 'children': ['141']}; {'id': '141', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '142', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '146', 'type': 'subscript', 'children': ['147', '153']}; {'id': '147', 'type': 'call', 'children': ['148', '151']}; {'id': '148', 'type': 'attribute', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '151', 'type': 'argument_list', 'children': ['152']}; {'id': '152', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '153', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '154', 'type': 'if_statement', 'children': ['155', '158', '179']}; {'id': '155', 'type': 'comparison_operator', 'children': ['156', '157'], 'value': '=='}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '158', 'type': 'block', 'children': ['159', '170']}; {'id': '159', 'type': 'if_statement', 'children': ['160', '163']}; {'id': '160', 'type': 'comparison_operator', 'children': ['161', '162'], 'value': 'not'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'wi'}; {'id': '163', 'type': 'block', 'children': ['164']}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '169']}; {'id': '166', 'type': 'subscript', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'wi'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '169', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '177']}; {'id': '172', 'type': 'attribute', 'children': ['173', '176']}; {'id': '173', 'type': 'subscript', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'wi'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '177', 'type': 'argument_list', 'children': ['178']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'pident'}; {'id': '179', 'type': 'else_clause', 'children': ['180']}; {'id': '180', 'type': 'block', 'children': ['181', '192', '207']}; {'id': '181', 'type': 'if_statement', 'children': ['182', '185']}; {'id': '182', 'type': 'comparison_operator', 'children': ['183', '184'], 'value': 'not'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '185', 'type': 'block', 'children': ['186']}; {'id': '186', 'type': 'expression_statement', 'children': ['187']}; {'id': '187', 'type': 'assignment', 'children': ['188', '191']}; {'id': '188', 'type': 'subscript', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '191', 'type': 'dictionary', 'children': []}; {'id': '192', 'type': 'if_statement', 'children': ['193', '198']}; {'id': '193', 'type': 'comparison_operator', 'children': ['194', '195'], 'value': 'not'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '195', 'type': 'subscript', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '198', 'type': 'block', 'children': ['199']}; {'id': '199', 'type': 'expression_statement', 'children': ['200']}; {'id': '200', 'type': 'assignment', 'children': ['201', '206']}; {'id': '201', 'type': 'subscript', 'children': ['202', '205']}; {'id': '202', 'type': 'subscript', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '206', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '207', 'type': 'expression_statement', 'children': ['208']}; {'id': '208', 'type': 'call', 'children': ['209', '216']}; {'id': '209', 'type': 'attribute', 'children': ['210', '215']}; {'id': '210', 'type': 'subscript', 'children': ['211', '214']}; {'id': '211', 'type': 'subscript', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'cA'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'cB'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '216', 'type': 'argument_list', 'children': ['217']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'pident'}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'assignment', 'children': ['220', '221', '236']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '221', 'type': 'ERROR', 'children': ['222', '225', '226']}; {'id': '222', 'type': 'ERROR', 'children': ['223', '224']}; {'id': '223', 'type': 'escape_sequence', 'children': [], 'value': '\\n'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'clade'}; {'id': '226', 'type': 'comparison_operator', 'children': ['227', '228'], 'value': 'in'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'pidents'}; {'id': '228', 'type': 'call', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '230', 'type': 'argument_list', 'children': ['231']}; {'id': '231', 'type': 'call', 'children': ['232', '235']}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'wi'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '235', 'type': 'argument_list', 'children': []}; {'id': '236', 'type': 'type', 'children': ['237']}; {'id': '237', 'type': 'call', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '239', 'type': 'argument_list', 'children': ['240']}; {'id': '240', 'type': 'call', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'list', 'children': ['246', '252', '253'], 'value': "['wi:%s' % str(i), clade, str(min(pidents))]"}; {'id': '246', 'type': 'binary_operator', 'children': ['247', '248'], 'value': '%'}; {'id': '247', 'type': 'string', 'children': [], 'value': "'wi:%s'"}; {'id': '248', 'type': 'call', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '250', 'type': 'argument_list', 'children': ['251']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'clade'}; {'id': '253', 'type': 'call', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '255', 'type': 'argument_list', 'children': ['256']}; {'id': '256', 'type': 'call', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '258', 'type': 'argument_list', 'children': ['259']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'pidents'}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'assignment', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'comps'}; {'id': '263', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '264', 'type': 'expression_statement', 'children': ['265']}; {'id': '265', 'type': 'assignment', 'children': ['266', '267', '277', '279']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '267', 'type': 'ERROR', 'children': ['268', '271']}; {'id': '268', 'type': 'ERROR', 'children': ['269', '270']}; {'id': '269', 'type': 'escape_sequence', 'children': [], 'value': '\\n'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '271', 'type': 'comparison_operator', 'children': ['272', '273'], 'value': 'in'}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '273', 'type': 'call', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'print_pairwise'}; {'id': '275', 'type': 'argument_list', 'children': ['276']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '277', 'type': 'ERROR', 'children': ['278']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'if'}; {'id': '279', 'type': 'type', 'children': ['280']}; {'id': '280', 'type': 'constrained_type', 'children': ['281', '285']}; {'id': '281', 'type': 'type', 'children': ['282']}; {'id': '282', 'type': 'comparison_operator', 'children': ['283', '284'], 'value': 'is'}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '284', 'type': 'None', 'children': []}; {'id': '285', 'type': 'type', 'children': ['286']}; {'id': '286', 'type': 'call', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '288', 'type': 'argument_list', 'children': ['289']}; {'id': '289', 'type': 'call', 'children': ['290', '293']}; {'id': '290', 'type': 'attribute', 'children': ['291', '292']}; {'id': '291', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '293', 'type': 'argument_list', 'children': ['294']}; {'id': '294', 'type': 'binary_operator', 'children': ['295', '302'], 'value': '+'}; {'id': '295', 'type': 'list', 'children': ['296'], 'value': "['bt:%s' % str(i)]"}; {'id': '296', 'type': 'binary_operator', 'children': ['297', '298'], 'value': '%'}; {'id': '297', 'type': 'string', 'children': [], 'value': "'bt:%s'"}; {'id': '298', 'type': 'call', 'children': ['299', '300']}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '300', 'type': 'argument_list', 'children': ['301']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '302', 'type': 'list_comprehension', 'children': ['303', '307']}; {'id': '303', 'type': 'call', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '305', 'type': 'argument_list', 'children': ['306']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '307', 'type': 'for_in_clause', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '310', 'type': 'ERROR', 'children': ['311', '314', '315', '316', '320', '322', '323', '338', '340', '343', '367']}; {'id': '311', 'type': 'subscript', 'children': ['312', '313']}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '313', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '314', 'type': 'string', 'children': [], 'value': "'\n comps.extend([j for j in comp[1:] if j != '"}; {'id': '315', 'type': 'ERROR', 'children': []}; {'id': '316', 'type': 'call', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'print_comps'}; {'id': '318', 'type': 'argument_list', 'children': ['319']}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'comps'}; {'id': '320', 'type': 'ERROR', 'children': ['321']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'comps'}; {'id': '322', 'type': 'ERROR', 'children': []}; {'id': '323', 'type': 'call', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '325', 'type': 'argument_list', 'children': ['326', '329']}; {'id': '326', 'type': 'ERROR', 'children': ['327', '328']}; {'id': '327', 'type': 'escape_sequence', 'children': [], 'value': '\\n'}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '329', 'type': 'comparison_operator', 'children': ['330', '331'], 'value': 'in'}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '331', 'type': 'call', 'children': ['332', '333']}; {'id': '332', 'type': 'identifier', 'children': [], 'value': 'print_pairwise'}; {'id': '333', 'type': 'argument_list', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'bt'}; {'id': '335', 'type': 'keyword_argument', 'children': ['336', '337']}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'median'}; {'id': '337', 'type': 'True', 'children': []}; {'id': '338', 'type': 'ERROR', 'children': ['339']}; {'id': '339', 'type': 'identifier', 'children': [], 'value': 'if'}; {'id': '340', 'type': 'comparison_operator', 'children': ['341', '342'], 'value': 'is'}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '342', 'type': 'None', 'children': []}; {'id': '343', 'type': 'call', 'children': ['344', '345']}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '345', 'type': 'argument_list', 'children': ['346']}; {'id': '346', 'type': 'call', 'children': ['347', '350']}; {'id': '347', 'type': 'attribute', 'children': ['348', '349']}; {'id': '348', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '349', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '350', 'type': 'argument_list', 'children': ['351']}; {'id': '351', 'type': 'binary_operator', 'children': ['352', '359'], 'value': '+'}; {'id': '352', 'type': 'list', 'children': ['353'], 'value': "['bt:%s' % str(i)]"}; {'id': '353', 'type': 'binary_operator', 'children': ['354', '355'], 'value': '%'}; {'id': '354', 'type': 'string', 'children': [], 'value': "'bt:%s'"}; {'id': '355', 'type': 'call', 'children': ['356', '357']}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '357', 'type': 'argument_list', 'children': ['358']}; {'id': '358', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '359', 'type': 'list_comprehension', 'children': ['360', '364']}; {'id': '360', 'type': 'call', 'children': ['361', '362']}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '362', 'type': 'argument_list', 'children': ['363']}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '364', 'type': 'for_in_clause', 'children': ['365', '366']}; {'id': '365', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '366', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '367', 'type': 'comparison_operator', 'children': ['368', '371'], 'value': '!='}; {'id': '368', 'type': 'subscript', 'children': ['369', '370']}; {'id': '369', 'type': 'identifier', 'children': [], 'value': 'comp'}; {'id': '370', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '371', 'type': 'binary_operator', 'children': ['372', '373', '374'], 'value': '-'}; {'id': '372', 'type': 'string', 'children': [], 'value': "'\n comps.extend([j for j in comp[1:] if j != '"}; {'id': '373', 'type': 'ERROR', 'children': []}; {'id': '374', 'type': 'call', 'children': ['375', '376']}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'print_comps'}; {'id': '376', 'type': 'argument_list', 'children': ['377']}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'comps'}
print min. pident within each clade and then matrix of between-clade max.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_configure_logger'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8', '9', '10']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'quiet'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'fpath'}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'pre_hooks'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'post_hooks'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'metric_grouping_interval'}; {'id': '11', 'type': 'block', 'children': ['12', '24', '26', '30', '57', '63', '77', '87', '96', '102', '125', '141', '157', '164', '178', '182', '194', '210', '218', '236', '245', '272', '280', '289', '296']}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '15', 'type': 'call', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '17', 'type': 'argument_list', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'logging'}; {'id': '19', 'type': 'call', 'children': ['20', '23']}; {'id': '20', 'type': 'attribute', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'upper'}; {'id': '23', 'type': 'argument_list', 'children': []}; {'id': '24', 'type': 'global_statement', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': '_GLOBAL_LOG_CONFIGURED'}; {'id': '26', 'type': 'if_statement', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': '_GLOBAL_LOG_CONFIGURED'}; {'id': '28', 'type': 'block', 'children': ['29']}; {'id': '29', 'type': 'return_statement', 'children': []}; {'id': '30', 'type': 'function_definition', 'children': ['31', '32', '34']}; {'id': '31', 'type': 'function_name', 'children': [], 'value': 'wrap_hook'}; {'id': '32', 'type': 'parameters', 'children': ['33']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'fn'}; {'id': '34', 'type': 'block', 'children': ['35', '55']}; {'id': '35', 'type': 'decorated_definition', 'children': ['36', '41']}; {'id': '36', 'type': 'decorator', 'children': ['37']}; {'id': '37', 'type': 'call', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'wraps'}; {'id': '39', 'type': 'argument_list', 'children': ['40']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'fn'}; {'id': '41', 'type': 'function_definition', 'children': ['42', '43', '47']}; {'id': '42', 'type': 'function_name', 'children': [], 'value': 'processor'}; {'id': '43', 'type': 'parameters', 'children': ['44', '45', '46']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'method_name'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'event_dict'}; {'id': '47', 'type': 'block', 'children': ['48', '53']}; {'id': '48', 'type': 'expression_statement', 'children': ['49']}; {'id': '49', 'type': 'call', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'fn'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'event_dict'}; {'id': '53', 'type': 'return_statement', 'children': ['54']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'event_dict'}; {'id': '55', 'type': 'return_statement', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'processor'}; {'id': '57', 'type': 'expression_statement', 'children': ['58']}; {'id': '58', 'type': 'assignment', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '60', 'type': 'call', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'define_log_processors'}; {'id': '62', 'type': 'argument_list', 'children': []}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'call', 'children': ['65', '68']}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '68', 'type': 'argument_list', 'children': ['69']}; {'id': '69', 'type': 'list_comprehension', 'children': ['70', '74']}; {'id': '70', 'type': 'call', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'wrap_hook'}; {'id': '72', 'type': 'argument_list', 'children': ['73']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '74', 'type': 'for_in_clause', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'pre_hooks'}; {'id': '77', 'type': 'if_statement', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'metric_grouping_interval'}; {'id': '79', 'type': 'block', 'children': ['80']}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'call', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '85', 'type': 'argument_list', 'children': ['86']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'metrics_grouping_processor'}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'log_renderer'}; {'id': '90', 'type': 'call', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'define_log_renderer'}; {'id': '92', 'type': 'argument_list', 'children': ['93', '94', '95']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'fpath'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'quiet'}; {'id': '96', 'type': 'expression_statement', 'children': ['97']}; {'id': '97', 'type': 'assignment', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'stderr_required'}; {'id': '99', 'type': '()', 'children': ['100']}; {'id': '100', 'type': 'not_operator', 'children': ['101']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'quiet'}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'assignment', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'pretty_to_stderr'}; {'id': '105', 'type': '()', 'children': ['106']}; {'id': '106', 'type': 'boolean_operator', 'children': ['107', '108'], 'value': 'and'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'stderr_required'}; {'id': '108', 'type': '()', 'children': ['109']}; {'id': '109', 'type': 'boolean_operator', 'children': ['110', '113'], 'value': 'or'}; {'id': '110', 'type': 'comparison_operator', 'children': ['111', '112'], 'value': '=='}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '112', 'type': 'string', 'children': [], 'value': '"pretty"'}; {'id': '113', 'type': '()', 'children': ['114']}; {'id': '114', 'type': 'boolean_operator', 'children': ['115', '118'], 'value': 'and'}; {'id': '115', 'type': 'comparison_operator', 'children': ['116', '117'], 'value': 'is'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '117', 'type': 'None', 'children': []}; {'id': '118', 'type': 'call', 'children': ['119', '124']}; {'id': '119', 'type': 'attribute', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'isatty'}; {'id': '124', 'type': 'argument_list', 'children': []}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'assignment', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'should_inject_pretty_renderer'}; {'id': '128', 'type': '()', 'children': ['129']}; {'id': '129', 'type': 'boolean_operator', 'children': ['130', '131'], 'value': 'and'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'pretty_to_stderr'}; {'id': '131', 'type': 'not_operator', 'children': ['132']}; {'id': '132', 'type': 'call', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '134', 'type': 'argument_list', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'log_renderer'}; {'id': '136', 'type': 'attribute', 'children': ['137', '140']}; {'id': '137', 'type': 'attribute', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'structlog'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'dev'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'ConsoleRenderer'}; {'id': '141', 'type': 'if_statement', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'should_inject_pretty_renderer'}; {'id': '143', 'type': 'block', 'children': ['144', '148']}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'stderr_required'}; {'id': '147', 'type': 'False', 'children': []}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'call', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'StderrConsoleRenderer'}; {'id': '156', 'type': 'argument_list', 'children': []}; {'id': '157', 'type': 'expression_statement', 'children': ['158']}; {'id': '158', 'type': 'call', 'children': ['159', '162']}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '162', 'type': 'argument_list', 'children': ['163']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'log_renderer'}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'call', 'children': ['166', '169']}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'list_comprehension', 'children': ['171', '175']}; {'id': '171', 'type': 'call', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'wrap_hook'}; {'id': '173', 'type': 'argument_list', 'children': ['174']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '175', 'type': 'for_in_clause', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'post_hooks'}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'assignment', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '181', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '182', 'type': 'if_statement', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'stderr_required'}; {'id': '184', 'type': 'block', 'children': ['185']}; {'id': '185', 'type': 'expression_statement', 'children': ['186']}; {'id': '186', 'type': 'call', 'children': ['187', '190']}; {'id': '187', 'type': 'attribute', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '190', 'type': 'argument_list', 'children': ['191']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '194', 'type': 'if_statement', 'children': ['195', '198']}; {'id': '195', 'type': 'comparison_operator', 'children': ['196', '197'], 'value': 'is'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'fpath'}; {'id': '197', 'type': 'None', 'children': []}; {'id': '198', 'type': 'block', 'children': ['199']}; {'id': '199', 'type': 'expression_statement', 'children': ['200']}; {'id': '200', 'type': 'call', 'children': ['201', '204']}; {'id': '201', 'type': 'attribute', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '204', 'type': 'argument_list', 'children': ['205']}; {'id': '205', 'type': 'call', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '207', 'type': 'argument_list', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'fpath'}; {'id': '209', 'type': 'string', 'children': [], 'value': "'a'"}; {'id': '210', 'type': 'assert_statement', 'children': ['211', '217']}; {'id': '211', 'type': 'comparison_operator', 'children': ['212', '216'], 'value': '!='}; {'id': '212', 'type': 'call', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '214', 'type': 'argument_list', 'children': ['215']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '216', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '217', 'type': 'string', 'children': [], 'value': '"cannot configure logger for 0 streams"'}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'assignment', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '221', 'type': 'conditional_expression', 'children': ['222', '225', '231'], 'value': 'if'}; {'id': '222', 'type': 'subscript', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '224', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '225', 'type': 'comparison_operator', 'children': ['226', '230'], 'value': '=='}; {'id': '226', 'type': 'call', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '228', 'type': 'argument_list', 'children': ['229']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '230', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '231', 'type': 'call', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'Stream'}; {'id': '233', 'type': 'argument_list', 'children': ['234']}; {'id': '234', 'type': 'list_splat', 'children': ['235']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'streams'}; {'id': '236', 'type': 'expression_statement', 'children': ['237']}; {'id': '237', 'type': 'call', 'children': ['238', '241']}; {'id': '238', 'type': 'attribute', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'atexit'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'register'}; {'id': '241', 'type': 'argument_list', 'children': ['242']}; {'id': '242', 'type': 'attribute', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '245', 'type': 'expression_statement', 'children': ['246']}; {'id': '246', 'type': 'call', 'children': ['247', '250']}; {'id': '247', 'type': 'attribute', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'structlog'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'configure'}; {'id': '250', 'type': 'argument_list', 'children': ['251', '254', '257', '266', '269']}; {'id': '251', 'type': 'keyword_argument', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'processors'}; {'id': '254', 'type': 'keyword_argument', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'context_class'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '257', 'type': 'keyword_argument', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'logger_factory'}; {'id': '259', 'type': 'call', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'LevelLoggerFactory'}; {'id': '261', 'type': 'argument_list', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '263', 'type': 'keyword_argument', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '266', 'type': 'keyword_argument', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'wrapper_class'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'BoundLevelLogger'}; {'id': '269', 'type': 'keyword_argument', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'cache_logger_on_first_use'}; {'id': '271', 'type': 'True', 'children': []}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'assignment', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'stdlib_root_log'}; {'id': '275', 'type': 'call', 'children': ['276', '279']}; {'id': '276', 'type': 'attribute', 'children': ['277', '278']}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'logging'}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'getLogger'}; {'id': '279', 'type': 'argument_list', 'children': []}; {'id': '280', 'type': 'expression_statement', 'children': ['281']}; {'id': '281', 'type': 'call', 'children': ['282', '285']}; {'id': '282', 'type': 'attribute', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'stdlib_root_log'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'addHandler'}; {'id': '285', 'type': 'argument_list', 'children': ['286']}; {'id': '286', 'type': 'call', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'StdlibStructlogHandler'}; {'id': '288', 'type': 'argument_list', 'children': []}; {'id': '289', 'type': 'expression_statement', 'children': ['290']}; {'id': '290', 'type': 'call', 'children': ['291', '294']}; {'id': '291', 'type': 'attribute', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'stdlib_root_log'}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'setLevel'}; {'id': '294', 'type': 'argument_list', 'children': ['295']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '296', 'type': 'expression_statement', 'children': ['297']}; {'id': '297', 'type': 'assignment', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': '_GLOBAL_LOG_CONFIGURED'}; {'id': '299', 'type': 'True', 'children': []}
configures a logger when required write to stderr or a file
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'ERROR', 'children': ['2']}; {'id': '2', 'type': 'function_definition', 'children': ['3', '4', '8']}; {'id': '3', 'type': 'function_name', 'children': [], 'value': 'parse_fasta_annotations'}; {'id': '4', 'type': 'parameters', 'children': ['5', '6', '7']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'fastas'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'annot_tables'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'trans_table'}; {'id': '8', 'type': 'block', 'children': ['9', '57', '215', '235', '246', '260', '277']}; {'id': '9', 'type': 'if_statement', 'children': ['10', '13']}; {'id': '10', 'type': 'comparison_operator', 'children': ['11', '12'], 'value': 'is'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'annot_tables'}; {'id': '12', 'type': 'False', 'children': []}; {'id': '13', 'type': 'block', 'children': ['14', '18']}; {'id': '14', 'type': 'expression_statement', 'children': ['15']}; {'id': '15', 'type': 'assignment', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'annots'}; {'id': '17', 'type': 'dictionary', 'children': []}; {'id': '18', 'type': 'for_statement', 'children': ['19', '20', '21']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'annot_tables'}; {'id': '21', 'type': 'block', 'children': ['22']}; {'id': '22', 'type': 'for_statement', 'children': ['23', '24', '28']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'cds'}; {'id': '24', 'type': 'call', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '26', 'type': 'argument_list', 'children': ['27']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '28', 'type': 'block', 'children': ['29', '45']}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '36']}; {'id': '31', 'type': 'pattern_list', 'children': ['32', '33', '34', '35']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '36', 'type': 'call', 'children': ['37', '44']}; {'id': '37', 'type': 'attribute', 'children': ['38', '43']}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'cds'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '42', 'type': 'argument_list', 'children': []}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '44', 'type': 'argument_list', 'children': []}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'assignment', 'children': ['47', '50']}; {'id': '47', 'type': 'subscript', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'annots'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '50', 'type': 'list', 'children': ['51', '52', '53'], 'value': '[start, end, int(strand)]'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '53', 'type': 'call', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '55', 'type': 'argument_list', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '57', 'type': 'for_statement', 'children': ['58', '59', '60', '203', '208']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'fasta'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'fastas'}; {'id': '60', 'type': 'ERROR', 'children': ['61', '160', '179', '180', '182', '183', '185', '191', '197', '200']}; {'id': '61', 'type': 'for_statement', 'children': ['62', '63', '67', '78', '131']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '63', 'type': 'call', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'parse_fasta'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'fasta'}; {'id': '67', 'type': 'ERROR', 'children': ['68', '73']}; {'id': '68', 'type': 'call', 'children': ['69', '70', '72']}; {'id': '69', 'type': 'string', 'children': [], 'value': "'\n print('"}; {'id': '70', 'type': 'ERROR', 'children': ['71']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '72', 'type': 'argument_list', 'children': []}; {'id': '73', 'type': 'comparison_operator', 'children': ['74', '75'], 'value': 'in'}; {'id': '74', 'type': 'string', 'children': [], 'value': "'ID='"}; {'id': '75', 'type': 'subscript', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '77', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '78', 'type': 'block', 'children': ['79', '101']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '82', 'type': 'subscript', 'children': ['83', '100']}; {'id': '83', 'type': 'call', 'children': ['84', '97']}; {'id': '84', 'type': 'attribute', 'children': ['85', '96']}; {'id': '85', 'type': 'subscript', 'children': ['86', '95']}; {'id': '86', 'type': 'call', 'children': ['87', '92']}; {'id': '87', 'type': 'attribute', 'children': ['88', '91']}; {'id': '88', 'type': 'subscript', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '90', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '92', 'type': 'argument_list', 'children': ['93', '94']}; {'id': '93', 'type': 'string', 'children': [], 'value': "'ID='"}; {'id': '94', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '95', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '97', 'type': 'argument_list', 'children': ['98', '99']}; {'id': '98', 'type': 'string', 'children': [], 'value': "';'"}; {'id': '99', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '100', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'assignment', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '104', 'type': 'subscript', 'children': ['105', '130']}; {'id': '105', 'type': 'call', 'children': ['106', '124']}; {'id': '106', 'type': 'attribute', 'children': ['107', '123']}; {'id': '107', 'type': 'subscript', 'children': ['108', '122']}; {'id': '108', 'type': 'call', 'children': ['109', '120']}; {'id': '109', 'type': 'attribute', 'children': ['110', '119']}; {'id': '110', 'type': 'subscript', 'children': ['111', '118']}; {'id': '111', 'type': 'call', 'children': ['112', '117']}; {'id': '112', 'type': 'attribute', 'children': ['113', '116']}; {'id': '113', 'type': 'subscript', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '115', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '117', 'type': 'argument_list', 'children': []}; {'id': '118', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '120', 'type': 'argument_list', 'children': ['121']}; {'id': '121', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '122', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '124', 'type': 'argument_list', 'children': ['125', '129']}; {'id': '125', 'type': 'binary_operator', 'children': ['126', '127'], 'value': '%'}; {'id': '126', 'type': 'string', 'children': [], 'value': "'_%s'"}; {'id': '127', 'type': '()', 'children': ['128']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'ID'}; {'id': '129', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '130', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '131', 'type': 'else_clause', 'children': ['132']}; {'id': '132', 'type': 'block', 'children': ['133']}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'assignment', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '136', 'type': 'subscript', 'children': ['137', '159']}; {'id': '137', 'type': 'call', 'children': ['138', '156']}; {'id': '138', 'type': 'attribute', 'children': ['139', '155']}; {'id': '139', 'type': 'subscript', 'children': ['140', '154']}; {'id': '140', 'type': 'call', 'children': ['141', '152']}; {'id': '141', 'type': 'attribute', 'children': ['142', '151']}; {'id': '142', 'type': 'subscript', 'children': ['143', '150']}; {'id': '143', 'type': 'call', 'children': ['144', '149']}; {'id': '144', 'type': 'attribute', 'children': ['145', '148']}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '147', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '149', 'type': 'argument_list', 'children': []}; {'id': '150', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '154', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '156', 'type': 'argument_list', 'children': ['157', '158']}; {'id': '157', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '158', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '159', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'locus'}; {'id': '163', 'type': 'subscript', 'children': ['164', '178']}; {'id': '164', 'type': 'call', 'children': ['165', '176']}; {'id': '165', 'type': 'attribute', 'children': ['166', '175']}; {'id': '166', 'type': 'subscript', 'children': ['167', '174']}; {'id': '167', 'type': 'call', 'children': ['168', '173']}; {'id': '168', 'type': 'attribute', 'children': ['169', '172']}; {'id': '169', 'type': 'subscript', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '171', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '173', 'type': 'argument_list', 'children': []}; {'id': '174', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '176', 'type': 'argument_list', 'children': ['177']}; {'id': '177', 'type': 'string', 'children': [], 'value': "'>'"}; {'id': '178', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '179', 'type': 'string', 'children': [], 'value': "'\n info = seq[0].split('"}; {'id': '180', 'type': 'ERROR', 'children': ['181']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '183', 'type': 'ERROR', 'children': ['184']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '185', 'type': 'call', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'subscript', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '190', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '191', 'type': 'call', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '193', 'type': 'argument_list', 'children': ['194']}; {'id': '194', 'type': 'subscript', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '196', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '197', 'type': 'subscript', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '199', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '200', 'type': 'comparison_operator', 'children': ['201', '202'], 'value': '=='}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '202', 'type': 'string', 'children': [], 'value': "'1'"}; {'id': '203', 'type': 'block', 'children': ['204']}; {'id': '204', 'type': 'expression_statement', 'children': ['205']}; {'id': '205', 'type': 'assignment', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '207', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '208', 'type': 'else_clause', 'children': ['209']}; {'id': '209', 'type': 'block', 'children': ['210']}; {'id': '210', 'type': 'expression_statement', 'children': ['211']}; {'id': '211', 'type': 'assignment', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '213', 'type': 'unary_operator', 'children': ['214'], 'value': '-'}; {'id': '214', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'product'}; {'id': '218', 'type': 'list', 'children': ['219'], 'value': "[''.join(info[4].split()[1:])]"}; {'id': '219', 'type': 'call', 'children': ['220', '223']}; {'id': '220', 'type': 'attribute', 'children': ['221', '222']}; {'id': '221', 'type': 'string', 'children': [], 'value': "''"}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'subscript', 'children': ['225', '232']}; {'id': '225', 'type': 'call', 'children': ['226', '231']}; {'id': '226', 'type': 'attribute', 'children': ['227', '230']}; {'id': '227', 'type': 'subscript', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '229', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '231', 'type': 'argument_list', 'children': []}; {'id': '232', 'type': 'slice', 'children': ['233', '234']}; {'id': '233', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '234', 'type': 'colon', 'children': []}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'assignment', 'children': ['237', '243']}; {'id': '237', 'type': 'pattern_list', 'children': ['238', '239', '241', '242']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'else'}; {'id': '239', 'type': 'ERROR', 'children': ['240']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '243', 'type': 'subscript', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'annots'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'locus'}; {'id': '246', 'type': 'expression_statement', 'children': ['247']}; {'id': '247', 'type': 'assignment', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'product'}; {'id': '249', 'type': 'subscript', 'children': ['250', '259']}; {'id': '250', 'type': 'call', 'children': ['251', '256']}; {'id': '251', 'type': 'attribute', 'children': ['252', '255']}; {'id': '252', 'type': 'subscript', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '254', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '256', 'type': 'argument_list', 'children': ['257', '258']}; {'id': '257', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '258', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '259', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'assignment', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '263', 'type': 'dictionary', 'children': ['264', '268', '274']}; {'id': '264', 'type': 'pair', 'children': ['265', '266']}; {'id': '265', 'type': 'string', 'children': [], 'value': "'transl_table'"}; {'id': '266', 'type': 'list', 'children': ['267'], 'value': '[trans_table]'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'trans_table'}; {'id': '268', 'type': 'pair', 'children': ['269', '270']}; {'id': '269', 'type': 'string', 'children': [], 'value': "'translation'"}; {'id': '270', 'type': 'list', 'children': ['271'], 'value': '[seq[1]]'}; {'id': '271', 'type': 'subscript', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '273', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '274', 'type': 'pair', 'children': ['275', '276']}; {'id': '275', 'type': 'string', 'children': [], 'value': "'product'"}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'product'}; {'id': '277', 'type': 'expression_statement', 'children': ['278']}; {'id': '278', 'type': 'yield', 'children': ['279']}; {'id': '279', 'type': 'expression_list', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '281', 'type': 'list', 'children': ['282', '283', '287'], 'value': '[locus, [start, end, strand], info]'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'locus'}; {'id': '283', 'type': 'list', 'children': ['284', '285', '286'], 'value': '[start, end, strand]'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'strand'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'info'}
parse gene call information from Prodigal fasta output
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'print_consensus'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'genomes'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '128', '204']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '9', 'type': 'dictionary', 'children': []}; {'id': '10', 'type': 'for_statement', 'children': ['11', '14', '22']}; {'id': '11', 'type': 'pattern_list', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'contigs'}; {'id': '14', 'type': 'call', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '16', 'type': 'argument_list', 'children': ['17']}; {'id': '17', 'type': 'call', 'children': ['18', '21']}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'genomes'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '21', 'type': 'argument_list', 'children': []}; {'id': '22', 'type': 'block', 'children': ['23', '29']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '28']}; {'id': '25', 'type': 'subscript', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '28', 'type': 'dictionary', 'children': []}; {'id': '29', 'type': 'for_statement', 'children': ['30', '33', '41']}; {'id': '30', 'type': 'pattern_list', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '35', 'type': 'argument_list', 'children': ['36']}; {'id': '36', 'type': 'call', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'contigs'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '40', 'type': 'argument_list', 'children': []}; {'id': '41', 'type': 'block', 'children': ['42']}; {'id': '42', 'type': 'for_statement', 'children': ['43', '46', '54']}; {'id': '43', 'type': 'pattern_list', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'stats'}; {'id': '46', 'type': 'call', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'call', 'children': ['50', '53']}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '53', 'type': 'argument_list', 'children': []}; {'id': '54', 'type': 'block', 'children': ['55', '70', '82']}; {'id': '55', 'type': 'if_statement', 'children': ['56', '61']}; {'id': '56', 'type': 'comparison_operator', 'children': ['57', '58'], 'value': 'not'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '58', 'type': 'subscript', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '61', 'type': 'block', 'children': ['62']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '69']}; {'id': '64', 'type': 'subscript', 'children': ['65', '68']}; {'id': '65', 'type': 'subscript', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '69', 'type': 'dictionary', 'children': []}; {'id': '70', 'type': 'expression_statement', 'children': ['71']}; {'id': '71', 'type': 'assignment', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '73', 'type': 'assignment', 'children': ['74', '81']}; {'id': '74', 'type': 'subscript', 'children': ['75', '80']}; {'id': '75', 'type': 'subscript', 'children': ['76', '79']}; {'id': '76', 'type': 'subscript', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '81', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '82', 'type': 'for_statement', 'children': ['83', '86', '93']}; {'id': '83', 'type': 'pattern_list', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'pos'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'ps'}; {'id': '86', 'type': 'call', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '88', 'type': 'argument_list', 'children': ['89', '92']}; {'id': '89', 'type': 'subscript', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'stats'}; {'id': '91', 'type': 'string', 'children': [], 'value': "'bp_stats'"}; {'id': '92', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '93', 'type': 'block', 'children': ['94', '108', '121']}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'assignment', 'children': ['96', '99']}; {'id': '96', 'type': 'pattern_list', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'consensus'}; {'id': '99', 'type': 'expression_list', 'children': ['100', '103']}; {'id': '100', 'type': 'subscript', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'ps'}; {'id': '102', 'type': 'string', 'children': [], 'value': "'ref'"}; {'id': '103', 'type': 'subscript', 'children': ['104', '107']}; {'id': '104', 'type': 'subscript', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'ps'}; {'id': '106', 'type': 'string', 'children': [], 'value': "'consensus'"}; {'id': '107', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '108', 'type': 'if_statement', 'children': ['109', '112']}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '111'], 'value': '=='}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'consensus'}; {'id': '111', 'type': 'string', 'children': [], 'value': "'n/a'"}; {'id': '112', 'type': 'block', 'children': ['113']}; {'id': '113', 'type': 'expression_statement', 'children': ['114']}; {'id': '114', 'type': 'assignment', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'consensus'}; {'id': '116', 'type': 'call', 'children': ['117', '120']}; {'id': '117', 'type': 'attribute', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '120', 'type': 'argument_list', 'children': []}; {'id': '121', 'type': 'expression_statement', 'children': ['122']}; {'id': '122', 'type': 'call', 'children': ['123', '126']}; {'id': '123', 'type': 'attribute', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '126', 'type': 'argument_list', 'children': ['127']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'consensus'}; {'id': '128', 'type': 'for_statement', 'children': ['129', '132', '137']}; {'id': '129', 'type': 'pattern_list', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '132', 'type': 'call', 'children': ['133', '136']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'cons'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '136', 'type': 'argument_list', 'children': []}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'for_statement', 'children': ['139', '142', '147']}; {'id': '139', 'type': 'pattern_list', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'contigs'}; {'id': '142', 'type': 'call', 'children': ['143', '146']}; {'id': '143', 'type': 'attribute', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '146', 'type': 'argument_list', 'children': []}; {'id': '147', 'type': 'block', 'children': ['148', '156', '164', '198']}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'fn'}; {'id': '151', 'type': 'binary_operator', 'children': ['152', '153'], 'value': '%'}; {'id': '152', 'type': 'string', 'children': [], 'value': "'%s.%s.consensus.fa'"}; {'id': '153', 'type': 'tuple', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'assignment', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '159', 'type': 'call', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '161', 'type': 'argument_list', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'fn'}; {'id': '163', 'type': 'string', 'children': [], 'value': "'w'"}; {'id': '164', 'type': 'for_statement', 'children': ['165', '168', '173']}; {'id': '165', 'type': 'pattern_list', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '168', 'type': 'call', 'children': ['169', '172']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'contigs'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '172', 'type': 'argument_list', 'children': []}; {'id': '173', 'type': 'block', 'children': ['174', '185']}; {'id': '174', 'type': 'expression_statement', 'children': ['175']}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '177', 'type': 'argument_list', 'children': ['178', '182']}; {'id': '178', 'type': 'binary_operator', 'children': ['179', '180'], 'value': '%'}; {'id': '179', 'type': 'string', 'children': [], 'value': "'>%s'"}; {'id': '180', 'type': '()', 'children': ['181']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'contig'}; {'id': '182', 'type': 'keyword_argument', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '185', 'type': 'expression_statement', 'children': ['186']}; {'id': '186', 'type': 'call', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '188', 'type': 'argument_list', 'children': ['189', '195']}; {'id': '189', 'type': 'call', 'children': ['190', '193']}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'string', 'children': [], 'value': "''"}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '193', 'type': 'argument_list', 'children': ['194']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '195', 'type': 'keyword_argument', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '203', 'type': 'argument_list', 'children': []}; {'id': '204', 'type': 'return_statement', 'children': ['205']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'cons'}
print consensensus sequences for each genome and sample
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'parse_cov'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'cov_table'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'scaffold2genome'}; {'id': '6', 'type': 'block', 'children': ['7', '11', '15', '179', '195', '255']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '10', 'type': 'dictionary', 'children': []}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'assignment', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'mapped'}; {'id': '14', 'type': 'dictionary', 'children': []}; {'id': '15', 'type': 'for_statement', 'children': ['16', '17', '21']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '17', 'type': 'call', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '19', 'type': 'argument_list', 'children': ['20']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'cov_table'}; {'id': '21', 'type': 'block', 'children': ['22', '35', '126', '132', '155', '161']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '25', 'type': 'call', 'children': ['26', '33']}; {'id': '26', 'type': 'attribute', 'children': ['27', '32']}; {'id': '27', 'type': 'call', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '31', 'type': 'argument_list', 'children': []}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '35', 'type': 'if_statement', 'children': ['36', '41', '124']}; {'id': '36', 'type': 'attribute', 'children': ['37', '40']}; {'id': '37', 'type': 'subscript', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '39', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '41', 'type': 'ERROR', 'children': ['42', '43', '76', '79', '80', '121']}; {'id': '42', 'type': 'ERROR', 'children': []}; {'id': '43', 'type': 'keyword_argument', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '45', 'type': 'subscript', 'children': ['46', '51', '53']}; {'id': '46', 'type': 'subscript', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '48', 'type': 'slice', 'children': ['49', '50']}; {'id': '49', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '50', 'type': 'colon', 'children': []}; {'id': '51', 'type': 'ERROR', 'children': ['52']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '53', 'type': 'comparison_operator', 'children': ['54', '72', '75'], 'value': 'in'}; {'id': '54', 'type': 'subscript', 'children': ['55', '71']}; {'id': '55', 'type': 'call', 'children': ['56', '68']}; {'id': '56', 'type': 'attribute', 'children': ['57', '67']}; {'id': '57', 'type': 'subscript', 'children': ['58', '65']}; {'id': '58', 'type': 'call', 'children': ['59', '62']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'rsplit'}; {'id': '62', 'type': 'argument_list', 'children': ['63', '64']}; {'id': '63', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '64', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '65', 'type': 'unary_operator', 'children': ['66'], 'value': '-'}; {'id': '66', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '70']}; {'id': '69', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '70', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '71', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '72', 'type': 'ERROR', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '76', 'type': 'ERROR', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'continue'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'scaffold'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '80', 'type': 'subscript', 'children': ['81', '111', '113']}; {'id': '81', 'type': 'subscript', 'children': ['82', '96', '98']}; {'id': '82', 'type': 'call', 'children': ['83', '91', '94']}; {'id': '83', 'type': 'call', 'children': ['84', '89']}; {'id': '84', 'type': 'attribute', 'children': ['85', '88']}; {'id': '85', 'type': 'subscript', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '87', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'string', 'children': [], 'value': "': '"}; {'id': '91', 'type': 'ERROR', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '94', 'type': 'argument_list', 'children': ['95']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '96', 'type': 'ERROR', 'children': ['97']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'covs'}; {'id': '98', 'type': 'comparison_operator', 'children': ['99', '103', '106'], 'value': 'in'}; {'id': '99', 'type': 'call', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '101', 'type': 'argument_list', 'children': ['102']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '103', 'type': 'ERROR', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '108', 'type': 'slice', 'children': ['109', '110']}; {'id': '109', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '110', 'type': 'colon', 'children': []}; {'id': '111', 'type': 'ERROR', 'children': ['112']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'bases'}; {'id': '113', 'type': 'comparison_operator', 'children': ['114', '117', '120'], 'value': 'in'}; {'id': '114', 'type': 'binary_operator', 'children': ['115', '116'], 'value': '*'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '117', 'type': 'ERROR', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'covs'}; {'id': '121', 'type': 'comparison_operator', 'children': ['122', '123'], 'value': 'not'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'scaffold'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'scaffold2genome'}; {'id': '124', 'type': 'block', 'children': ['125']}; {'id': '125', 'type': 'continue_statement', 'children': []}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'assignment', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '129', 'type': 'subscript', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'scaffold2genome'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'scaffold'}; {'id': '132', 'type': 'if_statement', 'children': ['133', '136']}; {'id': '133', 'type': 'comparison_operator', 'children': ['134', '135'], 'value': 'not'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '136', 'type': 'block', 'children': ['137', '143']}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'assignment', 'children': ['139', '142']}; {'id': '139', 'type': 'subscript', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '142', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '148']}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'mapped'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '148', 'type': 'dictionary_comprehension', 'children': ['149', '152']}; {'id': '149', 'type': 'pair', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '151', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '152', 'type': 'for_in_clause', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'augmented_assignment', 'children': ['157', '160'], 'value': '+='}; {'id': '157', 'type': 'subscript', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '161', 'type': 'for_statement', 'children': ['162', '165', '170']}; {'id': '162', 'type': 'pattern_list', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'count'}; {'id': '165', 'type': 'call', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '167', 'type': 'argument_list', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'bases'}; {'id': '170', 'type': 'block', 'children': ['171']}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'augmented_assignment', 'children': ['173', '178'], 'value': '+='}; {'id': '173', 'type': 'subscript', 'children': ['174', '177']}; {'id': '174', 'type': 'subscript', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'mapped'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'count'}; {'id': '179', 'type': 'expression_statement', 'children': ['180']}; {'id': '180', 'type': 'assignment', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'coverage'}; {'id': '182', 'type': 'dictionary', 'children': ['183', '186', '189', '192']}; {'id': '183', 'type': 'pair', 'children': ['184', '185']}; {'id': '184', 'type': 'string', 'children': [], 'value': "'genome'"}; {'id': '185', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '186', 'type': 'pair', 'children': ['187', '188']}; {'id': '187', 'type': 'string', 'children': [], 'value': "'genome size (bp)'"}; {'id': '188', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '189', 'type': 'pair', 'children': ['190', '191']}; {'id': '190', 'type': 'string', 'children': [], 'value': "'sample'"}; {'id': '191', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '192', 'type': 'pair', 'children': ['193', '194']}; {'id': '193', 'type': 'string', 'children': [], 'value': "'coverage'"}; {'id': '194', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '195', 'type': 'for_statement', 'children': ['196', '199', '204']}; {'id': '196', 'type': 'pattern_list', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '203', 'type': 'argument_list', 'children': []}; {'id': '204', 'type': 'block', 'children': ['205']}; {'id': '205', 'type': 'for_statement', 'children': ['206', '207', '208']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'samples'}; {'id': '208', 'type': 'block', 'children': ['209', '219', '228', '237', '246']}; {'id': '209', 'type': 'expression_statement', 'children': ['210']}; {'id': '210', 'type': 'assignment', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'cov'}; {'id': '212', 'type': 'binary_operator', 'children': ['213', '218'], 'value': '/'}; {'id': '213', 'type': 'subscript', 'children': ['214', '217']}; {'id': '214', 'type': 'subscript', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'mapped'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '219', 'type': 'expression_statement', 'children': ['220']}; {'id': '220', 'type': 'call', 'children': ['221', '226']}; {'id': '221', 'type': 'attribute', 'children': ['222', '225']}; {'id': '222', 'type': 'subscript', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'coverage'}; {'id': '224', 'type': 'string', 'children': [], 'value': "'genome'"}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '228', 'type': 'expression_statement', 'children': ['229']}; {'id': '229', 'type': 'call', 'children': ['230', '235']}; {'id': '230', 'type': 'attribute', 'children': ['231', '234']}; {'id': '231', 'type': 'subscript', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'coverage'}; {'id': '233', 'type': 'string', 'children': [], 'value': "'genome size (bp)'"}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '235', 'type': 'argument_list', 'children': ['236']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'length'}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'call', 'children': ['239', '244']}; {'id': '239', 'type': 'attribute', 'children': ['240', '243']}; {'id': '240', 'type': 'subscript', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'coverage'}; {'id': '242', 'type': 'string', 'children': [], 'value': "'sample'"}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'sample'}; {'id': '246', 'type': 'expression_statement', 'children': ['247']}; {'id': '247', 'type': 'call', 'children': ['248', '253']}; {'id': '248', 'type': 'attribute', 'children': ['249', '252']}; {'id': '249', 'type': 'subscript', 'children': ['250', '251']}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'coverage'}; {'id': '251', 'type': 'string', 'children': [], 'value': "'coverage'"}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'cov'}; {'id': '255', 'type': 'return_statement', 'children': ['256']}; {'id': '256', 'type': 'call', 'children': ['257', '260']}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'pd'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'DataFrame'}; {'id': '260', 'type': 'argument_list', 'children': ['261']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'coverage'}
calculate genome coverage from scaffold coverage table
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'ERROR', 'children': ['2', '298', '304']}; {'id': '2', 'type': 'function_definition', 'children': ['3', '4', '17']}; {'id': '3', 'type': 'function_name', 'children': [], 'value': 'calc_thresholds'}; {'id': '4', 'type': 'parameters', 'children': ['5', '6', '7', '14']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'file_name'}; {'id': '7', 'type': 'default_parameter', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'thresholds'}; {'id': '9', 'type': 'list', 'children': ['10', '11', '12', '13'], 'value': '[False, False, False, False]'}; {'id': '10', 'type': 'False', 'children': []}; {'id': '11', 'type': 'False', 'children': []}; {'id': '12', 'type': 'False', 'children': []}; {'id': '13', 'type': 'False', 'children': []}; {'id': '14', 'type': 'default_parameter', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'stdevs'}; {'id': '16', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '17', 'type': 'block', 'children': ['18', '25', '29', '70', '78', '84']}; {'id': '18', 'type': 'expression_statement', 'children': ['19']}; {'id': '19', 'type': 'assignment', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'calc_threshold'}; {'id': '21', 'type': 'subscript', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'thresholds'}; {'id': '23', 'type': 'unary_operator', 'children': ['24'], 'value': '-'}; {'id': '24', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '28', 'type': 'dictionary', 'children': []}; {'id': '29', 'type': 'for_statement', 'children': ['30', '31', '42']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '31', 'type': 'call', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'itertools'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'permutations'}; {'id': '35', 'type': 'argument_list', 'children': ['36', '41']}; {'id': '36', 'type': 'list_comprehension', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '38', 'type': 'for_in_clause', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '41', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '42', 'type': 'block', 'children': ['43', '58']}; {'id': '43', 'type': 'if_statement', 'children': ['44', '49']}; {'id': '44', 'type': 'comparison_operator', 'children': ['45', '48'], 'value': 'not'}; {'id': '45', 'type': 'subscript', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '47', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '49', 'type': 'block', 'children': ['50']}; {'id': '50', 'type': 'expression_statement', 'children': ['51']}; {'id': '51', 'type': 'assignment', 'children': ['52', '57']}; {'id': '52', 'type': 'subscript', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '54', 'type': 'subscript', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '56', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '57', 'type': 'dictionary', 'children': []}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'assignment', 'children': ['60', '69']}; {'id': '60', 'type': 'subscript', 'children': ['61', '66']}; {'id': '61', 'type': 'subscript', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '63', 'type': 'subscript', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '65', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '66', 'type': 'subscript', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '68', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '69', 'type': 'dictionary', 'children': []}; {'id': '70', 'type': 'expression_statement', 'children': ['71']}; {'id': '71', 'type': 'assignment', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'out'}; {'id': '73', 'type': 'call', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '75', 'type': 'argument_list', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'file_name'}; {'id': '77', 'type': 'string', 'children': [], 'value': "'w'"}; {'id': '78', 'type': 'expression_statement', 'children': ['79']}; {'id': '79', 'type': 'assignment', 'children': ['80', '81', '83']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '81', 'type': 'ERROR', 'children': ['82']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'comparisons'}; {'id': '83', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '84', 'type': 'for_statement', 'children': ['85', '86', '87']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '87', 'type': 'block', 'children': ['88']}; {'id': '88', 'type': 'for_statement', 'children': ['89', '90', '93']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '90', 'type': 'subscript', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '93', 'type': 'block', 'children': ['94', '108', '114', '121', '140', '170', '179', '188', '197', '206', '215']}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'assignment', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '97', 'type': 'call', 'children': ['98', '101']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'string', 'children': [], 'value': "''"}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '101', 'type': 'argument_list', 'children': ['102']}; {'id': '102', 'type': 'call', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'list', 'children': ['106', '107'], 'value': '[genome, compare]'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '108', 'type': 'if_statement', 'children': ['109', '112']}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '111'], 'value': 'in'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'comparisons'}; {'id': '112', 'type': 'block', 'children': ['113']}; {'id': '113', 'type': 'continue_statement', 'children': []}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'call', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'comparisons'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '121', 'type': 'expression_statement', 'children': ['122']}; {'id': '122', 'type': 'assignment', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '124', 'type': 'dictionary', 'children': ['125', '128', '131', '134', '137']}; {'id': '125', 'type': 'pair', 'children': ['126', '127']}; {'id': '126', 'type': 'string', 'children': [], 'value': "'percent identity'"}; {'id': '127', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '128', 'type': 'pair', 'children': ['129', '130']}; {'id': '129', 'type': 'string', 'children': [], 'value': "'e-value'"}; {'id': '130', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '131', 'type': 'pair', 'children': ['132', '133']}; {'id': '132', 'type': 'string', 'children': [], 'value': "'bit score'"}; {'id': '133', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '134', 'type': 'pair', 'children': ['135', '136']}; {'id': '135', 'type': 'string', 'children': [], 'value': "'normalized bit score'"}; {'id': '136', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '137', 'type': 'pair', 'children': ['138', '139']}; {'id': '138', 'type': 'string', 'children': [], 'value': "'alignment length fraction'"}; {'id': '139', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '159']}; {'id': '142', 'type': 'pattern_list', 'children': ['143', '144', '155', '156', '157', '158']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '144', 'type': 'ERROR', 'children': ['145', '147', '154']}; {'id': '145', 'type': 'ERROR', 'children': ['146']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '147', 'type': 'comparison_operator', 'children': ['148', '149'], 'value': 'in'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'id'}; {'id': '149', 'type': 'subscript', 'children': ['150', '153']}; {'id': '150', 'type': 'subscript', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'pident'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'length_fraction'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'norm_bit'}; {'id': '159', 'type': 'subscript', 'children': ['160', '167']}; {'id': '160', 'type': 'subscript', 'children': ['161', '166']}; {'id': '161', 'type': 'subscript', 'children': ['162', '165']}; {'id': '162', 'type': 'subscript', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'rbh'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'id'}; {'id': '167', 'type': 'slice', 'children': ['168', '169']}; {'id': '168', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '169', 'type': 'colon', 'children': []}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '177']}; {'id': '172', 'type': 'attribute', 'children': ['173', '176']}; {'id': '173', 'type': 'subscript', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '175', 'type': 'string', 'children': [], 'value': "'percent identity'"}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '177', 'type': 'argument_list', 'children': ['178']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'pident'}; {'id': '179', 'type': 'expression_statement', 'children': ['180']}; {'id': '180', 'type': 'call', 'children': ['181', '186']}; {'id': '181', 'type': 'attribute', 'children': ['182', '185']}; {'id': '182', 'type': 'subscript', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '184', 'type': 'string', 'children': [], 'value': "'alignment length fraction'"}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '186', 'type': 'argument_list', 'children': ['187']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'length_fraction'}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'call', 'children': ['190', '195']}; {'id': '190', 'type': 'attribute', 'children': ['191', '194']}; {'id': '191', 'type': 'subscript', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '193', 'type': 'string', 'children': [], 'value': "'e-value'"}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '195', 'type': 'argument_list', 'children': ['196']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '197', 'type': 'expression_statement', 'children': ['198']}; {'id': '198', 'type': 'call', 'children': ['199', '204']}; {'id': '199', 'type': 'attribute', 'children': ['200', '203']}; {'id': '200', 'type': 'subscript', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '202', 'type': 'string', 'children': [], 'value': "'bit score'"}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '204', 'type': 'argument_list', 'children': ['205']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'bit'}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'call', 'children': ['208', '213']}; {'id': '208', 'type': 'attribute', 'children': ['209', '212']}; {'id': '209', 'type': 'subscript', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '211', 'type': 'string', 'children': [], 'value': "'normalized bit score'"}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '213', 'type': 'argument_list', 'children': ['214']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'norm_bit'}; {'id': '215', 'type': 'if_statement', 'children': ['216', '219', '287']}; {'id': '216', 'type': 'comparison_operator', 'children': ['217', '218'], 'value': 'is'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'calc_threshold'}; {'id': '218', 'type': 'True', 'children': []}; {'id': '219', 'type': 'ERROR', 'children': ['220', '226', '235', '244', '253', '254', '256', '257', '262', '267', '269', '276', '277', '279']}; {'id': '220', 'type': 'expression_statement', 'children': ['221']}; {'id': '221', 'type': 'assignment', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'norms'}; {'id': '223', 'type': 'subscript', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '225', 'type': 'string', 'children': [], 'value': "'normalized bit score'"}; {'id': '226', 'type': 'expression_statement', 'children': ['227']}; {'id': '227', 'type': 'assignment', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'average'}; {'id': '229', 'type': 'call', 'children': ['230', '233']}; {'id': '230', 'type': 'attribute', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'numpy'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'average'}; {'id': '233', 'type': 'argument_list', 'children': ['234']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'norms'}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'assignment', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'std'}; {'id': '238', 'type': 'call', 'children': ['239', '242']}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'numpy'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'std'}; {'id': '242', 'type': 'argument_list', 'children': ['243']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'norms'}; {'id': '244', 'type': 'expression_statement', 'children': ['245']}; {'id': '245', 'type': 'assignment', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'normal_thresh'}; {'id': '247', 'type': 'binary_operator', 'children': ['248', '249'], 'value': '-'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'average'}; {'id': '249', 'type': '()', 'children': ['250']}; {'id': '250', 'type': 'binary_operator', 'children': ['251', '252'], 'value': '*'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'std'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'stdevs'}; {'id': '253', 'type': 'string', 'children': [], 'value': "'\n print('"}; {'id': '254', 'type': 'ERROR', 'children': ['255']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '256', 'type': 'ERROR', 'children': []}; {'id': '257', 'type': 'subscript', 'children': ['258', '261']}; {'id': '258', 'type': 'subscript', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '262', 'type': 'subscript', 'children': ['263', '266']}; {'id': '263', 'type': 'subscript', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'compare'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'genome'}; {'id': '267', 'type': 'ERROR', 'children': ['268']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'normal_thresh'}; {'id': '269', 'type': 'ERROR', 'children': ['270']}; {'id': '270', 'type': 'comparison_operator', 'children': ['271', '272', '275'], 'value': 'in'}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'normal_thresh'}; {'id': '272', 'type': 'ERROR', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'for'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'score'}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '277', 'type': 'ERROR', 'children': ['278']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'if'}; {'id': '279', 'type': 'comparison_operator', 'children': ['280', '286'], 'value': '>'}; {'id': '280', 'type': 'call', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '282', 'type': 'argument_list', 'children': ['283']}; {'id': '283', 'type': 'subscript', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'scores'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'score'}; {'id': '286', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '287', 'type': 'block', 'children': ['288']}; {'id': '288', 'type': 'expression_statement', 'children': ['289']}; {'id': '289', 'type': 'call', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '291', 'type': 'argument_list', 'children': ['292', '295']}; {'id': '292', 'type': 'concatenated_string', 'children': ['293', '294']}; {'id': '293', 'type': 'string', 'children': [], 'value': "'\n print('"}; {'id': '294', 'type': 'string', 'children': [], 'value': "'"}; {'id': '295', 'type': 'keyword_argument', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '297', 'type': 'identifier', 'children': [], 'value': 'out'}; {'id': '298', 'type': 'expression_statement', 'children': ['299']}; {'id': '299', 'type': 'call', 'children': ['300', '303']}; {'id': '300', 'type': 'attribute', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'out'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '303', 'type': 'argument_list', 'children': []}; {'id': '304', 'type': 'if_statement', 'children': ['305', '308', '320']}; {'id': '305', 'type': 'comparison_operator', 'children': ['306', '307'], 'value': 'is'}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'calc_threshold'}; {'id': '307', 'type': 'True', 'children': []}; {'id': '308', 'type': 'block', 'children': ['309']}; {'id': '309', 'type': 'return_statement', 'children': ['310']}; {'id': '310', 'type': 'binary_operator', 'children': ['311', '318'], 'value': '+'}; {'id': '311', 'type': 'subscript', 'children': ['312', '313']}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'thresholds'}; {'id': '313', 'type': 'slice', 'children': ['314', '315', '316']}; {'id': '314', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '315', 'type': 'colon', 'children': []}; {'id': '316', 'type': 'unary_operator', 'children': ['317'], 'value': '-'}; {'id': '317', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '318', 'type': 'list', 'children': ['319'], 'value': '[norm_threshold]'}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'norm_threshold'}; {'id': '320', 'type': 'else_clause', 'children': ['321']}; {'id': '321', 'type': 'block', 'children': ['322']}; {'id': '322', 'type': 'return_statement', 'children': ['323']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'thresholds'}
if thresholds are not specififed, calculate based on the distribution of normalized bit scores
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'validate_complex_list'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '6', 'type': 'default_parameter', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '8', 'type': 'None', 'children': []}; {'id': '9', 'type': 'block', 'children': ['10']}; {'id': '10', 'type': 'if_statement', 'children': ['11', '14']}; {'id': '11', 'type': 'comparison_operator', 'children': ['12', '13'], 'value': 'is'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '13', 'type': 'None', 'children': []}; {'id': '14', 'type': 'block', 'children': ['15', '24', '46']}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '18', 'type': 'argument_list', 'children': ['19', '20', '21']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '21', 'type': 'tuple', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '24', 'type': 'if_statement', 'children': ['25', '28', '35']}; {'id': '25', 'type': 'comparison_operator', 'children': ['26', '27'], 'value': 'in'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': '_complex_definitions'}; {'id': '28', 'type': 'block', 'children': ['29']}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '32', 'type': 'subscript', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': '_complex_definitions'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '35', 'type': 'else_clause', 'children': ['36']}; {'id': '36', 'type': 'block', 'children': ['37']}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'assignment', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '40', 'type': 'conditional_expression', 'children': ['41', '42', '45'], 'value': 'if'}; {'id': '41', 'type': 'dictionary', 'children': []}; {'id': '42', 'type': 'comparison_operator', 'children': ['43', '44'], 'value': 'is'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '44', 'type': 'None', 'children': []}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '46', 'type': 'for_statement', 'children': ['47', '50', '57']}; {'id': '47', 'type': 'pattern_list', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'complex_struct'}; {'id': '50', 'type': 'call', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '52', 'type': 'argument_list', 'children': ['53']}; {'id': '53', 'type': 'call', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'wrap_value'}; {'id': '55', 'type': 'argument_list', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '57', 'type': 'block', 'children': ['58', '71', '78']}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'assignment', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'cs_idx'}; {'id': '61', 'type': 'binary_operator', 'children': ['62', '70'], 'value': '+'}; {'id': '62', 'type': 'binary_operator', 'children': ['63', '66'], 'value': '+'}; {'id': '63', 'type': 'binary_operator', 'children': ['64', '65'], 'value': '+'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '65', 'type': 'string', 'children': [], 'value': "'['"}; {'id': '66', 'type': 'call', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '68', 'type': 'argument_list', 'children': ['69']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '70', 'type': 'string', 'children': [], 'value': "']'"}; {'id': '71', 'type': 'expression_statement', 'children': ['72']}; {'id': '72', 'type': 'call', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '74', 'type': 'argument_list', 'children': ['75', '76', '77']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'cs_idx'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'complex_struct'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '78', 'type': 'for_statement', 'children': ['79', '82', '86']}; {'id': '79', 'type': 'pattern_list', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'cs_prop'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'cs_val'}; {'id': '82', 'type': 'call', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'iteritems'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'complex_struct'}; {'id': '86', 'type': 'block', 'children': ['87', '98', '122']}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'cs_key'}; {'id': '90', 'type': 'call', 'children': ['91', '94']}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '94', 'type': 'argument_list', 'children': ['95']}; {'id': '95', 'type': 'tuple', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'cs_idx'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'cs_prop'}; {'id': '98', 'type': 'if_statement', 'children': ['99', '102']}; {'id': '99', 'type': 'comparison_operator', 'children': ['100', '101'], 'value': 'not'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'cs_prop'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '102', 'type': 'block', 'children': ['103']}; {'id': '103', 'type': 'expression_statement', 'children': ['104']}; {'id': '104', 'type': 'call', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '106', 'type': 'argument_list', 'children': ['107', '108', '109', '110']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '108', 'type': 'None', 'children': []}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '110', 'type': '()', 'children': ['111']}; {'id': '111', 'type': 'call', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'string', 'children': [], 'value': "'keys: {0}'"}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '115', 'type': 'argument_list', 'children': ['116']}; {'id': '116', 'type': 'call', 'children': ['117', '120']}; {'id': '117', 'type': 'attribute', 'children': ['118', '119']}; {'id': '118', 'type': 'string', 'children': [], 'value': "','"}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '120', 'type': 'argument_list', 'children': ['121']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '122', 'type': 'if_statement', 'children': ['123', '129', '139']}; {'id': '123', 'type': 'not_operator', 'children': ['124']}; {'id': '124', 'type': 'call', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '126', 'type': 'argument_list', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'cs_val'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '129', 'type': 'block', 'children': ['130']}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'call', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '133', 'type': 'argument_list', 'children': ['134', '135', '136']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'cs_key'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'cs_val'}; {'id': '136', 'type': 'tuple', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'string_types'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '139', 'type': 'else_clause', 'children': ['140']}; {'id': '140', 'type': 'block', 'children': ['141']}; {'id': '141', 'type': 'for_statement', 'children': ['142', '145', '149']}; {'id': '142', 'type': 'pattern_list', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'list_idx'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'list_val'}; {'id': '145', 'type': 'call', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '147', 'type': 'argument_list', 'children': ['148']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'cs_val'}; {'id': '149', 'type': 'block', 'children': ['150', '163']}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'assignment', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'list_prop'}; {'id': '153', 'type': 'binary_operator', 'children': ['154', '162'], 'value': '+'}; {'id': '154', 'type': 'binary_operator', 'children': ['155', '158'], 'value': '+'}; {'id': '155', 'type': 'binary_operator', 'children': ['156', '157'], 'value': '+'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'cs_key'}; {'id': '157', 'type': 'string', 'children': [], 'value': "'['"}; {'id': '158', 'type': 'call', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '160', 'type': 'argument_list', 'children': ['161']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'list_idx'}; {'id': '162', 'type': 'string', 'children': [], 'value': "']'"}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'call', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '166', 'type': 'argument_list', 'children': ['167', '168', '169']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'list_prop'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'list_val'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'string_types'}
Default validation for Attribute Details data structure
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'validate_dates'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '6', 'type': 'default_parameter', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '8', 'type': 'None', 'children': []}; {'id': '9', 'type': 'block', 'children': ['10']}; {'id': '10', 'type': 'if_statement', 'children': ['11', '14']}; {'id': '11', 'type': 'comparison_operator', 'children': ['12', '13'], 'value': 'is'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '13', 'type': 'None', 'children': []}; {'id': '14', 'type': 'block', 'children': ['15', '22', '29']}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '18', 'type': 'argument_list', 'children': ['19', '20', '21']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'date_keys'}; {'id': '25', 'type': 'call', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '27', 'type': 'argument_list', 'children': ['28']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '29', 'type': 'if_statement', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'date_keys'}; {'id': '31', 'type': 'block', 'children': ['32', '84', '90', '103', '109', '116', '123', '140', '157', '174', '191']}; {'id': '32', 'type': 'if_statement', 'children': ['33', '40']}; {'id': '33', 'type': 'boolean_operator', 'children': ['34', '37'], 'value': 'or'}; {'id': '34', 'type': 'comparison_operator', 'children': ['35', '36'], 'value': 'not'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'date_keys'}; {'id': '37', 'type': 'comparison_operator', 'children': ['38', '39'], 'value': 'not'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'DATE_VALUES'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'date_keys'}; {'id': '40', 'type': 'block', 'children': ['41', '65']}; {'id': '41', 'type': 'if_statement', 'children': ['42', '45', '52']}; {'id': '42', 'type': 'comparison_operator', 'children': ['43', '44'], 'value': 'in'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': '_complex_definitions'}; {'id': '45', 'type': 'block', 'children': ['46']}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'assignment', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '49', 'type': 'subscript', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': '_complex_definitions'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '52', 'type': 'else_clause', 'children': ['53']}; {'id': '53', 'type': 'block', 'children': ['54']}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'assignment', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '57', 'type': 'conditional_expression', 'children': ['58', '61', '64'], 'value': 'if'}; {'id': '58', 'type': 'subscript', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': '_complex_definitions'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'DATES'}; {'id': '61', 'type': 'comparison_operator', 'children': ['62', '63'], 'value': 'is'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '63', 'type': 'None', 'children': []}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'xpath_map'}; {'id': '65', 'type': 'expression_statement', 'children': ['66']}; {'id': '66', 'type': 'call', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '70', '71', '72']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '70', 'type': 'None', 'children': []}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '72', 'type': '()', 'children': ['73']}; {'id': '73', 'type': 'call', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'string', 'children': [], 'value': "'keys: {0}'"}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'call', 'children': ['79', '82']}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'string', 'children': [], 'value': "','"}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '82', 'type': 'argument_list', 'children': ['83']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'complex_keys'}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '87', 'type': 'subscript', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE'}; {'id': '90', 'type': 'if_statement', 'children': ['91', '94']}; {'id': '91', 'type': 'comparison_operator', 'children': ['92', '93'], 'value': 'not'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPES'}; {'id': '94', 'type': 'block', 'children': ['95']}; {'id': '95', 'type': 'expression_statement', 'children': ['96']}; {'id': '96', 'type': 'call', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '98', 'type': 'argument_list', 'children': ['99', '100', '101', '102']}; {'id': '99', 'type': 'string', 'children': [], 'value': "'dates.type'"}; {'id': '100', 'type': 'None', 'children': []}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPES'}; {'id': '103', 'type': 'expression_statement', 'children': ['104']}; {'id': '104', 'type': 'assignment', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'date_vals'}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'DATE_VALUES'}; {'id': '109', 'type': 'expression_statement', 'children': ['110']}; {'id': '110', 'type': 'call', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '112', 'type': 'argument_list', 'children': ['113', '114', '115']}; {'id': '113', 'type': 'string', 'children': [], 'value': "'dates.values'"}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'date_vals'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'assignment', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '119', 'type': 'call', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '121', 'type': 'argument_list', 'children': ['122']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'date_vals'}; {'id': '123', 'type': 'if_statement', 'children': ['124', '131']}; {'id': '124', 'type': 'boolean_operator', 'children': ['125', '128'], 'value': 'and'}; {'id': '125', 'type': 'comparison_operator', 'children': ['126', '127'], 'value': '=='}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE_MISSING'}; {'id': '128', 'type': 'comparison_operator', 'children': ['129', '130'], 'value': '!='}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '130', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '131', 'type': 'block', 'children': ['132']}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '135', 'type': 'argument_list', 'children': ['136', '137', '138', '139']}; {'id': '136', 'type': 'string', 'children': [], 'value': "'len(dates.values)'"}; {'id': '137', 'type': 'None', 'children': []}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '139', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '140', 'type': 'if_statement', 'children': ['141', '148']}; {'id': '141', 'type': 'boolean_operator', 'children': ['142', '145'], 'value': 'and'}; {'id': '142', 'type': 'comparison_operator', 'children': ['143', '144'], 'value': '=='}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE_SINGLE'}; {'id': '145', 'type': 'comparison_operator', 'children': ['146', '147'], 'value': '!='}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '147', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '148', 'type': 'block', 'children': ['149']}; {'id': '149', 'type': 'expression_statement', 'children': ['150']}; {'id': '150', 'type': 'call', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '152', 'type': 'argument_list', 'children': ['153', '154', '155', '156']}; {'id': '153', 'type': 'string', 'children': [], 'value': "'len(dates.values)'"}; {'id': '154', 'type': 'None', 'children': []}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '156', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '157', 'type': 'if_statement', 'children': ['158', '165']}; {'id': '158', 'type': 'boolean_operator', 'children': ['159', '162'], 'value': 'and'}; {'id': '159', 'type': 'comparison_operator', 'children': ['160', '161'], 'value': '=='}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE_RANGE'}; {'id': '162', 'type': 'comparison_operator', 'children': ['163', '164'], 'value': '!='}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '164', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '165', 'type': 'block', 'children': ['166']}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'call', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '169', 'type': 'argument_list', 'children': ['170', '171', '172', '173']}; {'id': '170', 'type': 'string', 'children': [], 'value': "'len(dates.values)'"}; {'id': '171', 'type': 'None', 'children': []}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '173', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '174', 'type': 'if_statement', 'children': ['175', '182']}; {'id': '175', 'type': 'boolean_operator', 'children': ['176', '179'], 'value': 'and'}; {'id': '176', 'type': 'comparison_operator', 'children': ['177', '178'], 'value': '=='}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'date_type'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'DATE_TYPE_MULTIPLE'}; {'id': '179', 'type': 'comparison_operator', 'children': ['180', '181'], 'value': '<'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '181', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '182', 'type': 'block', 'children': ['183']}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'call', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': '_validation_error'}; {'id': '186', 'type': 'argument_list', 'children': ['187', '188', '189', '190']}; {'id': '187', 'type': 'string', 'children': [], 'value': "'len(dates.values)'"}; {'id': '188', 'type': 'None', 'children': []}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'dates_len'}; {'id': '190', 'type': 'string', 'children': [], 'value': "'at least two'"}; {'id': '191', 'type': 'for_statement', 'children': ['192', '195', '199']}; {'id': '192', 'type': 'pattern_list', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'date'}; {'id': '195', 'type': 'call', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '197', 'type': 'argument_list', 'children': ['198']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'date_vals'}; {'id': '199', 'type': 'block', 'children': ['200', '211']}; {'id': '200', 'type': 'expression_statement', 'children': ['201']}; {'id': '201', 'type': 'assignment', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'date_key'}; {'id': '203', 'type': 'binary_operator', 'children': ['204', '210'], 'value': '+'}; {'id': '204', 'type': 'binary_operator', 'children': ['205', '206'], 'value': '+'}; {'id': '205', 'type': 'string', 'children': [], 'value': "'dates.value['"}; {'id': '206', 'type': 'call', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '210', 'type': 'string', 'children': [], 'value': "']'"}; {'id': '211', 'type': 'expression_statement', 'children': ['212']}; {'id': '212', 'type': 'call', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'validate_type'}; {'id': '214', 'type': 'argument_list', 'children': ['215', '216', '217']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'date_key'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'date'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'string_types'}
Default validation for Date Types data structure
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'getSequence'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '7', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '8', 'type': 'block', 'children': ['9', '11', '15', '19', '23', '27', '31', '344', '356', '371']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'string', 'children': [], 'value': "'''Get a sequence of nodes.'''"}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'assignment', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '14', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '18', 'type': 'string', 'children': [], 'value': "''"}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '22', 'type': 'None', 'children': []}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'right_operand'}; {'id': '26', 'type': 'None', 'children': []}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'sequence_closed'}; {'id': '30', 'type': 'False', 'children': []}; {'id': '31', 'type': 'while_statement', 'children': ['32', '33']}; {'id': '32', 'type': 'True', 'children': []}; {'id': '33', 'type': 'block', 'children': ['34', '42', '47', '240']}; {'id': '34', 'type': 'expression_statement', 'children': ['35']}; {'id': '35', 'type': 'assignment', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '37', 'type': 'call', 'children': ['38', '41']}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'next'}; {'id': '41', 'type': 'argument_list', 'children': []}; {'id': '42', 'type': 'if_statement', 'children': ['43', '45']}; {'id': '43', 'type': 'not_operator', 'children': ['44']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '45', 'type': 'block', 'children': ['46']}; {'id': '46', 'type': 'break_statement', 'children': []}; {'id': '47', 'type': 'if_statement', 'children': ['48', '55', '67', '93', '118', '146', '177', '195', '213']}; {'id': '48', 'type': 'boolean_operator', 'children': ['49', '50'], 'value': 'and'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '50', 'type': 'comparison_operator', 'children': ['51', '52'], 'value': 'not'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'meta_chars'}; {'id': '55', 'type': 'block', 'children': ['56']}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'call', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '61', 'type': 'argument_list', 'children': ['62']}; {'id': '62', 'type': 'call', 'children': ['63', '66']}; {'id': '63', 'type': 'attribute', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'getLiteral'}; {'id': '66', 'type': 'argument_list', 'children': []}; {'id': '67', 'type': 'elif_clause', 'children': ['68', '81']}; {'id': '68', 'type': 'boolean_operator', 'children': ['69', '74'], 'value': 'and'}; {'id': '69', 'type': 'boolean_operator', 'children': ['70', '71'], 'value': 'and'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '71', 'type': 'comparison_operator', 'children': ['72', '73'], 'value': '=='}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '73', 'type': 'string', 'children': [], 'value': "u'$'"}; {'id': '74', 'type': 'comparison_operator', 'children': ['75', '80'], 'value': '=='}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'lookahead'}; {'id': '79', 'type': 'argument_list', 'children': []}; {'id': '80', 'type': 'string', 'children': [], 'value': "u'{'"}; {'id': '81', 'type': 'block', 'children': ['82']}; {'id': '82', 'type': 'expression_statement', 'children': ['83']}; {'id': '83', 'type': 'call', 'children': ['84', '87']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '87', 'type': 'argument_list', 'children': ['88']}; {'id': '88', 'type': 'call', 'children': ['89', '92']}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'getSource'}; {'id': '92', 'type': 'argument_list', 'children': []}; {'id': '93', 'type': 'elif_clause', 'children': ['94', '106']}; {'id': '94', 'type': 'boolean_operator', 'children': ['95', '98'], 'value': 'and'}; {'id': '95', 'type': 'comparison_operator', 'children': ['96', '97'], 'value': '=='}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '97', 'type': 'string', 'children': [], 'value': "u'['"}; {'id': '98', 'type': 'not_operator', 'children': ['99']}; {'id': '99', 'type': 'comparison_operator', 'children': ['100', '105'], 'value': '=='}; {'id': '100', 'type': 'call', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '104', 'type': 'argument_list', 'children': []}; {'id': '105', 'type': 'string', 'children': [], 'value': "u'\\\\'"}; {'id': '106', 'type': 'block', 'children': ['107']}; {'id': '107', 'type': 'expression_statement', 'children': ['108']}; {'id': '108', 'type': 'call', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '112', 'type': 'argument_list', 'children': ['113']}; {'id': '113', 'type': 'call', 'children': ['114', '117']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'getCharacterSet'}; {'id': '117', 'type': 'argument_list', 'children': []}; {'id': '118', 'type': 'elif_clause', 'children': ['119', '131']}; {'id': '119', 'type': 'boolean_operator', 'children': ['120', '123'], 'value': 'and'}; {'id': '120', 'type': 'comparison_operator', 'children': ['121', '122'], 'value': '=='}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '122', 'type': 'string', 'children': [], 'value': "u'('"}; {'id': '123', 'type': 'not_operator', 'children': ['124']}; {'id': '124', 'type': 'comparison_operator', 'children': ['125', '130'], 'value': '=='}; {'id': '125', 'type': 'call', 'children': ['126', '129']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '129', 'type': 'argument_list', 'children': []}; {'id': '130', 'type': 'string', 'children': [], 'value': "u'\\\\'"}; {'id': '131', 'type': 'block', 'children': ['132']}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'call', 'children': ['134', '137']}; {'id': '134', 'type': 'attribute', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'getSequence'}; {'id': '142', 'type': 'argument_list', 'children': ['143']}; {'id': '143', 'type': 'binary_operator', 'children': ['144', '145'], 'value': '+'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '145', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '146', 'type': 'elif_clause', 'children': ['147', '159']}; {'id': '147', 'type': 'boolean_operator', 'children': ['148', '151'], 'value': 'and'}; {'id': '148', 'type': 'comparison_operator', 'children': ['149', '150'], 'value': '=='}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '150', 'type': 'string', 'children': [], 'value': "u')'"}; {'id': '151', 'type': 'not_operator', 'children': ['152']}; {'id': '152', 'type': 'comparison_operator', 'children': ['153', '158'], 'value': '=='}; {'id': '153', 'type': 'call', 'children': ['154', '157']}; {'id': '154', 'type': 'attribute', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '157', 'type': 'argument_list', 'children': []}; {'id': '158', 'type': 'string', 'children': [], 'value': "u'\\\\'"}; {'id': '159', 'type': 'block', 'children': ['160', '172', '176']}; {'id': '160', 'type': 'if_statement', 'children': ['161', '164']}; {'id': '161', 'type': 'comparison_operator', 'children': ['162', '163'], 'value': '=='}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '163', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '164', 'type': 'block', 'children': ['165']}; {'id': '165', 'type': 'raise_statement', 'children': ['166']}; {'id': '166', 'type': 'call', 'children': ['167', '170']}; {'id': '167', 'type': 'attribute', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '170', 'type': 'argument_list', 'children': ['171']}; {'id': '171', 'type': 'string', 'children': [], 'value': 'u"Extra closing parenthesis"'}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'assignment', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'sequence_closed'}; {'id': '175', 'type': 'True', 'children': []}; {'id': '176', 'type': 'break_statement', 'children': []}; {'id': '177', 'type': 'elif_clause', 'children': ['178', '190']}; {'id': '178', 'type': 'boolean_operator', 'children': ['179', '182'], 'value': 'and'}; {'id': '179', 'type': 'comparison_operator', 'children': ['180', '181'], 'value': '=='}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '181', 'type': 'string', 'children': [], 'value': "u'|'"}; {'id': '182', 'type': 'not_operator', 'children': ['183']}; {'id': '183', 'type': 'comparison_operator', 'children': ['184', '189'], 'value': '=='}; {'id': '184', 'type': 'call', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '188', 'type': 'argument_list', 'children': []}; {'id': '189', 'type': 'string', 'children': [], 'value': "u'\\\\'"}; {'id': '190', 'type': 'block', 'children': ['191']}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '195', 'type': 'elif_clause', 'children': ['196', '208']}; {'id': '196', 'type': 'boolean_operator', 'children': ['197', '200'], 'value': 'and'}; {'id': '197', 'type': 'comparison_operator', 'children': ['198', '199'], 'value': '=='}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '199', 'type': 'string', 'children': [], 'value': "u'&'"}; {'id': '200', 'type': 'not_operator', 'children': ['201']}; {'id': '201', 'type': 'comparison_operator', 'children': ['202', '207'], 'value': '=='}; {'id': '202', 'type': 'call', 'children': ['203', '206']}; {'id': '203', 'type': 'attribute', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '206', 'type': 'argument_list', 'children': []}; {'id': '207', 'type': 'string', 'children': [], 'value': "u'\\\\'"}; {'id': '208', 'type': 'block', 'children': ['209']}; {'id': '209', 'type': 'expression_statement', 'children': ['210']}; {'id': '210', 'type': 'assignment', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '213', 'type': 'else_clause', 'children': ['214']}; {'id': '214', 'type': 'block', 'children': ['215']}; {'id': '215', 'type': 'if_statement', 'children': ['216', '230']}; {'id': '216', 'type': 'boolean_operator', 'children': ['217', '222'], 'value': 'and'}; {'id': '217', 'type': 'comparison_operator', 'children': ['218', '219'], 'value': 'in'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'meta_chars'}; {'id': '222', 'type': 'not_operator', 'children': ['223']}; {'id': '223', 'type': 'comparison_operator', 'children': ['224', '229'], 'value': '=='}; {'id': '224', 'type': 'call', 'children': ['225', '228']}; {'id': '225', 'type': 'attribute', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'last'}; {'id': '228', 'type': 'argument_list', 'children': []}; {'id': '229', 'type': 'string', 'children': [], 'value': 'u"\\\\"'}; {'id': '230', 'type': 'block', 'children': ['231']}; {'id': '231', 'type': 'raise_statement', 'children': ['232']}; {'id': '232', 'type': 'call', 'children': ['233', '236']}; {'id': '233', 'type': 'attribute', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'binary_operator', 'children': ['238', '239'], 'value': '%'}; {'id': '238', 'type': 'string', 'children': [], 'value': 'u"Un-escaped special character: %s"'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '240', 'type': 'if_statement', 'children': ['241', '245', '274']}; {'id': '241', 'type': 'boolean_operator', 'children': ['242', '243'], 'value': 'and'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '243', 'type': 'not_operator', 'children': ['244']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '245', 'type': 'block', 'children': ['246', '266']}; {'id': '246', 'type': 'if_statement', 'children': ['247', '256']}; {'id': '247', 'type': 'boolean_operator', 'children': ['248', '250'], 'value': 'or'}; {'id': '248', 'type': 'not_operator', 'children': ['249']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '250', 'type': 'comparison_operator', 'children': ['251', '255'], 'value': '<'}; {'id': '251', 'type': 'call', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '255', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '256', 'type': 'block', 'children': ['257']}; {'id': '257', 'type': 'raise_statement', 'children': ['258']}; {'id': '258', 'type': 'call', 'children': ['259', '262']}; {'id': '259', 'type': 'attribute', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '262', 'type': 'argument_list', 'children': ['263']}; {'id': '263', 'type': 'binary_operator', 'children': ['264', '265'], 'value': '%'}; {'id': '264', 'type': 'string', 'children': [], 'value': 'u"Operator: %s with no left operand"'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '266', 'type': 'expression_statement', 'children': ['267']}; {'id': '267', 'type': 'assignment', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '269', 'type': 'call', 'children': ['270', '273']}; {'id': '270', 'type': 'attribute', 'children': ['271', '272']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '273', 'type': 'argument_list', 'children': []}; {'id': '274', 'type': 'elif_clause', 'children': ['275', '285']}; {'id': '275', 'type': 'boolean_operator', 'children': ['276', '284'], 'value': 'and'}; {'id': '276', 'type': 'boolean_operator', 'children': ['277', '278'], 'value': 'and'}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '278', 'type': 'comparison_operator', 'children': ['279', '283'], 'value': '>='}; {'id': '279', 'type': 'call', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '281', 'type': 'argument_list', 'children': ['282']}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '283', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '285', 'type': 'block', 'children': ['286', '294', '332', '336', '340']}; {'id': '286', 'type': 'expression_statement', 'children': ['287']}; {'id': '287', 'type': 'assignment', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'right_operand'}; {'id': '289', 'type': 'call', 'children': ['290', '293']}; {'id': '290', 'type': 'attribute', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '293', 'type': 'argument_list', 'children': []}; {'id': '294', 'type': 'if_statement', 'children': ['295', '298', '313']}; {'id': '295', 'type': 'comparison_operator', 'children': ['296', '297'], 'value': '=='}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '297', 'type': 'string', 'children': [], 'value': "u'|'"}; {'id': '298', 'type': 'block', 'children': ['299']}; {'id': '299', 'type': 'expression_statement', 'children': ['300']}; {'id': '300', 'type': 'call', 'children': ['301', '304']}; {'id': '301', 'type': 'attribute', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '304', 'type': 'argument_list', 'children': ['305']}; {'id': '305', 'type': 'call', 'children': ['306', '309']}; {'id': '306', 'type': 'attribute', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'SequenceOR'}; {'id': '309', 'type': 'argument_list', 'children': ['310']}; {'id': '310', 'type': 'list', 'children': ['311', '312'], 'value': '[left_operand, right_operand]'}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'right_operand'}; {'id': '313', 'type': 'elif_clause', 'children': ['314', '317']}; {'id': '314', 'type': 'comparison_operator', 'children': ['315', '316'], 'value': '=='}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '316', 'type': 'string', 'children': [], 'value': "u'&'"}; {'id': '317', 'type': 'block', 'children': ['318']}; {'id': '318', 'type': 'expression_statement', 'children': ['319']}; {'id': '319', 'type': 'call', 'children': ['320', '323']}; {'id': '320', 'type': 'attribute', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '323', 'type': 'argument_list', 'children': ['324']}; {'id': '324', 'type': 'call', 'children': ['325', '328']}; {'id': '325', 'type': 'attribute', 'children': ['326', '327']}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'SequenceAND'}; {'id': '328', 'type': 'argument_list', 'children': ['329']}; {'id': '329', 'type': 'list', 'children': ['330', '331'], 'value': '[left_operand, right_operand]'}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '331', 'type': 'identifier', 'children': [], 'value': 'right_operand'}; {'id': '332', 'type': 'expression_statement', 'children': ['333']}; {'id': '333', 'type': 'assignment', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '335', 'type': 'string', 'children': [], 'value': "u''"}; {'id': '336', 'type': 'expression_statement', 'children': ['337']}; {'id': '337', 'type': 'assignment', 'children': ['338', '339']}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'left_operand'}; {'id': '339', 'type': 'None', 'children': []}; {'id': '340', 'type': 'expression_statement', 'children': ['341']}; {'id': '341', 'type': 'assignment', 'children': ['342', '343']}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'right_operand'}; {'id': '343', 'type': 'None', 'children': []}; {'id': '344', 'type': 'if_statement', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '346', 'type': 'block', 'children': ['347']}; {'id': '347', 'type': 'raise_statement', 'children': ['348']}; {'id': '348', 'type': 'call', 'children': ['349', '352']}; {'id': '349', 'type': 'attribute', 'children': ['350', '351']}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '351', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '352', 'type': 'argument_list', 'children': ['353']}; {'id': '353', 'type': 'binary_operator', 'children': ['354', '355'], 'value': '%'}; {'id': '354', 'type': 'string', 'children': [], 'value': 'u"Operator: %s with no right operand"'}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'op'}; {'id': '356', 'type': 'if_statement', 'children': ['357', '363']}; {'id': '357', 'type': 'boolean_operator', 'children': ['358', '361'], 'value': 'and'}; {'id': '358', 'type': 'comparison_operator', 'children': ['359', '360'], 'value': '>'}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '360', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '361', 'type': 'not_operator', 'children': ['362']}; {'id': '362', 'type': 'identifier', 'children': [], 'value': 'sequence_closed'}; {'id': '363', 'type': 'block', 'children': ['364']}; {'id': '364', 'type': 'raise_statement', 'children': ['365']}; {'id': '365', 'type': 'call', 'children': ['366', '369']}; {'id': '366', 'type': 'attribute', 'children': ['367', '368']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '369', 'type': 'argument_list', 'children': ['370']}; {'id': '370', 'type': 'string', 'children': [], 'value': 'u"Missing closing parenthesis"'}; {'id': '371', 'type': 'return_statement', 'children': ['372']}; {'id': '372', 'type': 'call', 'children': ['373', '376']}; {'id': '373', 'type': 'attribute', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'StringGenerator'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'Sequence'}; {'id': '376', 'type': 'argument_list', 'children': ['377']}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'seq'}
Get a sequence of nodes.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'process'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '8', 'type': 'block', 'children': ['9', '15', '23', '30', '38', '42', '129', '138', '147']}; {'id': '9', 'type': 'if_statement', 'children': ['10', '13']}; {'id': '10', 'type': 'comparison_operator', 'children': ['11', '12'], 'value': 'in'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '13', 'type': 'block', 'children': ['14']}; {'id': '14', 'type': 'return_statement', 'children': []}; {'id': '15', 'type': 'if_statement', 'children': ['16', '21']}; {'id': '16', 'type': 'call', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'enum'}; {'id': '20', 'type': 'argument_list', 'children': []}; {'id': '21', 'type': 'block', 'children': ['22']}; {'id': '22', 'type': 'return_statement', 'children': []}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'call', 'children': ['25', '28']}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '28', 'type': 'argument_list', 'children': ['29']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'resolve'}; {'id': '37', 'type': 'argument_list', 'children': []}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '41', 'type': 'None', 'children': []}; {'id': '42', 'type': 'if_statement', 'children': ['43', '48', '53']}; {'id': '43', 'type': 'call', 'children': ['44', '47']}; {'id': '44', 'type': 'attribute', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'multi_occurrence'}; {'id': '47', 'type': 'argument_list', 'children': []}; {'id': '48', 'type': 'block', 'children': ['49']}; {'id': '49', 'type': 'expression_statement', 'children': ['50']}; {'id': '50', 'type': 'assignment', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '52', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '53', 'type': 'else_clause', 'children': ['54']}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'if_statement', 'children': ['56', '62']}; {'id': '56', 'type': 'comparison_operator', 'children': ['57', '61'], 'value': '>'}; {'id': '57', 'type': 'call', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '59', 'type': 'argument_list', 'children': ['60']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '61', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '62', 'type': 'block', 'children': ['63']}; {'id': '63', 'type': 'if_statement', 'children': ['64', '69', '93']}; {'id': '64', 'type': 'call', 'children': ['65', '68']}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'mixed'}; {'id': '68', 'type': 'argument_list', 'children': []}; {'id': '69', 'type': 'block', 'children': ['70', '81', '87']}; {'id': '70', 'type': 'expression_statement', 'children': ['71']}; {'id': '71', 'type': 'assignment', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '73', 'type': 'call', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'Factory'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'property'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '81', 'type': 'expression_statement', 'children': ['82']}; {'id': '82', 'type': 'assignment', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'md'}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': '__metadata__'}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '92']}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'md'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'sxtype'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '93', 'type': 'else_clause', 'children': ['94']}; {'id': '94', 'type': 'block', 'children': ['95', '106', '112', '118']}; {'id': '95', 'type': 'expression_statement', 'children': ['96']}; {'id': '96', 'type': 'assignment', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '98', 'type': 'call', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'Factory'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'object'}; {'id': '102', 'type': 'argument_list', 'children': ['103']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '106', 'type': 'expression_statement', 'children': ['107']}; {'id': '107', 'type': 'assignment', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'md'}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': '__metadata__'}; {'id': '112', 'type': 'expression_statement', 'children': ['113']}; {'id': '113', 'type': 'assignment', 'children': ['114', '117']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'md'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'sxtype'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'assignment', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'md'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'ordering'}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'ordering'}; {'id': '127', 'type': 'argument_list', 'children': ['128']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '129', 'type': 'expression_statement', 'children': ['130']}; {'id': '130', 'type': 'call', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'setattr'}; {'id': '132', 'type': 'argument_list', 'children': ['133', '134', '137']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '134', 'type': 'attribute', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '138', 'type': 'if_statement', 'children': ['139', '142']}; {'id': '139', 'type': 'comparison_operator', 'children': ['140', '141'], 'value': 'is'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '141', 'type': 'None', 'children': []}; {'id': '142', 'type': 'block', 'children': ['143']}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '147', 'type': 'if_statement', 'children': ['148', '154']}; {'id': '148', 'type': 'not_operator', 'children': ['149']}; {'id': '149', 'type': 'call', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '151', 'type': 'argument_list', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '154', 'type': 'block', 'children': ['155', '163']}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'call', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'add_attributes'}; {'id': '160', 'type': 'argument_list', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '163', 'type': 'for_statement', 'children': ['164', '167', '172']}; {'id': '164', 'type': 'pattern_list', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'ancestry'}; {'id': '167', 'type': 'call', 'children': ['168', '171']}; {'id': '168', 'type': 'attribute', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'resolved'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '171', 'type': 'argument_list', 'children': []}; {'id': '172', 'type': 'block', 'children': ['173', '183']}; {'id': '173', 'type': 'if_statement', 'children': ['174', '181']}; {'id': '174', 'type': 'call', 'children': ['175', '178']}; {'id': '175', 'type': 'attribute', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'skip_child'}; {'id': '178', 'type': 'argument_list', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'ancestry'}; {'id': '181', 'type': 'block', 'children': ['182']}; {'id': '182', 'type': 'continue_statement', 'children': []}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'call', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'process'}; {'id': '188', 'type': 'argument_list', 'children': ['189', '190', '191']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '191', 'type': 'subscript', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '193', 'type': 'slice', 'children': ['194']}; {'id': '194', 'type': 'colon', 'children': []}
process the specified type then process its children
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_process_tz'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '8', 'type': 'block', 'children': ['9', '98', '105', '112', '149', '155', '203']}; {'id': '9', 'type': 'function_definition', 'children': ['10', '11', '13']}; {'id': '10', 'type': 'function_name', 'children': [], 'value': '_tz'}; {'id': '11', 'type': 'parameters', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '13', 'type': 'block', 'children': ['14', '23', '43', '74', '96']}; {'id': '14', 'type': 'if_statement', 'children': ['15', '20']}; {'id': '15', 'type': 'comparison_operator', 'children': ['16', '17'], 'value': 'in'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '17', 'type': 'tuple', 'children': ['18', '19']}; {'id': '18', 'type': 'None', 'children': []}; {'id': '19', 'type': 'string', 'children': [], 'value': "'naive'"}; {'id': '20', 'type': 'block', 'children': ['21']}; {'id': '21', 'type': 'return_statement', 'children': ['22']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '23', 'type': 'if_statement', 'children': ['24', '27']}; {'id': '24', 'type': 'comparison_operator', 'children': ['25', '26'], 'value': '=='}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '26', 'type': 'string', 'children': [], 'value': "'local'"}; {'id': '27', 'type': 'block', 'children': ['28', '39']}; {'id': '28', 'type': 'if_statement', 'children': ['29', '33']}; {'id': '29', 'type': 'boolean_operator', 'children': ['30', '31'], 'value': 'and'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': '__debug__'}; {'id': '31', 'type': 'not_operator', 'children': ['32']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'localtz'}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'raise_statement', 'children': ['35']}; {'id': '35', 'type': 'call', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '37', 'type': 'argument_list', 'children': ['38']}; {'id': '38', 'type': 'string', 'children': [], 'value': '"Requested conversion to local timezone, but `localtz` not installed."'}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'localtz'}; {'id': '43', 'type': 'if_statement', 'children': ['44', '50']}; {'id': '44', 'type': 'not_operator', 'children': ['45']}; {'id': '45', 'type': 'call', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '47', 'type': 'argument_list', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '50', 'type': 'block', 'children': ['51', '67']}; {'id': '51', 'type': 'if_statement', 'children': ['52', '56']}; {'id': '52', 'type': 'boolean_operator', 'children': ['53', '54'], 'value': 'and'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': '__debug__'}; {'id': '54', 'type': 'not_operator', 'children': ['55']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'localtz'}; {'id': '56', 'type': 'block', 'children': ['57']}; {'id': '57', 'type': 'raise_statement', 'children': ['58']}; {'id': '58', 'type': 'call', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '60', 'type': 'argument_list', 'children': ['61']}; {'id': '61', 'type': 'binary_operator', 'children': ['62', '63'], 'value': '+'}; {'id': '62', 'type': 'string', 'children': [], 'value': '"The `pytz` package must be installed to look up timezone: "'}; {'id': '63', 'type': 'call', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'repr'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '67', 'type': 'expression_statement', 'children': ['68']}; {'id': '68', 'type': 'assignment', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '70', 'type': 'call', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'get_tz'}; {'id': '72', 'type': 'argument_list', 'children': ['73']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '74', 'type': 'if_statement', 'children': ['75', '83']}; {'id': '75', 'type': 'boolean_operator', 'children': ['76', '82'], 'value': 'and'}; {'id': '76', 'type': 'not_operator', 'children': ['77']}; {'id': '77', 'type': 'call', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '79', 'type': 'argument_list', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '81', 'type': 'string', 'children': [], 'value': "'normalize'"}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'get_tz'}; {'id': '83', 'type': 'block', 'children': ['84']}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '87', 'type': 'call', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'get_tz'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'call', 'children': ['91', '94']}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'tzname'}; {'id': '94', 'type': 'argument_list', 'children': ['95']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '96', 'type': 'return_statement', 'children': ['97']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'assignment', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '101', 'type': 'call', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': '_tz'}; {'id': '103', 'type': 'argument_list', 'children': ['104']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '108', 'type': 'call', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': '_tz'}; {'id': '110', 'type': 'argument_list', 'children': ['111']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '112', 'type': 'if_statement', 'children': ['113', '119']}; {'id': '113', 'type': 'boolean_operator', 'children': ['114', '118'], 'value': 'and'}; {'id': '114', 'type': 'not_operator', 'children': ['115']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '119', 'type': 'block', 'children': ['120']}; {'id': '120', 'type': 'if_statement', 'children': ['121', '126', '136']}; {'id': '121', 'type': 'call', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '123', 'type': 'argument_list', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '125', 'type': 'string', 'children': [], 'value': "'localize'"}; {'id': '126', 'type': 'block', 'children': ['127']}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '130', 'type': 'call', 'children': ['131', '134']}; {'id': '131', 'type': 'attribute', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'localize'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '136', 'type': 'else_clause', 'children': ['137']}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'assignment', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '141', 'type': 'call', 'children': ['142', '145']}; {'id': '142', 'type': 'attribute', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '145', 'type': 'argument_list', 'children': ['146']}; {'id': '146', 'type': 'keyword_argument', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'naive'}; {'id': '149', 'type': 'if_statement', 'children': ['150', '152']}; {'id': '150', 'type': 'not_operator', 'children': ['151']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '152', 'type': 'block', 'children': ['153']}; {'id': '153', 'type': 'return_statement', 'children': ['154']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '155', 'type': 'if_statement', 'children': ['156', '161', '176', '192']}; {'id': '156', 'type': 'call', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '158', 'type': 'argument_list', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '160', 'type': 'string', 'children': [], 'value': "'normalize'"}; {'id': '161', 'type': 'block', 'children': ['162']}; {'id': '162', 'type': 'expression_statement', 'children': ['163']}; {'id': '163', 'type': 'assignment', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '165', 'type': 'call', 'children': ['166', '169']}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'normalize'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'call', 'children': ['171', '174']}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'astimezone'}; {'id': '174', 'type': 'argument_list', 'children': ['175']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '176', 'type': 'elif_clause', 'children': ['177', '180']}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '179'], 'value': '=='}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '179', 'type': 'string', 'children': [], 'value': "'naive'"}; {'id': '180', 'type': 'block', 'children': ['181']}; {'id': '181', 'type': 'expression_statement', 'children': ['182']}; {'id': '182', 'type': 'assignment', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '184', 'type': 'call', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '188', 'type': 'argument_list', 'children': ['189']}; {'id': '189', 'type': 'keyword_argument', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '191', 'type': 'None', 'children': []}; {'id': '192', 'type': 'else_clause', 'children': ['193']}; {'id': '193', 'type': 'block', 'children': ['194']}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'assignment', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '197', 'type': 'call', 'children': ['198', '201']}; {'id': '198', 'type': 'attribute', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'astimezone'}; {'id': '201', 'type': 'argument_list', 'children': ['202']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '203', 'type': 'return_statement', 'children': ['204']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'dt'}
Process timezone casting and conversion.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'cut_levels'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'nodes'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'start_level'}; {'id': '6', 'type': 'block', 'children': ['7', '11', '15', '146', '162']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'final'}; {'id': '10', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'assignment', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '14', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '15', 'type': 'for_statement', 'children': ['16', '17', '18']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'nodes'}; {'id': '18', 'type': 'block', 'children': ['19', '34', '52', '112']}; {'id': '19', 'type': 'if_statement', 'children': ['20', '26']}; {'id': '20', 'type': 'not_operator', 'children': ['21']}; {'id': '21', 'type': 'call', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '23', 'type': 'argument_list', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '25', 'type': 'string', 'children': [], 'value': "'level'"}; {'id': '26', 'type': 'block', 'children': ['27', '33']}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'call', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '30', 'type': 'argument_list', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '33', 'type': 'continue_statement', 'children': []}; {'id': '34', 'type': 'if_statement', 'children': ['35', '44']}; {'id': '35', 'type': 'call', 'children': ['36', '41']}; {'id': '36', 'type': 'attribute', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '41', 'type': 'argument_list', 'children': ['42', '43']}; {'id': '42', 'type': 'string', 'children': [], 'value': "'soft_root'"}; {'id': '43', 'type': 'False', 'children': []}; {'id': '44', 'type': 'block', 'children': ['45', '51']}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'call', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '48', 'type': 'argument_list', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '51', 'type': 'continue_statement', 'children': []}; {'id': '52', 'type': 'if_statement', 'children': ['53', '58', '89', '104']}; {'id': '53', 'type': 'comparison_operator', 'children': ['54', '57'], 'value': '=='}; {'id': '54', 'type': 'attribute', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'start_level'}; {'id': '58', 'type': 'block', 'children': ['59', '66', '72']}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'call', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'final'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '64', 'type': 'argument_list', 'children': ['65']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'assignment', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '71', 'type': 'None', 'children': []}; {'id': '72', 'type': 'if_statement', 'children': ['73', '82']}; {'id': '73', 'type': 'boolean_operator', 'children': ['74', '78'], 'value': 'and'}; {'id': '74', 'type': 'not_operator', 'children': ['75']}; {'id': '75', 'type': 'attribute', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'visible'}; {'id': '78', 'type': 'not_operator', 'children': ['79']}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '82', 'type': 'block', 'children': ['83']}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'call', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '86', 'type': 'argument_list', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '89', 'type': 'elif_clause', 'children': ['90', '97']}; {'id': '90', 'type': 'comparison_operator', 'children': ['91', '94'], 'value': '=='}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '94', 'type': 'binary_operator', 'children': ['95', '96'], 'value': '+'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'start_level'}; {'id': '96', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '97', 'type': 'block', 'children': ['98']}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'assignment', 'children': ['100', '103']}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '103', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '104', 'type': 'else_clause', 'children': ['105']}; {'id': '105', 'type': 'block', 'children': ['106']}; {'id': '106', 'type': 'expression_statement', 'children': ['107']}; {'id': '107', 'type': 'call', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '109', 'type': 'argument_list', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '112', 'type': 'if_statement', 'children': ['113', '117']}; {'id': '113', 'type': 'not_operator', 'children': ['114']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'visible'}; {'id': '117', 'type': 'block', 'children': ['118', '122', '136']}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'assignment', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'keep_node'}; {'id': '121', 'type': 'False', 'children': []}; {'id': '122', 'type': 'for_statement', 'children': ['123', '124', '127']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '127', 'type': 'block', 'children': ['128']}; {'id': '128', 'type': 'expression_statement', 'children': ['129']}; {'id': '129', 'type': 'assignment', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'keep_node'}; {'id': '131', 'type': 'boolean_operator', 'children': ['132', '133'], 'value': 'or'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'keep_node'}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'visible'}; {'id': '136', 'type': 'if_statement', 'children': ['137', '139']}; {'id': '137', 'type': 'not_operator', 'children': ['138']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'keep_node'}; {'id': '139', 'type': 'block', 'children': ['140']}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'call', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '143', 'type': 'argument_list', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '146', 'type': 'for_statement', 'children': ['147', '148', '149']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'removed'}; {'id': '149', 'type': 'block', 'children': ['150']}; {'id': '150', 'type': 'if_statement', 'children': ['151', '154']}; {'id': '151', 'type': 'comparison_operator', 'children': ['152', '153'], 'value': 'in'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'final'}; {'id': '154', 'type': 'block', 'children': ['155']}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'call', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'final'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '160', 'type': 'argument_list', 'children': ['161']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '162', 'type': 'return_statement', 'children': ['163']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'final'}
cutting nodes away from menus
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'S'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'Document'}; {'id': '5', 'type': 'list_splat_pattern', 'children': ['6']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'fields'}; {'id': '7', 'type': 'block', 'children': ['8', '12', '115']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '11', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '12', 'type': 'for_statement', 'children': ['13', '14', '15']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'fields'}; {'id': '15', 'type': 'block', 'children': ['16', '39', '43', '62', '73', '90', '101']}; {'id': '16', 'type': 'if_statement', 'children': ['17', '22']}; {'id': '17', 'type': 'call', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '19', 'type': 'argument_list', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'tuple'}; {'id': '22', 'type': 'block', 'children': ['23', '29', '38']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '28']}; {'id': '25', 'type': 'pattern_list', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'direction'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'call', 'children': ['31', '34']}; {'id': '31', 'type': 'attribute', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '34', 'type': 'argument_list', 'children': ['35']}; {'id': '35', 'type': 'tuple', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'direction'}; {'id': '38', 'type': 'continue_statement', 'children': []}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'direction'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'ASCENDING'}; {'id': '43', 'type': 'if_statement', 'children': ['44', '51']}; {'id': '44', 'type': 'not_operator', 'children': ['45']}; {'id': '45', 'type': 'call', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '49', 'type': 'argument_list', 'children': ['50']}; {'id': '50', 'type': 'string', 'children': [], 'value': "'__'"}; {'id': '51', 'type': 'block', 'children': ['52']}; {'id': '52', 'type': 'expression_statement', 'children': ['53']}; {'id': '53', 'type': 'assignment', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '55', 'type': 'call', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '59', 'type': 'argument_list', 'children': ['60', '61']}; {'id': '60', 'type': 'string', 'children': [], 'value': "'__'"}; {'id': '61', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '62', 'type': 'if_statement', 'children': ['63', '68']}; {'id': '63', 'type': 'comparison_operator', 'children': ['64', '67'], 'value': '=='}; {'id': '64', 'type': 'subscript', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '66', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '67', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '68', 'type': 'block', 'children': ['69']}; {'id': '69', 'type': 'expression_statement', 'children': ['70']}; {'id': '70', 'type': 'assignment', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'direction'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'DESCENDING'}; {'id': '73', 'type': 'if_statement', 'children': ['74', '81']}; {'id': '74', 'type': 'comparison_operator', 'children': ['75', '78'], 'value': 'in'}; {'id': '75', 'type': 'subscript', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '77', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '78', 'type': 'tuple', 'children': ['79', '80']}; {'id': '79', 'type': 'string', 'children': [], 'value': "'+'"}; {'id': '80', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '81', 'type': 'block', 'children': ['82']}; {'id': '82', 'type': 'expression_statement', 'children': ['83']}; {'id': '83', 'type': 'assignment', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '85', 'type': 'subscript', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '87', 'type': 'slice', 'children': ['88', '89']}; {'id': '88', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '89', 'type': 'colon', 'children': []}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'assignment', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': '_field'}; {'id': '93', 'type': 'call', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'traverse'}; {'id': '95', 'type': 'argument_list', 'children': ['96', '97', '98']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'Document'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '98', 'type': 'keyword_argument', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '100', 'type': 'None', 'children': []}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'call', 'children': ['103', '106']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '106', 'type': 'argument_list', 'children': ['107']}; {'id': '107', 'type': 'tuple', 'children': ['108', '114']}; {'id': '108', 'type': 'conditional_expression', 'children': ['109', '112', '113'], 'value': 'if'}; {'id': '109', 'type': '()', 'children': ['110']}; {'id': '110', 'type': 'unary_operator', 'children': ['111'], 'value': '~'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': '_field'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': '_field'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'field'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'direction'}; {'id': '115', 'type': 'return_statement', 'children': ['116']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'result'}
Generate a MongoDB sort order list using the Django ORM style.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '13']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'run_experiment'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '10']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'roleouts'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '7', 'type': 'default_parameter', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'in_cloud'}; {'id': '9', 'type': 'False', 'children': []}; {'id': '10', 'type': 'default_parameter', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'dynProfile'}; {'id': '12', 'type': 'None', 'children': []}; {'id': '13', 'type': 'block', 'children': ['14', '396', '441']}; {'id': '14', 'type': 'function_definition', 'children': ['15', '16', '17']}; {'id': '15', 'type': 'function_name', 'children': [], 'value': 'run'}; {'id': '16', 'type': 'parameters', 'children': []}; {'id': '17', 'type': 'block', 'children': ['18', '42', '51', '59', '68', '77', '86', '93', '391']}; {'id': '18', 'type': 'if_statement', 'children': ['19', '22', '32']}; {'id': '19', 'type': 'comparison_operator', 'children': ['20', '21'], 'value': 'is'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'dynProfile'}; {'id': '21', 'type': 'None', 'children': []}; {'id': '22', 'type': 'block', 'children': ['23']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'maxsteps'}; {'id': '26', 'type': 'call', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '28', 'type': 'argument_list', 'children': ['29']}; {'id': '29', 'type': 'attribute', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'profile'}; {'id': '32', 'type': 'else_clause', 'children': ['33']}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'expression_statement', 'children': ['35']}; {'id': '35', 'type': 'assignment', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'maxsteps'}; {'id': '37', 'type': 'subscript', 'children': ['38', '41']}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'dynProfile'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'shape'}; {'id': '41', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '42', 'type': 'expression_statement', 'children': ['43']}; {'id': '43', 'type': 'assignment', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'na'}; {'id': '45', 'type': 'call', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '47', 'type': 'argument_list', 'children': ['48']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'agents'}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'ni'}; {'id': '54', 'type': 'binary_operator', 'children': ['55', '58'], 'value': '*'}; {'id': '55', 'type': 'binary_operator', 'children': ['56', '57'], 'value': '*'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'roleouts'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'maxsteps'}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '62', 'type': 'call', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '64', 'type': 'argument_list', 'children': ['65']}; {'id': '65', 'type': 'tuple', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'na'}; {'id': '67', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '71', 'type': 'call', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '73', 'type': 'argument_list', 'children': ['74']}; {'id': '74', 'type': 'tuple', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'na'}; {'id': '76', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'assignment', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '80', 'type': 'call', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '82', 'type': 'argument_list', 'children': ['83']}; {'id': '83', 'type': 'tuple', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'na'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'ni'}; {'id': '86', 'type': 'expression_statement', 'children': ['87']}; {'id': '87', 'type': 'assignment', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'vmarkup'}; {'id': '89', 'type': 'call', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'vectorize'}; {'id': '91', 'type': 'argument_list', 'children': ['92']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'get_markup'}; {'id': '93', 'type': 'for_statement', 'children': ['94', '95', '99']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'roleout'}; {'id': '95', 'type': 'call', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '97', 'type': 'argument_list', 'children': ['98']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'roleouts'}; {'id': '99', 'type': 'block', 'children': ['100', '126', '133', '139', '148', '157', '377', '384']}; {'id': '100', 'type': 'if_statement', 'children': ['101', '104']}; {'id': '101', 'type': 'comparison_operator', 'children': ['102', '103'], 'value': 'is'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'dynProfile'}; {'id': '103', 'type': 'None', 'children': []}; {'id': '104', 'type': 'block', 'children': ['105', '111']}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '108', 'type': 'binary_operator', 'children': ['109', '110'], 'value': '*'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'roleout'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '116']}; {'id': '113', 'type': 'attribute', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'profile'}; {'id': '116', 'type': 'subscript', 'children': ['117', '118', '124']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'dynProfile'}; {'id': '118', 'type': 'slice', 'children': ['119', '120', '121']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '120', 'type': 'colon', 'children': []}; {'id': '121', 'type': 'binary_operator', 'children': ['122', '123'], 'value': '+'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '124', 'type': 'slice', 'children': ['125']}; {'id': '125', 'type': 'colon', 'children': []}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'call', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'doEpisodes'}; {'id': '131', 'type': 'argument_list', 'children': ['132']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'assignment', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '136', 'type': 'binary_operator', 'children': ['137', '138'], 'value': '*'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'episodes'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'maxsteps'}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'assignment', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'epi_action'}; {'id': '142', 'type': 'call', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '144', 'type': 'argument_list', 'children': ['145']}; {'id': '145', 'type': 'tuple', 'children': ['146', '147']}; {'id': '146', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'epi_reward'}; {'id': '151', 'type': 'call', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'tuple', 'children': ['155', '156']}; {'id': '155', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '157', 'type': 'for_statement', 'children': ['158', '163', '164', '176']}; {'id': '158', 'type': 'pattern_list', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '160', 'type': 'tuple_pattern', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'task'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '163', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '164', 'type': 'call', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '166', 'type': 'argument_list', 'children': ['167']}; {'id': '167', 'type': 'call', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '169', 'type': 'argument_list', 'children': ['170', '173']}; {'id': '170', 'type': 'attribute', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'tasks'}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'experiment'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'agents'}; {'id': '176', 'type': 'block', 'children': ['177', '188', '199', '317', '336', '351', '365', '371']}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'assignment', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '180', 'type': 'call', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '182', 'type': 'argument_list', 'children': ['183']}; {'id': '183', 'type': 'subscript', 'children': ['184', '187']}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '187', 'type': 'string', 'children': [], 'value': '"action"'}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'assignment', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'reward'}; {'id': '191', 'type': 'call', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '193', 'type': 'argument_list', 'children': ['194']}; {'id': '194', 'type': 'subscript', 'children': ['195', '198']}; {'id': '195', 'type': 'attribute', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'history'}; {'id': '198', 'type': 'string', 'children': [], 'value': '"reward"'}; {'id': '199', 'type': 'for_statement', 'children': ['200', '201', '205']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '201', 'type': 'call', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '205', 'type': 'block', 'children': ['206']}; {'id': '206', 'type': 'if_statement', 'children': ['207', '214', '258', '307']}; {'id': '207', 'type': 'call', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '209', 'type': 'argument_list', 'children': ['210', '213']}; {'id': '210', 'type': 'attribute', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'learner'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'DirectSearchLearner'}; {'id': '214', 'type': 'block', 'children': ['215', '232', '238']}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '222']}; {'id': '217', 'type': 'subscript', 'children': ['218', '219', '220']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '220', 'type': 'slice', 'children': ['221']}; {'id': '221', 'type': 'colon', 'children': []}; {'id': '222', 'type': 'call', 'children': ['223', '226']}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'task'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'denormalize'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'subscript', 'children': ['228', '229', '230']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '230', 'type': 'slice', 'children': ['231']}; {'id': '231', 'type': 'colon', 'children': []}; {'id': '232', 'type': 'expression_statement', 'children': ['233']}; {'id': '233', 'type': 'assignment', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '235', 'type': 'binary_operator', 'children': ['236', '237'], 'value': '*'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'roleout'}; {'id': '238', 'type': 'expression_statement', 'children': ['239']}; {'id': '239', 'type': 'assignment', 'children': ['240', '249']}; {'id': '240', 'type': 'subscript', 'children': ['241', '242', '243']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '243', 'type': 'slice', 'children': ['244', '245', '246']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '245', 'type': 'colon', 'children': []}; {'id': '246', 'type': 'binary_operator', 'children': ['247', '248'], 'value': '+'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '249', 'type': 'subscript', 'children': ['250', '257']}; {'id': '250', 'type': 'attribute', 'children': ['251', '256']}; {'id': '251', 'type': 'attribute', 'children': ['252', '255']}; {'id': '252', 'type': 'attribute', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'learner'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'explorer'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'sigma'}; {'id': '257', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '258', 'type': 'elif_clause', 'children': ['259', '266']}; {'id': '259', 'type': 'call', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '261', 'type': 'argument_list', 'children': ['262', '265']}; {'id': '262', 'type': 'attribute', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'learner'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'ValueBasedLearner'}; {'id': '266', 'type': 'block', 'children': ['267', '283', '289']}; {'id': '267', 'type': 'expression_statement', 'children': ['268']}; {'id': '268', 'type': 'assignment', 'children': ['269', '274']}; {'id': '269', 'type': 'subscript', 'children': ['270', '271', '272']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '272', 'type': 'slice', 'children': ['273']}; {'id': '273', 'type': 'colon', 'children': []}; {'id': '274', 'type': 'call', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'vmarkup'}; {'id': '276', 'type': 'argument_list', 'children': ['277', '282']}; {'id': '277', 'type': 'subscript', 'children': ['278', '279', '280']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '280', 'type': 'slice', 'children': ['281']}; {'id': '281', 'type': 'colon', 'children': []}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'task'}; {'id': '283', 'type': 'expression_statement', 'children': ['284']}; {'id': '284', 'type': 'assignment', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '286', 'type': 'binary_operator', 'children': ['287', '288'], 'value': '*'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'roleout'}; {'id': '289', 'type': 'expression_statement', 'children': ['290']}; {'id': '290', 'type': 'assignment', 'children': ['291', '300']}; {'id': '291', 'type': 'subscript', 'children': ['292', '293', '294']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '294', 'type': 'slice', 'children': ['295', '296', '297']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '296', 'type': 'colon', 'children': []}; {'id': '297', 'type': 'binary_operator', 'children': ['298', '299'], 'value': '+'}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'nei'}; {'id': '300', 'type': 'attribute', 'children': ['301', '306']}; {'id': '301', 'type': 'attribute', 'children': ['302', '305']}; {'id': '302', 'type': 'attribute', 'children': ['303', '304']}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'learner'}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'explorer'}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '307', 'type': 'else_clause', 'children': ['308']}; {'id': '308', 'type': 'block', 'children': ['309']}; {'id': '309', 'type': 'expression_statement', 'children': ['310']}; {'id': '310', 'type': 'assignment', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '312', 'type': 'call', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'vmarkup'}; {'id': '314', 'type': 'argument_list', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'task'}; {'id': '317', 'type': 'expression_statement', 'children': ['318']}; {'id': '318', 'type': 'assignment', 'children': ['319', '320']}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'epi_action'}; {'id': '320', 'type': 'attribute', 'children': ['321', '335']}; {'id': '321', 'type': 'subscript', 'children': ['322', '323', '326']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'c_'}; {'id': '323', 'type': 'attribute', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'epi_action'}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'T'}; {'id': '326', 'type': 'call', 'children': ['327', '334']}; {'id': '327', 'type': 'attribute', 'children': ['328', '333']}; {'id': '328', 'type': 'subscript', 'children': ['329', '330', '332']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '330', 'type': 'slice', 'children': ['331']}; {'id': '331', 'type': 'colon', 'children': []}; {'id': '332', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'flatten'}; {'id': '334', 'type': 'argument_list', 'children': []}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'T'}; {'id': '336', 'type': 'expression_statement', 'children': ['337']}; {'id': '337', 'type': 'assignment', 'children': ['338', '339']}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'epi_reward'}; {'id': '339', 'type': 'attribute', 'children': ['340', '350']}; {'id': '340', 'type': 'subscript', 'children': ['341', '342', '345']}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'c_'}; {'id': '342', 'type': 'attribute', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'epi_reward'}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'T'}; {'id': '345', 'type': 'call', 'children': ['346', '349']}; {'id': '346', 'type': 'attribute', 'children': ['347', '348']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'reward'}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'flatten'}; {'id': '349', 'type': 'argument_list', 'children': []}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'T'}; {'id': '351', 'type': 'if_statement', 'children': ['352', '357']}; {'id': '352', 'type': 'call', 'children': ['353', '354']}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '354', 'type': 'argument_list', 'children': ['355', '356']}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '356', 'type': 'string', 'children': [], 'value': '"module"'}; {'id': '357', 'type': 'block', 'children': ['358']}; {'id': '358', 'type': 'print_statement', 'children': ['359', '360']}; {'id': '359', 'type': 'string', 'children': [], 'value': '"PARAMS:"'}; {'id': '360', 'type': 'attribute', 'children': ['361', '364']}; {'id': '361', 'type': 'attribute', 'children': ['362', '363']}; {'id': '362', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '365', 'type': 'expression_statement', 'children': ['366']}; {'id': '366', 'type': 'call', 'children': ['367', '370']}; {'id': '367', 'type': 'attribute', 'children': ['368', '369']}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '369', 'type': 'identifier', 'children': [], 'value': 'learn'}; {'id': '370', 'type': 'argument_list', 'children': []}; {'id': '371', 'type': 'expression_statement', 'children': ['372']}; {'id': '372', 'type': 'call', 'children': ['373', '376']}; {'id': '373', 'type': 'attribute', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'agent'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'reset'}; {'id': '376', 'type': 'argument_list', 'children': []}; {'id': '377', 'type': 'expression_statement', 'children': ['378']}; {'id': '378', 'type': 'assignment', 'children': ['379', '380']}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '380', 'type': 'subscript', 'children': ['381', '382', '383']}; {'id': '381', 'type': 'identifier', 'children': [], 'value': 'c_'}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '383', 'type': 'identifier', 'children': [], 'value': 'epi_action'}; {'id': '384', 'type': 'expression_statement', 'children': ['385']}; {'id': '385', 'type': 'assignment', 'children': ['386', '387']}; {'id': '386', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '387', 'type': 'subscript', 'children': ['388', '389', '390']}; {'id': '388', 'type': 'identifier', 'children': [], 'value': 'c_'}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '390', 'type': 'identifier', 'children': [], 'value': 'epi_reward'}; {'id': '391', 'type': 'return_statement', 'children': ['392']}; {'id': '392', 'type': 'expression_list', 'children': ['393', '394', '395']}; {'id': '393', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '394', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '395', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '396', 'type': 'if_statement', 'children': ['397', '398', '430']}; {'id': '397', 'type': 'identifier', 'children': [], 'value': 'in_cloud'}; {'id': '398', 'type': 'block', 'children': ['399', '402', '414', '423']}; {'id': '399', 'type': 'import_statement', 'children': ['400']}; {'id': '400', 'type': 'dotted_name', 'children': ['401']}; {'id': '401', 'type': 'identifier', 'children': [], 'value': 'cloud'}; {'id': '402', 'type': 'expression_statement', 'children': ['403']}; {'id': '403', 'type': 'assignment', 'children': ['404', '405']}; {'id': '404', 'type': 'identifier', 'children': [], 'value': 'job_id'}; {'id': '405', 'type': 'call', 'children': ['406', '409']}; {'id': '406', 'type': 'attribute', 'children': ['407', '408']}; {'id': '407', 'type': 'identifier', 'children': [], 'value': 'cloud'}; {'id': '408', 'type': 'identifier', 'children': [], 'value': 'call'}; {'id': '409', 'type': 'argument_list', 'children': ['410', '411']}; {'id': '410', 'type': 'identifier', 'children': [], 'value': 'run'}; {'id': '411', 'type': 'keyword_argument', 'children': ['412', '413']}; {'id': '412', 'type': 'identifier', 'children': [], 'value': '_high_cpu'}; {'id': '413', 'type': 'False', 'children': []}; {'id': '414', 'type': 'expression_statement', 'children': ['415']}; {'id': '415', 'type': 'assignment', 'children': ['416', '417']}; {'id': '416', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '417', 'type': 'call', 'children': ['418', '421']}; {'id': '418', 'type': 'attribute', 'children': ['419', '420']}; {'id': '419', 'type': 'identifier', 'children': [], 'value': 'cloud'}; {'id': '420', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '421', 'type': 'argument_list', 'children': ['422']}; {'id': '422', 'type': 'identifier', 'children': [], 'value': 'job_id'}; {'id': '423', 'type': 'expression_statement', 'children': ['424']}; {'id': '424', 'type': 'assignment', 'children': ['425', '429']}; {'id': '425', 'type': 'pattern_list', 'children': ['426', '427', '428']}; {'id': '426', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '427', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '428', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '429', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '430', 'type': 'else_clause', 'children': ['431']}; {'id': '431', 'type': 'block', 'children': ['432']}; {'id': '432', 'type': 'expression_statement', 'children': ['433']}; {'id': '433', 'type': 'assignment', 'children': ['434', '438']}; {'id': '434', 'type': 'pattern_list', 'children': ['435', '436', '437']}; {'id': '435', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '436', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '437', 'type': 'identifier', 'children': [], 'value': 'epsilon'}; {'id': '438', 'type': 'call', 'children': ['439', '440']}; {'id': '439', 'type': 'identifier', 'children': [], 'value': 'run'}; {'id': '440', 'type': 'argument_list', 'children': []}; {'id': '441', 'type': 'return_statement', 'children': ['442']}; {'id': '442', 'type': 'expression_list', 'children': ['443', '444', '445']}; {'id': '443', 'type': 'identifier', 'children': [], 'value': 'all_action'}; {'id': '444', 'type': 'identifier', 'children': [], 'value': 'all_reward'}; {'id': '445', 'type': 'identifier', 'children': [], 'value': 'epsilon'}
Runs the given experiment and returns the results.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '14']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'total_cost'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '8', '11']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '7', 'type': 'None', 'children': []}; {'id': '8', 'type': 'default_parameter', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '10', 'type': 'None', 'children': []}; {'id': '11', 'type': 'default_parameter', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '13', 'type': 'None', 'children': []}; {'id': '14', 'type': 'block', 'children': ['15', '26', '37', '48', '58', '175']}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '18', 'type': 'conditional_expression', 'children': ['19', '22', '25'], 'value': 'if'}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '22', 'type': 'comparison_operator', 'children': ['23', '24'], 'value': 'is'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '24', 'type': 'None', 'children': []}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '29', 'type': 'conditional_expression', 'children': ['30', '33', '36'], 'value': 'if'}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '33', 'type': 'comparison_operator', 'children': ['34', '35'], 'value': 'is'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '35', 'type': 'None', 'children': []}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'assignment', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '40', 'type': 'conditional_expression', 'children': ['41', '44', '47'], 'value': 'if'}; {'id': '41', 'type': 'attribute', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '44', 'type': 'comparison_operator', 'children': ['45', '46'], 'value': 'is'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '46', 'type': 'None', 'children': []}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '48', 'type': 'expression_statement', 'children': ['49']}; {'id': '49', 'type': 'assignment', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '51', 'type': 'conditional_expression', 'children': ['52', '53', '57'], 'value': 'if'}; {'id': '52', 'type': 'float', 'children': [], 'value': '0.0'}; {'id': '53', 'type': 'not_operator', 'children': ['54']}; {'id': '54', 'type': 'attribute', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'online'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '58', 'type': 'if_statement', 'children': ['59', '62', '158', '171']}; {'id': '59', 'type': 'comparison_operator', 'children': ['60', '61'], 'value': '=='}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'PW_LINEAR'}; {'id': '62', 'type': 'block', 'children': ['63', '72']}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'assignment', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'n_segments'}; {'id': '66', 'type': 'binary_operator', 'children': ['67', '71'], 'value': '-'}; {'id': '67', 'type': 'call', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '69', 'type': 'argument_list', 'children': ['70']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '71', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '72', 'type': 'for_statement', 'children': ['73', '74', '78', '132']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '74', 'type': 'call', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '76', 'type': 'argument_list', 'children': ['77']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'n_segments'}; {'id': '78', 'type': 'block', 'children': ['79', '87', '97', '109', '117']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '84']}; {'id': '81', 'type': 'pattern_list', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'x1'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'y1'}; {'id': '84', 'type': 'subscript', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '92']}; {'id': '89', 'type': 'pattern_list', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'x2'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'y2'}; {'id': '92', 'type': 'subscript', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '94', 'type': 'binary_operator', 'children': ['95', '96'], 'value': '+'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '96', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '100', 'type': 'binary_operator', 'children': ['101', '105'], 'value': '/'}; {'id': '101', 'type': '()', 'children': ['102']}; {'id': '102', 'type': 'binary_operator', 'children': ['103', '104'], 'value': '-'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'y2'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'y1'}; {'id': '105', 'type': '()', 'children': ['106']}; {'id': '106', 'type': 'binary_operator', 'children': ['107', '108'], 'value': '-'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'x2'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'x1'}; {'id': '109', 'type': 'expression_statement', 'children': ['110']}; {'id': '110', 'type': 'assignment', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '112', 'type': 'binary_operator', 'children': ['113', '114'], 'value': '-'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'y1'}; {'id': '114', 'type': 'binary_operator', 'children': ['115', '116'], 'value': '*'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'x1'}; {'id': '117', 'type': 'if_statement', 'children': ['118', '122']}; {'id': '118', 'type': 'comparison_operator', 'children': ['119', '120', '121'], 'value': '<='}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'x1'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'x2'}; {'id': '122', 'type': 'block', 'children': ['123', '131']}; {'id': '123', 'type': 'expression_statement', 'children': ['124']}; {'id': '124', 'type': 'assignment', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '126', 'type': 'binary_operator', 'children': ['127', '130'], 'value': '+'}; {'id': '127', 'type': 'binary_operator', 'children': ['128', '129'], 'value': '*'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '131', 'type': 'break_statement', 'children': []}; {'id': '132', 'type': 'else_clause', 'children': ['133']}; {'id': '133', 'type': 'block', 'children': ['134', '150']}; {'id': '134', 'type': 'expression_statement', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '139', 'type': 'argument_list', 'children': ['140']}; {'id': '140', 'type': 'binary_operator', 'children': ['141', '142'], 'value': '%'}; {'id': '141', 'type': 'string', 'children': [], 'value': '"Value [%f] outside pwl cost curve [%s]."'}; {'id': '142', 'type': 'tuple', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '144', 'type': 'subscript', 'children': ['145', '149']}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '147', 'type': 'unary_operator', 'children': ['148'], 'value': '-'}; {'id': '148', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '149', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'assignment', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '153', 'type': 'binary_operator', 'children': ['154', '157'], 'value': '+'}; {'id': '154', 'type': 'binary_operator', 'children': ['155', '156'], 'value': '*'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '158', 'type': 'elif_clause', 'children': ['159', '162']}; {'id': '159', 'type': 'comparison_operator', 'children': ['160', '161'], 'value': '=='}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'POLYNOMIAL'}; {'id': '162', 'type': 'block', 'children': ['163']}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'assignment', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '166', 'type': 'call', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'polyval'}; {'id': '168', 'type': 'argument_list', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '171', 'type': 'else_clause', 'children': ['172']}; {'id': '172', 'type': 'block', 'children': ['173']}; {'id': '173', 'type': 'raise_statement', 'children': ['174']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '175', 'type': 'if_statement', 'children': ['176', '179', '183']}; {'id': '176', 'type': 'attribute', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'is_load'}; {'id': '179', 'type': 'block', 'children': ['180']}; {'id': '180', 'type': 'return_statement', 'children': ['181']}; {'id': '181', 'type': 'unary_operator', 'children': ['182'], 'value': '-'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '183', 'type': 'else_clause', 'children': ['184']}; {'id': '184', 'type': 'block', 'children': ['185']}; {'id': '185', 'type': 'return_statement', 'children': ['186']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'result'}
Computes total cost for the generator at the given output level.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_quadratic_costs'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'ipol'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'nxyz'}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'base_mva'}; {'id': '9', 'type': 'block', 'children': ['10', '17', '24', '38', '61', '89', '117', '126', '316']}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'ipol'}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'rnpol'}; {'id': '20', 'type': 'call', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '22', 'type': 'argument_list', 'children': ['23']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'gpol'}; {'id': '27', 'type': 'list_comprehension', 'children': ['28', '29', '32']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '29', 'type': 'for_in_clause', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '32', 'type': 'if_clause', 'children': ['33']}; {'id': '33', 'type': 'comparison_operator', 'children': ['34', '37'], 'value': '=='}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'POLYNOMIAL'}; {'id': '38', 'type': 'if_statement', 'children': ['39', '53']}; {'id': '39', 'type': 'list_comprehension', 'children': ['40', '41', '44']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '41', 'type': 'for_in_clause', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'gpol'}; {'id': '44', 'type': 'if_clause', 'children': ['45']}; {'id': '45', 'type': 'comparison_operator', 'children': ['46', '52'], 'value': '>'}; {'id': '46', 'type': 'call', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'attribute', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '52', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '53', 'type': 'block', 'children': ['54']}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'call', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '59', 'type': 'argument_list', 'children': ['60']}; {'id': '60', 'type': 'string', 'children': [], 'value': '"Order of polynomial cost greater than quadratic."'}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'iqdr'}; {'id': '64', 'type': 'list_comprehension', 'children': ['65', '66', '74']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '66', 'type': 'for_in_clause', 'children': ['67', '70']}; {'id': '67', 'type': 'pattern_list', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '70', 'type': 'call', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '72', 'type': 'argument_list', 'children': ['73']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '74', 'type': 'if_clause', 'children': ['75']}; {'id': '75', 'type': 'boolean_operator', 'children': ['76', '81'], 'value': 'and'}; {'id': '76', 'type': 'comparison_operator', 'children': ['77', '80'], 'value': '=='}; {'id': '77', 'type': 'attribute', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'POLYNOMIAL'}; {'id': '81', 'type': 'comparison_operator', 'children': ['82', '88'], 'value': '=='}; {'id': '82', 'type': 'call', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'attribute', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '88', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '89', 'type': 'expression_statement', 'children': ['90']}; {'id': '90', 'type': 'assignment', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'ilin'}; {'id': '92', 'type': 'list_comprehension', 'children': ['93', '94', '102']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '94', 'type': 'for_in_clause', 'children': ['95', '98']}; {'id': '95', 'type': 'pattern_list', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '98', 'type': 'call', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '100', 'type': 'argument_list', 'children': ['101']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '102', 'type': 'if_clause', 'children': ['103']}; {'id': '103', 'type': 'boolean_operator', 'children': ['104', '109'], 'value': 'and'}; {'id': '104', 'type': 'comparison_operator', 'children': ['105', '108'], 'value': '=='}; {'id': '105', 'type': 'attribute', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'pcost_model'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'POLYNOMIAL'}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '116'], 'value': '=='}; {'id': '110', 'type': 'call', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '112', 'type': 'argument_list', 'children': ['113']}; {'id': '113', 'type': 'attribute', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '116', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '117', 'type': 'expression_statement', 'children': ['118']}; {'id': '118', 'type': 'assignment', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '122', 'type': 'argument_list', 'children': ['123']}; {'id': '123', 'type': 'tuple', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '125', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '126', 'type': 'if_statement', 'children': ['127', '130', '292']}; {'id': '127', 'type': 'comparison_operator', 'children': ['128', '129'], 'value': '>'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '129', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '130', 'type': 'block', 'children': ['131', '159', '192', '206', '217', '241', '261', '269']}; {'id': '131', 'type': 'if_statement', 'children': ['132', '138']}; {'id': '132', 'type': 'comparison_operator', 'children': ['133', '137'], 'value': '>'}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '135', 'type': 'argument_list', 'children': ['136']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'iqdr'}; {'id': '137', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '138', 'type': 'block', 'children': ['139']}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'assignment', 'children': ['141', '146']}; {'id': '141', 'type': 'subscript', 'children': ['142', '143', '144']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'iqdr'}; {'id': '144', 'type': 'slice', 'children': ['145']}; {'id': '145', 'type': 'colon', 'children': []}; {'id': '146', 'type': 'call', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'list_comprehension', 'children': ['150', '156']}; {'id': '150', 'type': 'call', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'attribute', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '156', 'type': 'for_in_clause', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '159', 'type': 'if_statement', 'children': ['160', '166']}; {'id': '160', 'type': 'comparison_operator', 'children': ['161', '165'], 'value': '>'}; {'id': '161', 'type': 'call', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '163', 'type': 'argument_list', 'children': ['164']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'ilin'}; {'id': '165', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '166', 'type': 'block', 'children': ['167']}; {'id': '167', 'type': 'expression_statement', 'children': ['168']}; {'id': '168', 'type': 'assignment', 'children': ['169', '175']}; {'id': '169', 'type': 'subscript', 'children': ['170', '171', '172']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'ilin'}; {'id': '172', 'type': 'slice', 'children': ['173', '174']}; {'id': '173', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '174', 'type': 'colon', 'children': []}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '177', 'type': 'argument_list', 'children': ['178']}; {'id': '178', 'type': 'list_comprehension', 'children': ['179', '189']}; {'id': '179', 'type': 'call', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '181', 'type': 'argument_list', 'children': ['182']}; {'id': '182', 'type': 'subscript', 'children': ['183', '186']}; {'id': '183', 'type': 'attribute', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'p_cost'}; {'id': '186', 'type': 'slice', 'children': ['187', '188']}; {'id': '187', 'type': 'colon', 'children': []}; {'id': '188', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '189', 'type': 'for_in_clause', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '195', 'type': 'binary_operator', 'children': ['196', '197'], 'value': '*'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '197', 'type': 'call', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '199', 'type': 'argument_list', 'children': ['200']}; {'id': '200', 'type': 'list', 'children': ['201', '204', '205'], 'value': '[base_mva**2, base_mva, 1]'}; {'id': '201', 'type': 'binary_operator', 'children': ['202', '203'], 'value': '**'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'base_mva'}; {'id': '203', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'base_mva'}; {'id': '205', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'assignment', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'Pg'}; {'id': '209', 'type': 'call', 'children': ['210', '215']}; {'id': '210', 'type': 'attribute', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'om'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'get_var'}; {'id': '215', 'type': 'argument_list', 'children': ['216']}; {'id': '216', 'type': 'string', 'children': [], 'value': '"Pg"'}; {'id': '217', 'type': 'expression_statement', 'children': ['218']}; {'id': '218', 'type': 'assignment', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'Npol'}; {'id': '220', 'type': 'call', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'csr_matrix'}; {'id': '222', 'type': 'argument_list', 'children': ['223', '238']}; {'id': '223', 'type': 'tuple', 'children': ['224', '228']}; {'id': '224', 'type': 'call', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'ones'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '228', 'type': 'tuple', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'rnpol'}; {'id': '230', 'type': 'binary_operator', 'children': ['231', '234'], 'value': '+'}; {'id': '231', 'type': 'attribute', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'Pg'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '234', 'type': 'call', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'ipol'}; {'id': '238', 'type': 'tuple', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'nxyz'}; {'id': '241', 'type': 'expression_statement', 'children': ['242']}; {'id': '242', 'type': 'assignment', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'Hpol'}; {'id': '244', 'type': 'call', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'csr_matrix'}; {'id': '246', 'type': 'argument_list', 'children': ['247', '258']}; {'id': '247', 'type': 'tuple', 'children': ['248', '255']}; {'id': '248', 'type': 'binary_operator', 'children': ['249', '250'], 'value': '*'}; {'id': '249', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '250', 'type': 'subscript', 'children': ['251', '252', '254']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '252', 'type': 'slice', 'children': ['253']}; {'id': '253', 'type': 'colon', 'children': []}; {'id': '254', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '255', 'type': 'tuple', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'rnpol'}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'rnpol'}; {'id': '258', 'type': 'tuple', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '261', 'type': 'expression_statement', 'children': ['262']}; {'id': '262', 'type': 'assignment', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'Cpol'}; {'id': '264', 'type': 'subscript', 'children': ['265', '266', '268']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '266', 'type': 'slice', 'children': ['267']}; {'id': '267', 'type': 'colon', 'children': []}; {'id': '268', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '269', 'type': 'expression_statement', 'children': ['270']}; {'id': '270', 'type': 'assignment', 'children': ['271', '272']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'fparm_pol'}; {'id': '272', 'type': 'attribute', 'children': ['273', '291']}; {'id': '273', 'type': '()', 'children': ['274']}; {'id': '274', 'type': 'binary_operator', 'children': ['275', '279'], 'value': '*'}; {'id': '275', 'type': 'call', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'ones'}; {'id': '277', 'type': 'argument_list', 'children': ['278']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'npol'}; {'id': '279', 'type': 'call', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '281', 'type': 'argument_list', 'children': ['282']}; {'id': '282', 'type': 'list', 'children': ['283', '285', '287', '289'], 'value': '[[1], [0], [0], [1]]'}; {'id': '283', 'type': 'list', 'children': ['284'], 'value': '[1]'}; {'id': '284', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '285', 'type': 'list', 'children': ['286'], 'value': '[0]'}; {'id': '286', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '287', 'type': 'list', 'children': ['288'], 'value': '[0]'}; {'id': '288', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '289', 'type': 'list', 'children': ['290'], 'value': '[1]'}; {'id': '290', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'T'}; {'id': '292', 'type': 'else_clause', 'children': ['293']}; {'id': '293', 'type': 'block', 'children': ['294', '300', '307']}; {'id': '294', 'type': 'expression_statement', 'children': ['295']}; {'id': '295', 'type': 'assignment', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'Npol'}; {'id': '297', 'type': 'assignment', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'Hpol'}; {'id': '299', 'type': 'None', 'children': []}; {'id': '300', 'type': 'expression_statement', 'children': ['301']}; {'id': '301', 'type': 'assignment', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'Cpol'}; {'id': '303', 'type': 'call', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '305', 'type': 'argument_list', 'children': ['306']}; {'id': '306', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '307', 'type': 'expression_statement', 'children': ['308']}; {'id': '308', 'type': 'assignment', 'children': ['309', '310']}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'fparm_pol'}; {'id': '310', 'type': 'call', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '312', 'type': 'argument_list', 'children': ['313']}; {'id': '313', 'type': 'tuple', 'children': ['314', '315']}; {'id': '314', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '315', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '316', 'type': 'return_statement', 'children': ['317']}; {'id': '317', 'type': 'expression_list', 'children': ['318', '319', '320', '321', '322', '323']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'Npol'}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'Hpol'}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'Cpol'}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'fparm_pol'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'polycf'}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'npol'}
Returns the quadratic cost components of the objective function.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_gh'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '6', 'type': 'block', 'children': ['7', '26', '45', '80', '95', '114', '133', '144', '159', '170', '192', '212', '384']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'Pgen'}; {'id': '10', 'type': 'subscript', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '12', 'type': 'slice', 'children': ['13', '18', '19']}; {'id': '13', 'type': 'attribute', 'children': ['14', '17']}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': '_Pg'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '18', 'type': 'colon', 'children': []}; {'id': '19', 'type': 'binary_operator', 'children': ['20', '25'], 'value': '+'}; {'id': '20', 'type': 'attribute', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': '_Pg'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'iN'}; {'id': '25', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'Qgen'}; {'id': '29', 'type': 'subscript', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '31', 'type': 'slice', 'children': ['32', '37', '38']}; {'id': '32', 'type': 'attribute', 'children': ['33', '36']}; {'id': '33', 'type': 'attribute', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': '_Qg'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '37', 'type': 'colon', 'children': []}; {'id': '38', 'type': 'binary_operator', 'children': ['39', '44'], 'value': '+'}; {'id': '39', 'type': 'attribute', 'children': ['40', '43']}; {'id': '40', 'type': 'attribute', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': '_Qg'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'iN'}; {'id': '44', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '45', 'type': 'for_statement', 'children': ['46', '49', '55']}; {'id': '46', 'type': 'pattern_list', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'gen'}; {'id': '49', 'type': 'call', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': '_gn'}; {'id': '55', 'type': 'block', 'children': ['56', '68']}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'gen'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '61', 'type': 'binary_operator', 'children': ['62', '65'], 'value': '*'}; {'id': '62', 'type': 'subscript', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'Pgen'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': '_base_mva'}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '73']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'gen'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'q'}; {'id': '73', 'type': 'binary_operator', 'children': ['74', '77'], 'value': '*'}; {'id': '74', 'type': 'subscript', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'Qgen'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '77', 'type': 'attribute', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': '_base_mva'}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'Sbus'}; {'id': '83', 'type': 'call', 'children': ['84', '91']}; {'id': '84', 'type': 'attribute', 'children': ['85', '90']}; {'id': '85', 'type': 'attribute', 'children': ['86', '89']}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'om'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'getSbus'}; {'id': '91', 'type': 'argument_list', 'children': ['92']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': '_bs'}; {'id': '95', 'type': 'expression_statement', 'children': ['96']}; {'id': '96', 'type': 'assignment', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'Vang'}; {'id': '98', 'type': 'subscript', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '100', 'type': 'slice', 'children': ['101', '106', '107']}; {'id': '101', 'type': 'attribute', 'children': ['102', '105']}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': '_Va'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '106', 'type': 'colon', 'children': []}; {'id': '107', 'type': 'binary_operator', 'children': ['108', '113'], 'value': '+'}; {'id': '108', 'type': 'attribute', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': '_Va'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'iN'}; {'id': '113', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'Vmag'}; {'id': '117', 'type': 'subscript', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '119', 'type': 'slice', 'children': ['120', '125', '126']}; {'id': '120', 'type': 'attribute', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': '_Vm'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '125', 'type': 'colon', 'children': []}; {'id': '126', 'type': 'binary_operator', 'children': ['127', '132'], 'value': '+'}; {'id': '127', 'type': 'attribute', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': '_Vm'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'iN'}; {'id': '132', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'assignment', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '136', 'type': 'binary_operator', 'children': ['137', '138'], 'value': '*'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'Vmag'}; {'id': '138', 'type': 'call', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'exp'}; {'id': '140', 'type': 'argument_list', 'children': ['141']}; {'id': '141', 'type': 'binary_operator', 'children': ['142', '143'], 'value': '*'}; {'id': '142', 'type': 'integer', 'children': [], 'value': '1j'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'Vang'}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'mis'}; {'id': '147', 'type': 'binary_operator', 'children': ['148', '158'], 'value': '-'}; {'id': '148', 'type': 'binary_operator', 'children': ['149', '150'], 'value': '*'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '150', 'type': 'call', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'binary_operator', 'children': ['154', '157'], 'value': '*'}; {'id': '154', 'type': 'attribute', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': '_Ybus'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'Sbus'}; {'id': '159', 'type': 'expression_statement', 'children': ['160']}; {'id': '160', 'type': 'assignment', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '162', 'type': 'subscript', 'children': ['163', '164', '167']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '164', 'type': 'attribute', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'mis'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'real'}; {'id': '167', 'type': 'attribute', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'mis'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'imag'}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'assignment', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '173', 'type': 'call', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '175', 'type': 'argument_list', 'children': ['176']}; {'id': '176', 'type': 'list_comprehension', 'children': ['177', '187']}; {'id': '177', 'type': 'binary_operator', 'children': ['178', '186'], 'value': '**'}; {'id': '178', 'type': '()', 'children': ['179']}; {'id': '179', 'type': 'binary_operator', 'children': ['180', '183'], 'value': '/'}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'l'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'rate_a'}; {'id': '183', 'type': 'attribute', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': '_base_mva'}; {'id': '186', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '187', 'type': 'for_in_clause', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'l'}; {'id': '189', 'type': 'attribute', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': '_ln'}; {'id': '192', 'type': 'for_statement', 'children': ['193', '196', '200']}; {'id': '193', 'type': 'pattern_list', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '196', 'type': 'call', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '198', 'type': 'argument_list', 'children': ['199']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '200', 'type': 'block', 'children': ['201']}; {'id': '201', 'type': 'if_statement', 'children': ['202', '205']}; {'id': '202', 'type': 'comparison_operator', 'children': ['203', '204'], 'value': '=='}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '204', 'type': 'float', 'children': [], 'value': '0.0'}; {'id': '205', 'type': 'block', 'children': ['206']}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'assignment', 'children': ['208', '211']}; {'id': '208', 'type': 'subscript', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'Inf'}; {'id': '212', 'type': 'if_statement', 'children': ['213', '218', '258']}; {'id': '213', 'type': 'comparison_operator', 'children': ['214', '217'], 'value': '=='}; {'id': '214', 'type': 'attribute', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'flow_lim'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'IFLOW'}; {'id': '218', 'type': 'block', 'children': ['219', '227', '235']}; {'id': '219', 'type': 'expression_statement', 'children': ['220']}; {'id': '220', 'type': 'assignment', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'If'}; {'id': '222', 'type': 'binary_operator', 'children': ['223', '226'], 'value': '*'}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': '_Yf'}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '227', 'type': 'expression_statement', 'children': ['228']}; {'id': '228', 'type': 'assignment', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'It'}; {'id': '230', 'type': 'binary_operator', 'children': ['231', '234'], 'value': '*'}; {'id': '231', 'type': 'attribute', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': '_Yt'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'assignment', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '238', 'type': 'subscript', 'children': ['239', '240', '249']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '240', 'type': 'binary_operator', 'children': ['241', '248'], 'value': '-'}; {'id': '241', 'type': '()', 'children': ['242']}; {'id': '242', 'type': 'binary_operator', 'children': ['243', '244'], 'value': '*'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'If'}; {'id': '244', 'type': 'call', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '246', 'type': 'argument_list', 'children': ['247']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'If'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '249', 'type': 'binary_operator', 'children': ['250', '257'], 'value': '-'}; {'id': '250', 'type': '()', 'children': ['251']}; {'id': '251', 'type': 'binary_operator', 'children': ['252', '253'], 'value': '*'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'It'}; {'id': '253', 'type': 'call', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '255', 'type': 'argument_list', 'children': ['256']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'It'}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '258', 'type': 'else_clause', 'children': ['259']}; {'id': '259', 'type': 'block', 'children': ['260', '274', '288', '303', '318']}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'assignment', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'i_fbus'}; {'id': '263', 'type': 'list_comprehension', 'children': ['264', '269']}; {'id': '264', 'type': 'attribute', 'children': ['265', '268']}; {'id': '265', 'type': 'attribute', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'from_bus'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': '_i'}; {'id': '269', 'type': 'for_in_clause', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '271', 'type': 'attribute', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': '_ln'}; {'id': '274', 'type': 'expression_statement', 'children': ['275']}; {'id': '275', 'type': 'assignment', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'i_tbus'}; {'id': '277', 'type': 'list_comprehension', 'children': ['278', '283']}; {'id': '278', 'type': 'attribute', 'children': ['279', '282']}; {'id': '279', 'type': 'attribute', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'to_bus'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': '_i'}; {'id': '283', 'type': 'for_in_clause', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '285', 'type': 'attribute', 'children': ['286', '287']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': '_ln'}; {'id': '288', 'type': 'expression_statement', 'children': ['289']}; {'id': '289', 'type': 'assignment', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'Sf'}; {'id': '291', 'type': 'binary_operator', 'children': ['292', '295'], 'value': '*'}; {'id': '292', 'type': 'subscript', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'i_fbus'}; {'id': '295', 'type': 'call', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '297', 'type': 'argument_list', 'children': ['298']}; {'id': '298', 'type': 'binary_operator', 'children': ['299', '302'], 'value': '*'}; {'id': '299', 'type': 'attribute', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '301', 'type': 'identifier', 'children': [], 'value': '_Yf'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '303', 'type': 'expression_statement', 'children': ['304']}; {'id': '304', 'type': 'assignment', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'St'}; {'id': '306', 'type': 'binary_operator', 'children': ['307', '310'], 'value': '*'}; {'id': '307', 'type': 'subscript', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'i_tbus'}; {'id': '310', 'type': 'call', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '312', 'type': 'argument_list', 'children': ['313']}; {'id': '313', 'type': 'binary_operator', 'children': ['314', '317'], 'value': '*'}; {'id': '314', 'type': 'attribute', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': '_Yt'}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'V'}; {'id': '318', 'type': 'if_statement', 'children': ['319', '324', '348', '380']}; {'id': '319', 'type': 'comparison_operator', 'children': ['320', '323'], 'value': '=='}; {'id': '320', 'type': 'attribute', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'flow_lim'}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'PFLOW'}; {'id': '324', 'type': 'block', 'children': ['325']}; {'id': '325', 'type': 'expression_statement', 'children': ['326']}; {'id': '326', 'type': 'assignment', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '328', 'type': 'subscript', 'children': ['329', '330', '339']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '330', 'type': 'binary_operator', 'children': ['331', '338'], 'value': '-'}; {'id': '331', 'type': 'binary_operator', 'children': ['332', '337'], 'value': '**'}; {'id': '332', 'type': 'call', 'children': ['333', '336']}; {'id': '333', 'type': 'attribute', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'Sf'}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'real'}; {'id': '336', 'type': 'argument_list', 'children': []}; {'id': '337', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '339', 'type': 'binary_operator', 'children': ['340', '347'], 'value': '-'}; {'id': '340', 'type': 'binary_operator', 'children': ['341', '346'], 'value': '**'}; {'id': '341', 'type': 'call', 'children': ['342', '345']}; {'id': '342', 'type': 'attribute', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'St'}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'real'}; {'id': '345', 'type': 'argument_list', 'children': []}; {'id': '346', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '348', 'type': 'elif_clause', 'children': ['349', '354']}; {'id': '349', 'type': 'comparison_operator', 'children': ['350', '353'], 'value': '=='}; {'id': '350', 'type': 'attribute', 'children': ['351', '352']}; {'id': '351', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'flow_lim'}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'SFLOW'}; {'id': '354', 'type': 'block', 'children': ['355']}; {'id': '355', 'type': 'expression_statement', 'children': ['356']}; {'id': '356', 'type': 'assignment', 'children': ['357', '358']}; {'id': '357', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '358', 'type': 'attribute', 'children': ['359', '379']}; {'id': '359', 'type': 'subscript', 'children': ['360', '361', '370']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '361', 'type': 'binary_operator', 'children': ['362', '369'], 'value': '-'}; {'id': '362', 'type': '()', 'children': ['363']}; {'id': '363', 'type': 'binary_operator', 'children': ['364', '365'], 'value': '*'}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'Sf'}; {'id': '365', 'type': 'call', 'children': ['366', '367']}; {'id': '366', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '367', 'type': 'argument_list', 'children': ['368']}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'Sf'}; {'id': '369', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '370', 'type': 'binary_operator', 'children': ['371', '378'], 'value': '-'}; {'id': '371', 'type': '()', 'children': ['372']}; {'id': '372', 'type': 'binary_operator', 'children': ['373', '374'], 'value': '*'}; {'id': '373', 'type': 'identifier', 'children': [], 'value': 'St'}; {'id': '374', 'type': 'call', 'children': ['375', '376']}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'conj'}; {'id': '376', 'type': 'argument_list', 'children': ['377']}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'St'}; {'id': '378', 'type': 'identifier', 'children': [], 'value': 'flow_max'}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'real'}; {'id': '380', 'type': 'else_clause', 'children': ['381']}; {'id': '381', 'type': 'block', 'children': ['382']}; {'id': '382', 'type': 'raise_statement', 'children': ['383']}; {'id': '383', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '384', 'type': 'return_statement', 'children': ['385']}; {'id': '385', 'type': 'expression_list', 'children': ['386', '387']}; {'id': '386', 'type': 'identifier', 'children': [], 'value': 'h'}; {'id': '387', 'type': 'identifier', 'children': [], 'value': 'g'}
Evaluates the constraint function values.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'performAction'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '6', 'type': 'block', 'children': ['7', '27', '37', '49', '66', '80', '102', '163', '169']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'gs'}; {'id': '10', 'type': 'list_comprehension', 'children': ['11', '12', '19']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '12', 'type': 'for_in_clause', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '14', 'type': 'attribute', 'children': ['15', '18']}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'online_generators'}; {'id': '19', 'type': 'if_clause', 'children': ['20']}; {'id': '20', 'type': 'comparison_operator', 'children': ['21', '26'], 'value': '!='}; {'id': '21', 'type': 'attribute', 'children': ['22', '25']}; {'id': '22', 'type': 'attribute', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'bus'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'REFERENCE'}; {'id': '27', 'type': 'assert_statement', 'children': ['28']}; {'id': '28', 'type': 'comparison_operator', 'children': ['29', '33'], 'value': '=='}; {'id': '29', 'type': 'call', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '31', 'type': 'argument_list', 'children': ['32']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '35', 'type': 'argument_list', 'children': ['36']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'gs'}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '42', 'type': 'argument_list', 'children': ['43']}; {'id': '43', 'type': 'binary_operator', 'children': ['44', '45'], 'value': '%'}; {'id': '44', 'type': 'string', 'children': [], 'value': '"Action: %s"'}; {'id': '45', 'type': 'call', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '47', 'type': 'argument_list', 'children': ['48']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '49', 'type': 'for_statement', 'children': ['50', '53', '57']}; {'id': '50', 'type': 'pattern_list', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '53', 'type': 'call', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '55', 'type': 'argument_list', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'gs'}; {'id': '57', 'type': 'block', 'children': ['58']}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'assignment', 'children': ['60', '63']}; {'id': '60', 'type': 'attribute', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '63', 'type': 'subscript', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'call', 'children': ['68', '79']}; {'id': '68', 'type': 'attribute', 'children': ['69', '78']}; {'id': '69', 'type': 'call', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'NewtonPF'}; {'id': '71', 'type': 'argument_list', 'children': ['72', '75']}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '75', 'type': 'keyword_argument', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'verbose'}; {'id': '77', 'type': 'False', 'children': []}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'solve'}; {'id': '79', 'type': 'argument_list', 'children': []}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '91']}; {'id': '82', 'type': 'subscript', 'children': ['83', '86', '88']}; {'id': '83', 'type': 'attribute', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': '_Pg'}; {'id': '86', 'type': 'slice', 'children': ['87']}; {'id': '87', 'type': 'colon', 'children': []}; {'id': '88', 'type': 'attribute', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': '_step'}; {'id': '91', 'type': 'list_comprehension', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'p'}; {'id': '95', 'type': 'for_in_clause', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '97', 'type': 'attribute', 'children': ['98', '101']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'online_generators'}; {'id': '102', 'type': 'if_statement', 'children': ['103', '115']}; {'id': '103', 'type': 'comparison_operator', 'children': ['104', '107'], 'value': '!='}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': '_step'}; {'id': '107', 'type': 'binary_operator', 'children': ['108', '114'], 'value': '-'}; {'id': '108', 'type': 'call', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '110', 'type': 'argument_list', 'children': ['111']}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'profile'}; {'id': '114', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '115', 'type': 'block', 'children': ['116', '134']}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'assignment', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'pq_buses'}; {'id': '119', 'type': 'list_comprehension', 'children': ['120', '121', '128']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '121', 'type': 'for_in_clause', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '123', 'type': 'attribute', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'buses'}; {'id': '128', 'type': 'if_clause', 'children': ['129']}; {'id': '129', 'type': 'comparison_operator', 'children': ['130', '133'], 'value': '=='}; {'id': '130', 'type': 'attribute', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'PQ'}; {'id': '134', 'type': 'for_statement', 'children': ['135', '138', '142']}; {'id': '135', 'type': 'pattern_list', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '138', 'type': 'call', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '140', 'type': 'argument_list', 'children': ['141']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'pq_buses'}; {'id': '142', 'type': 'block', 'children': ['143']}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'p_demand'}; {'id': '148', 'type': 'binary_operator', 'children': ['149', '154'], 'value': '*'}; {'id': '149', 'type': 'subscript', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': '_Pd0'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '154', 'type': 'subscript', 'children': ['155', '158']}; {'id': '155', 'type': 'attribute', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'profile'}; {'id': '158', 'type': 'binary_operator', 'children': ['159', '162'], 'value': '+'}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': '_step'}; {'id': '162', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'augmented_assignment', 'children': ['165', '168'], 'value': '+='}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': '_step'}; {'id': '168', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'call', 'children': ['171', '174']}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '174', 'type': 'argument_list', 'children': ['175']}; {'id': '175', 'type': 'binary_operator', 'children': ['176', '177'], 'value': '%'}; {'id': '176', 'type': 'string', 'children': [], 'value': '"Entering step %d."'}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': '_step'}
Perform an action on the world that changes it's internal state.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '20', '28']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'blt'}; {'id': '3', 'type': 'parameters', 'children': ['4', '12']}; {'id': '4', 'type': 'typed_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '6', 'type': 'type', 'children': ['7']}; {'id': '7', 'type': 'generic_type', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'List'}; {'id': '9', 'type': 'type_parameter', 'children': ['10']}; {'id': '10', 'type': 'type', 'children': ['11']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'SYM'}; {'id': '12', 'type': 'typed_parameter', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '14', 'type': 'type', 'children': ['15']}; {'id': '15', 'type': 'generic_type', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'List'}; {'id': '17', 'type': 'type_parameter', 'children': ['18']}; {'id': '18', 'type': 'type', 'children': ['19']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'SYM'}; {'id': '20', 'type': 'type', 'children': ['21']}; {'id': '21', 'type': 'generic_type', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'Dict'}; {'id': '23', 'type': 'type_parameter', 'children': ['24', '26']}; {'id': '24', 'type': 'type', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '26', 'type': 'type', 'children': ['27']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'Any'}; {'id': '28', 'type': 'block', 'children': ['29', '39', '58']}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'J'}; {'id': '32', 'type': 'call', 'children': ['33', '36']}; {'id': '33', 'type': 'attribute', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'ca'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'jacobian'}; {'id': '36', 'type': 'argument_list', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '49']}; {'id': '41', 'type': 'pattern_list', 'children': ['42', '43', '44', '45', '46', '47', '48']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'nblock'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'rowperm'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'colperm'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'rowblock'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'colblock'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'coarserow'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'coarsecol'}; {'id': '49', 'type': 'call', 'children': ['50', '57']}; {'id': '50', 'type': 'attribute', 'children': ['51', '56']}; {'id': '51', 'type': 'call', 'children': ['52', '55']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'J'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'sparsity'}; {'id': '55', 'type': 'argument_list', 'children': []}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'btf'}; {'id': '57', 'type': 'argument_list', 'children': []}; {'id': '58', 'type': 'return_statement', 'children': ['59']}; {'id': '59', 'type': 'dictionary', 'children': ['60', '63', '66', '69', '72', '75', '78', '81']}; {'id': '60', 'type': 'pair', 'children': ['61', '62']}; {'id': '61', 'type': 'string', 'children': [], 'value': "'J'"}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'J'}; {'id': '63', 'type': 'pair', 'children': ['64', '65']}; {'id': '64', 'type': 'string', 'children': [], 'value': "'nblock'"}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'nblock'}; {'id': '66', 'type': 'pair', 'children': ['67', '68']}; {'id': '67', 'type': 'string', 'children': [], 'value': "'rowperm'"}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'rowperm'}; {'id': '69', 'type': 'pair', 'children': ['70', '71']}; {'id': '70', 'type': 'string', 'children': [], 'value': "'colperm'"}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'colperm'}; {'id': '72', 'type': 'pair', 'children': ['73', '74']}; {'id': '73', 'type': 'string', 'children': [], 'value': "'rowblock'"}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'rowblock'}; {'id': '75', 'type': 'pair', 'children': ['76', '77']}; {'id': '76', 'type': 'string', 'children': [], 'value': "'colblock'"}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'colblock'}; {'id': '78', 'type': 'pair', 'children': ['79', '80']}; {'id': '79', 'type': 'string', 'children': [], 'value': "'coarserow'"}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'coarserow'}; {'id': '81', 'type': 'pair', 'children': ['82', '83']}; {'id': '82', 'type': 'string', 'children': [], 'value': "'coarsecol'"}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'coarsecol'}
Sort equations by dependence
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'sort_generators'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'call', 'children': ['8', '13']}; {'id': '8', 'type': 'attribute', 'children': ['9', '12']}; {'id': '9', 'type': 'attribute', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'sort'}; {'id': '13', 'type': 'argument_list', 'children': ['14']}; {'id': '14', 'type': 'keyword_argument', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '16', 'type': 'lambda', 'children': ['17', '19']}; {'id': '17', 'type': 'lambda_parameters', 'children': ['18']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'gn'}; {'id': '19', 'type': 'attribute', 'children': ['20', '23']}; {'id': '20', 'type': 'attribute', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'gn'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'bus'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': '_i'}
Reorders the list of generators according to bus index.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'format'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'file_metrics'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'build_metrics'}; {'id': '6', 'type': 'block', 'children': ['7', '132', '141', '150', '157', '226', '245', '250', '276']}; {'id': '7', 'type': 'function_definition', 'children': ['8', '9', '14']}; {'id': '8', 'type': 'function_name', 'children': [], 'value': 'indent'}; {'id': '9', 'type': 'parameters', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '11', 'type': 'default_parameter', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '13', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '14', 'type': 'block', 'children': ['15', '23']}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '18', 'type': 'binary_operator', 'children': ['19', '20'], 'value': '+'}; {'id': '19', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '20', 'type': 'binary_operator', 'children': ['21', '22'], 'value': '*'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '22', 'type': 'string', 'children': [], 'value': '" "'}; {'id': '23', 'type': 'if_statement', 'children': ['24', '28', '106']}; {'id': '24', 'type': 'call', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '26', 'type': 'argument_list', 'children': ['27']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '28', 'type': 'block', 'children': ['29', '52', '73', '85']}; {'id': '29', 'type': 'if_statement', 'children': ['30', '43']}; {'id': '30', 'type': 'boolean_operator', 'children': ['31', '35'], 'value': 'or'}; {'id': '31', 'type': 'not_operator', 'children': ['32']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'text'}; {'id': '35', 'type': 'not_operator', 'children': ['36']}; {'id': '36', 'type': 'call', 'children': ['37', '42']}; {'id': '37', 'type': 'attribute', 'children': ['38', '41']}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'text'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '42', 'type': 'argument_list', 'children': []}; {'id': '43', 'type': 'block', 'children': ['44']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'text'}; {'id': '49', 'type': 'binary_operator', 'children': ['50', '51'], 'value': '+'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '51', 'type': 'string', 'children': [], 'value': '" "'}; {'id': '52', 'type': 'if_statement', 'children': ['53', '66']}; {'id': '53', 'type': 'boolean_operator', 'children': ['54', '58'], 'value': 'or'}; {'id': '54', 'type': 'not_operator', 'children': ['55']}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '58', 'type': 'not_operator', 'children': ['59']}; {'id': '59', 'type': 'call', 'children': ['60', '65']}; {'id': '60', 'type': 'attribute', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '65', 'type': 'argument_list', 'children': []}; {'id': '66', 'type': 'block', 'children': ['67']}; {'id': '67', 'type': 'expression_statement', 'children': ['68']}; {'id': '68', 'type': 'assignment', 'children': ['69', '72']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '73', 'type': 'for_statement', 'children': ['74', '75', '76']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '76', 'type': 'block', 'children': ['77']}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'call', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'indent'}; {'id': '80', 'type': 'argument_list', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '82', 'type': 'binary_operator', 'children': ['83', '84'], 'value': '+'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '84', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '85', 'type': 'if_statement', 'children': ['86', '99']}; {'id': '86', 'type': 'boolean_operator', 'children': ['87', '91'], 'value': 'or'}; {'id': '87', 'type': 'not_operator', 'children': ['88']}; {'id': '88', 'type': 'attribute', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '91', 'type': 'not_operator', 'children': ['92']}; {'id': '92', 'type': 'call', 'children': ['93', '98']}; {'id': '93', 'type': 'attribute', 'children': ['94', '97']}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '98', 'type': 'argument_list', 'children': []}; {'id': '99', 'type': 'block', 'children': ['100']}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'assignment', 'children': ['102', '105']}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '106', 'type': 'else_clause', 'children': ['107']}; {'id': '107', 'type': 'block', 'children': ['108']}; {'id': '108', 'type': 'if_statement', 'children': ['109', '125']}; {'id': '109', 'type': 'boolean_operator', 'children': ['110', '111'], 'value': 'and'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '111', 'type': '()', 'children': ['112']}; {'id': '112', 'type': 'boolean_operator', 'children': ['113', '117'], 'value': 'or'}; {'id': '113', 'type': 'not_operator', 'children': ['114']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '117', 'type': 'not_operator', 'children': ['118']}; {'id': '118', 'type': 'call', 'children': ['119', '124']}; {'id': '119', 'type': 'attribute', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '124', 'type': 'argument_list', 'children': []}; {'id': '125', 'type': 'block', 'children': ['126']}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'assignment', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'elem'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'assignment', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'Element'}; {'id': '139', 'type': 'argument_list', 'children': ['140']}; {'id': '140', 'type': 'string', 'children': [], 'value': "'metrics'"}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'assignment', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'files'}; {'id': '144', 'type': 'call', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'Element'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'string', 'children': [], 'value': "'files'"}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'call', 'children': ['152', '155']}; {'id': '152', 'type': 'attribute', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '155', 'type': 'argument_list', 'children': ['156']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'files'}; {'id': '157', 'type': 'for_statement', 'children': ['158', '159', '164']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '159', 'type': 'call', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'file_metrics'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '163', 'type': 'argument_list', 'children': []}; {'id': '164', 'type': 'block', 'children': ['165', '186']}; {'id': '165', 'type': 'expression_statement', 'children': ['166']}; {'id': '166', 'type': 'assignment', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'tmp_file'}; {'id': '168', 'type': 'call', 'children': ['169', '172']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'SubElement'}; {'id': '172', 'type': 'argument_list', 'children': ['173', '174', '175']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'files'}; {'id': '174', 'type': 'string', 'children': [], 'value': '"file"'}; {'id': '175', 'type': 'dictionary', 'children': ['176', '179']}; {'id': '176', 'type': 'pair', 'children': ['177', '178']}; {'id': '177', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '179', 'type': 'pair', 'children': ['180', '181']}; {'id': '180', 'type': 'string', 'children': [], 'value': "'language'"}; {'id': '181', 'type': 'subscript', 'children': ['182', '185']}; {'id': '182', 'type': 'subscript', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'file_metrics'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '185', 'type': 'string', 'children': [], 'value': "'language'"}; {'id': '186', 'type': 'for_statement', 'children': ['187', '188', '195']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '188', 'type': 'call', 'children': ['189', '194']}; {'id': '189', 'type': 'attribute', 'children': ['190', '193']}; {'id': '190', 'type': 'subscript', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'file_metrics'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '194', 'type': 'argument_list', 'children': []}; {'id': '195', 'type': 'block', 'children': ['196', '202']}; {'id': '196', 'type': 'if_statement', 'children': ['197', '200']}; {'id': '197', 'type': 'comparison_operator', 'children': ['198', '199'], 'value': '=='}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '199', 'type': 'string', 'children': [], 'value': "'language'"}; {'id': '200', 'type': 'block', 'children': ['201']}; {'id': '201', 'type': 'continue_statement', 'children': []}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'tmp_metric'}; {'id': '205', 'type': 'call', 'children': ['206', '209']}; {'id': '206', 'type': 'attribute', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'SubElement'}; {'id': '209', 'type': 'argument_list', 'children': ['210', '211', '212']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'tmp_file'}; {'id': '211', 'type': 'string', 'children': [], 'value': '"metric"'}; {'id': '212', 'type': 'dictionary', 'children': ['213', '216']}; {'id': '213', 'type': 'pair', 'children': ['214', '215']}; {'id': '214', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '216', 'type': 'pair', 'children': ['217', '218']}; {'id': '217', 'type': 'string', 'children': [], 'value': "'value'"}; {'id': '218', 'type': 'call', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '220', 'type': 'argument_list', 'children': ['221']}; {'id': '221', 'type': 'subscript', 'children': ['222', '225']}; {'id': '222', 'type': 'subscript', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'file_metrics'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '226', 'type': 'if_statement', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'build_metrics'}; {'id': '228', 'type': 'block', 'children': ['229', '238']}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'assignment', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'build'}; {'id': '232', 'type': 'call', 'children': ['233', '236']}; {'id': '233', 'type': 'attribute', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'Element'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'string', 'children': [], 'value': "'build'"}; {'id': '238', 'type': 'expression_statement', 'children': ['239']}; {'id': '239', 'type': 'call', 'children': ['240', '243']}; {'id': '240', 'type': 'attribute', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '243', 'type': 'argument_list', 'children': ['244']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'build'}; {'id': '245', 'type': 'expression_statement', 'children': ['246']}; {'id': '246', 'type': 'call', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'indent'}; {'id': '248', 'type': 'argument_list', 'children': ['249']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '250', 'type': 'if_statement', 'children': ['251', '252', '265']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'PY3'}; {'id': '252', 'type': 'block', 'children': ['253']}; {'id': '253', 'type': 'expression_statement', 'children': ['254']}; {'id': '254', 'type': 'assignment', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'body'}; {'id': '256', 'type': 'call', 'children': ['257', '260']}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'tostring'}; {'id': '260', 'type': 'argument_list', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '262', 'type': 'keyword_argument', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '264', 'type': 'string', 'children': [], 'value': "'unicode'"}; {'id': '265', 'type': 'else_clause', 'children': ['266']}; {'id': '266', 'type': 'block', 'children': ['267']}; {'id': '267', 'type': 'expression_statement', 'children': ['268']}; {'id': '268', 'type': 'assignment', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'body'}; {'id': '270', 'type': 'call', 'children': ['271', '274']}; {'id': '271', 'type': 'attribute', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'ET'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'tostring'}; {'id': '274', 'type': 'argument_list', 'children': ['275']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '276', 'type': 'return_statement', 'children': ['277']}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'body'}
compute output in XML format.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_voltage_angle_diff_limit'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'buses'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '7', 'type': 'block', 'children': ['8', '15', '300']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'nb'}; {'id': '11', 'type': 'call', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '13', 'type': 'argument_list', 'children': ['14']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'buses'}; {'id': '15', 'type': 'if_statement', 'children': ['16', '20', '275']}; {'id': '16', 'type': 'not_operator', 'children': ['17']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'ignore_ang_lim'}; {'id': '20', 'type': 'block', 'children': ['21', '59', '83', '107', '114']}; {'id': '21', 'type': 'expression_statement', 'children': ['22']}; {'id': '22', 'type': 'assignment', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '24', 'type': 'list_comprehension', 'children': ['25', '26', '34']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '26', 'type': 'for_in_clause', 'children': ['27', '30']}; {'id': '27', 'type': 'pattern_list', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '30', 'type': 'call', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '32', 'type': 'argument_list', 'children': ['33']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '34', 'type': 'if_clause', 'children': ['35']}; {'id': '35', 'type': 'boolean_operator', 'children': ['36', '48'], 'value': 'or'}; {'id': '36', 'type': '()', 'children': ['37']}; {'id': '37', 'type': 'boolean_operator', 'children': ['38', '41'], 'value': 'and'}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'ang_min'}; {'id': '41', 'type': '()', 'children': ['42']}; {'id': '42', 'type': 'comparison_operator', 'children': ['43', '46'], 'value': '>'}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'ang_min'}; {'id': '46', 'type': 'unary_operator', 'children': ['47'], 'value': '-'}; {'id': '47', 'type': 'float', 'children': [], 'value': '360.0'}; {'id': '48', 'type': '()', 'children': ['49']}; {'id': '49', 'type': 'boolean_operator', 'children': ['50', '53'], 'value': 'and'}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'ang_max'}; {'id': '53', 'type': '()', 'children': ['54']}; {'id': '54', 'type': 'comparison_operator', 'children': ['55', '58'], 'value': '<'}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'ang_max'}; {'id': '58', 'type': 'float', 'children': [], 'value': '360.0'}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'iangl'}; {'id': '62', 'type': 'subscript', 'children': ['63', '82']}; {'id': '63', 'type': 'call', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'list_comprehension', 'children': ['67', '68', '76']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '68', 'type': 'for_in_clause', 'children': ['69', '72']}; {'id': '69', 'type': 'pattern_list', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '72', 'type': 'call', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '74', 'type': 'argument_list', 'children': ['75']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '76', 'type': 'if_clause', 'children': ['77']}; {'id': '77', 'type': 'comparison_operator', 'children': ['78', '81'], 'value': 'is'}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'ang_min'}; {'id': '81', 'type': 'None', 'children': []}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'iangh'}; {'id': '86', 'type': 'subscript', 'children': ['87', '106']}; {'id': '87', 'type': 'call', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'list_comprehension', 'children': ['91', '92', '100']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '92', 'type': 'for_in_clause', 'children': ['93', '96']}; {'id': '93', 'type': 'pattern_list', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '96', 'type': 'call', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '98', 'type': 'argument_list', 'children': ['99']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '100', 'type': 'if_clause', 'children': ['101']}; {'id': '101', 'type': 'comparison_operator', 'children': ['102', '105'], 'value': 'is'}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'ang_max'}; {'id': '105', 'type': 'None', 'children': []}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '107', 'type': 'expression_statement', 'children': ['108']}; {'id': '108', 'type': 'assignment', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '110', 'type': 'call', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '112', 'type': 'argument_list', 'children': ['113']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '114', 'type': 'if_statement', 'children': ['115', '118', '250']}; {'id': '115', 'type': 'comparison_operator', 'children': ['116', '117'], 'value': '>'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '117', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '118', 'type': 'block', 'children': ['119', '131', '148', '165', '172', '192', '201', '206', '228']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'assignment', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'ii'}; {'id': '122', 'type': 'binary_operator', 'children': ['123', '127'], 'value': '+'}; {'id': '123', 'type': 'call', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '127', 'type': 'call', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '129', 'type': 'argument_list', 'children': ['130']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '131', 'type': 'expression_statement', 'children': ['132']}; {'id': '132', 'type': 'assignment', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'jjf'}; {'id': '134', 'type': 'subscript', 'children': ['135', '147']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'list_comprehension', 'children': ['139', '144']}; {'id': '139', 'type': 'attribute', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'from_bus'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': '_i'}; {'id': '144', 'type': 'for_in_clause', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'jjt'}; {'id': '151', 'type': 'subscript', 'children': ['152', '164']}; {'id': '152', 'type': 'call', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '154', 'type': 'argument_list', 'children': ['155']}; {'id': '155', 'type': 'list_comprehension', 'children': ['156', '161']}; {'id': '156', 'type': 'attribute', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'to_bus'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': '_i'}; {'id': '161', 'type': 'for_in_clause', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'iang'}; {'id': '165', 'type': 'expression_statement', 'children': ['166']}; {'id': '166', 'type': 'assignment', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'jj'}; {'id': '168', 'type': 'subscript', 'children': ['169', '170', '171']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'jjf'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'jjt'}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'assignment', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'Aang'}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'csr_matrix'}; {'id': '177', 'type': 'argument_list', 'children': ['178', '189']}; {'id': '178', 'type': 'subscript', 'children': ['179', '180', '184']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'r_'}; {'id': '180', 'type': 'call', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'ones'}; {'id': '182', 'type': 'argument_list', 'children': ['183']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '184', 'type': 'unary_operator', 'children': ['185'], 'value': '-'}; {'id': '185', 'type': 'call', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'ones'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '189', 'type': 'tuple', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'ii'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'jj'}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '195', 'type': 'binary_operator', 'children': ['196', '197'], 'value': '*'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'Inf'}; {'id': '197', 'type': 'call', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'ones'}; {'id': '199', 'type': 'argument_list', 'children': ['200']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'nang'}; {'id': '201', 'type': 'expression_statement', 'children': ['202']}; {'id': '202', 'type': 'assignment', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'lang'}; {'id': '204', 'type': 'unary_operator', 'children': ['205'], 'value': '-'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'assignment', 'children': ['208', '211']}; {'id': '208', 'type': 'subscript', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'lang'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'iangl'}; {'id': '211', 'type': 'subscript', 'children': ['212', '227']}; {'id': '212', 'type': 'call', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '214', 'type': 'argument_list', 'children': ['215']}; {'id': '215', 'type': 'list_comprehension', 'children': ['216', '224']}; {'id': '216', 'type': 'binary_operator', 'children': ['217', '220'], 'value': '*'}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'ang_min'}; {'id': '220', 'type': '()', 'children': ['221']}; {'id': '221', 'type': 'binary_operator', 'children': ['222', '223'], 'value': '/'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'pi'}; {'id': '223', 'type': 'float', 'children': [], 'value': '180.0'}; {'id': '224', 'type': 'for_in_clause', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'iangl'}; {'id': '228', 'type': 'expression_statement', 'children': ['229']}; {'id': '229', 'type': 'assignment', 'children': ['230', '233']}; {'id': '230', 'type': 'subscript', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'iangh'}; {'id': '233', 'type': 'subscript', 'children': ['234', '249']}; {'id': '234', 'type': 'call', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'list_comprehension', 'children': ['238', '246']}; {'id': '238', 'type': 'binary_operator', 'children': ['239', '242'], 'value': '*'}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'ang_max'}; {'id': '242', 'type': '()', 'children': ['243']}; {'id': '243', 'type': 'binary_operator', 'children': ['244', '245'], 'value': '/'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'pi'}; {'id': '245', 'type': 'float', 'children': [], 'value': '180.0'}; {'id': '246', 'type': 'for_in_clause', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'branches'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'iangh'}; {'id': '250', 'type': 'else_clause', 'children': ['251']}; {'id': '251', 'type': 'block', 'children': ['252', '261', '268']}; {'id': '252', 'type': 'expression_statement', 'children': ['253']}; {'id': '253', 'type': 'assignment', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'Aang'}; {'id': '255', 'type': 'call', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '257', 'type': 'argument_list', 'children': ['258']}; {'id': '258', 'type': 'tuple', 'children': ['259', '260']}; {'id': '259', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'nb'}; {'id': '261', 'type': 'expression_statement', 'children': ['262']}; {'id': '262', 'type': 'assignment', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'lang'}; {'id': '264', 'type': 'call', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '266', 'type': 'argument_list', 'children': ['267']}; {'id': '267', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '268', 'type': 'expression_statement', 'children': ['269']}; {'id': '269', 'type': 'assignment', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '271', 'type': 'call', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '273', 'type': 'argument_list', 'children': ['274']}; {'id': '274', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '275', 'type': 'else_clause', 'children': ['276']}; {'id': '276', 'type': 'block', 'children': ['277', '286', '293']}; {'id': '277', 'type': 'expression_statement', 'children': ['278']}; {'id': '278', 'type': 'assignment', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'Aang'}; {'id': '280', 'type': 'call', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'zeros'}; {'id': '282', 'type': 'argument_list', 'children': ['283']}; {'id': '283', 'type': 'tuple', 'children': ['284', '285']}; {'id': '284', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'nb'}; {'id': '286', 'type': 'expression_statement', 'children': ['287']}; {'id': '287', 'type': 'assignment', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'lang'}; {'id': '289', 'type': 'call', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '291', 'type': 'argument_list', 'children': ['292']}; {'id': '292', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '293', 'type': 'expression_statement', 'children': ['294']}; {'id': '294', 'type': 'assignment', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '296', 'type': 'call', 'children': ['297', '298']}; {'id': '297', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '298', 'type': 'argument_list', 'children': ['299']}; {'id': '299', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '300', 'type': 'return_statement', 'children': ['301']}; {'id': '301', 'type': 'call', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'LinearConstraint'}; {'id': '303', 'type': 'argument_list', 'children': ['304', '305', '306', '307', '308']}; {'id': '304', 'type': 'string', 'children': [], 'value': '"ang"'}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'Aang'}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'lang'}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'uang'}; {'id': '308', 'type': 'list', 'children': ['309'], 'value': '["Va"]'}; {'id': '309', 'type': 'string', 'children': [], 'value': '"Va"'}
Returns the constraint on the branch voltage angle differences.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_clipPrices'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '38', '70', '107', '144']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '10']}; {'id': '7', 'type': 'attribute', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'guaranteeOfferPrice'}; {'id': '10', 'type': 'block', 'children': ['11']}; {'id': '11', 'type': 'for_statement', 'children': ['12', '13', '16']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '13', 'type': 'attribute', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'offers'}; {'id': '16', 'type': 'block', 'children': ['17']}; {'id': '17', 'type': 'if_statement', 'children': ['18', '29']}; {'id': '18', 'type': 'boolean_operator', 'children': ['19', '22'], 'value': 'and'}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'accepted'}; {'id': '22', 'type': 'comparison_operator', 'children': ['23', '26'], 'value': '<'}; {'id': '23', 'type': 'attribute', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'price'}; {'id': '29', 'type': 'block', 'children': ['30']}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'price'}; {'id': '38', 'type': 'if_statement', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'guaranteeBidPrice'}; {'id': '42', 'type': 'block', 'children': ['43']}; {'id': '43', 'type': 'for_statement', 'children': ['44', '45', '48']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'bids'}; {'id': '48', 'type': 'block', 'children': ['49']}; {'id': '49', 'type': 'if_statement', 'children': ['50', '61']}; {'id': '50', 'type': 'boolean_operator', 'children': ['51', '54'], 'value': 'and'}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'accepted'}; {'id': '54', 'type': 'comparison_operator', 'children': ['55', '58'], 'value': '>'}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'price'}; {'id': '61', 'type': 'block', 'children': ['62']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '67']}; {'id': '64', 'type': 'attribute', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'price'}; {'id': '70', 'type': 'if_statement', 'children': ['71', '79']}; {'id': '71', 'type': 'call', 'children': ['72', '77']}; {'id': '72', 'type': 'attribute', 'children': ['73', '76']}; {'id': '73', 'type': 'attribute', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'limits'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'has_key'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'string', 'children': [], 'value': '"maxClearedOffer"'}; {'id': '79', 'type': 'block', 'children': ['80', '88']}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'maxClearedOffer'}; {'id': '83', 'type': 'subscript', 'children': ['84', '87']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'limits'}; {'id': '87', 'type': 'string', 'children': [], 'value': '"maxClearedOffer"'}; {'id': '88', 'type': 'for_statement', 'children': ['89', '90', '93']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'offers'}; {'id': '93', 'type': 'block', 'children': ['94']}; {'id': '94', 'type': 'if_statement', 'children': ['95', '100']}; {'id': '95', 'type': 'comparison_operator', 'children': ['96', '99'], 'value': '>'}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'maxClearedOffer'}; {'id': '100', 'type': 'block', 'children': ['101']}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'assignment', 'children': ['103', '106']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'offer'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'maxClearedOffer'}; {'id': '107', 'type': 'if_statement', 'children': ['108', '116']}; {'id': '108', 'type': 'call', 'children': ['109', '114']}; {'id': '109', 'type': 'attribute', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'limits'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'has_key'}; {'id': '114', 'type': 'argument_list', 'children': ['115']}; {'id': '115', 'type': 'string', 'children': [], 'value': '"minClearedBid"'}; {'id': '116', 'type': 'block', 'children': ['117', '125']}; {'id': '117', 'type': 'expression_statement', 'children': ['118']}; {'id': '118', 'type': 'assignment', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'minClearedBid'}; {'id': '120', 'type': 'subscript', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'limits'}; {'id': '124', 'type': 'string', 'children': [], 'value': '"minClearedBid"'}; {'id': '125', 'type': 'for_statement', 'children': ['126', '127', '130']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '127', 'type': 'attribute', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'bids'}; {'id': '130', 'type': 'block', 'children': ['131']}; {'id': '131', 'type': 'if_statement', 'children': ['132', '137']}; {'id': '132', 'type': 'comparison_operator', 'children': ['133', '136'], 'value': '<'}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'minClearedBid'}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'assignment', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'minClearedBid'}; {'id': '144', 'type': 'if_statement', 'children': ['145', '150']}; {'id': '145', 'type': 'comparison_operator', 'children': ['146', '149'], 'value': '!='}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'auctionType'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'DISCRIMINATIVE'}; {'id': '150', 'type': 'block', 'children': ['151']}; {'id': '151', 'type': 'for_statement', 'children': ['152', '153', '158']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '153', 'type': 'attribute', 'children': ['154', '157']}; {'id': '154', 'type': 'attribute', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'generators'}; {'id': '158', 'type': 'block', 'children': ['159', '175', '201', '217']}; {'id': '159', 'type': 'expression_statement', 'children': ['160']}; {'id': '160', 'type': 'assignment', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'gOffers'}; {'id': '162', 'type': 'list_comprehension', 'children': ['163', '164', '169']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '164', 'type': 'for_in_clause', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'offers'}; {'id': '169', 'type': 'if_clause', 'children': ['170']}; {'id': '170', 'type': 'comparison_operator', 'children': ['171', '174'], 'value': '=='}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'generator'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '175', 'type': 'if_statement', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'gOffers'}; {'id': '177', 'type': 'block', 'children': ['178', '191']}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'assignment', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'uniformPrice'}; {'id': '181', 'type': 'call', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '183', 'type': 'argument_list', 'children': ['184']}; {'id': '184', 'type': 'list_comprehension', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '188', 'type': 'for_in_clause', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'gOffers'}; {'id': '191', 'type': 'for_statement', 'children': ['192', '193', '194']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'gOffers'}; {'id': '194', 'type': 'block', 'children': ['195']}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'assignment', 'children': ['197', '200']}; {'id': '197', 'type': 'attribute', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'of'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'uniformPrice'}; {'id': '201', 'type': 'expression_statement', 'children': ['202']}; {'id': '202', 'type': 'assignment', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'gBids'}; {'id': '204', 'type': 'list_comprehension', 'children': ['205', '206', '211']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '206', 'type': 'for_in_clause', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'bids'}; {'id': '211', 'type': 'if_clause', 'children': ['212']}; {'id': '212', 'type': 'comparison_operator', 'children': ['213', '216'], 'value': '=='}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'vLoad'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'g'}; {'id': '217', 'type': 'if_statement', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'gBids'}; {'id': '219', 'type': 'block', 'children': ['220', '233']}; {'id': '220', 'type': 'expression_statement', 'children': ['221']}; {'id': '221', 'type': 'assignment', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'uniformPrice'}; {'id': '223', 'type': 'call', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '225', 'type': 'argument_list', 'children': ['226']}; {'id': '226', 'type': 'list_comprehension', 'children': ['227', '230']}; {'id': '227', 'type': 'attribute', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'cleared_price'}; {'id': '230', 'type': 'for_in_clause', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'gBids'}; {'id': '233', 'type': 'for_statement', 'children': ['234', '235', '236']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'gBids'}; {'id': '236', 'type': 'block', 'children': ['237']}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'assignment', 'children': ['239', '242']}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'bid'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'clearedPrice'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'uniformPrice'}
Clip cleared prices according to guarantees and limits.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'from_config'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '18', '172']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'matrix'}; {'id': '9', 'type': 'dictionary', 'children': []}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'variables'}; {'id': '13', 'type': 'call', 'children': ['14', '17']}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '17', 'type': 'argument_list', 'children': []}; {'id': '18', 'type': 'for_statement', 'children': ['19', '20', '29']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'entries'}; {'id': '20', 'type': 'call', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'product'}; {'id': '22', 'type': 'argument_list', 'children': ['23']}; {'id': '23', 'type': 'list_splat', 'children': ['24']}; {'id': '24', 'type': 'call', 'children': ['25', '28']}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '28', 'type': 'argument_list', 'children': []}; {'id': '29', 'type': 'block', 'children': ['30', '41', '45', '108']}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'combination'}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '35', 'type': 'argument_list', 'children': ['36']}; {'id': '36', 'type': 'call', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '38', 'type': 'argument_list', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'variables'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'entries'}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'assignment', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'include'}; {'id': '44', 'type': 'True', 'children': []}; {'id': '45', 'type': 'for_statement', 'children': ['46', '47', '52']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'combination'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '51', 'type': 'argument_list', 'children': []}; {'id': '52', 'type': 'block', 'children': ['53']}; {'id': '53', 'type': 'for_statement', 'children': ['54', '55', '58']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'reducers'}; {'id': '58', 'type': 'block', 'children': ['59', '95']}; {'id': '59', 'type': 'if_statement', 'children': ['60', '65', '77']}; {'id': '60', 'type': 'comparison_operator', 'children': ['61', '64'], 'value': '=='}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '64', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '65', 'type': 'block', 'children': ['66']}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'assignment', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '69', 'type': 'not_operator', 'children': ['70']}; {'id': '70', 'type': 'attribute', 'children': ['71', '76']}; {'id': '71', 'type': 'subscript', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'combination'}; {'id': '73', 'type': 'attribute', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'variable'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '77', 'type': 'else_clause', 'children': ['78']}; {'id': '78', 'type': 'block', 'children': ['79']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '82', 'type': 'call', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'fnmatch'}; {'id': '84', 'type': 'argument_list', 'children': ['85', '92']}; {'id': '85', 'type': 'attribute', 'children': ['86', '91']}; {'id': '86', 'type': 'subscript', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'combination'}; {'id': '88', 'type': 'attribute', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'variable'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '95', 'type': 'if_statement', 'children': ['96', '103']}; {'id': '96', 'type': 'conditional_expression', 'children': ['97', '98', '101'], 'value': 'if'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'reducer'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'is_exclude'}; {'id': '101', 'type': 'not_operator', 'children': ['102']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '103', 'type': 'block', 'children': ['104']}; {'id': '104', 'type': 'expression_statement', 'children': ['105']}; {'id': '105', 'type': 'assignment', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'include'}; {'id': '107', 'type': 'False', 'children': []}; {'id': '108', 'type': 'if_statement', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'include'}; {'id': '110', 'type': 'block', 'children': ['111', '129', '146', '166']}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '118', 'type': 'generator_expression', 'children': ['119', '122', '125']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '122', 'type': 'for_in_clause', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'entries'}; {'id': '125', 'type': 'if_clause', 'children': ['126']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '129', 'type': 'expression_statement', 'children': ['130']}; {'id': '130', 'type': 'assignment', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '132', 'type': 'call', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'variables'}; {'id': '139', 'type': 'generator_expression', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '143', 'type': 'for_in_clause', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'entries'}; {'id': '146', 'type': 'if_statement', 'children': ['147', '156']}; {'id': '147', 'type': 'boolean_operator', 'children': ['148', '151'], 'value': 'and'}; {'id': '148', 'type': 'comparison_operator', 'children': ['149', '150'], 'value': 'in'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'matrix'}; {'id': '151', 'type': 'comparison_operator', 'children': ['152', '153'], 'value': '!='}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '153', 'type': 'subscript', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'matrix'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '156', 'type': 'block', 'children': ['157']}; {'id': '157', 'type': 'raise_statement', 'children': ['158']}; {'id': '158', 'type': 'call', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'DuplicateEnvironment'}; {'id': '160', 'type': 'argument_list', 'children': ['161', '162', '163']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '163', 'type': 'subscript', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'matrix'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'assignment', 'children': ['168', '171']}; {'id': '168', 'type': 'subscript', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'matrix'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '172', 'type': 'return_statement', 'children': ['173']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'matrix'}
Generate a matrix from a configuration dictionary.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'cleanup'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '12', '24', '45', '54', '66', '75', '97', '106', '123', '132', '154', '163', '190']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '11']}; {'id': '8', 'type': 'attribute', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'pre_exit_trigger'}; {'id': '11', 'type': 'True', 'children': []}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'call', 'children': ['14', '19']}; {'id': '14', 'type': 'attribute', 'children': ['15', '18']}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '19', 'type': 'argument_list', 'children': ['20', '21']}; {'id': '20', 'type': 'string', 'children': [], 'value': '"Shutting down %s, please wait a moment."'}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '24', 'type': 'for_statement', 'children': ['25', '26', '31']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'threading'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '30', 'type': 'argument_list', 'children': []}; {'id': '31', 'type': 'block', 'children': ['32']}; {'id': '32', 'type': 'if_statement', 'children': ['33', '38']}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '35', 'type': 'argument_list', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'TimerClass'}; {'id': '38', 'type': 'block', 'children': ['39']}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'call', 'children': ['41', '44']}; {'id': '41', 'type': 'attribute', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'cancel'}; {'id': '44', 'type': 'argument_list', 'children': []}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'call', 'children': ['47', '52']}; {'id': '47', 'type': 'attribute', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '52', 'type': 'argument_list', 'children': ['53']}; {'id': '53', 'type': 'string', 'children': [], 'value': "'Timers cancelled'"}; {'id': '54', 'type': 'for_statement', 'children': ['55', '56', '59']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'objects'}; {'id': '59', 'type': 'block', 'children': ['60']}; {'id': '60', 'type': 'expression_statement', 'children': ['61']}; {'id': '61', 'type': 'call', 'children': ['62', '65']}; {'id': '62', 'type': 'attribute', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'cleanup'}; {'id': '65', 'type': 'argument_list', 'children': []}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'call', 'children': ['68', '73']}; {'id': '68', 'type': 'attribute', 'children': ['69', '72']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '73', 'type': 'argument_list', 'children': ['74']}; {'id': '74', 'type': 'string', 'children': [], 'value': "'Sensors etc cleanups done'"}; {'id': '75', 'type': 'for_statement', 'children': ['76', '77', '90']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'ser'}; {'id': '77', 'type': 'generator_expression', 'children': ['78', '79', '84']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '79', 'type': 'for_in_clause', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '81', 'type': 'attribute', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'services'}; {'id': '84', 'type': 'if_clause', 'children': ['85']}; {'id': '85', 'type': 'call', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '87', 'type': 'argument_list', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'AbstractUserService'}; {'id': '90', 'type': 'block', 'children': ['91']}; {'id': '91', 'type': 'expression_statement', 'children': ['92']}; {'id': '92', 'type': 'call', 'children': ['93', '96']}; {'id': '93', 'type': 'attribute', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'ser'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'cleanup_system'}; {'id': '96', 'type': 'argument_list', 'children': []}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'call', 'children': ['99', '104']}; {'id': '99', 'type': 'attribute', 'children': ['100', '103']}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'string', 'children': [], 'value': "'User services cleaned up'"}; {'id': '106', 'type': 'if_statement', 'children': ['107', '114']}; {'id': '107', 'type': 'call', 'children': ['108', '113']}; {'id': '108', 'type': 'attribute', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'worker_thread'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'is_alive'}; {'id': '113', 'type': 'argument_list', 'children': []}; {'id': '114', 'type': 'block', 'children': ['115']}; {'id': '115', 'type': 'expression_statement', 'children': ['116']}; {'id': '116', 'type': 'call', 'children': ['117', '122']}; {'id': '117', 'type': 'attribute', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'worker_thread'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'stop'}; {'id': '122', 'type': 'argument_list', 'children': []}; {'id': '123', 'type': 'expression_statement', 'children': ['124']}; {'id': '124', 'type': 'call', 'children': ['125', '130']}; {'id': '125', 'type': 'attribute', 'children': ['126', '129']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '130', 'type': 'argument_list', 'children': ['131']}; {'id': '131', 'type': 'string', 'children': [], 'value': "'Worker thread really stopped'"}; {'id': '132', 'type': 'for_statement', 'children': ['133', '134', '147']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'ser'}; {'id': '134', 'type': 'generator_expression', 'children': ['135', '136', '141']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '136', 'type': 'for_in_clause', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'services'}; {'id': '141', 'type': 'if_clause', 'children': ['142']}; {'id': '142', 'type': 'call', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '144', 'type': 'argument_list', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'AbstractSystemService'}; {'id': '147', 'type': 'block', 'children': ['148']}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'ser'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'cleanup_system'}; {'id': '153', 'type': 'argument_list', 'children': []}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'call', 'children': ['156', '161']}; {'id': '156', 'type': 'attribute', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'string', 'children': [], 'value': "'System services cleaned up'"}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'assignment', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '166', 'type': 'call', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '168', 'type': 'generator_expression', 'children': ['169', '172', '179']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '172', 'type': 'for_in_clause', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '174', 'type': 'call', 'children': ['175', '178']}; {'id': '175', 'type': 'attribute', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'threading'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '178', 'type': 'argument_list', 'children': []}; {'id': '179', 'type': 'if_clause', 'children': ['180']}; {'id': '180', 'type': 'boolean_operator', 'children': ['181', '186'], 'value': 'and'}; {'id': '181', 'type': 'call', 'children': ['182', '185']}; {'id': '182', 'type': 'attribute', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'is_alive'}; {'id': '185', 'type': 'argument_list', 'children': []}; {'id': '186', 'type': 'not_operator', 'children': ['187']}; {'id': '187', 'type': 'attribute', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'daemon'}; {'id': '190', 'type': 'if_statement', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'threads'}; {'id': '192', 'type': 'block', 'children': ['193']}; {'id': '193', 'type': 'expression_statement', 'children': ['194']}; {'id': '194', 'type': 'call', 'children': ['195', '200']}; {'id': '195', 'type': 'attribute', 'children': ['196', '199']}; {'id': '196', 'type': 'attribute', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '200', 'type': 'argument_list', 'children': ['201', '204']}; {'id': '201', 'type': 'concatenated_string', 'children': ['202', '203']}; {'id': '202', 'type': 'string', 'children': [], 'value': "'After cleanup, we have still the following threads '"}; {'id': '203', 'type': 'string', 'children': [], 'value': "'running: %s'"}; {'id': '204', 'type': 'call', 'children': ['205', '208']}; {'id': '205', 'type': 'attribute', 'children': ['206', '207']}; {'id': '206', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'threads'}
Clean up before quitting
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_init_report'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '12', '18']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '11']}; {'id': '8', 'type': 'attribute', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'sections'}; {'id': '11', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '17']}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'section_names'}; {'id': '17', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '18', 'type': 'try_statement', 'children': ['19', '86', '90']}; {'id': '19', 'type': 'block', 'children': ['20', '60']}; {'id': '20', 'type': 'if_statement', 'children': ['21', '33']}; {'id': '21', 'type': 'comparison_operator', 'children': ['22', '32'], 'value': 'is'}; {'id': '22', 'type': 'call', 'children': ['23', '28']}; {'id': '23', 'type': 'attribute', 'children': ['24', '27']}; {'id': '24', 'type': 'attribute', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'isdir'}; {'id': '28', 'type': 'argument_list', 'children': ['29']}; {'id': '29', 'type': 'attribute', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '32', 'type': 'False', 'children': []}; {'id': '33', 'type': 'block', 'children': ['34', '51']}; {'id': '34', 'type': 'if_statement', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'verbose'}; {'id': '38', 'type': 'block', 'children': ['39']}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'call', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '42', 'type': 'argument_list', 'children': ['43']}; {'id': '43', 'type': 'call', 'children': ['44', '47']}; {'id': '44', 'type': 'attribute', 'children': ['45', '46']}; {'id': '45', 'type': 'string', 'children': [], 'value': '"Created directory {}"'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '47', 'type': 'argument_list', 'children': ['48']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'call', 'children': ['53', '56']}; {'id': '53', 'type': 'attribute', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'mkdir'}; {'id': '56', 'type': 'argument_list', 'children': ['57']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '60', 'type': 'for_statement', 'children': ['61', '62', '65']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'this'}; {'id': '62', 'type': 'attribute', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': '_to_create'}; {'id': '65', 'type': 'block', 'children': ['66']}; {'id': '66', 'type': 'try_statement', 'children': ['67', '83']}; {'id': '67', 'type': 'block', 'children': ['68']}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'call', 'children': ['70', '73']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'mkdir'}; {'id': '73', 'type': 'argument_list', 'children': ['74']}; {'id': '74', 'type': 'binary_operator', 'children': ['75', '82'], 'value': '+'}; {'id': '75', 'type': 'binary_operator', 'children': ['76', '79'], 'value': '+'}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'this'}; {'id': '83', 'type': 'except_clause', 'children': ['84']}; {'id': '84', 'type': 'block', 'children': ['85']}; {'id': '85', 'type': 'pass_statement', 'children': []}; {'id': '86', 'type': 'except_clause', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'Exception'}; {'id': '88', 'type': 'block', 'children': ['89']}; {'id': '89', 'type': 'pass_statement', 'children': []}; {'id': '90', 'type': 'finally_clause', 'children': ['91']}; {'id': '91', 'type': 'block', 'children': ['92', '101', '115', '134', '154', '160', '199', '256']}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'temp_path'}; {'id': '95', 'type': 'call', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'easydev'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'get_package_location'}; {'id': '99', 'type': 'argument_list', 'children': ['100']}; {'id': '100', 'type': 'string', 'children': [], 'value': '"reports"'}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'augmented_assignment', 'children': ['103', '104'], 'value': '+='}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'temp_path'}; {'id': '104', 'type': 'binary_operator', 'children': ['105', '114'], 'value': '+'}; {'id': '105', 'type': 'binary_operator', 'children': ['106', '111'], 'value': '+'}; {'id': '106', 'type': 'binary_operator', 'children': ['107', '110'], 'value': '+'}; {'id': '107', 'type': 'attribute', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '110', 'type': 'string', 'children': [], 'value': '"reports"'}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '114', 'type': 'string', 'children': [], 'value': '"resources"'}; {'id': '115', 'type': 'expression_statement', 'children': ['116']}; {'id': '116', 'type': 'assignment', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'filenames'}; {'id': '118', 'type': 'call', 'children': ['119', '122']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'glob'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'glob'}; {'id': '122', 'type': 'argument_list', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '129']}; {'id': '124', 'type': 'attribute', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '129', 'type': 'argument_list', 'children': ['130']}; {'id': '130', 'type': 'list', 'children': ['131', '132', '133'], 'value': '[temp_path, "css", "*.css"]'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'temp_path'}; {'id': '132', 'type': 'string', 'children': [], 'value': '"css"'}; {'id': '133', 'type': 'string', 'children': [], 'value': '"*.css"'}; {'id': '134', 'type': 'expression_statement', 'children': ['135']}; {'id': '135', 'type': 'augmented_assignment', 'children': ['136', '137'], 'value': '+='}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'filenames'}; {'id': '137', 'type': 'call', 'children': ['138', '141']}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'glob'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'glob'}; {'id': '141', 'type': 'argument_list', 'children': ['142']}; {'id': '142', 'type': 'call', 'children': ['143', '148']}; {'id': '143', 'type': 'attribute', 'children': ['144', '147']}; {'id': '144', 'type': 'attribute', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'list', 'children': ['150', '153'], 'value': "[self.searchpath, '*.css']"}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'searchpath'}; {'id': '153', 'type': 'string', 'children': [], 'value': "'*.css'"}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'augmented_assignment', 'children': ['156', '157'], 'value': '+='}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'filenames'}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'extra_css_list'}; {'id': '160', 'type': 'for_statement', 'children': ['161', '162', '163']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'filenames'}; {'id': '163', 'type': 'block', 'children': ['164', '179']}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '167', 'type': 'call', 'children': ['168', '173']}; {'id': '168', 'type': 'attribute', 'children': ['169', '172']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '173', 'type': 'argument_list', 'children': ['174']}; {'id': '174', 'type': 'list', 'children': ['175', '178'], 'value': "[self.directory, 'css' ]"}; {'id': '175', 'type': 'attribute', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '178', 'type': 'string', 'children': [], 'value': "'css'"}; {'id': '179', 'type': 'if_statement', 'children': ['180', '190']}; {'id': '180', 'type': 'comparison_operator', 'children': ['181', '189'], 'value': 'is'}; {'id': '181', 'type': 'call', 'children': ['182', '187']}; {'id': '182', 'type': 'attribute', 'children': ['183', '186']}; {'id': '183', 'type': 'attribute', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '189', 'type': 'False', 'children': []}; {'id': '190', 'type': 'block', 'children': ['191']}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'call', 'children': ['193', '196']}; {'id': '193', 'type': 'attribute', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'shutil'}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '196', 'type': 'argument_list', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '199', 'type': 'for_statement', 'children': ['200', '201', '205']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '201', 'type': 'list', 'children': ['202', '203', '204'], 'value': '[\'sorttable.js\', \'highlight.pack.js\', "jquery-1.12.3.min.js"]'}; {'id': '202', 'type': 'string', 'children': [], 'value': "'sorttable.js'"}; {'id': '203', 'type': 'string', 'children': [], 'value': "'highlight.pack.js'"}; {'id': '204', 'type': 'string', 'children': [], 'value': '"jquery-1.12.3.min.js"'}; {'id': '205', 'type': 'block', 'children': ['206', '222']}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'assignment', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '209', 'type': 'call', 'children': ['210', '215']}; {'id': '210', 'type': 'attribute', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '215', 'type': 'argument_list', 'children': ['216']}; {'id': '216', 'type': 'list', 'children': ['217', '220', '221'], 'value': "[self.directory, 'js', filename ]"}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '220', 'type': 'string', 'children': [], 'value': "'js'"}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '222', 'type': 'if_statement', 'children': ['223', '233']}; {'id': '223', 'type': 'comparison_operator', 'children': ['224', '232'], 'value': 'is'}; {'id': '224', 'type': 'call', 'children': ['225', '230']}; {'id': '225', 'type': 'attribute', 'children': ['226', '229']}; {'id': '226', 'type': 'attribute', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '230', 'type': 'argument_list', 'children': ['231']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '232', 'type': 'False', 'children': []}; {'id': '233', 'type': 'block', 'children': ['234', '248']}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'assignment', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '237', 'type': 'call', 'children': ['238', '243']}; {'id': '238', 'type': 'attribute', 'children': ['239', '242']}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '243', 'type': 'argument_list', 'children': ['244']}; {'id': '244', 'type': 'list', 'children': ['245', '246', '247'], 'value': '[temp_path, "javascript", filename]'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'temp_path'}; {'id': '246', 'type': 'string', 'children': [], 'value': '"javascript"'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '248', 'type': 'expression_statement', 'children': ['249']}; {'id': '249', 'type': 'call', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'shutil'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '253', 'type': 'argument_list', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '256', 'type': 'for_statement', 'children': ['257', '258', '261']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '258', 'type': 'attribute', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'extra_js_list'}; {'id': '261', 'type': 'block', 'children': ['262', '273', '289']}; {'id': '262', 'type': 'expression_statement', 'children': ['263']}; {'id': '263', 'type': 'assignment', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '265', 'type': 'call', 'children': ['266', '271']}; {'id': '266', 'type': 'attribute', 'children': ['267', '270']}; {'id': '267', 'type': 'attribute', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '271', 'type': 'argument_list', 'children': ['272']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '273', 'type': 'expression_statement', 'children': ['274']}; {'id': '274', 'type': 'assignment', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '276', 'type': 'call', 'children': ['277', '282']}; {'id': '277', 'type': 'attribute', 'children': ['278', '281']}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '282', 'type': 'argument_list', 'children': ['283']}; {'id': '283', 'type': 'list', 'children': ['284', '287', '288'], 'value': "[self.directory, 'js', basename ]"}; {'id': '284', 'type': 'attribute', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '287', 'type': 'string', 'children': [], 'value': "'js'"}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '289', 'type': 'if_statement', 'children': ['290', '300']}; {'id': '290', 'type': 'comparison_operator', 'children': ['291', '299'], 'value': 'is'}; {'id': '291', 'type': 'call', 'children': ['292', '297']}; {'id': '292', 'type': 'attribute', 'children': ['293', '296']}; {'id': '293', 'type': 'attribute', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '297', 'type': 'argument_list', 'children': ['298']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'target'}; {'id': '299', 'type': 'False', 'children': []}; {'id': '300', 'type': 'block', 'children': ['301']}; {'id': '301', 'type': 'expression_statement', 'children': ['302']}; {'id': '302', 'type': 'call', 'children': ['303', '306']}; {'id': '303', 'type': 'attribute', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'shutil'}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '306', 'type': 'argument_list', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'target'}
create the report directory and return the directory name
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'model_to_dict'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '5', 'type': 'dictionary_splat_pattern', 'children': ['6']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '7', 'type': 'block', 'children': ['8', '10', '17', '21', '53', '242', '257']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'string', 'children': [], 'value': '"Takes a model instance and converts it into a dict."'}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': '_defaults'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '20', 'type': 'dictionary', 'children': []}; {'id': '21', 'type': 'if_statement', 'children': ['22', '25']}; {'id': '22', 'type': 'subscript', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '24', 'type': 'string', 'children': [], 'value': "'prehook'"}; {'id': '25', 'type': 'block', 'children': ['26']}; {'id': '26', 'type': 'if_statement', 'children': ['27', '36']}; {'id': '27', 'type': 'call', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '29', 'type': 'argument_list', 'children': ['30', '33']}; {'id': '30', 'type': 'subscript', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '32', 'type': 'string', 'children': [], 'value': "'prehook'"}; {'id': '33', 'type': 'attribute', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'collections'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'Callable'}; {'id': '36', 'type': 'block', 'children': ['37', '46']}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'assignment', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '40', 'type': 'call', 'children': ['41', '44']}; {'id': '41', 'type': 'subscript', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '43', 'type': 'string', 'children': [], 'value': "'prehook'"}; {'id': '44', 'type': 'argument_list', 'children': ['45']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '46', 'type': 'if_statement', 'children': ['47', '50']}; {'id': '47', 'type': 'comparison_operator', 'children': ['48', '49'], 'value': 'is'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '49', 'type': 'None', 'children': []}; {'id': '50', 'type': 'block', 'children': ['51']}; {'id': '51', 'type': 'return_statement', 'children': ['52']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '53', 'type': 'for_statement', 'children': ['54', '55', '58']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '55', 'type': 'subscript', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '57', 'type': 'string', 'children': [], 'value': "'fields'"}; {'id': '58', 'type': 'block', 'children': ['59', '71', '79', '91', '104', '236']}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'accessor'}; {'id': '62', 'type': 'call', 'children': ['63', '68']}; {'id': '63', 'type': 'attribute', 'children': ['64', '67']}; {'id': '64', 'type': 'subscript', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '66', 'type': 'string', 'children': [], 'value': "'aliases'"}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '71', 'type': 'expression_statement', 'children': ['72']}; {'id': '72', 'type': 'assignment', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '74', 'type': 'binary_operator', 'children': ['75', '78'], 'value': '+'}; {'id': '75', 'type': 'subscript', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '77', 'type': 'string', 'children': [], 'value': "'prefix'"}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '79', 'type': 'if_statement', 'children': ['80', '83']}; {'id': '80', 'type': 'subscript', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '82', 'type': 'string', 'children': [], 'value': "'camelcase'"}; {'id': '83', 'type': 'block', 'children': ['84']}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '87', 'type': 'call', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'convert_to_camel'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '91', 'type': 'expression_statement', 'children': ['92']}; {'id': '92', 'type': 'assignment', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '94', 'type': 'call', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'get_field_value'}; {'id': '96', 'type': 'argument_list', 'children': ['97', '98', '99']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'accessor'}; {'id': '99', 'type': 'keyword_argument', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'allow_missing'}; {'id': '101', 'type': 'subscript', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '103', 'type': 'string', 'children': [], 'value': "'allow_missing'"}; {'id': '104', 'type': 'if_statement', 'children': ['105', '114']}; {'id': '105', 'type': 'call', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '109', 'type': 'tuple', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'models'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'Model'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'QuerySet'}; {'id': '114', 'type': 'block', 'children': ['115', '130', '150']}; {'id': '115', 'type': 'expression_statement', 'children': ['116']}; {'id': '116', 'type': 'assignment', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '118', 'type': 'call', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': '_defaults'}; {'id': '120', 'type': 'argument_list', 'children': ['121']}; {'id': '121', 'type': 'call', 'children': ['122', '127']}; {'id': '122', 'type': 'attribute', 'children': ['123', '126']}; {'id': '123', 'type': 'subscript', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '125', 'type': 'string', 'children': [], 'value': "'related'"}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '127', 'type': 'argument_list', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'accessor'}; {'id': '129', 'type': 'dictionary', 'children': []}; {'id': '130', 'type': 'if_statement', 'children': ['131', '136']}; {'id': '131', 'type': 'comparison_operator', 'children': ['132', '133'], 'value': 'in'}; {'id': '132', 'type': 'string', 'children': [], 'value': "'%(accessor)s'"}; {'id': '133', 'type': 'subscript', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '135', 'type': 'string', 'children': [], 'value': "'prefix'"}; {'id': '136', 'type': 'block', 'children': ['137']}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'assignment', 'children': ['139', '142']}; {'id': '139', 'type': 'subscript', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '141', 'type': 'string', 'children': [], 'value': "'prefix'"}; {'id': '142', 'type': 'binary_operator', 'children': ['143', '146'], 'value': '%'}; {'id': '143', 'type': 'subscript', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '145', 'type': 'string', 'children': [], 'value': "'prefix'"}; {'id': '146', 'type': 'dictionary', 'children': ['147']}; {'id': '147', 'type': 'pair', 'children': ['148', '149']}; {'id': '148', 'type': 'string', 'children': [], 'value': "'accessor'"}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '150', 'type': 'if_statement', 'children': ['151', '158', '225']}; {'id': '151', 'type': 'call', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '153', 'type': 'argument_list', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '155', 'type': 'attribute', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'models'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'Model'}; {'id': '158', 'type': 'block', 'children': ['159']}; {'id': '159', 'type': 'if_statement', 'children': ['160', '178', '197']}; {'id': '160', 'type': 'boolean_operator', 'children': ['161', '173', '174'], 'value': 'and'}; {'id': '161', 'type': 'boolean_operator', 'children': ['162', '170'], 'value': 'and'}; {'id': '162', 'type': 'comparison_operator', 'children': ['163', '169'], 'value': '=='}; {'id': '163', 'type': 'call', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '165', 'type': 'argument_list', 'children': ['166']}; {'id': '166', 'type': 'subscript', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '168', 'type': 'string', 'children': [], 'value': "'fields'"}; {'id': '169', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '170', 'type': 'subscript', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '172', 'type': 'string', 'children': [], 'value': "'flat'"}; {'id': '173', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '174', 'type': 'not_operator', 'children': ['175']}; {'id': '175', 'type': 'subscript', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '177', 'type': 'string', 'children': [], 'value': "'merge'"}; {'id': '178', 'type': 'block', 'children': ['179']}; {'id': '179', 'type': 'expression_statement', 'children': ['180']}; {'id': '180', 'type': 'assignment', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '182', 'type': 'subscript', 'children': ['183', '196']}; {'id': '183', 'type': 'call', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '185', 'type': 'argument_list', 'children': ['186']}; {'id': '186', 'type': 'call', 'children': ['187', '195']}; {'id': '187', 'type': 'attribute', 'children': ['188', '194']}; {'id': '188', 'type': 'call', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'serialize'}; {'id': '190', 'type': 'argument_list', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '192', 'type': 'dictionary_splat', 'children': ['193']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '195', 'type': 'argument_list', 'children': []}; {'id': '196', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '197', 'type': 'else_clause', 'children': ['198']}; {'id': '198', 'type': 'block', 'children': ['199', '208', '221']}; {'id': '199', 'type': 'expression_statement', 'children': ['200']}; {'id': '200', 'type': 'assignment', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': '_attrs'}; {'id': '202', 'type': 'call', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'serialize'}; {'id': '204', 'type': 'argument_list', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '206', 'type': 'dictionary_splat', 'children': ['207']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '208', 'type': 'if_statement', 'children': ['209', '212']}; {'id': '209', 'type': 'subscript', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '211', 'type': 'string', 'children': [], 'value': "'merge'"}; {'id': '212', 'type': 'block', 'children': ['213', '220']}; {'id': '213', 'type': 'expression_statement', 'children': ['214']}; {'id': '214', 'type': 'call', 'children': ['215', '218']}; {'id': '215', 'type': 'attribute', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '218', 'type': 'argument_list', 'children': ['219']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': '_attrs'}; {'id': '220', 'type': 'continue_statement', 'children': []}; {'id': '221', 'type': 'expression_statement', 'children': ['222']}; {'id': '222', 'type': 'assignment', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': '_attrs'}; {'id': '225', 'type': 'else_clause', 'children': ['226']}; {'id': '226', 'type': 'block', 'children': ['227']}; {'id': '227', 'type': 'expression_statement', 'children': ['228']}; {'id': '228', 'type': 'assignment', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '230', 'type': 'call', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'serialize'}; {'id': '232', 'type': 'argument_list', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '234', 'type': 'dictionary_splat', 'children': ['235']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': '_options'}; {'id': '236', 'type': 'expression_statement', 'children': ['237']}; {'id': '237', 'type': 'assignment', 'children': ['238', '241']}; {'id': '238', 'type': 'subscript', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '242', 'type': 'if_statement', 'children': ['243', '246']}; {'id': '243', 'type': 'subscript', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '245', 'type': 'string', 'children': [], 'value': "'posthook'"}; {'id': '246', 'type': 'block', 'children': ['247']}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'assignment', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '250', 'type': 'call', 'children': ['251', '254']}; {'id': '251', 'type': 'subscript', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '253', 'type': 'string', 'children': [], 'value': "'posthook'"}; {'id': '254', 'type': 'argument_list', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'attrs'}; {'id': '257', 'type': 'return_statement', 'children': ['258']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'attrs'}
Takes a model instance and converts it into a dict.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'endpoint'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '5', 'type': 'block', 'children': ['6', '15', '52', '79', '110', '134', '157', '168', '177', '202', '229', '246', '288', '316']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '12']}; {'id': '7', 'type': 'comparison_operator', 'children': ['8', '11'], 'value': '!='}; {'id': '8', 'type': 'attribute', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '11', 'type': 'string', 'children': [], 'value': "'POST'"}; {'id': '12', 'type': 'block', 'children': ['13']}; {'id': '13', 'type': 'raise_statement', 'children': ['14']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'Http404'}; {'id': '15', 'type': 'if_statement', 'children': ['16', '21']}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '18', 'type': 'argument_list', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '20', 'type': 'string', 'children': [], 'value': "'BOUNCY_TOPIC_ARN'"}; {'id': '21', 'type': 'block', 'children': ['22', '34']}; {'id': '22', 'type': 'if_statement', 'children': ['23', '28']}; {'id': '23', 'type': 'comparison_operator', 'children': ['24', '25'], 'value': 'not'}; {'id': '24', 'type': 'string', 'children': [], 'value': "'HTTP_X_AMZ_SNS_TOPIC_ARN'"}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'META'}; {'id': '28', 'type': 'block', 'children': ['29']}; {'id': '29', 'type': 'return_statement', 'children': ['30']}; {'id': '30', 'type': 'call', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '32', 'type': 'argument_list', 'children': ['33']}; {'id': '33', 'type': 'string', 'children': [], 'value': "'No TopicArn Header'"}; {'id': '34', 'type': 'if_statement', 'children': ['35', '46']}; {'id': '35', 'type': '()', 'children': ['36']}; {'id': '36', 'type': 'not_operator', 'children': ['37']}; {'id': '37', 'type': 'comparison_operator', 'children': ['38', '43'], 'value': 'in'}; {'id': '38', 'type': 'subscript', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'META'}; {'id': '42', 'type': 'string', 'children': [], 'value': "'HTTP_X_AMZ_SNS_TOPIC_ARN'"}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'BOUNCY_TOPIC_ARN'}; {'id': '46', 'type': 'block', 'children': ['47']}; {'id': '47', 'type': 'return_statement', 'children': ['48']}; {'id': '48', 'type': 'call', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '50', 'type': 'argument_list', 'children': ['51']}; {'id': '51', 'type': 'string', 'children': [], 'value': "'Bad Topic'"}; {'id': '52', 'type': 'if_statement', 'children': ['53', '60', '67']}; {'id': '53', 'type': 'call', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '55', 'type': 'argument_list', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'body'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '60', 'type': 'block', 'children': ['61']}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'request_body'}; {'id': '64', 'type': 'attribute', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'body'}; {'id': '67', 'type': 'else_clause', 'children': ['68']}; {'id': '68', 'type': 'block', 'children': ['69']}; {'id': '69', 'type': 'expression_statement', 'children': ['70']}; {'id': '70', 'type': 'assignment', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'request_body'}; {'id': '72', 'type': 'call', 'children': ['73', '78']}; {'id': '73', 'type': 'attribute', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'body'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'decode'}; {'id': '78', 'type': 'argument_list', 'children': []}; {'id': '79', 'type': 'try_statement', 'children': ['80', '90']}; {'id': '80', 'type': 'block', 'children': ['81']}; {'id': '81', 'type': 'expression_statement', 'children': ['82']}; {'id': '82', 'type': 'assignment', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '84', 'type': 'call', 'children': ['85', '88']}; {'id': '85', 'type': 'attribute', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'json'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'loads'}; {'id': '88', 'type': 'argument_list', 'children': ['89']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'request_body'}; {'id': '90', 'type': 'except_clause', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '92', 'type': 'block', 'children': ['93', '105']}; {'id': '93', 'type': 'expression_statement', 'children': ['94']}; {'id': '94', 'type': 'call', 'children': ['95', '98']}; {'id': '95', 'type': 'attribute', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '98', 'type': 'argument_list', 'children': ['99']}; {'id': '99', 'type': 'call', 'children': ['100', '103']}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'string', 'children': [], 'value': "'Notification Not Valid JSON: {}'"}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '103', 'type': 'argument_list', 'children': ['104']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'request_body'}; {'id': '105', 'type': 'return_statement', 'children': ['106']}; {'id': '106', 'type': 'call', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '108', 'type': 'argument_list', 'children': ['109']}; {'id': '109', 'type': 'string', 'children': [], 'value': "'Not Valid JSON'"}; {'id': '110', 'type': 'if_statement', 'children': ['111', '121']}; {'id': '111', 'type': 'not_operator', 'children': ['112']}; {'id': '112', 'type': 'comparison_operator', 'children': ['113', '117'], 'value': '<='}; {'id': '113', 'type': 'call', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '115', 'type': 'argument_list', 'children': ['116']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'VITAL_NOTIFICATION_FIELDS'}; {'id': '117', 'type': 'call', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '121', 'type': 'block', 'children': ['122', '129']}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '127', 'type': 'argument_list', 'children': ['128']}; {'id': '128', 'type': 'string', 'children': [], 'value': "'Request Missing Necessary Keys'"}; {'id': '129', 'type': 'return_statement', 'children': ['130']}; {'id': '130', 'type': 'call', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '132', 'type': 'argument_list', 'children': ['133']}; {'id': '133', 'type': 'string', 'children': [], 'value': "'Request Missing Necessary Keys'"}; {'id': '134', 'type': 'if_statement', 'children': ['135', '141']}; {'id': '135', 'type': 'not_operator', 'children': ['136']}; {'id': '136', 'type': 'comparison_operator', 'children': ['137', '140'], 'value': 'in'}; {'id': '137', 'type': 'subscript', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '139', 'type': 'string', 'children': [], 'value': "'Type'"}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'ALLOWED_TYPES'}; {'id': '141', 'type': 'block', 'children': ['142', '152']}; {'id': '142', 'type': 'expression_statement', 'children': ['143']}; {'id': '143', 'type': 'call', 'children': ['144', '147']}; {'id': '144', 'type': 'attribute', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '147', 'type': 'argument_list', 'children': ['148', '149']}; {'id': '148', 'type': 'string', 'children': [], 'value': "'Notification Type Not Known %s'"}; {'id': '149', 'type': 'subscript', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '151', 'type': 'string', 'children': [], 'value': "'Type'"}; {'id': '152', 'type': 'return_statement', 'children': ['153']}; {'id': '153', 'type': 'call', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '155', 'type': 'argument_list', 'children': ['156']}; {'id': '156', 'type': 'string', 'children': [], 'value': "'Unknown Notification Type'"}; {'id': '157', 'type': 'expression_statement', 'children': ['158']}; {'id': '158', 'type': 'assignment', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'domain'}; {'id': '160', 'type': 'attribute', 'children': ['161', '167']}; {'id': '161', 'type': 'call', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'urlparse'}; {'id': '163', 'type': 'argument_list', 'children': ['164']}; {'id': '164', 'type': 'subscript', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '166', 'type': 'string', 'children': [], 'value': "'SigningCertURL'"}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'netloc'}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '171', 'type': 'call', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '173', 'type': 'argument_list', 'children': ['174', '175', '176']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '175', 'type': 'string', 'children': [], 'value': "'BOUNCY_CERT_DOMAIN_REGEX'"}; {'id': '176', 'type': 'string', 'children': [], 'value': 'r"sns.[a-z0-9\\-]+.amazonaws.com$"'}; {'id': '177', 'type': 'if_statement', 'children': ['178', '186']}; {'id': '178', 'type': 'not_operator', 'children': ['179']}; {'id': '179', 'type': 'call', 'children': ['180', '183']}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '183', 'type': 'argument_list', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'domain'}; {'id': '186', 'type': 'block', 'children': ['187', '197']}; {'id': '187', 'type': 'expression_statement', 'children': ['188']}; {'id': '188', 'type': 'call', 'children': ['189', '192']}; {'id': '189', 'type': 'attribute', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '192', 'type': 'argument_list', 'children': ['193', '194']}; {'id': '193', 'type': 'string', 'children': [], 'value': "'Improper Certificate Location %s'"}; {'id': '194', 'type': 'subscript', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '196', 'type': 'string', 'children': [], 'value': "'SigningCertURL'"}; {'id': '197', 'type': 'return_statement', 'children': ['198']}; {'id': '198', 'type': 'call', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '200', 'type': 'argument_list', 'children': ['201']}; {'id': '201', 'type': 'string', 'children': [], 'value': "'Improper Certificate Location'"}; {'id': '202', 'type': 'if_statement', 'children': ['203', '216']}; {'id': '203', 'type': '()', 'children': ['204']}; {'id': '204', 'type': 'boolean_operator', 'children': ['205', '211'], 'value': 'and'}; {'id': '205', 'type': 'call', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '207', 'type': 'argument_list', 'children': ['208', '209', '210']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '209', 'type': 'string', 'children': [], 'value': "'BOUNCY_VERIFY_CERTIFICATE'"}; {'id': '210', 'type': 'True', 'children': []}; {'id': '211', 'type': 'not_operator', 'children': ['212']}; {'id': '212', 'type': 'call', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'verify_notification'}; {'id': '214', 'type': 'argument_list', 'children': ['215']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '216', 'type': 'block', 'children': ['217', '224']}; {'id': '217', 'type': 'expression_statement', 'children': ['218']}; {'id': '218', 'type': 'call', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '222', 'type': 'argument_list', 'children': ['223']}; {'id': '223', 'type': 'string', 'children': [], 'value': "'Verification Failure %s'"}; {'id': '224', 'type': 'return_statement', 'children': ['225']}; {'id': '225', 'type': 'call', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'HttpResponseBadRequest'}; {'id': '227', 'type': 'argument_list', 'children': ['228']}; {'id': '228', 'type': 'string', 'children': [], 'value': "'Improper Signature'"}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'call', 'children': ['231', '236']}; {'id': '231', 'type': 'attribute', 'children': ['232', '235']}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'signals'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'notification'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'send'}; {'id': '236', 'type': 'argument_list', 'children': ['237', '240', '243']}; {'id': '237', 'type': 'keyword_argument', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'sender'}; {'id': '239', 'type': 'string', 'children': [], 'value': "'bouncy_endpoint'"}; {'id': '240', 'type': 'keyword_argument', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'notification'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '243', 'type': 'keyword_argument', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '246', 'type': 'if_statement', 'children': ['247', '252', '269']}; {'id': '247', 'type': 'comparison_operator', 'children': ['248', '251'], 'value': '=='}; {'id': '248', 'type': 'subscript', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '250', 'type': 'string', 'children': [], 'value': "'Type'"}; {'id': '251', 'type': 'string', 'children': [], 'value': "'SubscriptionConfirmation'"}; {'id': '252', 'type': 'block', 'children': ['253', '264']}; {'id': '253', 'type': 'if_statement', 'children': ['254', '261']}; {'id': '254', 'type': 'not_operator', 'children': ['255']}; {'id': '255', 'type': 'call', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '257', 'type': 'argument_list', 'children': ['258', '259', '260']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '259', 'type': 'string', 'children': [], 'value': "'BOUNCY_AUTO_SUBSCRIBE'"}; {'id': '260', 'type': 'True', 'children': []}; {'id': '261', 'type': 'block', 'children': ['262']}; {'id': '262', 'type': 'raise_statement', 'children': ['263']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'Http404'}; {'id': '264', 'type': 'return_statement', 'children': ['265']}; {'id': '265', 'type': 'call', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'approve_subscription'}; {'id': '267', 'type': 'argument_list', 'children': ['268']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '269', 'type': 'elif_clause', 'children': ['270', '275']}; {'id': '270', 'type': 'comparison_operator', 'children': ['271', '274'], 'value': '=='}; {'id': '271', 'type': 'subscript', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '273', 'type': 'string', 'children': [], 'value': "'Type'"}; {'id': '274', 'type': 'string', 'children': [], 'value': "'UnsubscribeConfirmation'"}; {'id': '275', 'type': 'block', 'children': ['276', '283']}; {'id': '276', 'type': 'expression_statement', 'children': ['277']}; {'id': '277', 'type': 'call', 'children': ['278', '281']}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '281', 'type': 'argument_list', 'children': ['282']}; {'id': '282', 'type': 'string', 'children': [], 'value': "'UnsubscribeConfirmation Not Handled'"}; {'id': '283', 'type': 'return_statement', 'children': ['284']}; {'id': '284', 'type': 'call', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'HttpResponse'}; {'id': '286', 'type': 'argument_list', 'children': ['287']}; {'id': '287', 'type': 'string', 'children': [], 'value': "'UnsubscribeConfirmation Not Handled'"}; {'id': '288', 'type': 'try_statement', 'children': ['289', '301']}; {'id': '289', 'type': 'block', 'children': ['290']}; {'id': '290', 'type': 'expression_statement', 'children': ['291']}; {'id': '291', 'type': 'assignment', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '293', 'type': 'call', 'children': ['294', '297']}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'json'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'loads'}; {'id': '297', 'type': 'argument_list', 'children': ['298']}; {'id': '298', 'type': 'subscript', 'children': ['299', '300']}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '300', 'type': 'string', 'children': [], 'value': "'Message'"}; {'id': '301', 'type': 'except_clause', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '303', 'type': 'block', 'children': ['304', '311']}; {'id': '304', 'type': 'expression_statement', 'children': ['305']}; {'id': '305', 'type': 'call', 'children': ['306', '309']}; {'id': '306', 'type': 'attribute', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '309', 'type': 'argument_list', 'children': ['310']}; {'id': '310', 'type': 'string', 'children': [], 'value': "'Non-Valid JSON Message Received'"}; {'id': '311', 'type': 'return_statement', 'children': ['312']}; {'id': '312', 'type': 'call', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'HttpResponse'}; {'id': '314', 'type': 'argument_list', 'children': ['315']}; {'id': '315', 'type': 'string', 'children': [], 'value': "'Message is not valid JSON'"}; {'id': '316', 'type': 'return_statement', 'children': ['317']}; {'id': '317', 'type': 'call', 'children': ['318', '319']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'process_message'}; {'id': '319', 'type': 'argument_list', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'data'}
Endpoint that SNS accesses. Includes logic verifying request
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '24']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'new_from_files'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8', '9', '12', '13', '18', '19', '22']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'basepath'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '8', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '9', 'type': 'default_parameter', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'bohrs'}; {'id': '11', 'type': 'False', 'children': []}; {'id': '12', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '13', 'type': 'default_parameter', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'software'}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': '_E_SW'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'ORCA'}; {'id': '18', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '19', 'type': 'default_parameter', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'repo_clobber'}; {'id': '21', 'type': 'False', 'children': []}; {'id': '22', 'type': 'dictionary_splat_pattern', 'children': ['23']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '24', 'type': 'block', 'children': ['25', '28', '35', '44', '53', '62', '71', '84', '93', '100', '109', '126', '143', '160', '177', '199', '227', '255', '270', '300', '315', '342']}; {'id': '25', 'type': 'import_statement', 'children': ['26']}; {'id': '26', 'type': 'dotted_name', 'children': ['27']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '28', 'type': 'import_from_statement', 'children': ['29', '31']}; {'id': '29', 'type': 'dotted_name', 'children': ['30']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '31', 'type': 'aliased_import', 'children': ['32', '34']}; {'id': '32', 'type': 'dotted_name', 'children': ['33']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '35', 'type': 'import_from_statement', 'children': ['36', '40']}; {'id': '36', 'type': 'relative_import', 'children': ['37', '38']}; {'id': '37', 'type': 'import_prefix', 'children': []}; {'id': '38', 'type': 'dotted_name', 'children': ['39']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'xyz'}; {'id': '40', 'type': 'aliased_import', 'children': ['41', '43']}; {'id': '41', 'type': 'dotted_name', 'children': ['42']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'OpanXYZ'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'OX'}; {'id': '44', 'type': 'import_from_statement', 'children': ['45', '49']}; {'id': '45', 'type': 'relative_import', 'children': ['46', '47']}; {'id': '46', 'type': 'import_prefix', 'children': []}; {'id': '47', 'type': 'dotted_name', 'children': ['48']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'grad'}; {'id': '49', 'type': 'aliased_import', 'children': ['50', '52']}; {'id': '50', 'type': 'dotted_name', 'children': ['51']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'OrcaEngrad'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'OE'}; {'id': '53', 'type': 'import_from_statement', 'children': ['54', '58']}; {'id': '54', 'type': 'relative_import', 'children': ['55', '56']}; {'id': '55', 'type': 'import_prefix', 'children': []}; {'id': '56', 'type': 'dotted_name', 'children': ['57']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'hess'}; {'id': '58', 'type': 'aliased_import', 'children': ['59', '61']}; {'id': '59', 'type': 'dotted_name', 'children': ['60']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'OrcaHess'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'OH'}; {'id': '62', 'type': 'import_from_statement', 'children': ['63', '67']}; {'id': '63', 'type': 'relative_import', 'children': ['64', '65']}; {'id': '64', 'type': 'import_prefix', 'children': []}; {'id': '65', 'type': 'dotted_name', 'children': ['66']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '67', 'type': 'aliased_import', 'children': ['68', '70']}; {'id': '68', 'type': 'dotted_name', 'children': ['69']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'OpanAnharmRepo'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'OR'}; {'id': '71', 'type': 'import_from_statement', 'children': ['72', '76', '80']}; {'id': '72', 'type': 'relative_import', 'children': ['73', '74']}; {'id': '73', 'type': 'import_prefix', 'children': []}; {'id': '74', 'type': 'dotted_name', 'children': ['75']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '76', 'type': 'aliased_import', 'children': ['77', '79']}; {'id': '77', 'type': 'dotted_name', 'children': ['78']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'EnumDispDirection'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'E_DDir'}; {'id': '80', 'type': 'aliased_import', 'children': ['81', '83']}; {'id': '81', 'type': 'dotted_name', 'children': ['82']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'EnumFileType'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'E_FT'}; {'id': '84', 'type': 'import_from_statement', 'children': ['85', '89']}; {'id': '85', 'type': 'relative_import', 'children': ['86', '87']}; {'id': '86', 'type': 'import_prefix', 'children': []}; {'id': '87', 'type': 'dotted_name', 'children': ['88']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '89', 'type': 'aliased_import', 'children': ['90', '92']}; {'id': '90', 'type': 'dotted_name', 'children': ['91']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'EnumSoftware'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'E_SW'}; {'id': '93', 'type': 'import_from_statement', 'children': ['94', '98']}; {'id': '94', 'type': 'relative_import', 'children': ['95', '96']}; {'id': '95', 'type': 'import_prefix', 'children': []}; {'id': '96', 'type': 'dotted_name', 'children': ['97']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '98', 'type': 'dotted_name', 'children': ['99']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'DEF'}; {'id': '100', 'type': 'import_from_statement', 'children': ['101', '105']}; {'id': '101', 'type': 'relative_import', 'children': ['102', '103']}; {'id': '102', 'type': 'import_prefix', 'children': []}; {'id': '103', 'type': 'dotted_name', 'children': ['104']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '105', 'type': 'aliased_import', 'children': ['106', '108']}; {'id': '106', 'type': 'dotted_name', 'children': ['107']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'AnharmError'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '109', 'type': 'if_statement', 'children': ['110', '116']}; {'id': '110', 'type': 'not_operator', 'children': ['111']}; {'id': '111', 'type': 'comparison_operator', 'children': ['112', '115'], 'value': '=='}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'w_xyz'}; {'id': '115', 'type': 'None', 'children': []}; {'id': '116', 'type': 'block', 'children': ['117']}; {'id': '117', 'type': 'raise_statement', 'children': ['118']}; {'id': '118', 'type': 'call', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '120', 'type': 'argument_list', 'children': ['121', '124', '125']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'STATUS'}; {'id': '124', 'type': 'string', 'children': [], 'value': '"XYZ object is already bound"'}; {'id': '125', 'type': 'string', 'children': [], 'value': '""'}; {'id': '126', 'type': 'if_statement', 'children': ['127', '133']}; {'id': '127', 'type': 'not_operator', 'children': ['128']}; {'id': '128', 'type': 'comparison_operator', 'children': ['129', '132'], 'value': '=='}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'w_grad'}; {'id': '132', 'type': 'None', 'children': []}; {'id': '133', 'type': 'block', 'children': ['134']}; {'id': '134', 'type': 'raise_statement', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '141', '142']}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'STATUS'}; {'id': '141', 'type': 'string', 'children': [], 'value': '"GRAD object is already bound"'}; {'id': '142', 'type': 'string', 'children': [], 'value': '""'}; {'id': '143', 'type': 'if_statement', 'children': ['144', '150']}; {'id': '144', 'type': 'not_operator', 'children': ['145']}; {'id': '145', 'type': 'comparison_operator', 'children': ['146', '149'], 'value': '=='}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'w_hess'}; {'id': '149', 'type': 'None', 'children': []}; {'id': '150', 'type': 'block', 'children': ['151']}; {'id': '151', 'type': 'raise_statement', 'children': ['152']}; {'id': '152', 'type': 'call', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '154', 'type': 'argument_list', 'children': ['155', '158', '159']}; {'id': '155', 'type': 'attribute', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'STATUS'}; {'id': '158', 'type': 'string', 'children': [], 'value': '"HESS object is already bound"'}; {'id': '159', 'type': 'string', 'children': [], 'value': '""'}; {'id': '160', 'type': 'if_statement', 'children': ['161', '167']}; {'id': '161', 'type': 'not_operator', 'children': ['162']}; {'id': '162', 'type': 'comparison_operator', 'children': ['163', '166'], 'value': '=='}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '166', 'type': 'None', 'children': []}; {'id': '167', 'type': 'block', 'children': ['168']}; {'id': '168', 'type': 'raise_statement', 'children': ['169']}; {'id': '169', 'type': 'call', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '171', 'type': 'argument_list', 'children': ['172', '175', '176']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'ANHErr'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'STATUS'}; {'id': '175', 'type': 'string', 'children': [], 'value': '"Repository object is already bound"'}; {'id': '176', 'type': 'string', 'children': [], 'value': '""'}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'assignment', 'children': ['179', '182']}; {'id': '179', 'type': 'attribute', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'w_xyz'}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'OX'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '189']}; {'id': '186', 'type': 'attribute', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '189', 'type': 'argument_list', 'children': ['190', '191', '192']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'basepath'}; {'id': '191', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '192', 'type': 'binary_operator', 'children': ['193', '198'], 'value': '+'}; {'id': '193', 'type': 'binary_operator', 'children': ['194', '195'], 'value': '+'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '195', 'type': 'attribute', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'extsep'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'xyz_ext'}; {'id': '199', 'type': 'expression_statement', 'children': ['200']}; {'id': '200', 'type': 'assignment', 'children': ['201', '204']}; {'id': '201', 'type': 'attribute', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'w_grad'}; {'id': '204', 'type': 'call', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'OE'}; {'id': '206', 'type': 'argument_list', 'children': ['207', '221', '222', '223', '226']}; {'id': '207', 'type': 'call', 'children': ['208', '211']}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '211', 'type': 'argument_list', 'children': ['212', '213', '214']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'basepath'}; {'id': '213', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '214', 'type': 'binary_operator', 'children': ['215', '220'], 'value': '+'}; {'id': '215', 'type': 'binary_operator', 'children': ['216', '217'], 'value': '+'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'extsep'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'engrad_ext'}; {'id': '221', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '222', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'E_DDir'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'NO_DISP'}; {'id': '226', 'type': 'float', 'children': [], 'value': '0.0'}; {'id': '227', 'type': 'expression_statement', 'children': ['228']}; {'id': '228', 'type': 'assignment', 'children': ['229', '232']}; {'id': '229', 'type': 'attribute', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'w_hess'}; {'id': '232', 'type': 'call', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'OH'}; {'id': '234', 'type': 'argument_list', 'children': ['235', '249', '250', '251', '254']}; {'id': '235', 'type': 'call', 'children': ['236', '239']}; {'id': '236', 'type': 'attribute', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '239', 'type': 'argument_list', 'children': ['240', '241', '242']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'basepath'}; {'id': '241', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '242', 'type': 'binary_operator', 'children': ['243', '248'], 'value': '+'}; {'id': '243', 'type': 'binary_operator', 'children': ['244', '245'], 'value': '+'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '245', 'type': 'attribute', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'extsep'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'hess_ext'}; {'id': '249', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '250', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '251', 'type': 'attribute', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'E_DDir'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'NO_DISP'}; {'id': '254', 'type': 'float', 'children': [], 'value': '0.0'}; {'id': '255', 'type': 'if_statement', 'children': ['256', '262']}; {'id': '256', 'type': 'not_operator', 'children': ['257']}; {'id': '257', 'type': 'call', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '259', 'type': 'argument_list', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '262', 'type': 'block', 'children': ['263']}; {'id': '263', 'type': 'raise_statement', 'children': ['264']}; {'id': '264', 'type': 'call', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'TypeError'}; {'id': '266', 'type': 'argument_list', 'children': ['267']}; {'id': '267', 'type': 'binary_operator', 'children': ['268', '269'], 'value': '+'}; {'id': '268', 'type': 'string', 'children': [], 'value': '"Must create new repository when loading "'}; {'id': '269', 'type': 'string', 'children': [], 'value': '"a new dataset."'}; {'id': '270', 'type': 'if_statement', 'children': ['271', '289']}; {'id': '271', 'type': 'boolean_operator', 'children': ['272', '282'], 'value': 'and'}; {'id': '272', 'type': 'comparison_operator', 'children': ['273', '281'], 'value': '>'}; {'id': '273', 'type': 'call', 'children': ['274', '277']}; {'id': '274', 'type': 'attribute', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '277', 'type': 'argument_list', 'children': ['278']}; {'id': '278', 'type': 'subscript', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '280', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '281', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '282', 'type': 'not_operator', 'children': ['283']}; {'id': '283', 'type': 'call', 'children': ['284', '287']}; {'id': '284', 'type': 'attribute', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'isabs'}; {'id': '287', 'type': 'argument_list', 'children': ['288']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '289', 'type': 'block', 'children': ['290']}; {'id': '290', 'type': 'expression_statement', 'children': ['291']}; {'id': '291', 'type': 'assignment', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '293', 'type': 'call', 'children': ['294', '297']}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '297', 'type': 'argument_list', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'basepath'}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '300', 'type': 'if_statement', 'children': ['301', '307']}; {'id': '301', 'type': 'call', 'children': ['302', '305']}; {'id': '302', 'type': 'attribute', 'children': ['303', '304']}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'isdir'}; {'id': '305', 'type': 'argument_list', 'children': ['306']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '307', 'type': 'block', 'children': ['308']}; {'id': '308', 'type': 'raise_statement', 'children': ['309']}; {'id': '309', 'type': 'call', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'IOError'}; {'id': '311', 'type': 'argument_list', 'children': ['312']}; {'id': '312', 'type': 'binary_operator', 'children': ['313', '314'], 'value': '+'}; {'id': '313', 'type': 'string', 'children': [], 'value': '"Cannot bind repository -- specified "'}; {'id': '314', 'type': 'string', 'children': [], 'value': '"location is a directory"'}; {'id': '315', 'type': 'if_statement', 'children': ['316', '322']}; {'id': '316', 'type': 'call', 'children': ['317', '320']}; {'id': '317', 'type': 'attribute', 'children': ['318', '319']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'osp'}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '320', 'type': 'argument_list', 'children': ['321']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '322', 'type': 'block', 'children': ['323']}; {'id': '323', 'type': 'if_statement', 'children': ['324', '325', '333']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'repo_clobber'}; {'id': '325', 'type': 'block', 'children': ['326']}; {'id': '326', 'type': 'expression_statement', 'children': ['327']}; {'id': '327', 'type': 'call', 'children': ['328', '331']}; {'id': '328', 'type': 'attribute', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '331', 'type': 'argument_list', 'children': ['332']}; {'id': '332', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '333', 'type': 'else_clause', 'children': ['334']}; {'id': '334', 'type': 'block', 'children': ['335']}; {'id': '335', 'type': 'raise_statement', 'children': ['336']}; {'id': '336', 'type': 'call', 'children': ['337', '338']}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'IOError'}; {'id': '338', 'type': 'argument_list', 'children': ['339']}; {'id': '339', 'type': 'binary_operator', 'children': ['340', '341'], 'value': '+'}; {'id': '340', 'type': 'string', 'children': [], 'value': '"Target repository file exists and "'}; {'id': '341', 'type': 'string', 'children': [], 'value': '"clobber is disabled."'}; {'id': '342', 'type': 'expression_statement', 'children': ['343']}; {'id': '343', 'type': 'assignment', 'children': ['344', '347']}; {'id': '344', 'type': 'attribute', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'repo'}; {'id': '347', 'type': 'call', 'children': ['348', '349']}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'OR'}; {'id': '349', 'type': 'argument_list', 'children': ['350']}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'repo'}
Initialize with data from files.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'sort_protein_sequences'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'protein_sequences'}; {'id': '5', 'type': 'block', 'children': ['6']}; {'id': '6', 'type': 'return_statement', 'children': ['7']}; {'id': '7', 'type': 'call', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '9', 'type': 'argument_list', 'children': ['10']}; {'id': '10', 'type': 'call', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '12', 'type': 'argument_list', 'children': ['13', '14', '19']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'protein_sequences'}; {'id': '14', 'type': 'keyword_argument', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'ProteinSequence'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'ascending_sort_key'}; {'id': '19', 'type': 'keyword_argument', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'reverse'}; {'id': '21', 'type': 'True', 'children': []}
Sort protein sequences in decreasing order of priority
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'info'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'long_description'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'classifiers'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '8', 'type': 'block', 'children': ['9', '17']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'client'}; {'id': '12', 'type': 'call', 'children': ['13', '16']}; {'id': '13', 'type': 'attribute', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'requests'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'Session'}; {'id': '16', 'type': 'argument_list', 'children': []}; {'id': '17', 'type': 'for_statement', 'children': ['18', '19', '20']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'name_or_url'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '20', 'type': 'block', 'children': ['21', '29', '54', '90', '95', '107', '111', '125', '139', '143', '148', '152', '164', '180', '196', '208', '217', '233', '249', '253', '267', '286', '305', '334', '385']}; {'id': '21', 'type': 'expression_statement', 'children': ['22']}; {'id': '22', 'type': 'assignment', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '24', 'type': 'call', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'get_package'}; {'id': '26', 'type': 'argument_list', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'name_or_url'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'client'}; {'id': '29', 'type': 'if_statement', 'children': ['30', '32']}; {'id': '30', 'type': 'not_operator', 'children': ['31']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '32', 'type': 'block', 'children': ['33', '53']}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'call', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'secho'}; {'id': '36', 'type': 'argument_list', 'children': ['37', '45', '48']}; {'id': '37', 'type': 'call', 'children': ['38', '41']}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'string', 'children': [], 'value': 'u\'Invalid name or URL: "{name}"\''}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '41', 'type': 'argument_list', 'children': ['42']}; {'id': '42', 'type': 'keyword_argument', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'name_or_url'}; {'id': '45', 'type': 'keyword_argument', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'fg'}; {'id': '47', 'type': 'string', 'children': [], 'value': "'red'"}; {'id': '48', 'type': 'keyword_argument', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '53', 'type': 'continue_statement', 'children': []}; {'id': '54', 'type': 'try_statement', 'children': ['55', '64']}; {'id': '55', 'type': 'block', 'children': ['56']}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '59', 'type': 'subscript', 'children': ['60', '63']}; {'id': '60', 'type': 'attribute', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '63', 'type': 'string', 'children': [], 'value': "'info'"}; {'id': '64', 'type': 'except_clause', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'NotFoundError'}; {'id': '66', 'type': 'block', 'children': ['67', '89']}; {'id': '67', 'type': 'expression_statement', 'children': ['68']}; {'id': '68', 'type': 'call', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'secho'}; {'id': '70', 'type': 'argument_list', 'children': ['71', '81', '84']}; {'id': '71', 'type': 'call', 'children': ['72', '77']}; {'id': '72', 'type': 'attribute', 'children': ['73', '76']}; {'id': '73', 'type': 'concatenated_string', 'children': ['74', '75']}; {'id': '74', 'type': 'string', 'children': [], 'value': 'u\'No versions found for "{0}". \''}; {'id': '75', 'type': 'string', 'children': [], 'value': "u'Skipping. . .'"}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '81', 'type': 'keyword_argument', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'fg'}; {'id': '83', 'type': 'string', 'children': [], 'value': "'red'"}; {'id': '84', 'type': 'keyword_argument', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '89', 'type': 'continue_statement', 'children': []}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'call', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'echo_header'}; {'id': '93', 'type': 'argument_list', 'children': ['94']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'name_or_url'}; {'id': '95', 'type': 'if_statement', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'summary'}; {'id': '99', 'type': 'block', 'children': ['100']}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'call', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '103', 'type': 'argument_list', 'children': ['104']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'summary'}; {'id': '107', 'type': 'expression_statement', 'children': ['108']}; {'id': '108', 'type': 'call', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '110', 'type': 'argument_list', 'children': []}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'call', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '114', 'type': 'argument_list', 'children': ['115']}; {'id': '115', 'type': 'call', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'string', 'children': [], 'value': "'Latest release: {version:12}'"}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'keyword_argument', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '122', 'type': 'subscript', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '124', 'type': 'string', 'children': [], 'value': "'version'"}; {'id': '125', 'type': 'if_statement', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'long_description'}; {'id': '127', 'type': 'block', 'children': ['128', '132']}; {'id': '128', 'type': 'expression_statement', 'children': ['129']}; {'id': '129', 'type': 'call', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '131', 'type': 'argument_list', 'children': []}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '135', 'type': 'argument_list', 'children': ['136']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'call', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '142', 'type': 'argument_list', 'children': []}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'call', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'echo_download_summary'}; {'id': '146', 'type': 'argument_list', 'children': ['147']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'call', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '151', 'type': 'argument_list', 'children': []}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'assignment', 'children': ['154', '157']}; {'id': '154', 'type': 'pattern_list', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'author_email'}; {'id': '157', 'type': 'expression_list', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '161', 'type': 'attribute', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'author_email'}; {'id': '164', 'type': 'if_statement', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '166', 'type': 'block', 'children': ['167']}; {'id': '167', 'type': 'expression_statement', 'children': ['168']}; {'id': '168', 'type': 'call', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '170', 'type': 'argument_list', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'string', 'children': [], 'value': "u'Author: {author:12}'"}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '175', 'type': 'argument_list', 'children': ['176']}; {'id': '176', 'type': 'dictionary_splat', 'children': ['177']}; {'id': '177', 'type': 'call', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'locals'}; {'id': '179', 'type': 'argument_list', 'children': []}; {'id': '180', 'type': 'if_statement', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'author_email'}; {'id': '182', 'type': 'block', 'children': ['183']}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'call', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '186', 'type': 'argument_list', 'children': ['187']}; {'id': '187', 'type': 'call', 'children': ['188', '191']}; {'id': '188', 'type': 'attribute', 'children': ['189', '190']}; {'id': '189', 'type': 'string', 'children': [], 'value': "u'Author email: {author_email:12}'"}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '191', 'type': 'argument_list', 'children': ['192']}; {'id': '192', 'type': 'dictionary_splat', 'children': ['193']}; {'id': '193', 'type': 'call', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'locals'}; {'id': '195', 'type': 'argument_list', 'children': []}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '201']}; {'id': '198', 'type': 'pattern_list', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'maintainer'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'maintainer_email'}; {'id': '201', 'type': 'tuple', 'children': ['202', '205']}; {'id': '202', 'type': 'attribute', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'maintainer'}; {'id': '205', 'type': 'attribute', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'maintainer_email'}; {'id': '208', 'type': 'if_statement', 'children': ['209', '212']}; {'id': '209', 'type': 'boolean_operator', 'children': ['210', '211'], 'value': 'or'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'maintainer'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'maintainer_email'}; {'id': '212', 'type': 'block', 'children': ['213']}; {'id': '213', 'type': 'expression_statement', 'children': ['214']}; {'id': '214', 'type': 'call', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '216', 'type': 'argument_list', 'children': []}; {'id': '217', 'type': 'if_statement', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'maintainer'}; {'id': '219', 'type': 'block', 'children': ['220']}; {'id': '220', 'type': 'expression_statement', 'children': ['221']}; {'id': '221', 'type': 'call', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'call', 'children': ['225', '228']}; {'id': '225', 'type': 'attribute', 'children': ['226', '227']}; {'id': '226', 'type': 'string', 'children': [], 'value': "u'Maintainer: {maintainer:12}'"}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '228', 'type': 'argument_list', 'children': ['229']}; {'id': '229', 'type': 'dictionary_splat', 'children': ['230']}; {'id': '230', 'type': 'call', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'locals'}; {'id': '232', 'type': 'argument_list', 'children': []}; {'id': '233', 'type': 'if_statement', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'maintainer_email'}; {'id': '235', 'type': 'block', 'children': ['236']}; {'id': '236', 'type': 'expression_statement', 'children': ['237']}; {'id': '237', 'type': 'call', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '239', 'type': 'argument_list', 'children': ['240']}; {'id': '240', 'type': 'call', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'string', 'children': [], 'value': "u'Maintainer email: {maintainer_email:12}'"}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'dictionary_splat', 'children': ['246']}; {'id': '246', 'type': 'call', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'locals'}; {'id': '248', 'type': 'argument_list', 'children': []}; {'id': '249', 'type': 'expression_statement', 'children': ['250']}; {'id': '250', 'type': 'call', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '252', 'type': 'argument_list', 'children': []}; {'id': '253', 'type': 'expression_statement', 'children': ['254']}; {'id': '254', 'type': 'call', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '256', 'type': 'argument_list', 'children': ['257']}; {'id': '257', 'type': 'call', 'children': ['258', '261']}; {'id': '258', 'type': 'attribute', 'children': ['259', '260']}; {'id': '259', 'type': 'string', 'children': [], 'value': "u'PyPI URL: {pypi_url:12}'"}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '261', 'type': 'argument_list', 'children': ['262']}; {'id': '262', 'type': 'keyword_argument', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'pypi_url'}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'package_url'}; {'id': '267', 'type': 'if_statement', 'children': ['268', '271']}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'home_page'}; {'id': '271', 'type': 'block', 'children': ['272']}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'call', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '275', 'type': 'argument_list', 'children': ['276']}; {'id': '276', 'type': 'call', 'children': ['277', '280']}; {'id': '277', 'type': 'attribute', 'children': ['278', '279']}; {'id': '278', 'type': 'string', 'children': [], 'value': "u'Home Page: {home_page:12}'"}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '280', 'type': 'argument_list', 'children': ['281']}; {'id': '281', 'type': 'keyword_argument', 'children': ['282', '283']}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'home_page'}; {'id': '283', 'type': 'attribute', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'home_page'}; {'id': '286', 'type': 'if_statement', 'children': ['287', '290']}; {'id': '287', 'type': 'attribute', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'docs_url'}; {'id': '290', 'type': 'block', 'children': ['291']}; {'id': '291', 'type': 'expression_statement', 'children': ['292']}; {'id': '292', 'type': 'call', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '294', 'type': 'argument_list', 'children': ['295']}; {'id': '295', 'type': 'call', 'children': ['296', '299']}; {'id': '296', 'type': 'attribute', 'children': ['297', '298']}; {'id': '297', 'type': 'string', 'children': [], 'value': "u'Documentation: {docs_url:12}'"}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '299', 'type': 'argument_list', 'children': ['300']}; {'id': '300', 'type': 'keyword_argument', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'docs_url'}; {'id': '302', 'type': 'attribute', 'children': ['303', '304']}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'docs_url'}; {'id': '305', 'type': 'if_statement', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'classifiers'}; {'id': '307', 'type': 'block', 'children': ['308', '312', '317']}; {'id': '308', 'type': 'expression_statement', 'children': ['309']}; {'id': '309', 'type': 'call', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '311', 'type': 'argument_list', 'children': []}; {'id': '312', 'type': 'expression_statement', 'children': ['313']}; {'id': '313', 'type': 'call', 'children': ['314', '315']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '315', 'type': 'argument_list', 'children': ['316']}; {'id': '316', 'type': 'string', 'children': [], 'value': "u'Classifiers: '"}; {'id': '317', 'type': 'for_statement', 'children': ['318', '319', '326']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '319', 'type': 'call', 'children': ['320', '323']}; {'id': '320', 'type': 'attribute', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '323', 'type': 'argument_list', 'children': ['324', '325']}; {'id': '324', 'type': 'string', 'children': [], 'value': "'classifiers'"}; {'id': '325', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '326', 'type': 'block', 'children': ['327']}; {'id': '327', 'type': 'expression_statement', 'children': ['328']}; {'id': '328', 'type': 'call', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '330', 'type': 'argument_list', 'children': ['331']}; {'id': '331', 'type': 'binary_operator', 'children': ['332', '333'], 'value': '+'}; {'id': '332', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '334', 'type': 'if_statement', 'children': ['335', '340']}; {'id': '335', 'type': 'boolean_operator', 'children': ['336', '337'], 'value': 'and'}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '337', 'type': 'attribute', 'children': ['338', '339']}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '339', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '340', 'type': 'block', 'children': ['341', '345', '353', '378']}; {'id': '341', 'type': 'expression_statement', 'children': ['342']}; {'id': '342', 'type': 'call', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '344', 'type': 'argument_list', 'children': []}; {'id': '345', 'type': 'expression_statement', 'children': ['346']}; {'id': '346', 'type': 'call', 'children': ['347', '348']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '348', 'type': 'argument_list', 'children': ['349', '350']}; {'id': '349', 'type': 'string', 'children': [], 'value': "u'License: '"}; {'id': '350', 'type': 'keyword_argument', 'children': ['351', '352']}; {'id': '351', 'type': 'identifier', 'children': [], 'value': 'nl'}; {'id': '352', 'type': 'False', 'children': []}; {'id': '353', 'type': 'if_statement', 'children': ['354', '373']}; {'id': '354', 'type': 'boolean_operator', 'children': ['355', '365'], 'value': 'or'}; {'id': '355', 'type': 'comparison_operator', 'children': ['356', '364'], 'value': '>='}; {'id': '356', 'type': 'call', 'children': ['357', '362']}; {'id': '357', 'type': 'attribute', 'children': ['358', '361']}; {'id': '358', 'type': 'attribute', 'children': ['359', '360']}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '362', 'type': 'argument_list', 'children': ['363']}; {'id': '363', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '364', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '365', 'type': 'comparison_operator', 'children': ['366', '372'], 'value': '>'}; {'id': '366', 'type': 'call', 'children': ['367', '368']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '368', 'type': 'argument_list', 'children': ['369']}; {'id': '369', 'type': 'attribute', 'children': ['370', '371']}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '372', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '373', 'type': 'block', 'children': ['374']}; {'id': '374', 'type': 'expression_statement', 'children': ['375']}; {'id': '375', 'type': 'call', 'children': ['376', '377']}; {'id': '376', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '377', 'type': 'argument_list', 'children': []}; {'id': '378', 'type': 'expression_statement', 'children': ['379']}; {'id': '379', 'type': 'call', 'children': ['380', '381']}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '381', 'type': 'argument_list', 'children': ['382']}; {'id': '382', 'type': 'attribute', 'children': ['383', '384']}; {'id': '383', 'type': 'identifier', 'children': [], 'value': 'package'}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'license'}; {'id': '385', 'type': 'expression_statement', 'children': ['386']}; {'id': '386', 'type': 'call', 'children': ['387', '388']}; {'id': '387', 'type': 'identifier', 'children': [], 'value': 'echo'}; {'id': '388', 'type': 'argument_list', 'children': []}
Get info about a package or packages.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'FD'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '16', '40', '69', '105', '140', '255', '277']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '10']}; {'id': '7', 'type': 'attribute', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'Verbose'}; {'id': '10', 'type': 'block', 'children': ['11']}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'call', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '14', 'type': 'argument_list', 'children': ['15']}; {'id': '15', 'type': 'string', 'children': [], 'value': '"Finite Difference Solution Technique"'}; {'id': '16', 'type': 'try_statement', 'children': ['17', '22']}; {'id': '17', 'type': 'block', 'children': ['18']}; {'id': '18', 'type': 'expression_statement', 'children': ['19']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'qs'}; {'id': '22', 'type': 'except_clause', 'children': ['23']}; {'id': '23', 'type': 'block', 'children': ['24', '36']}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '29']}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'qs'}; {'id': '29', 'type': 'call', 'children': ['30', '35']}; {'id': '30', 'type': 'attribute', 'children': ['31', '34']}; {'id': '31', 'type': 'attribute', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'q0'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '35', 'type': 'argument_list', 'children': []}; {'id': '36', 'type': 'delete_statement', 'children': ['37']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'q0'}; {'id': '40', 'type': 'expression_statement', 'children': ['41']}; {'id': '41', 'type': 'assignment', 'children': ['42', '45']}; {'id': '42', 'type': 'attribute', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '45', 'type': 'call', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'arange'}; {'id': '49', 'type': 'argument_list', 'children': ['50', '55', '66']}; {'id': '50', 'type': 'binary_operator', 'children': ['51', '54'], 'value': '/'}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'dx'}; {'id': '54', 'type': 'float', 'children': [], 'value': '2.'}; {'id': '55', 'type': 'binary_operator', 'children': ['56', '59'], 'value': '*'}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'dx'}; {'id': '59', 'type': 'subscript', 'children': ['60', '65']}; {'id': '60', 'type': 'attribute', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'qs'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'shape'}; {'id': '65', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'dx'}; {'id': '69', 'type': 'if_statement', 'children': ['70', '75']}; {'id': '70', 'type': 'comparison_operator', 'children': ['71', '74'], 'value': '=='}; {'id': '71', 'type': 'attribute', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'dimension'}; {'id': '74', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '75', 'type': 'block', 'children': ['76']}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '81']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'y'}; {'id': '81', 'type': 'call', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'arange'}; {'id': '85', 'type': 'argument_list', 'children': ['86', '91', '102']}; {'id': '86', 'type': 'binary_operator', 'children': ['87', '90'], 'value': '/'}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'dy'}; {'id': '90', 'type': 'float', 'children': [], 'value': '2.'}; {'id': '91', 'type': 'binary_operator', 'children': ['92', '95'], 'value': '*'}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'dy'}; {'id': '95', 'type': 'subscript', 'children': ['96', '101']}; {'id': '96', 'type': 'attribute', 'children': ['97', '100']}; {'id': '97', 'type': 'attribute', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'qs'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'shape'}; {'id': '101', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'dy'}; {'id': '105', 'type': 'try_statement', 'children': ['106', '111']}; {'id': '106', 'type': 'block', 'children': ['107']}; {'id': '107', 'type': 'expression_statement', 'children': ['108']}; {'id': '108', 'type': 'attribute', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'Solver'}; {'id': '111', 'type': 'except_clause', 'children': ['112']}; {'id': '112', 'type': 'block', 'children': ['113']}; {'id': '113', 'type': 'if_statement', 'children': ['114', '117', '131']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '117', 'type': 'block', 'children': ['118']}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'assignment', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'Solver'}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'configGet'}; {'id': '127', 'type': 'argument_list', 'children': ['128', '129', '130']}; {'id': '128', 'type': 'string', 'children': [], 'value': '"string"'}; {'id': '129', 'type': 'string', 'children': [], 'value': '"numerical"'}; {'id': '130', 'type': 'string', 'children': [], 'value': '"Solver"'}; {'id': '131', 'type': 'else_clause', 'children': ['132']}; {'id': '132', 'type': 'block', 'children': ['133']}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'call', 'children': ['135', '138']}; {'id': '135', 'type': 'attribute', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '138', 'type': 'argument_list', 'children': ['139']}; {'id': '139', 'type': 'string', 'children': [], 'value': '"No solver defined!"'}; {'id': '140', 'type': 'if_statement', 'children': ['141', '144']}; {'id': '141', 'type': 'attribute', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '144', 'type': 'block', 'children': ['145', '158', '231']}; {'id': '145', 'type': 'expression_statement', 'children': ['146']}; {'id': '146', 'type': 'assignment', 'children': ['147', '150']}; {'id': '147', 'type': 'attribute', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'iterative_ConvergenceTolerance'}; {'id': '150', 'type': 'call', 'children': ['151', '154']}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'configGet'}; {'id': '154', 'type': 'argument_list', 'children': ['155', '156', '157']}; {'id': '155', 'type': 'string', 'children': [], 'value': '"float"'}; {'id': '156', 'type': 'string', 'children': [], 'value': '"numerical"'}; {'id': '157', 'type': 'string', 'children': [], 'value': '"ConvergenceTolerance"'}; {'id': '158', 'type': 'try_statement', 'children': ['159', '209']}; {'id': '159', 'type': 'block', 'children': ['160', '176']}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '165']}; {'id': '162', 'type': 'attribute', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '165', 'type': 'call', 'children': ['166', '169']}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'configGet'}; {'id': '169', 'type': 'argument_list', 'children': ['170', '171', '172', '173']}; {'id': '170', 'type': 'string', 'children': [], 'value': '"float"'}; {'id': '171', 'type': 'string', 'children': [], 'value': '"input"'}; {'id': '172', 'type': 'string', 'children': [], 'value': '"ElasticThickness"'}; {'id': '173', 'type': 'keyword_argument', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '175', 'type': 'False', 'children': []}; {'id': '176', 'type': 'if_statement', 'children': ['177', '182', '203']}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '181'], 'value': 'is'}; {'id': '178', 'type': 'attribute', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '181', 'type': 'None', 'children': []}; {'id': '182', 'type': 'block', 'children': ['183', '197']}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'assignment', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '186', 'type': 'call', 'children': ['187', '190']}; {'id': '187', 'type': 'attribute', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'configGet'}; {'id': '190', 'type': 'argument_list', 'children': ['191', '192', '193', '194']}; {'id': '191', 'type': 'string', 'children': [], 'value': '"string"'}; {'id': '192', 'type': 'string', 'children': [], 'value': '"input"'}; {'id': '193', 'type': 'string', 'children': [], 'value': '"ElasticThickness"'}; {'id': '194', 'type': 'keyword_argument', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '196', 'type': 'False', 'children': []}; {'id': '197', 'type': 'expression_statement', 'children': ['198']}; {'id': '198', 'type': 'assignment', 'children': ['199', '202']}; {'id': '199', 'type': 'attribute', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '203', 'type': 'else_clause', 'children': ['204']}; {'id': '204', 'type': 'block', 'children': ['205']}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'assignment', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '208', 'type': 'None', 'children': []}; {'id': '209', 'type': 'except_clause', 'children': ['210']}; {'id': '210', 'type': 'block', 'children': ['211', '225']}; {'id': '211', 'type': 'expression_statement', 'children': ['212']}; {'id': '212', 'type': 'assignment', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '214', 'type': 'call', 'children': ['215', '218']}; {'id': '215', 'type': 'attribute', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'configGet'}; {'id': '218', 'type': 'argument_list', 'children': ['219', '220', '221', '222']}; {'id': '219', 'type': 'string', 'children': [], 'value': '"string"'}; {'id': '220', 'type': 'string', 'children': [], 'value': '"input"'}; {'id': '221', 'type': 'string', 'children': [], 'value': '"ElasticThickness"'}; {'id': '222', 'type': 'keyword_argument', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '224', 'type': 'False', 'children': []}; {'id': '225', 'type': 'expression_statement', 'children': ['226']}; {'id': '226', 'type': 'assignment', 'children': ['227', '230']}; {'id': '227', 'type': 'attribute', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '231', 'type': 'if_statement', 'children': ['232', '237']}; {'id': '232', 'type': 'comparison_operator', 'children': ['233', '236'], 'value': 'is'}; {'id': '233', 'type': 'attribute', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '236', 'type': 'None', 'children': []}; {'id': '237', 'type': 'block', 'children': ['238']}; {'id': '238', 'type': 'if_statement', 'children': ['239', '244', '246']}; {'id': '239', 'type': 'comparison_operator', 'children': ['240', '243'], 'value': 'is'}; {'id': '240', 'type': 'attribute', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'coeff_matrix'}; {'id': '243', 'type': 'None', 'children': []}; {'id': '244', 'type': 'block', 'children': ['245']}; {'id': '245', 'type': 'pass_statement', 'children': []}; {'id': '246', 'type': 'else_clause', 'children': ['247']}; {'id': '247', 'type': 'block', 'children': ['248']}; {'id': '248', 'type': 'expression_statement', 'children': ['249']}; {'id': '249', 'type': 'call', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'string', 'children': [], 'value': '"No input elastic thickness or coefficient matrix supplied."'}; {'id': '255', 'type': 'if_statement', 'children': ['256', '264', '271']}; {'id': '256', 'type': 'comparison_operator', 'children': ['257', '263'], 'value': '=='}; {'id': '257', 'type': 'call', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '259', 'type': 'argument_list', 'children': ['260']}; {'id': '260', 'type': 'attribute', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '264', 'type': 'block', 'children': ['265']}; {'id': '265', 'type': 'expression_statement', 'children': ['266']}; {'id': '266', 'type': 'assignment', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '271', 'type': 'else_clause', 'children': ['272']}; {'id': '272', 'type': 'block', 'children': ['273']}; {'id': '273', 'type': 'expression_statement', 'children': ['274']}; {'id': '274', 'type': 'assignment', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '276', 'type': 'None', 'children': []}; {'id': '277', 'type': 'if_statement', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'Tepath'}; {'id': '279', 'type': 'block', 'children': ['280', '296', '348']}; {'id': '280', 'type': 'expression_statement', 'children': ['281']}; {'id': '281', 'type': 'assignment', 'children': ['282', '285']}; {'id': '282', 'type': 'attribute', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '285', 'type': 'call', 'children': ['286', '289']}; {'id': '286', 'type': 'attribute', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'loadFile'}; {'id': '289', 'type': 'argument_list', 'children': ['290', '293']}; {'id': '290', 'type': 'attribute', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '293', 'type': 'keyword_argument', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'close_on_fail'}; {'id': '295', 'type': 'False', 'children': []}; {'id': '296', 'type': 'if_statement', 'children': ['297', '302']}; {'id': '297', 'type': 'comparison_operator', 'children': ['298', '301'], 'value': 'is'}; {'id': '298', 'type': 'attribute', 'children': ['299', '300']}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '301', 'type': 'None', 'children': []}; {'id': '302', 'type': 'block', 'children': ['303', '308', '313', '318']}; {'id': '303', 'type': 'expression_statement', 'children': ['304']}; {'id': '304', 'type': 'call', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '306', 'type': 'argument_list', 'children': ['307']}; {'id': '307', 'type': 'string', 'children': [], 'value': '"Requested Te file is provided but cannot be located."'}; {'id': '308', 'type': 'expression_statement', 'children': ['309']}; {'id': '309', 'type': 'call', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '311', 'type': 'argument_list', 'children': ['312']}; {'id': '312', 'type': 'string', 'children': [], 'value': '"No scalar elastic thickness is provided in configuration file"'}; {'id': '313', 'type': 'expression_statement', 'children': ['314']}; {'id': '314', 'type': 'call', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '316', 'type': 'argument_list', 'children': ['317']}; {'id': '317', 'type': 'string', 'children': [], 'value': '"(Typo in path to input Te grid?)"'}; {'id': '318', 'type': 'if_statement', 'children': ['319', '324', '335']}; {'id': '319', 'type': 'comparison_operator', 'children': ['320', '323'], 'value': 'is'}; {'id': '320', 'type': 'attribute', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'coeff_matrix'}; {'id': '323', 'type': 'None', 'children': []}; {'id': '324', 'type': 'block', 'children': ['325', '330']}; {'id': '325', 'type': 'expression_statement', 'children': ['326']}; {'id': '326', 'type': 'call', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '328', 'type': 'argument_list', 'children': ['329']}; {'id': '329', 'type': 'string', 'children': [], 'value': '"But a coefficient matrix has been found."'}; {'id': '330', 'type': 'expression_statement', 'children': ['331']}; {'id': '331', 'type': 'call', 'children': ['332', '333']}; {'id': '332', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '333', 'type': 'argument_list', 'children': ['334']}; {'id': '334', 'type': 'string', 'children': [], 'value': '"Calculations will be carried forward using it."'}; {'id': '335', 'type': 'else_clause', 'children': ['336']}; {'id': '336', 'type': 'block', 'children': ['337', '342']}; {'id': '337', 'type': 'expression_statement', 'children': ['338']}; {'id': '338', 'type': 'call', 'children': ['339', '340']}; {'id': '339', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '340', 'type': 'argument_list', 'children': ['341']}; {'id': '341', 'type': 'string', 'children': [], 'value': '"Exiting."'}; {'id': '342', 'type': 'expression_statement', 'children': ['343']}; {'id': '343', 'type': 'call', 'children': ['344', '347']}; {'id': '344', 'type': 'attribute', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '347', 'type': 'argument_list', 'children': []}; {'id': '348', 'type': 'if_statement', 'children': ['349', '356']}; {'id': '349', 'type': 'call', 'children': ['350', '355']}; {'id': '350', 'type': 'attribute', 'children': ['351', '354']}; {'id': '351', 'type': 'attribute', 'children': ['352', '353']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'Te'}; {'id': '354', 'type': 'identifier', 'children': [], 'value': 'any'}; {'id': '355', 'type': 'argument_list', 'children': []}; {'id': '356', 'type': 'block', 'children': ['357']}; {'id': '357', 'type': 'expression_statement', 'children': ['358']}; {'id': '358', 'type': 'call', 'children': ['359', '362']}; {'id': '359', 'type': 'attribute', 'children': ['360', '361']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'TeArraySizeCheck'}; {'id': '362', 'type': 'argument_list', 'children': []}
Set-up for the finite difference solution method
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'http_error_handler'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '5', 'type': 'block', 'children': ['6', '50', '87', '302']}; {'id': '6', 'type': 'function_definition', 'children': ['7', '8', '10']}; {'id': '7', 'type': 'function_name', 'children': [], 'value': 'hrefs_to_resources'}; {'id': '8', 'type': 'parameters', 'children': ['9']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'hrefs'}; {'id': '10', 'type': 'block', 'children': ['11']}; {'id': '11', 'type': 'for_statement', 'children': ['12', '13', '24']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'href'}; {'id': '13', 'type': 'call', 'children': ['14', '23']}; {'id': '14', 'type': 'attribute', 'children': ['15', '22']}; {'id': '15', 'type': 'call', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'hrefs'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '19', 'type': 'argument_list', 'children': ['20', '21']}; {'id': '20', 'type': 'string', 'children': [], 'value': "','"}; {'id': '21', 'type': 'string', 'children': [], 'value': "''"}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '23', 'type': 'argument_list', 'children': []}; {'id': '24', 'type': 'block', 'children': ['25', '41']}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '30']}; {'id': '27', 'type': 'pattern_list', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '30', 'type': 'subscript', 'children': ['31', '37']}; {'id': '31', 'type': 'call', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'href'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '35', 'type': 'argument_list', 'children': ['36']}; {'id': '36', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '37', 'type': 'slice', 'children': ['38', '40']}; {'id': '38', 'type': 'unary_operator', 'children': ['39'], 'value': '-'}; {'id': '39', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '40', 'type': 'colon', 'children': []}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'yield', 'children': ['43']}; {'id': '43', 'type': 'call', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'Resource'}; {'id': '45', 'type': 'argument_list', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '47', 'type': 'keyword_argument', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '50', 'type': 'function_definition', 'children': ['51', '52', '54']}; {'id': '51', 'type': 'function_name', 'children': [], 'value': 'hrefs_list_to_resources'}; {'id': '52', 'type': 'parameters', 'children': ['53']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'hrefs_list'}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'for_statement', 'children': ['56', '57', '61']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'href'}; {'id': '57', 'type': 'call', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'eval'}; {'id': '59', 'type': 'argument_list', 'children': ['60']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'hrefs_list'}; {'id': '61', 'type': 'block', 'children': ['62', '78']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '67']}; {'id': '64', 'type': 'pattern_list', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '67', 'type': 'subscript', 'children': ['68', '74']}; {'id': '68', 'type': 'call', 'children': ['69', '72']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'href'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '72', 'type': 'argument_list', 'children': ['73']}; {'id': '73', 'type': 'string', 'children': [], 'value': "'/'"}; {'id': '74', 'type': 'slice', 'children': ['75', '77']}; {'id': '75', 'type': 'unary_operator', 'children': ['76'], 'value': '-'}; {'id': '76', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '77', 'type': 'colon', 'children': []}; {'id': '78', 'type': 'expression_statement', 'children': ['79']}; {'id': '79', 'type': 'yield', 'children': ['80']}; {'id': '80', 'type': 'call', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'Resource'}; {'id': '82', 'type': 'argument_list', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '84', 'type': 'keyword_argument', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '87', 'type': 'decorated_definition', 'children': ['88', '93']}; {'id': '88', 'type': 'decorator', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'wraps'}; {'id': '91', 'type': 'argument_list', 'children': ['92']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '93', 'type': 'function_definition', 'children': ['94', '95', '101']}; {'id': '94', 'type': 'function_name', 'children': [], 'value': 'wrapper'}; {'id': '95', 'type': 'parameters', 'children': ['96', '97', '99']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '97', 'type': 'list_splat_pattern', 'children': ['98']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '99', 'type': 'dictionary_splat_pattern', 'children': ['100']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '101', 'type': 'block', 'children': ['102']}; {'id': '102', 'type': 'try_statement', 'children': ['103', '113']}; {'id': '103', 'type': 'block', 'children': ['104']}; {'id': '104', 'type': 'return_statement', 'children': ['105']}; {'id': '105', 'type': 'call', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109', '111']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '109', 'type': 'list_splat', 'children': ['110']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '111', 'type': 'dictionary_splat', 'children': ['112']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '113', 'type': 'except_clause', 'children': ['114', '118']}; {'id': '114', 'type': 'as_pattern', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'HttpError'}; {'id': '116', 'type': 'as_pattern_target', 'children': ['117']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '118', 'type': 'block', 'children': ['119', '301']}; {'id': '119', 'type': 'if_statement', 'children': ['120', '125', '162']}; {'id': '120', 'type': 'comparison_operator', 'children': ['121', '124'], 'value': '=='}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'http_status'}; {'id': '124', 'type': 'integer', 'children': [], 'value': '404'}; {'id': '125', 'type': 'block', 'children': ['126', '134']}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'call', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'emit'}; {'id': '131', 'type': 'argument_list', 'children': ['132', '133']}; {'id': '132', 'type': 'string', 'children': [], 'value': "'deleted'"}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '134', 'type': 'if_statement', 'children': ['135', '140', '148']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'Resource'}; {'id': '140', 'type': 'block', 'children': ['141']}; {'id': '141', 'type': 'raise_statement', 'children': ['142']}; {'id': '142', 'type': 'call', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'ResourceNotFound'}; {'id': '144', 'type': 'argument_list', 'children': ['145']}; {'id': '145', 'type': 'keyword_argument', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'resource'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '148', 'type': 'elif_clause', 'children': ['149', '154']}; {'id': '149', 'type': 'call', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '151', 'type': 'argument_list', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'Collection'}; {'id': '154', 'type': 'block', 'children': ['155']}; {'id': '155', 'type': 'raise_statement', 'children': ['156']}; {'id': '156', 'type': 'call', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'CollectionNotFound'}; {'id': '158', 'type': 'argument_list', 'children': ['159']}; {'id': '159', 'type': 'keyword_argument', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'collection'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '162', 'type': 'elif_clause', 'children': ['163', '168']}; {'id': '163', 'type': 'comparison_operator', 'children': ['164', '167'], 'value': '=='}; {'id': '164', 'type': 'attribute', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'http_status'}; {'id': '167', 'type': 'integer', 'children': [], 'value': '409'}; {'id': '168', 'type': 'block', 'children': ['169', '181', '202', '214', '235', '247', '268', '280']}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'assignment', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '172', 'type': 'call', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '176', 'type': 'argument_list', 'children': ['177', '178']}; {'id': '177', 'type': 'string', 'children': [], 'value': "r'^Delete when children still present: (\\[[^]]*\\])'"}; {'id': '178', 'type': 'attribute', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '181', 'type': 'if_statement', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'raise_statement', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'ChildrenExists'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'keyword_argument', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'resources'}; {'id': '190', 'type': 'call', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '192', 'type': 'argument_list', 'children': ['193']}; {'id': '193', 'type': 'call', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'hrefs_list_to_resources'}; {'id': '195', 'type': 'argument_list', 'children': ['196']}; {'id': '196', 'type': 'call', 'children': ['197', '200']}; {'id': '197', 'type': 'attribute', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '200', 'type': 'argument_list', 'children': ['201']}; {'id': '201', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '205', 'type': 'call', 'children': ['206', '209']}; {'id': '206', 'type': 'attribute', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '209', 'type': 'argument_list', 'children': ['210', '211']}; {'id': '210', 'type': 'string', 'children': [], 'value': "r'^Delete when resource still referred: (\\[[^]]*\\])'"}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '214', 'type': 'if_statement', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '216', 'type': 'block', 'children': ['217']}; {'id': '217', 'type': 'raise_statement', 'children': ['218']}; {'id': '218', 'type': 'call', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'BackRefsExists'}; {'id': '220', 'type': 'argument_list', 'children': ['221']}; {'id': '221', 'type': 'keyword_argument', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'resources'}; {'id': '223', 'type': 'call', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '225', 'type': 'argument_list', 'children': ['226']}; {'id': '226', 'type': 'call', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'hrefs_list_to_resources'}; {'id': '228', 'type': 'argument_list', 'children': ['229']}; {'id': '229', 'type': 'call', 'children': ['230', '233']}; {'id': '230', 'type': 'attribute', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '233', 'type': 'argument_list', 'children': ['234']}; {'id': '234', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'assignment', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '238', 'type': 'call', 'children': ['239', '242']}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '242', 'type': 'argument_list', 'children': ['243', '244']}; {'id': '243', 'type': 'string', 'children': [], 'value': "r'^Children (.*) still exist$'"}; {'id': '244', 'type': 'attribute', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '247', 'type': 'if_statement', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '249', 'type': 'block', 'children': ['250']}; {'id': '250', 'type': 'raise_statement', 'children': ['251']}; {'id': '251', 'type': 'call', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'ChildrenExists'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'keyword_argument', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'resources'}; {'id': '256', 'type': 'call', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '258', 'type': 'argument_list', 'children': ['259']}; {'id': '259', 'type': 'call', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'hrefs_to_resources'}; {'id': '261', 'type': 'argument_list', 'children': ['262']}; {'id': '262', 'type': 'call', 'children': ['263', '266']}; {'id': '263', 'type': 'attribute', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '266', 'type': 'argument_list', 'children': ['267']}; {'id': '267', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '268', 'type': 'expression_statement', 'children': ['269']}; {'id': '269', 'type': 'assignment', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '271', 'type': 'call', 'children': ['272', '275']}; {'id': '272', 'type': 'attribute', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '275', 'type': 'argument_list', 'children': ['276', '277']}; {'id': '276', 'type': 'string', 'children': [], 'value': "r'^Back-References from (.*) still exist$'"}; {'id': '277', 'type': 'attribute', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'message'}; {'id': '280', 'type': 'if_statement', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '282', 'type': 'block', 'children': ['283']}; {'id': '283', 'type': 'raise_statement', 'children': ['284']}; {'id': '284', 'type': 'call', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'BackRefsExists'}; {'id': '286', 'type': 'argument_list', 'children': ['287']}; {'id': '287', 'type': 'keyword_argument', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'resources'}; {'id': '289', 'type': 'call', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '291', 'type': 'argument_list', 'children': ['292']}; {'id': '292', 'type': 'call', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'hrefs_to_resources'}; {'id': '294', 'type': 'argument_list', 'children': ['295']}; {'id': '295', 'type': 'call', 'children': ['296', '299']}; {'id': '296', 'type': 'attribute', 'children': ['297', '298']}; {'id': '297', 'type': 'identifier', 'children': [], 'value': 'matches'}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '299', 'type': 'argument_list', 'children': ['300']}; {'id': '300', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '301', 'type': 'raise_statement', 'children': []}; {'id': '302', 'type': 'return_statement', 'children': ['303']}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'wrapper'}
Handle 404 errors returned by the API server
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_handle_windows'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '6', 'type': 'block', 'children': ['7', '20', '70', '81', '85', '149', '171', '186', '325', '457']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '10', 'type': 'call', 'children': ['11', '14']}; {'id': '11', 'type': 'attribute', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': '_keyname'}; {'id': '14', 'type': 'argument_list', 'children': ['15']}; {'id': '15', 'type': 'call', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'GetKey'}; {'id': '19', 'type': 'argument_list', 'children': []}; {'id': '20', 'type': 'if_statement', 'children': ['21', '32']}; {'id': '21', 'type': 'comparison_operator', 'children': ['22', '25'], 'value': 'in'}; {'id': '22', 'type': 'attribute', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'Message'}; {'id': '25', 'type': 'binary_operator', 'children': ['26', '29'], 'value': '+'}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'KEYS_UP'}; {'id': '29', 'type': 'attribute', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'KEYS_DOWN'}; {'id': '32', 'type': 'block', 'children': ['33']}; {'id': '33', 'type': 'if_statement', 'children': ['34', '39']}; {'id': '34', 'type': 'comparison_operator', 'children': ['35', '36'], 'value': 'in'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '39', 'type': 'block', 'children': ['40', '54']}; {'id': '40', 'type': 'expression_statement', 'children': ['41']}; {'id': '41', 'type': 'assignment', 'children': ['42', '47']}; {'id': '42', 'type': 'subscript', 'children': ['43', '46']}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': '_realmodifiers'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '47', 'type': 'comparison_operator', 'children': ['48', '51'], 'value': 'in'}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'Message'}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'KEYS_DOWN'}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'assignment', 'children': ['56', '65']}; {'id': '56', 'type': 'subscript', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': '_modifiers'}; {'id': '60', 'type': 'subscript', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '65', 'type': 'subscript', 'children': ['66', '69']}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': '_realmodifiers'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '70', 'type': 'if_statement', 'children': ['71', '78']}; {'id': '71', 'type': 'comparison_operator', 'children': ['72', '75'], 'value': 'not'}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'Message'}; {'id': '75', 'type': 'attribute', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'KEYS_DOWN'}; {'id': '78', 'type': 'block', 'children': ['79']}; {'id': '79', 'type': 'return_statement', 'children': ['80']}; {'id': '80', 'type': 'True', 'children': []}; {'id': '81', 'type': 'expression_statement', 'children': ['82']}; {'id': '82', 'type': 'assignment', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'is_altgr'}; {'id': '84', 'type': 'False', 'children': []}; {'id': '85', 'type': 'if_statement', 'children': ['86', '97', '106', '123']}; {'id': '86', 'type': 'comparison_operator', 'children': ['87', '94'], 'value': 'in'}; {'id': '87', 'type': 'tuple', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'IsExtended'}; {'id': '93', 'type': 'argument_list', 'children': []}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'NUMPAD_SPECIALS'}; {'id': '97', 'type': 'block', 'children': ['98']}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'assignment', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '101', 'type': 'assignment', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '103', 'type': 'binary_operator', 'children': ['104', '105'], 'value': '+'}; {'id': '104', 'type': 'string', 'children': [], 'value': '"Numpad-"'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '106', 'type': 'elif_clause', 'children': ['107', '118']}; {'id': '107', 'type': 'boolean_operator', 'children': ['108', '112'], 'value': 'or'}; {'id': '108', 'type': 'not_operator', 'children': ['109']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'Ascii'}; {'id': '112', 'type': 'call', 'children': ['113', '116']}; {'id': '113', 'type': 'attribute', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '116', 'type': 'argument_list', 'children': ['117']}; {'id': '117', 'type': 'string', 'children': [], 'value': '"Numpad"'}; {'id': '118', 'type': 'block', 'children': ['119']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'assignment', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '123', 'type': 'else_clause', 'children': ['124']}; {'id': '124', 'type': 'block', 'children': ['125', '135']}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'assignment', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'is_altgr'}; {'id': '128', 'type': 'comparison_operator', 'children': ['129', '132'], 'value': 'in'}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'Ascii'}; {'id': '132', 'type': 'attribute', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'ALT_GRS'}; {'id': '135', 'type': 'expression_statement', 'children': ['136']}; {'id': '136', 'type': 'assignment', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': '_keyname'}; {'id': '142', 'type': 'argument_list', 'children': ['143']}; {'id': '143', 'type': 'call', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'unichr'}; {'id': '145', 'type': 'argument_list', 'children': ['146']}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'Ascii'}; {'id': '149', 'type': 'if_statement', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'DEBUG'}; {'id': '151', 'type': 'block', 'children': ['152']}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'call', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '155', 'type': 'argument_list', 'children': ['156']}; {'id': '156', 'type': 'binary_operator', 'children': ['157', '158'], 'value': '%'}; {'id': '157', 'type': 'string', 'children': [], 'value': '"Adding key %s (real %s)"'}; {'id': '158', 'type': 'tuple', 'children': ['159', '165']}; {'id': '159', 'type': 'call', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '163', 'type': 'argument_list', 'children': ['164']}; {'id': '164', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '165', 'type': 'call', 'children': ['166', '169']}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'call', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': '_output'}; {'id': '176', 'type': 'argument_list', 'children': ['177', '180', '183']}; {'id': '177', 'type': 'keyword_argument', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '179', 'type': 'string', 'children': [], 'value': '"keys"'}; {'id': '180', 'type': 'keyword_argument', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '183', 'type': 'keyword_argument', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '186', 'type': 'if_statement', 'children': ['187', '195']}; {'id': '187', 'type': 'boolean_operator', 'children': ['188', '193'], 'value': 'and'}; {'id': '188', 'type': 'comparison_operator', 'children': ['189', '190'], 'value': 'not'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'vkey'}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '193', 'type': 'not_operator', 'children': ['194']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'is_altgr'}; {'id': '195', 'type': 'block', 'children': ['196', '218']}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '203', 'type': 'generator_expression', 'children': ['204', '205', '212']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '205', 'type': 'for_in_clause', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '207', 'type': 'list', 'children': ['208', '209', '210', '211'], 'value': '["Ctrl", "Alt", "Shift", "Win"]'}; {'id': '208', 'type': 'string', 'children': [], 'value': '"Ctrl"'}; {'id': '209', 'type': 'string', 'children': [], 'value': '"Alt"'}; {'id': '210', 'type': 'string', 'children': [], 'value': '"Shift"'}; {'id': '211', 'type': 'string', 'children': [], 'value': '"Win"'}; {'id': '212', 'type': 'if_clause', 'children': ['213']}; {'id': '213', 'type': 'subscript', 'children': ['214', '217']}; {'id': '214', 'type': 'attribute', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': '_modifiers'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '218', 'type': 'if_statement', 'children': ['219', '224']}; {'id': '219', 'type': 'boolean_operator', 'children': ['220', '221'], 'value': 'and'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '221', 'type': 'comparison_operator', 'children': ['222', '223'], 'value': '!='}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '223', 'type': 'string', 'children': [], 'value': '"Shift"'}; {'id': '224', 'type': 'block', 'children': ['225', '250', '272', '280', '288', '310']}; {'id': '225', 'type': 'if_statement', 'children': ['226', '235']}; {'id': '226', 'type': 'boolean_operator', 'children': ['227', '232'], 'value': 'and'}; {'id': '227', 'type': 'subscript', 'children': ['228', '231']}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': '_modifiers'}; {'id': '231', 'type': 'string', 'children': [], 'value': '"Ctrl"'}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'Ascii'}; {'id': '235', 'type': 'block', 'children': ['236']}; {'id': '236', 'type': 'expression_statement', 'children': ['237']}; {'id': '237', 'type': 'assignment', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '239', 'type': 'call', 'children': ['240', '243']}; {'id': '240', 'type': 'attribute', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': '_keyname'}; {'id': '243', 'type': 'argument_list', 'children': ['244']}; {'id': '244', 'type': 'call', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'unichr'}; {'id': '246', 'type': 'argument_list', 'children': ['247']}; {'id': '247', 'type': 'attribute', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'KeyID'}; {'id': '250', 'type': 'expression_statement', 'children': ['251']}; {'id': '251', 'type': 'assignment', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'realmodifier'}; {'id': '253', 'type': 'call', 'children': ['254', '257']}; {'id': '254', 'type': 'attribute', 'children': ['255', '256']}; {'id': '255', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '257', 'type': 'generator_expression', 'children': ['258', '259', '270']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '259', 'type': 'for_in_clause', 'children': ['260', '263']}; {'id': '260', 'type': 'pattern_list', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '263', 'type': 'call', 'children': ['264', '269']}; {'id': '264', 'type': 'attribute', 'children': ['265', '268']}; {'id': '265', 'type': 'attribute', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': '_realmodifiers'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '269', 'type': 'argument_list', 'children': []}; {'id': '270', 'type': 'if_clause', 'children': ['271']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'assignment', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '275', 'type': 'binary_operator', 'children': ['276', '277'], 'value': '%'}; {'id': '276', 'type': 'string', 'children': [], 'value': '"%s-%s"'}; {'id': '277', 'type': 'tuple', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'realmodifier'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '280', 'type': 'expression_statement', 'children': ['281']}; {'id': '281', 'type': 'assignment', 'children': ['282', '283']}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '283', 'type': 'binary_operator', 'children': ['284', '285'], 'value': '%'}; {'id': '284', 'type': 'string', 'children': [], 'value': '"%s-%s"'}; {'id': '285', 'type': 'tuple', 'children': ['286', '287']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '288', 'type': 'if_statement', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'DEBUG'}; {'id': '290', 'type': 'block', 'children': ['291']}; {'id': '291', 'type': 'expression_statement', 'children': ['292']}; {'id': '292', 'type': 'call', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '294', 'type': 'argument_list', 'children': ['295']}; {'id': '295', 'type': 'binary_operator', 'children': ['296', '297'], 'value': '%'}; {'id': '296', 'type': 'string', 'children': [], 'value': '"Adding combo %s (real %s)"'}; {'id': '297', 'type': 'tuple', 'children': ['298', '304']}; {'id': '298', 'type': 'call', 'children': ['299', '302']}; {'id': '299', 'type': 'attribute', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '302', 'type': 'argument_list', 'children': ['303']}; {'id': '303', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '304', 'type': 'call', 'children': ['305', '308']}; {'id': '305', 'type': 'attribute', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '308', 'type': 'argument_list', 'children': ['309']}; {'id': '309', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '310', 'type': 'expression_statement', 'children': ['311']}; {'id': '311', 'type': 'call', 'children': ['312', '315']}; {'id': '312', 'type': 'attribute', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '314', 'type': 'identifier', 'children': [], 'value': '_output'}; {'id': '315', 'type': 'argument_list', 'children': ['316', '319', '322']}; {'id': '316', 'type': 'keyword_argument', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '318', 'type': 'string', 'children': [], 'value': '"combos"'}; {'id': '319', 'type': 'keyword_argument', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '322', 'type': 'keyword_argument', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '325', 'type': 'if_statement', 'children': ['326', '327']}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'DEBUG'}; {'id': '327', 'type': 'block', 'children': ['328', '335', '349', '363', '377', '391', '405', '417', '429', '441', '453']}; {'id': '328', 'type': 'expression_statement', 'children': ['329']}; {'id': '329', 'type': 'call', 'children': ['330', '331']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '331', 'type': 'argument_list', 'children': ['332']}; {'id': '332', 'type': 'binary_operator', 'children': ['333', '334'], 'value': '%'}; {'id': '333', 'type': 'string', 'children': [], 'value': '"CHARACTER: %r"'}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '335', 'type': 'expression_statement', 'children': ['336']}; {'id': '336', 'type': 'call', 'children': ['337', '338']}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '338', 'type': 'argument_list', 'children': ['339']}; {'id': '339', 'type': 'call', 'children': ['340', '343']}; {'id': '340', 'type': 'attribute', 'children': ['341', '342']}; {'id': '341', 'type': 'string', 'children': [], 'value': "'GetKey: {0}'"}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '343', 'type': 'argument_list', 'children': ['344']}; {'id': '344', 'type': 'call', 'children': ['345', '348']}; {'id': '345', 'type': 'attribute', 'children': ['346', '347']}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'GetKey'}; {'id': '348', 'type': 'argument_list', 'children': []}; {'id': '349', 'type': 'expression_statement', 'children': ['350']}; {'id': '350', 'type': 'call', 'children': ['351', '352']}; {'id': '351', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '352', 'type': 'argument_list', 'children': ['353']}; {'id': '353', 'type': 'call', 'children': ['354', '357']}; {'id': '354', 'type': 'attribute', 'children': ['355', '356']}; {'id': '355', 'type': 'string', 'children': [], 'value': "'IsAlt: {0}'"}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '357', 'type': 'argument_list', 'children': ['358']}; {'id': '358', 'type': 'call', 'children': ['359', '362']}; {'id': '359', 'type': 'attribute', 'children': ['360', '361']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'IsAlt'}; {'id': '362', 'type': 'argument_list', 'children': []}; {'id': '363', 'type': 'expression_statement', 'children': ['364']}; {'id': '364', 'type': 'call', 'children': ['365', '366']}; {'id': '365', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '366', 'type': 'argument_list', 'children': ['367']}; {'id': '367', 'type': 'call', 'children': ['368', '371']}; {'id': '368', 'type': 'attribute', 'children': ['369', '370']}; {'id': '369', 'type': 'string', 'children': [], 'value': "'IsExtended: {0}'"}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '371', 'type': 'argument_list', 'children': ['372']}; {'id': '372', 'type': 'call', 'children': ['373', '376']}; {'id': '373', 'type': 'attribute', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'IsExtended'}; {'id': '376', 'type': 'argument_list', 'children': []}; {'id': '377', 'type': 'expression_statement', 'children': ['378']}; {'id': '378', 'type': 'call', 'children': ['379', '380']}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '380', 'type': 'argument_list', 'children': ['381']}; {'id': '381', 'type': 'call', 'children': ['382', '385']}; {'id': '382', 'type': 'attribute', 'children': ['383', '384']}; {'id': '383', 'type': 'string', 'children': [], 'value': "'IsInjected: {0}'"}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '385', 'type': 'argument_list', 'children': ['386']}; {'id': '386', 'type': 'call', 'children': ['387', '390']}; {'id': '387', 'type': 'attribute', 'children': ['388', '389']}; {'id': '388', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'IsInjected'}; {'id': '390', 'type': 'argument_list', 'children': []}; {'id': '391', 'type': 'expression_statement', 'children': ['392']}; {'id': '392', 'type': 'call', 'children': ['393', '394']}; {'id': '393', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '394', 'type': 'argument_list', 'children': ['395']}; {'id': '395', 'type': 'call', 'children': ['396', '399']}; {'id': '396', 'type': 'attribute', 'children': ['397', '398']}; {'id': '397', 'type': 'string', 'children': [], 'value': "'IsTransition: {0}'"}; {'id': '398', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '399', 'type': 'argument_list', 'children': ['400']}; {'id': '400', 'type': 'call', 'children': ['401', '404']}; {'id': '401', 'type': 'attribute', 'children': ['402', '403']}; {'id': '402', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '403', 'type': 'identifier', 'children': [], 'value': 'IsTransition'}; {'id': '404', 'type': 'argument_list', 'children': []}; {'id': '405', 'type': 'expression_statement', 'children': ['406']}; {'id': '406', 'type': 'call', 'children': ['407', '408']}; {'id': '407', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '408', 'type': 'argument_list', 'children': ['409']}; {'id': '409', 'type': 'call', 'children': ['410', '413']}; {'id': '410', 'type': 'attribute', 'children': ['411', '412']}; {'id': '411', 'type': 'string', 'children': [], 'value': "'ASCII: {0}'"}; {'id': '412', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '413', 'type': 'argument_list', 'children': ['414']}; {'id': '414', 'type': 'attribute', 'children': ['415', '416']}; {'id': '415', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '416', 'type': 'identifier', 'children': [], 'value': 'Ascii'}; {'id': '417', 'type': 'expression_statement', 'children': ['418']}; {'id': '418', 'type': 'call', 'children': ['419', '420']}; {'id': '419', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '420', 'type': 'argument_list', 'children': ['421']}; {'id': '421', 'type': 'call', 'children': ['422', '425']}; {'id': '422', 'type': 'attribute', 'children': ['423', '424']}; {'id': '423', 'type': 'string', 'children': [], 'value': "'KeyID: {0}'"}; {'id': '424', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '425', 'type': 'argument_list', 'children': ['426']}; {'id': '426', 'type': 'attribute', 'children': ['427', '428']}; {'id': '427', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '428', 'type': 'identifier', 'children': [], 'value': 'KeyID'}; {'id': '429', 'type': 'expression_statement', 'children': ['430']}; {'id': '430', 'type': 'call', 'children': ['431', '432']}; {'id': '431', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '432', 'type': 'argument_list', 'children': ['433']}; {'id': '433', 'type': 'call', 'children': ['434', '437']}; {'id': '434', 'type': 'attribute', 'children': ['435', '436']}; {'id': '435', 'type': 'string', 'children': [], 'value': "'ScanCode: {0}'"}; {'id': '436', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '437', 'type': 'argument_list', 'children': ['438']}; {'id': '438', 'type': 'attribute', 'children': ['439', '440']}; {'id': '439', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '440', 'type': 'identifier', 'children': [], 'value': 'ScanCode'}; {'id': '441', 'type': 'expression_statement', 'children': ['442']}; {'id': '442', 'type': 'call', 'children': ['443', '444']}; {'id': '443', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '444', 'type': 'argument_list', 'children': ['445']}; {'id': '445', 'type': 'call', 'children': ['446', '449']}; {'id': '446', 'type': 'attribute', 'children': ['447', '448']}; {'id': '447', 'type': 'string', 'children': [], 'value': "'Message: {0}'"}; {'id': '448', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '449', 'type': 'argument_list', 'children': ['450']}; {'id': '450', 'type': 'attribute', 'children': ['451', '452']}; {'id': '451', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '452', 'type': 'identifier', 'children': [], 'value': 'Message'}; {'id': '453', 'type': 'expression_statement', 'children': ['454']}; {'id': '454', 'type': 'call', 'children': ['455', '456']}; {'id': '455', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '456', 'type': 'argument_list', 'children': []}; {'id': '457', 'type': 'return_statement', 'children': ['458']}; {'id': '458', 'type': 'True', 'children': []}
Windows key event handler.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_handle_linux'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'keycode'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'character'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'press'}; {'id': '8', 'type': 'block', 'children': ['9', '15', '25', '52', '70']}; {'id': '9', 'type': 'if_statement', 'children': ['10', '13']}; {'id': '10', 'type': 'comparison_operator', 'children': ['11', '12'], 'value': 'is'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'character'}; {'id': '12', 'type': 'None', 'children': []}; {'id': '13', 'type': 'block', 'children': ['14']}; {'id': '14', 'type': 'return_statement', 'children': []}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '18', 'type': 'call', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': '_keyname'}; {'id': '22', 'type': 'argument_list', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'character'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'keycode'}; {'id': '25', 'type': 'if_statement', 'children': ['26', '31']}; {'id': '26', 'type': 'comparison_operator', 'children': ['27', '28'], 'value': 'in'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '31', 'type': 'block', 'children': ['32', '44']}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'assignment', 'children': ['34', '43']}; {'id': '34', 'type': 'subscript', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': '_modifiers'}; {'id': '38', 'type': 'subscript', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'press'}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '51']}; {'id': '46', 'type': 'subscript', 'children': ['47', '50']}; {'id': '47', 'type': 'attribute', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': '_realmodifiers'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'press'}; {'id': '52', 'type': 'if_statement', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'press'}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'call', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': '_output'}; {'id': '60', 'type': 'argument_list', 'children': ['61', '64', '67']}; {'id': '61', 'type': 'keyword_argument', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '63', 'type': 'string', 'children': [], 'value': '"keys"'}; {'id': '64', 'type': 'keyword_argument', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '67', 'type': 'keyword_argument', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '70', 'type': 'if_statement', 'children': ['71', '78']}; {'id': '71', 'type': 'boolean_operator', 'children': ['72', '73'], 'value': 'and'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'press'}; {'id': '73', 'type': 'comparison_operator', 'children': ['74', '75'], 'value': 'not'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '75', 'type': 'attribute', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'MODIFIERNAMES'}; {'id': '78', 'type': 'block', 'children': ['79', '101']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '82', 'type': 'call', 'children': ['83', '86']}; {'id': '83', 'type': 'attribute', 'children': ['84', '85']}; {'id': '84', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '86', 'type': 'generator_expression', 'children': ['87', '88', '95']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '88', 'type': 'for_in_clause', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '90', 'type': 'list', 'children': ['91', '92', '93', '94'], 'value': '["Ctrl", "Alt", "Shift", "Win"]'}; {'id': '91', 'type': 'string', 'children': [], 'value': '"Ctrl"'}; {'id': '92', 'type': 'string', 'children': [], 'value': '"Alt"'}; {'id': '93', 'type': 'string', 'children': [], 'value': '"Shift"'}; {'id': '94', 'type': 'string', 'children': [], 'value': '"Win"'}; {'id': '95', 'type': 'if_clause', 'children': ['96']}; {'id': '96', 'type': 'subscript', 'children': ['97', '100']}; {'id': '97', 'type': 'attribute', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': '_modifiers'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '101', 'type': 'if_statement', 'children': ['102', '107']}; {'id': '102', 'type': 'boolean_operator', 'children': ['103', '104'], 'value': 'and'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '104', 'type': 'comparison_operator', 'children': ['105', '106'], 'value': '!='}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '106', 'type': 'string', 'children': [], 'value': '"Shift"'}; {'id': '107', 'type': 'block', 'children': ['108', '130', '138', '146', '168']}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'assignment', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'realmodifier'}; {'id': '111', 'type': 'call', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '115', 'type': 'generator_expression', 'children': ['116', '117', '128']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '117', 'type': 'for_in_clause', 'children': ['118', '121']}; {'id': '118', 'type': 'pattern_list', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '121', 'type': 'call', 'children': ['122', '127']}; {'id': '122', 'type': 'attribute', 'children': ['123', '126']}; {'id': '123', 'type': 'attribute', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': '_realmodifiers'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '127', 'type': 'argument_list', 'children': []}; {'id': '128', 'type': 'if_clause', 'children': ['129']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'assignment', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '133', 'type': 'binary_operator', 'children': ['134', '135'], 'value': '%'}; {'id': '134', 'type': 'string', 'children': [], 'value': '"%s-%s"'}; {'id': '135', 'type': 'tuple', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'realmodifier'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'assignment', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '141', 'type': 'binary_operator', 'children': ['142', '143'], 'value': '%'}; {'id': '142', 'type': 'string', 'children': [], 'value': '"%s-%s"'}; {'id': '143', 'type': 'tuple', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'modifier'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '146', 'type': 'if_statement', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'DEBUG'}; {'id': '148', 'type': 'block', 'children': ['149']}; {'id': '149', 'type': 'expression_statement', 'children': ['150']}; {'id': '150', 'type': 'call', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'binary_operator', 'children': ['154', '155'], 'value': '%'}; {'id': '154', 'type': 'string', 'children': [], 'value': '"Adding combo %s (real %s)"'}; {'id': '155', 'type': 'tuple', 'children': ['156', '162']}; {'id': '156', 'type': 'call', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '160', 'type': 'argument_list', 'children': ['161']}; {'id': '161', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '162', 'type': 'call', 'children': ['163', '166']}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '166', 'type': 'argument_list', 'children': ['167']}; {'id': '167', 'type': 'string', 'children': [], 'value': '"utf-8"'}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'call', 'children': ['170', '173']}; {'id': '170', 'type': 'attribute', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': '_output'}; {'id': '173', 'type': 'argument_list', 'children': ['174', '177', '180']}; {'id': '174', 'type': 'keyword_argument', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '176', 'type': 'string', 'children': [], 'value': '"combos"'}; {'id': '177', 'type': 'keyword_argument', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '180', 'type': 'keyword_argument', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'realkey'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'realkey'}
Linux key event handler.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_preprocess'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '5', 'type': 'block', 'children': ['6', '17', '28', '39', '50', '61', '72', '83', '94', '105', '116', '127', '138', '149', '333']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '9', 'type': 'call', 'children': ['10', '13']}; {'id': '10', 'type': 'attribute', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '13', 'type': 'argument_list', 'children': ['14', '15', '16']}; {'id': '14', 'type': 'string', 'children': [], 'value': "r'(\\b)a(\\b)'"}; {'id': '15', 'type': 'string', 'children': [], 'value': "r'\\g<1>one\\g<2>'"}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '24', 'type': 'argument_list', 'children': ['25', '26', '27']}; {'id': '25', 'type': 'string', 'children': [], 'value': "r'to the (.*) power'"}; {'id': '26', 'type': 'string', 'children': [], 'value': "r'to \\g<1>'"}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '31', 'type': 'call', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '35', 'type': 'argument_list', 'children': ['36', '37', '38']}; {'id': '36', 'type': 'string', 'children': [], 'value': "r'to the (.*?)(\\b)'"}; {'id': '37', 'type': 'string', 'children': [], 'value': "r'to \\g<1>\\g<2>'"}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '42', 'type': 'call', 'children': ['43', '46']}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '46', 'type': 'argument_list', 'children': ['47', '48', '49']}; {'id': '47', 'type': 'string', 'children': [], 'value': "r'log of'"}; {'id': '48', 'type': 'string', 'children': [], 'value': "r'log'"}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '50', 'type': 'expression_statement', 'children': ['51']}; {'id': '51', 'type': 'assignment', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '53', 'type': 'call', 'children': ['54', '57']}; {'id': '54', 'type': 'attribute', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '57', 'type': 'argument_list', 'children': ['58', '59', '60']}; {'id': '58', 'type': 'string', 'children': [], 'value': "r'(square )?root( of)?'"}; {'id': '59', 'type': 'string', 'children': [], 'value': "r'sqrt'"}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '64', 'type': 'call', 'children': ['65', '68']}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '70', '71']}; {'id': '69', 'type': 'string', 'children': [], 'value': "r'squared'"}; {'id': '70', 'type': 'string', 'children': [], 'value': "r'to two'"}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '79', 'type': 'argument_list', 'children': ['80', '81', '82']}; {'id': '80', 'type': 'string', 'children': [], 'value': "r'cubed'"}; {'id': '81', 'type': 'string', 'children': [], 'value': "r'to three'"}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '86', 'type': 'call', 'children': ['87', '90']}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '90', 'type': 'argument_list', 'children': ['91', '92', '93']}; {'id': '91', 'type': 'string', 'children': [], 'value': "r'divided?( by)?'"}; {'id': '92', 'type': 'string', 'children': [], 'value': "r'divide'"}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'assignment', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '97', 'type': 'call', 'children': ['98', '101']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '101', 'type': 'argument_list', 'children': ['102', '103', '104']}; {'id': '102', 'type': 'string', 'children': [], 'value': "r'(\\b)over(\\b)'"}; {'id': '103', 'type': 'string', 'children': [], 'value': "r'\\g<1>divide\\g<2>'"}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '108', 'type': 'call', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '112', 'type': 'argument_list', 'children': ['113', '114', '115']}; {'id': '113', 'type': 'string', 'children': [], 'value': "r'(\\b)EE(\\b)'"}; {'id': '114', 'type': 'string', 'children': [], 'value': "r'\\g<1>e\\g<2>'"}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'assignment', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '119', 'type': 'call', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '123', 'type': 'argument_list', 'children': ['124', '125', '126']}; {'id': '124', 'type': 'string', 'children': [], 'value': "r'(\\b)E(\\b)'"}; {'id': '125', 'type': 'string', 'children': [], 'value': "r'\\g<1>e\\g<2>'"}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '130', 'type': 'call', 'children': ['131', '134']}; {'id': '131', 'type': 'attribute', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '134', 'type': 'argument_list', 'children': ['135', '136', '137']}; {'id': '135', 'type': 'string', 'children': [], 'value': "r'(\\b)pie(\\b)'"}; {'id': '136', 'type': 'string', 'children': [], 'value': "r'\\g<1>pi\\g<2>'"}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'assignment', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '141', 'type': 'call', 'children': ['142', '145']}; {'id': '142', 'type': 'attribute', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '145', 'type': 'argument_list', 'children': ['146', '147', '148']}; {'id': '146', 'type': 'string', 'children': [], 'value': "r'(\\b)PI(\\b)'"}; {'id': '147', 'type': 'string', 'children': [], 'value': "r'\\g<1>pi\\g<2>'"}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '149', 'type': 'function_definition', 'children': ['150', '151', '153']}; {'id': '150', 'type': 'function_name', 'children': [], 'value': 'findImplicitMultiplications'}; {'id': '151', 'type': 'parameters', 'children': ['152']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '153', 'type': 'block', 'children': ['154', '232', '325']}; {'id': '154', 'type': 'function_definition', 'children': ['155', '156', '158']}; {'id': '155', 'type': 'function_name', 'children': [], 'value': 'findConstantMultiplications'}; {'id': '156', 'type': 'parameters', 'children': ['157']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '158', 'type': 'block', 'children': ['159', '168', '172', '178', '230']}; {'id': '159', 'type': 'expression_statement', 'children': ['160']}; {'id': '160', 'type': 'assignment', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '162', 'type': 'call', 'children': ['163', '166']}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '166', 'type': 'argument_list', 'children': ['167']}; {'id': '167', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '171', 'type': 'string', 'children': [], 'value': '""'}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'assignment', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'converter'}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'NumberService'}; {'id': '177', 'type': 'argument_list', 'children': []}; {'id': '178', 'type': 'for_statement', 'children': ['179', '182', '186']}; {'id': '179', 'type': 'pattern_list', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '186', 'type': 'block', 'children': ['187', '214']}; {'id': '187', 'type': 'if_statement', 'children': ['188', '197']}; {'id': '188', 'type': 'boolean_operator', 'children': ['189', '192'], 'value': 'and'}; {'id': '189', 'type': 'comparison_operator', 'children': ['190', '191'], 'value': '>'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '191', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '192', 'type': 'comparison_operator', 'children': ['193', '194'], 'value': 'in'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'MathService'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': '__constants__'}; {'id': '197', 'type': 'block', 'children': ['198']}; {'id': '198', 'type': 'if_statement', 'children': ['199', '209']}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'converter'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'isValid'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'subscript', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '206', 'type': 'binary_operator', 'children': ['207', '208'], 'value': '-'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '208', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '209', 'type': 'block', 'children': ['210']}; {'id': '210', 'type': 'expression_statement', 'children': ['211']}; {'id': '211', 'type': 'augmented_assignment', 'children': ['212', '213'], 'value': '+='}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '213', 'type': 'string', 'children': [], 'value': '" times"'}; {'id': '214', 'type': 'if_statement', 'children': ['215', '217', '222']}; {'id': '215', 'type': 'not_operator', 'children': ['216']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '217', 'type': 'block', 'children': ['218']}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'assignment', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '222', 'type': 'else_clause', 'children': ['223']}; {'id': '223', 'type': 'block', 'children': ['224']}; {'id': '224', 'type': 'expression_statement', 'children': ['225']}; {'id': '225', 'type': 'augmented_assignment', 'children': ['226', '227'], 'value': '+='}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '227', 'type': 'binary_operator', 'children': ['228', '229'], 'value': '+'}; {'id': '228', 'type': 'string', 'children': [], 'value': '" "'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '230', 'type': 'return_statement', 'children': ['231']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '232', 'type': 'function_definition', 'children': ['233', '234', '236']}; {'id': '233', 'type': 'function_name', 'children': [], 'value': 'findUnaryMultiplications'}; {'id': '234', 'type': 'parameters', 'children': ['235']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '236', 'type': 'block', 'children': ['237', '246', '250', '323']}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'assignment', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '240', 'type': 'call', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '246', 'type': 'expression_statement', 'children': ['247']}; {'id': '247', 'type': 'assignment', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '249', 'type': 'string', 'children': [], 'value': '""'}; {'id': '250', 'type': 'for_statement', 'children': ['251', '254', '258']}; {'id': '251', 'type': 'pattern_list', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '254', 'type': 'call', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '256', 'type': 'argument_list', 'children': ['257']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '258', 'type': 'block', 'children': ['259', '307']}; {'id': '259', 'type': 'if_statement', 'children': ['260', '269']}; {'id': '260', 'type': 'boolean_operator', 'children': ['261', '264'], 'value': 'and'}; {'id': '261', 'type': 'comparison_operator', 'children': ['262', '263'], 'value': '>'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '263', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '264', 'type': 'comparison_operator', 'children': ['265', '266'], 'value': 'in'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '266', 'type': 'attribute', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'MathService'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': '__unaryOperators__'}; {'id': '269', 'type': 'block', 'children': ['270', '278', '286', '294']}; {'id': '270', 'type': 'expression_statement', 'children': ['271']}; {'id': '271', 'type': 'assignment', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'last_op'}; {'id': '273', 'type': 'subscript', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '275', 'type': 'binary_operator', 'children': ['276', '277'], 'value': '-'}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '277', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '278', 'type': 'expression_statement', 'children': ['279']}; {'id': '279', 'type': 'assignment', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'binary'}; {'id': '281', 'type': 'comparison_operator', 'children': ['282', '283'], 'value': 'in'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'last_op'}; {'id': '283', 'type': 'attribute', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'MathService'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': '__binaryOperators__'}; {'id': '286', 'type': 'expression_statement', 'children': ['287']}; {'id': '287', 'type': 'assignment', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'unary'}; {'id': '289', 'type': 'comparison_operator', 'children': ['290', '291'], 'value': 'in'}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'last_op'}; {'id': '291', 'type': 'attribute', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'MathService'}; {'id': '293', 'type': 'identifier', 'children': [], 'value': '__unaryOperators__'}; {'id': '294', 'type': 'if_statement', 'children': ['295', '302']}; {'id': '295', 'type': 'boolean_operator', 'children': ['296', '297'], 'value': 'and'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'last_op'}; {'id': '297', 'type': 'not_operator', 'children': ['298']}; {'id': '298', 'type': '()', 'children': ['299']}; {'id': '299', 'type': 'boolean_operator', 'children': ['300', '301'], 'value': 'or'}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'binary'}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'unary'}; {'id': '302', 'type': 'block', 'children': ['303']}; {'id': '303', 'type': 'expression_statement', 'children': ['304']}; {'id': '304', 'type': 'augmented_assignment', 'children': ['305', '306'], 'value': '+='}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '306', 'type': 'string', 'children': [], 'value': '" times"'}; {'id': '307', 'type': 'if_statement', 'children': ['308', '310', '315']}; {'id': '308', 'type': 'not_operator', 'children': ['309']}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '310', 'type': 'block', 'children': ['311']}; {'id': '311', 'type': 'expression_statement', 'children': ['312']}; {'id': '312', 'type': 'assignment', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '315', 'type': 'else_clause', 'children': ['316']}; {'id': '316', 'type': 'block', 'children': ['317']}; {'id': '317', 'type': 'expression_statement', 'children': ['318']}; {'id': '318', 'type': 'augmented_assignment', 'children': ['319', '320'], 'value': '+='}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '320', 'type': 'binary_operator', 'children': ['321', '322'], 'value': '+'}; {'id': '321', 'type': 'string', 'children': [], 'value': '" "'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'w'}; {'id': '323', 'type': 'return_statement', 'children': ['324']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'revision'}; {'id': '325', 'type': 'return_statement', 'children': ['326']}; {'id': '326', 'type': 'call', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'findUnaryMultiplications'}; {'id': '328', 'type': 'argument_list', 'children': ['329']}; {'id': '329', 'type': 'call', 'children': ['330', '331']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'findConstantMultiplications'}; {'id': '331', 'type': 'argument_list', 'children': ['332']}; {'id': '332', 'type': 'identifier', 'children': [], 'value': 'inp'}; {'id': '333', 'type': 'return_statement', 'children': ['334']}; {'id': '334', 'type': 'call', 'children': ['335', '336']}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'findImplicitMultiplications'}; {'id': '336', 'type': 'argument_list', 'children': ['337']}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'inp'}
Revise wording to match canonical and expected forms.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'stats_keyboard'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '6', 'type': 'block', 'children': ['7', '19', '27', '35', '48', '63', '72', '200', '229', '387']}; {'id': '7', 'type': 'if_statement', 'children': ['8', '14']}; {'id': '8', 'type': 'comparison_operator', 'children': ['9', '13'], 'value': '<'}; {'id': '9', 'type': 'call', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '11', 'type': 'argument_list', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '13', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '14', 'type': 'block', 'children': ['15']}; {'id': '15', 'type': 'return_statement', 'children': ['16']}; {'id': '16', 'type': 'expression_list', 'children': ['17', '18']}; {'id': '17', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '18', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '24']}; {'id': '21', 'type': 'pattern_list', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '24', 'type': 'expression_list', 'children': ['25', '26']}; {'id': '25', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '26', 'type': 'None', 'children': []}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '32']}; {'id': '29', 'type': 'pattern_list', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '32', 'type': 'expression_list', 'children': ['33', '34']}; {'id': '33', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '34', 'type': 'None', 'children': []}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'UNBROKEN_DELTA'}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '42', 'type': 'argument_list', 'children': ['43']}; {'id': '43', 'type': 'keyword_argument', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'seconds'}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'KeyboardSessionMaxDelta'}; {'id': '48', 'type': 'expression_statement', 'children': ['49']}; {'id': '49', 'type': 'assignment', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'blank'}; {'id': '51', 'type': 'call', 'children': ['52', '55']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'collections'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'defaultdict'}; {'id': '55', 'type': 'argument_list', 'children': ['56']}; {'id': '56', 'type': 'lambda', 'children': ['57']}; {'id': '57', 'type': 'call', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'collections'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'defaultdict'}; {'id': '61', 'type': 'argument_list', 'children': ['62']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'assignment', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'collated'}; {'id': '66', 'type': 'list', 'children': ['67'], 'value': '[blank.copy()]'}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'blank'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '71', 'type': 'argument_list', 'children': []}; {'id': '72', 'type': 'for_statement', 'children': ['73', '74', '75']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '75', 'type': 'block', 'children': ['76', '170', '181', '194']}; {'id': '76', 'type': 'if_statement', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '78', 'type': 'block', 'children': ['79', '122', '130', '137']}; {'id': '79', 'type': 'if_statement', 'children': ['80', '110']}; {'id': '80', 'type': '()', 'children': ['81']}; {'id': '81', 'type': 'boolean_operator', 'children': ['82', '101'], 'value': 'or'}; {'id': '82', 'type': 'boolean_operator', 'children': ['83', '92'], 'value': 'or'}; {'id': '83', 'type': 'comparison_operator', 'children': ['84', '87'], 'value': '!='}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'second'}; {'id': '87', 'type': 'attribute', 'children': ['88', '91']}; {'id': '88', 'type': 'subscript', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '90', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'second'}; {'id': '92', 'type': 'comparison_operator', 'children': ['93', '96'], 'value': '!='}; {'id': '93', 'type': 'attribute', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'minute'}; {'id': '96', 'type': 'attribute', 'children': ['97', '100']}; {'id': '97', 'type': 'subscript', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '99', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'minute'}; {'id': '101', 'type': 'comparison_operator', 'children': ['102', '105'], 'value': '!='}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'hour'}; {'id': '105', 'type': 'attribute', 'children': ['106', '109']}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '108', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'hour'}; {'id': '110', 'type': 'block', 'children': ['111']}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'call', 'children': ['113', '116']}; {'id': '113', 'type': 'attribute', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'collated'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '116', 'type': 'argument_list', 'children': ['117']}; {'id': '117', 'type': 'call', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'blank'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '121', 'type': 'argument_list', 'children': []}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'assignment', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '125', 'type': 'binary_operator', 'children': ['126', '129'], 'value': '-'}; {'id': '126', 'type': 'subscript', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '128', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'call', 'children': ['132', '135']}; {'id': '132', 'type': 'attribute', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '135', 'type': 'argument_list', 'children': ['136']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '137', 'type': 'if_statement', 'children': ['138', '141', '146']}; {'id': '138', 'type': 'comparison_operator', 'children': ['139', '140'], 'value': '>'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'UNBROKEN_DELTA'}; {'id': '141', 'type': 'block', 'children': ['142']}; {'id': '142', 'type': 'expression_statement', 'children': ['143']}; {'id': '143', 'type': 'assignment', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '145', 'type': 'None', 'children': []}; {'id': '146', 'type': 'else_clause', 'children': ['147']}; {'id': '147', 'type': 'block', 'children': ['148', '163']}; {'id': '148', 'type': 'if_statement', 'children': ['149', '151']}; {'id': '149', 'type': 'not_operator', 'children': ['150']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '151', 'type': 'block', 'children': ['152', '156']}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'assignment', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '155', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'call', 'children': ['165', '168']}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '168', 'type': 'argument_list', 'children': ['169']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'assignment', 'children': ['172', '178']}; {'id': '172', 'type': 'subscript', 'children': ['173', '177']}; {'id': '173', 'type': 'subscript', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'collated'}; {'id': '175', 'type': 'unary_operator', 'children': ['176'], 'value': '-'}; {'id': '176', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '177', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '178', 'type': 'subscript', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '180', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '181', 'type': 'expression_statement', 'children': ['182']}; {'id': '182', 'type': 'augmented_assignment', 'children': ['183', '193'], 'value': '+='}; {'id': '183', 'type': 'subscript', 'children': ['184', '190']}; {'id': '184', 'type': 'subscript', 'children': ['185', '189']}; {'id': '185', 'type': 'subscript', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'collated'}; {'id': '187', 'type': 'unary_operator', 'children': ['188'], 'value': '-'}; {'id': '188', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '189', 'type': 'string', 'children': [], 'value': '"keys"'}; {'id': '190', 'type': 'subscript', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '192', 'type': 'string', 'children': [], 'value': '"realkey"'}; {'id': '193', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'assignment', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'prev_dt'}; {'id': '197', 'type': 'subscript', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '199', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '200', 'type': 'expression_statement', 'children': ['201']}; {'id': '201', 'type': 'assignment', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'longest_session'}; {'id': '203', 'type': 'call', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '205', 'type': 'argument_list', 'children': ['206', '215']}; {'id': '206', 'type': 'binary_operator', 'children': ['207', '208'], 'value': '+'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '208', 'type': 'list', 'children': ['209'], 'value': '[[datetime.timedelta()]]'}; {'id': '209', 'type': 'list', 'children': ['210'], 'value': '[datetime.timedelta()]'}; {'id': '210', 'type': 'call', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '214', 'type': 'argument_list', 'children': []}; {'id': '215', 'type': 'keyword_argument', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '217', 'type': 'lambda', 'children': ['218', '220']}; {'id': '218', 'type': 'lambda_parameters', 'children': ['219']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '220', 'type': 'call', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '222', 'type': 'argument_list', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '224', 'type': 'call', 'children': ['225', '228']}; {'id': '225', 'type': 'attribute', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '228', 'type': 'argument_list', 'children': []}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'assignment', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'stats'}; {'id': '232', 'type': 'conditional_expression', 'children': ['233', '250', '253'], 'value': 'if'}; {'id': '233', 'type': 'list', 'children': ['234'], 'value': '[\r\n ("Average interval between combos",\r\n sum(deltas, datetime.timedelta()) / len(deltas)),\r\n ]'}; {'id': '234', 'type': 'tuple', 'children': ['235', '236']}; {'id': '235', 'type': 'string', 'children': [], 'value': '"Average interval between combos"'}; {'id': '236', 'type': 'binary_operator', 'children': ['237', '246'], 'value': '/'}; {'id': '237', 'type': 'call', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '239', 'type': 'argument_list', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '241', 'type': 'call', 'children': ['242', '245']}; {'id': '242', 'type': 'attribute', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '245', 'type': 'argument_list', 'children': []}; {'id': '246', 'type': 'call', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '248', 'type': 'argument_list', 'children': ['249']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '250', 'type': 'comparison_operator', 'children': ['251', '252'], 'value': '=='}; {'id': '251', 'type': 'string', 'children': [], 'value': '"combos"'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'table'}; {'id': '253', 'type': 'list', 'children': ['254', '281', '297', '307', '326', '354', '365', '373'], 'value': '[\r\n ("Keys per hour",\r\n int(3600 * len(events) / timedelta_seconds(events[-1]["dt"] - events[0]["dt"]))),\r\n ("Average interval between keys",\r\n sum(deltas, datetime.timedelta()) / len(deltas)),\r\n ("Typing sessions (key interval < %ss)" % UNBROKEN_DELTA.seconds,\r\n len(sessions)),\r\n ("Average keys in session",\r\n sum(len(x) + 1 for x in sessions) / len(sessions)),\r\n ("Average session duration", sum((sum(x, datetime.timedelta())\r\n for x in sessions), datetime.timedelta()) / len(sessions)),\r\n ("Longest session duration",\r\n sum(longest_session, datetime.timedelta())),\r\n ("Keys in longest session",\r\n len(longest_session) + 1),\r\n ("Most keys in session",\r\n max(len(x) + 1 for x in sessions)),\r\n ]'}; {'id': '254', 'type': 'tuple', 'children': ['255', '256']}; {'id': '255', 'type': 'string', 'children': [], 'value': '"Keys per hour"'}; {'id': '256', 'type': 'call', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '258', 'type': 'argument_list', 'children': ['259']}; {'id': '259', 'type': 'binary_operator', 'children': ['260', '266'], 'value': '/'}; {'id': '260', 'type': 'binary_operator', 'children': ['261', '262'], 'value': '*'}; {'id': '261', 'type': 'integer', 'children': [], 'value': '3600'}; {'id': '262', 'type': 'call', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '264', 'type': 'argument_list', 'children': ['265']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '266', 'type': 'call', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'timedelta_seconds'}; {'id': '268', 'type': 'argument_list', 'children': ['269']}; {'id': '269', 'type': 'binary_operator', 'children': ['270', '276'], 'value': '-'}; {'id': '270', 'type': 'subscript', 'children': ['271', '275']}; {'id': '271', 'type': 'subscript', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '273', 'type': 'unary_operator', 'children': ['274'], 'value': '-'}; {'id': '274', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '275', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '276', 'type': 'subscript', 'children': ['277', '280']}; {'id': '277', 'type': 'subscript', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '279', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '280', 'type': 'string', 'children': [], 'value': '"dt"'}; {'id': '281', 'type': 'tuple', 'children': ['282', '283']}; {'id': '282', 'type': 'string', 'children': [], 'value': '"Average interval between keys"'}; {'id': '283', 'type': 'binary_operator', 'children': ['284', '293'], 'value': '/'}; {'id': '284', 'type': 'call', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '286', 'type': 'argument_list', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '288', 'type': 'call', 'children': ['289', '292']}; {'id': '289', 'type': 'attribute', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '292', 'type': 'argument_list', 'children': []}; {'id': '293', 'type': 'call', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '295', 'type': 'argument_list', 'children': ['296']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'deltas'}; {'id': '297', 'type': 'tuple', 'children': ['298', '303']}; {'id': '298', 'type': 'binary_operator', 'children': ['299', '300'], 'value': '%'}; {'id': '299', 'type': 'string', 'children': [], 'value': '"Typing sessions (key interval < %ss)"'}; {'id': '300', 'type': 'attribute', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'UNBROKEN_DELTA'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'seconds'}; {'id': '303', 'type': 'call', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '305', 'type': 'argument_list', 'children': ['306']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '307', 'type': 'tuple', 'children': ['308', '309']}; {'id': '308', 'type': 'string', 'children': [], 'value': '"Average keys in session"'}; {'id': '309', 'type': 'binary_operator', 'children': ['310', '322'], 'value': '/'}; {'id': '310', 'type': 'call', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '312', 'type': 'generator_expression', 'children': ['313', '319']}; {'id': '313', 'type': 'binary_operator', 'children': ['314', '318'], 'value': '+'}; {'id': '314', 'type': 'call', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '316', 'type': 'argument_list', 'children': ['317']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '318', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '319', 'type': 'for_in_clause', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '322', 'type': 'call', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '324', 'type': 'argument_list', 'children': ['325']}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '326', 'type': 'tuple', 'children': ['327', '328']}; {'id': '327', 'type': 'string', 'children': [], 'value': '"Average session duration"'}; {'id': '328', 'type': 'binary_operator', 'children': ['329', '350'], 'value': '/'}; {'id': '329', 'type': 'call', 'children': ['330', '331']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '331', 'type': 'argument_list', 'children': ['332', '345']}; {'id': '332', 'type': 'generator_expression', 'children': ['333', '342']}; {'id': '333', 'type': 'call', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '335', 'type': 'argument_list', 'children': ['336', '337']}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '337', 'type': 'call', 'children': ['338', '341']}; {'id': '338', 'type': 'attribute', 'children': ['339', '340']}; {'id': '339', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '341', 'type': 'argument_list', 'children': []}; {'id': '342', 'type': 'for_in_clause', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '345', 'type': 'call', 'children': ['346', '349']}; {'id': '346', 'type': 'attribute', 'children': ['347', '348']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '349', 'type': 'argument_list', 'children': []}; {'id': '350', 'type': 'call', 'children': ['351', '352']}; {'id': '351', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '352', 'type': 'argument_list', 'children': ['353']}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '354', 'type': 'tuple', 'children': ['355', '356']}; {'id': '355', 'type': 'string', 'children': [], 'value': '"Longest session duration"'}; {'id': '356', 'type': 'call', 'children': ['357', '358']}; {'id': '357', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '358', 'type': 'argument_list', 'children': ['359', '360']}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'longest_session'}; {'id': '360', 'type': 'call', 'children': ['361', '364']}; {'id': '361', 'type': 'attribute', 'children': ['362', '363']}; {'id': '362', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '364', 'type': 'argument_list', 'children': []}; {'id': '365', 'type': 'tuple', 'children': ['366', '367']}; {'id': '366', 'type': 'string', 'children': [], 'value': '"Keys in longest session"'}; {'id': '367', 'type': 'binary_operator', 'children': ['368', '372'], 'value': '+'}; {'id': '368', 'type': 'call', 'children': ['369', '370']}; {'id': '369', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '370', 'type': 'argument_list', 'children': ['371']}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'longest_session'}; {'id': '372', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '373', 'type': 'tuple', 'children': ['374', '375']}; {'id': '374', 'type': 'string', 'children': [], 'value': '"Most keys in session"'}; {'id': '375', 'type': 'call', 'children': ['376', '377']}; {'id': '376', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '377', 'type': 'generator_expression', 'children': ['378', '384']}; {'id': '378', 'type': 'binary_operator', 'children': ['379', '383'], 'value': '+'}; {'id': '379', 'type': 'call', 'children': ['380', '381']}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '381', 'type': 'argument_list', 'children': ['382']}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '383', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '384', 'type': 'for_in_clause', 'children': ['385', '386']}; {'id': '385', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '386', 'type': 'identifier', 'children': [], 'value': 'sessions'}; {'id': '387', 'type': 'return_statement', 'children': ['388']}; {'id': '388', 'type': 'expression_list', 'children': ['389', '390']}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'stats'}; {'id': '390', 'type': 'identifier', 'children': [], 'value': 'collated'}
Return statistics and collated events for keyboard events.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'process'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'versions'}; {'id': '6', 'type': 'block', 'children': ['7']}; {'id': '7', 'type': 'for_statement', 'children': ['8', '9', '17']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'tool_name'}; {'id': '9', 'type': 'call', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '11', 'type': 'argument_list', 'children': ['12']}; {'id': '12', 'type': 'call', 'children': ['13', '16']}; {'id': '13', 'type': 'attribute', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'versions'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '16', 'type': 'argument_list', 'children': []}; {'id': '17', 'type': 'block', 'children': ['18', '24']}; {'id': '18', 'type': 'expression_statement', 'children': ['19']}; {'id': '19', 'type': 'assignment', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '21', 'type': 'subscript', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'versions'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'tool_name'}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'call', 'children': ['26', '29']}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': '_log'}; {'id': '29', 'type': 'argument_list', 'children': ['30']}; {'id': '30', 'type': 'binary_operator', 'children': ['31', '32'], 'value': '%'}; {'id': '31', 'type': 'string', 'children': [], 'value': '"Using tool \'%s\', %s"'}; {'id': '32', 'type': 'tuple', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'tool_name'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'version'}
Logging version sorted ascending by tool name.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '4']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'main'}; {'id': '3', 'type': 'parameters', 'children': []}; {'id': '4', 'type': 'block', 'children': ['5', '24', '35', '56', '78', '105', '115', '250']}; {'id': '5', 'type': 'expression_statement', 'children': ['6']}; {'id': '6', 'type': 'assignment', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '8', 'type': 'call', 'children': ['9', '12']}; {'id': '9', 'type': 'attribute', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'argparse'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'ArgumentParser'}; {'id': '12', 'type': 'argument_list', 'children': ['13', '16', '19']}; {'id': '13', 'type': 'keyword_argument', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'prog'}; {'id': '15', 'type': 'string', 'children': [], 'value': "'ProTECT'"}; {'id': '16', 'type': 'keyword_argument', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '18', 'type': 'string', 'children': [], 'value': "'Prediction of T-Cell Epitopes for Cancer Therapy'"}; {'id': '19', 'type': 'keyword_argument', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'epilog'}; {'id': '21', 'type': 'concatenated_string', 'children': ['22', '23']}; {'id': '22', 'type': 'string', 'children': [], 'value': "'Contact Arjun Rao ([email protected]) if you encounter '"}; {'id': '23', 'type': 'string', 'children': [], 'value': "'any problems while running ProTECT'"}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'inputs'}; {'id': '27', 'type': 'call', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'add_mutually_exclusive_group'}; {'id': '31', 'type': 'argument_list', 'children': ['32']}; {'id': '32', 'type': 'keyword_argument', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'required'}; {'id': '34', 'type': 'True', 'children': []}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'call', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'inputs'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '40', 'type': 'argument_list', 'children': ['41', '42', '45', '50', '53']}; {'id': '41', 'type': 'string', 'children': [], 'value': "'--config_file'"}; {'id': '42', 'type': 'keyword_argument', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '44', 'type': 'string', 'children': [], 'value': "'config_file'"}; {'id': '45', 'type': 'keyword_argument', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '47', 'type': 'concatenated_string', 'children': ['48', '49']}; {'id': '48', 'type': 'string', 'children': [], 'value': "'Config file to be used in the '"}; {'id': '49', 'type': 'string', 'children': [], 'value': "'run.'"}; {'id': '50', 'type': 'keyword_argument', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '53', 'type': 'keyword_argument', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '55', 'type': 'None', 'children': []}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'call', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'inputs'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '61', 'type': 'argument_list', 'children': ['62', '63', '66', '72', '75']}; {'id': '62', 'type': 'string', 'children': [], 'value': "'--generate_config'"}; {'id': '63', 'type': 'keyword_argument', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '65', 'type': 'string', 'children': [], 'value': "'generate_config'"}; {'id': '66', 'type': 'keyword_argument', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '68', 'type': 'concatenated_string', 'children': ['69', '70', '71']}; {'id': '69', 'type': 'string', 'children': [], 'value': "'Generate a config file '"}; {'id': '70', 'type': 'string', 'children': [], 'value': "'in the current directory that is pre-filled with references and flags for '"}; {'id': '71', 'type': 'string', 'children': [], 'value': "'an hg19 run.'"}; {'id': '72', 'type': 'keyword_argument', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '74', 'type': 'string', 'children': [], 'value': "'store_true'"}; {'id': '75', 'type': 'keyword_argument', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '77', 'type': 'False', 'children': []}; {'id': '78', 'type': 'expression_statement', 'children': ['79']}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '83', 'type': 'argument_list', 'children': ['84', '85', '88', '96', '99', '102']}; {'id': '84', 'type': 'string', 'children': [], 'value': "'--max-cores-per-job'"}; {'id': '85', 'type': 'keyword_argument', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '87', 'type': 'string', 'children': [], 'value': "'max_cores'"}; {'id': '88', 'type': 'keyword_argument', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '90', 'type': 'concatenated_string', 'children': ['91', '92', '93', '94', '95']}; {'id': '91', 'type': 'string', 'children': [], 'value': "'Maximum cores to use per '"}; {'id': '92', 'type': 'string', 'children': [], 'value': "'job. Aligners and Haplotypers ask for cores dependent on the machine that '"}; {'id': '93', 'type': 'string', 'children': [], 'value': "'the launchpad gets assigned to -- In a heterogeneous cluster, this can '"}; {'id': '94', 'type': 'string', 'children': [], 'value': "'lead to problems. This value should be set to the number of cpus on the '"}; {'id': '95', 'type': 'string', 'children': [], 'value': "'smallest node in a cluster.'"}; {'id': '96', 'type': 'keyword_argument', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '99', 'type': 'keyword_argument', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'required'}; {'id': '101', 'type': 'False', 'children': []}; {'id': '102', 'type': 'keyword_argument', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '104', 'type': 'None', 'children': []}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '110']}; {'id': '107', 'type': 'pattern_list', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'others'}; {'id': '110', 'type': 'call', 'children': ['111', '114']}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'parse_known_args'}; {'id': '114', 'type': 'argument_list', 'children': []}; {'id': '115', 'type': 'if_statement', 'children': ['116', '119', '124']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'generate_config'}; {'id': '119', 'type': 'block', 'children': ['120']}; {'id': '120', 'type': 'expression_statement', 'children': ['121']}; {'id': '121', 'type': 'call', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'generate_config_file'}; {'id': '123', 'type': 'argument_list', 'children': []}; {'id': '124', 'type': 'else_clause', 'children': ['125']}; {'id': '125', 'type': 'block', 'children': ['126', '135', '143', '158', '225', '240']}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'call', 'children': ['128', '133']}; {'id': '128', 'type': 'attribute', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'Job'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'Runner'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'addToilOptions'}; {'id': '133', 'type': 'argument_list', 'children': ['134']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '135', 'type': 'expression_statement', 'children': ['136']}; {'id': '136', 'type': 'assignment', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '142', 'type': 'argument_list', 'children': []}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'config_file'}; {'id': '148', 'type': 'call', 'children': ['149', '154']}; {'id': '149', 'type': 'attribute', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'abspath'}; {'id': '154', 'type': 'argument_list', 'children': ['155']}; {'id': '155', 'type': 'attribute', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'config_file'}; {'id': '158', 'type': 'if_statement', 'children': ['159', '162']}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'maxCores'}; {'id': '162', 'type': 'block', 'children': ['163']}; {'id': '163', 'type': 'if_statement', 'children': ['164', '168', '180']}; {'id': '164', 'type': 'not_operator', 'children': ['165']}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '168', 'type': 'block', 'children': ['169']}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'assignment', 'children': ['171', '174']}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '174', 'type': 'call', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '176', 'type': 'argument_list', 'children': ['177']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'maxCores'}; {'id': '180', 'type': 'else_clause', 'children': ['181']}; {'id': '181', 'type': 'block', 'children': ['182']}; {'id': '182', 'type': 'if_statement', 'children': ['183', '193']}; {'id': '183', 'type': 'comparison_operator', 'children': ['184', '187'], 'value': '>'}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'maxCores'}; {'id': '193', 'type': 'block', 'children': ['194', '214']}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'call', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '197', 'type': 'argument_list', 'children': ['198', '209']}; {'id': '198', 'type': 'binary_operator', 'children': ['199', '202'], 'value': '%'}; {'id': '199', 'type': 'concatenated_string', 'children': ['200', '201']}; {'id': '200', 'type': 'string', 'children': [], 'value': '"The value provided to max-cores-per-job (%s) was greater than that "'}; {'id': '201', 'type': 'string', 'children': [], 'value': '"provided to maxCores (%s). Setting max-cores-per-job = maxCores."'}; {'id': '202', 'type': 'tuple', 'children': ['203', '206']}; {'id': '203', 'type': 'attribute', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '206', 'type': 'attribute', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'maxCores'}; {'id': '209', 'type': 'keyword_argument', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '214', 'type': 'expression_statement', 'children': ['215']}; {'id': '215', 'type': 'assignment', 'children': ['216', '219']}; {'id': '216', 'type': 'attribute', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '219', 'type': 'call', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '221', 'type': 'argument_list', 'children': ['222']}; {'id': '222', 'type': 'attribute', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'maxCores'}; {'id': '225', 'type': 'expression_statement', 'children': ['226']}; {'id': '226', 'type': 'assignment', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '228', 'type': 'call', 'children': ['229', '232']}; {'id': '229', 'type': 'attribute', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'Job'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'wrapJobFn'}; {'id': '232', 'type': 'argument_list', 'children': ['233', '234', '237']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'parse_config_file'}; {'id': '234', 'type': 'attribute', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'config_file'}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'max_cores'}; {'id': '240', 'type': 'expression_statement', 'children': ['241']}; {'id': '241', 'type': 'call', 'children': ['242', '247']}; {'id': '242', 'type': 'attribute', 'children': ['243', '246']}; {'id': '243', 'type': 'attribute', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'Job'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'Runner'}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'startToil'}; {'id': '247', 'type': 'argument_list', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '250', 'type': 'return_statement', 'children': ['251']}; {'id': '251', 'type': 'None', 'children': []}
This is the main function for ProTECT.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'create'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '6', 'type': 'block', 'children': ['7', '73', '80', '104', '119']}; {'id': '7', 'type': 'try_statement', 'children': ['8', '16', '40']}; {'id': '8', 'type': 'block', 'children': ['9']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '12', 'type': 'call', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'import_module'}; {'id': '14', 'type': 'argument_list', 'children': ['15']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '16', 'type': 'except_clause', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'ImportError'}; {'id': '18', 'type': 'block', 'children': ['19', '23', '35']}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '22', 'type': 'None', 'children': []}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '29']}; {'id': '25', 'type': 'pattern_list', 'children': ['26', '27', '28']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'mod_path'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': '_'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'cls_name'}; {'id': '29', 'type': 'call', 'children': ['30', '33']}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'rpartition'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '35', 'type': 'if_statement', 'children': ['36', '38']}; {'id': '36', 'type': 'not_operator', 'children': ['37']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'mod_path'}; {'id': '38', 'type': 'block', 'children': ['39']}; {'id': '39', 'type': 'raise_statement', 'children': []}; {'id': '40', 'type': 'else_clause', 'children': ['41']}; {'id': '41', 'type': 'block', 'children': ['42']}; {'id': '42', 'type': 'try_statement', 'children': ['43', '50', '59']}; {'id': '43', 'type': 'block', 'children': ['44']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '47', 'type': 'attribute', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'default_bot'}; {'id': '50', 'type': 'except_clause', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'AttributeError'}; {'id': '52', 'type': 'block', 'children': ['53']}; {'id': '53', 'type': 'return_statement', 'children': ['54']}; {'id': '54', 'type': 'call', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '56', 'type': 'argument_list', 'children': ['57', '58']}; {'id': '57', 'type': 'string', 'children': [], 'value': "f'{entry}.Bot'"}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '59', 'type': 'else_clause', 'children': ['60']}; {'id': '60', 'type': 'block', 'children': ['61']}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '67']}; {'id': '63', 'type': 'pattern_list', 'children': ['64', '65', '66']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'mod_path'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': '_'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'cls_name'}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'rpartition'}; {'id': '71', 'type': 'argument_list', 'children': ['72']}; {'id': '72', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'assignment', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'mod'}; {'id': '76', 'type': 'call', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'import_module'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'mod_path'}; {'id': '80', 'type': 'try_statement', 'children': ['81', '90']}; {'id': '81', 'type': 'block', 'children': ['82']}; {'id': '82', 'type': 'expression_statement', 'children': ['83']}; {'id': '83', 'type': 'assignment', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'bot_cls'}; {'id': '85', 'type': 'call', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '87', 'type': 'argument_list', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'mod'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'cls_name'}; {'id': '90', 'type': 'except_clause', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'AttributeError'}; {'id': '92', 'type': 'block', 'children': ['93', '103']}; {'id': '93', 'type': 'if_statement', 'children': ['94', '97']}; {'id': '94', 'type': 'comparison_operator', 'children': ['95', '96'], 'value': 'is'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'module'}; {'id': '96', 'type': 'None', 'children': []}; {'id': '97', 'type': 'block', 'children': ['98']}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'call', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'import_module'}; {'id': '101', 'type': 'argument_list', 'children': ['102']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '103', 'type': 'raise_statement', 'children': []}; {'id': '104', 'type': 'if_statement', 'children': ['105', '111']}; {'id': '105', 'type': 'not_operator', 'children': ['106']}; {'id': '106', 'type': 'call', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'issubclass'}; {'id': '108', 'type': 'argument_list', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'bot_cls'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'Bot'}; {'id': '111', 'type': 'block', 'children': ['112']}; {'id': '112', 'type': 'raise_statement', 'children': ['113']}; {'id': '113', 'type': 'call', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'ImproperlyConfigured'}; {'id': '115', 'type': 'argument_list', 'children': ['116']}; {'id': '116', 'type': 'binary_operator', 'children': ['117', '118'], 'value': '%'}; {'id': '117', 'type': 'string', 'children': [], 'value': '"\'%s\' isn\'t a subclass of Bot."'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '119', 'type': 'return_statement', 'children': ['120']}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '122', 'type': 'argument_list', 'children': ['123', '124', '125']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'entry'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'mod'}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'bot_cls'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'label'}
Factory that creates an bot config from an entry in INSTALLED_APPS.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'parse_inventory'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'default_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '6', 'type': 'None', 'children': []}; {'id': '7', 'type': 'block', 'children': ['8', '27', '34', '38', '42', '100', '113', '132', '145', '164', '177', '191', '204', '218', '231', '249']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '11', 'type': 'dictionary', 'children': ['12', '15', '18', '21', '24']}; {'id': '12', 'type': 'pair', 'children': ['13', '14']}; {'id': '13', 'type': 'string', 'children': [], 'value': '"name"'}; {'id': '14', 'type': 'string', 'children': [], 'value': '""'}; {'id': '15', 'type': 'pair', 'children': ['16', '17']}; {'id': '16', 'type': 'string', 'children': [], 'value': '"description"'}; {'id': '17', 'type': 'string', 'children': [], 'value': '""'}; {'id': '18', 'type': 'pair', 'children': ['19', '20']}; {'id': '19', 'type': 'string', 'children': [], 'value': '"pid"'}; {'id': '20', 'type': 'string', 'children': [], 'value': '""'}; {'id': '21', 'type': 'pair', 'children': ['22', '23']}; {'id': '22', 'type': 'string', 'children': [], 'value': '"vid"'}; {'id': '23', 'type': 'string', 'children': [], 'value': '""'}; {'id': '24', 'type': 'pair', 'children': ['25', '26']}; {'id': '25', 'type': 'string', 'children': [], 'value': '"sn"'}; {'id': '26', 'type': 'string', 'children': [], 'value': '""'}; {'id': '27', 'type': 'if_statement', 'children': ['28', '31']}; {'id': '28', 'type': 'comparison_operator', 'children': ['29', '30'], 'value': 'is'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '30', 'type': 'None', 'children': []}; {'id': '31', 'type': 'block', 'children': ['32']}; {'id': '32', 'type': 'return_statement', 'children': ['33']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '34', 'type': 'expression_statement', 'children': ['35']}; {'id': '35', 'type': 'assignment', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'capture_next'}; {'id': '37', 'type': 'False', 'children': []}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'chassis_udi_text'}; {'id': '41', 'type': 'None', 'children': []}; {'id': '42', 'type': 'for_statement', 'children': ['43', '44', '50']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '44', 'type': 'call', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '50', 'type': 'block', 'children': ['51', '59', '88']}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'lc_line'}; {'id': '54', 'type': 'call', 'children': ['55', '58']}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '58', 'type': 'argument_list', 'children': []}; {'id': '59', 'type': 'if_statement', 'children': ['60', '78']}; {'id': '60', 'type': 'boolean_operator', 'children': ['61', '77'], 'value': 'and'}; {'id': '61', 'type': 'boolean_operator', 'children': ['62', '74'], 'value': 'and'}; {'id': '62', 'type': '()', 'children': ['63']}; {'id': '63', 'type': 'boolean_operator', 'children': ['64', '71'], 'value': 'or'}; {'id': '64', 'type': 'boolean_operator', 'children': ['65', '68'], 'value': 'or'}; {'id': '65', 'type': 'comparison_operator', 'children': ['66', '67'], 'value': 'in'}; {'id': '66', 'type': 'string', 'children': [], 'value': "'chassis'"}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'lc_line'}; {'id': '68', 'type': 'comparison_operator', 'children': ['69', '70'], 'value': 'in'}; {'id': '69', 'type': 'string', 'children': [], 'value': "'switch system'"}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'lc_line'}; {'id': '71', 'type': 'comparison_operator', 'children': ['72', '73'], 'value': 'in'}; {'id': '72', 'type': 'string', 'children': [], 'value': "'rack'"}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'lc_line'}; {'id': '74', 'type': 'comparison_operator', 'children': ['75', '76'], 'value': 'in'}; {'id': '75', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'lc_line'}; {'id': '77', 'type': 'string', 'children': [], 'value': "'descr'"}; {'id': '78', 'type': 'block', 'children': ['79', '83', '87']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'capture_next'}; {'id': '82', 'type': 'True', 'children': []}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'chassis_udi_text'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '87', 'type': 'continue_statement', 'children': []}; {'id': '88', 'type': 'if_statement', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'capture_next'}; {'id': '90', 'type': 'block', 'children': ['91', '99']}; {'id': '91', 'type': 'expression_statement', 'children': ['92']}; {'id': '92', 'type': 'assignment', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '94', 'type': 'binary_operator', 'children': ['95', '98'], 'value': '+'}; {'id': '95', 'type': 'binary_operator', 'children': ['96', '97'], 'value': '+'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'chassis_udi_text'}; {'id': '97', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '99', 'type': 'break_statement', 'children': []}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'assignment', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '103', 'type': 'call', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109', '110']}; {'id': '108', 'type': 'string', 'children': [], 'value': 'r"(?i)NAME: (?P<name>.*?),? (?i)DESCR"'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'MULTILINE'}; {'id': '113', 'type': 'if_statement', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '115', 'type': 'block', 'children': ['116']}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'assignment', 'children': ['118', '121']}; {'id': '118', 'type': 'subscript', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '120', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '121', 'type': 'call', 'children': ['122', '130']}; {'id': '122', 'type': 'attribute', 'children': ['123', '129']}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '127', 'type': 'argument_list', 'children': ['128']}; {'id': '128', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '130', 'type': 'argument_list', 'children': ['131']}; {'id': '131', 'type': 'string', 'children': [], 'value': '\'" ,\''}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'assignment', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '139', 'type': 'argument_list', 'children': ['140', '141', '142']}; {'id': '140', 'type': 'string', 'children': [], 'value': 'r"(?i)DESCR: (?P<description>.*)"'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '142', 'type': 'attribute', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'MULTILINE'}; {'id': '145', 'type': 'if_statement', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '147', 'type': 'block', 'children': ['148']}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '153']}; {'id': '150', 'type': 'subscript', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '152', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '153', 'type': 'call', 'children': ['154', '162']}; {'id': '154', 'type': 'attribute', 'children': ['155', '161']}; {'id': '155', 'type': 'call', 'children': ['156', '159']}; {'id': '156', 'type': 'attribute', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '159', 'type': 'argument_list', 'children': ['160']}; {'id': '160', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '162', 'type': 'argument_list', 'children': ['163']}; {'id': '163', 'type': 'string', 'children': [], 'value': '\'" \''}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '167', 'type': 'call', 'children': ['168', '171']}; {'id': '168', 'type': 'attribute', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '171', 'type': 'argument_list', 'children': ['172', '173', '174']}; {'id': '172', 'type': 'string', 'children': [], 'value': 'r"(?i)PID: (?P<pid>.*?),? "'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '174', 'type': 'attribute', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'MULTILINE'}; {'id': '177', 'type': 'if_statement', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '179', 'type': 'block', 'children': ['180']}; {'id': '180', 'type': 'expression_statement', 'children': ['181']}; {'id': '181', 'type': 'assignment', 'children': ['182', '185']}; {'id': '182', 'type': 'subscript', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '184', 'type': 'string', 'children': [], 'value': "'pid'"}; {'id': '185', 'type': 'call', 'children': ['186', '189']}; {'id': '186', 'type': 'attribute', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'string', 'children': [], 'value': "'pid'"}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '194', 'type': 'call', 'children': ['195', '198']}; {'id': '195', 'type': 'attribute', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '198', 'type': 'argument_list', 'children': ['199', '200', '201']}; {'id': '199', 'type': 'string', 'children': [], 'value': 'r"(?i)VID: (?P<vid>.*?),? "'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '201', 'type': 'attribute', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'MULTILINE'}; {'id': '204', 'type': 'if_statement', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '206', 'type': 'block', 'children': ['207']}; {'id': '207', 'type': 'expression_statement', 'children': ['208']}; {'id': '208', 'type': 'assignment', 'children': ['209', '212']}; {'id': '209', 'type': 'subscript', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '211', 'type': 'string', 'children': [], 'value': "'vid'"}; {'id': '212', 'type': 'call', 'children': ['213', '216']}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '216', 'type': 'argument_list', 'children': ['217']}; {'id': '217', 'type': 'string', 'children': [], 'value': "'vid'"}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'assignment', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '221', 'type': 'call', 'children': ['222', '225']}; {'id': '222', 'type': 'attribute', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '225', 'type': 'argument_list', 'children': ['226', '227', '228']}; {'id': '226', 'type': 'string', 'children': [], 'value': 'r"(?i)SN: (?P<sn>.*)"'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'inventory_output'}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'MULTILINE'}; {'id': '231', 'type': 'if_statement', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '233', 'type': 'block', 'children': ['234']}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'assignment', 'children': ['236', '239']}; {'id': '236', 'type': 'subscript', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'udi'}; {'id': '238', 'type': 'string', 'children': [], 'value': "'sn'"}; {'id': '239', 'type': 'call', 'children': ['240', '248']}; {'id': '240', 'type': 'attribute', 'children': ['241', '247']}; {'id': '241', 'type': 'call', 'children': ['242', '245']}; {'id': '242', 'type': 'attribute', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '245', 'type': 'argument_list', 'children': ['246']}; {'id': '246', 'type': 'string', 'children': [], 'value': "'sn'"}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '248', 'type': 'argument_list', 'children': []}; {'id': '249', 'type': 'return_statement', 'children': ['250']}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'udi'}
Parse the inventory text and return udi dict.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_get_view_details'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'urlpatterns'}; {'id': '6', 'type': 'default_parameter', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '8', 'type': 'string', 'children': [], 'value': "''"}; {'id': '9', 'type': 'block', 'children': ['10']}; {'id': '10', 'type': 'for_statement', 'children': ['11', '12', '13']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'urlpatterns'}; {'id': '13', 'type': 'block', 'children': ['14']}; {'id': '14', 'type': 'if_statement', 'children': ['15', '22', '218']}; {'id': '15', 'type': 'call', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '17', 'type': 'argument_list', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '19', 'type': 'tuple', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'URLPattern'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'RegexURLPattern'}; {'id': '22', 'type': 'block', 'children': ['23']}; {'id': '23', 'type': 'try_statement', 'children': ['24', '214']}; {'id': '24', 'type': 'block', 'children': ['25', '32', '40', '44', '48', '52', '79', '90', '109']}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'd'}; {'id': '28', 'type': 'call', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'describe_pattern'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'assignment', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'docstr'}; {'id': '35', 'type': 'attribute', 'children': ['36', '39']}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'callback'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': '__doc__'}; {'id': '40', 'type': 'expression_statement', 'children': ['41']}; {'id': '41', 'type': 'assignment', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '43', 'type': 'None', 'children': []}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'expected_json_response'}; {'id': '47', 'type': 'string', 'children': [], 'value': "''"}; {'id': '48', 'type': 'expression_statement', 'children': ['49']}; {'id': '49', 'type': 'assignment', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'expected_url'}; {'id': '51', 'type': 'string', 'children': [], 'value': "''"}; {'id': '52', 'type': 'if_statement', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'docstr'}; {'id': '54', 'type': 'block', 'children': ['55', '70']}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '58', 'type': 'call', 'children': ['59', '62']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'findall'}; {'id': '62', 'type': 'argument_list', 'children': ['63', '64', '65']}; {'id': '63', 'type': 'string', 'children': [], 'value': "r'URL: (.*)'"}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'docstr'}; {'id': '65', 'type': 'keyword_argument', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'DOTALL'}; {'id': '70', 'type': 'if_statement', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '72', 'type': 'block', 'children': ['73']}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'assignment', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'expected_url'}; {'id': '76', 'type': 'subscript', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'u'}; {'id': '78', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '79', 'type': 'if_statement', 'children': ['80', '88']}; {'id': '80', 'type': 'comparison_operator', 'children': ['81', '82'], 'value': 'not'}; {'id': '81', 'type': 'string', 'children': [], 'value': "'view_class'"}; {'id': '82', 'type': 'call', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'dir'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'attribute', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'callback'}; {'id': '88', 'type': 'block', 'children': ['89']}; {'id': '89', 'type': 'continue_statement', 'children': []}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'assignment', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'possible_methods'}; {'id': '93', 'type': 'list_comprehension', 'children': ['94', '95', '105']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '95', 'type': 'for_in_clause', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '97', 'type': 'call', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'dir'}; {'id': '99', 'type': 'argument_list', 'children': ['100']}; {'id': '100', 'type': 'attribute', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'callback'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'view_class'}; {'id': '105', 'type': 'if_clause', 'children': ['106']}; {'id': '106', 'type': 'comparison_operator', 'children': ['107', '108'], 'value': 'in'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'METHODS'}; {'id': '109', 'type': 'for_statement', 'children': ['110', '111', '112']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'possible_methods'}; {'id': '112', 'type': 'block', 'children': ['113', '127']}; {'id': '113', 'type': 'expression_statement', 'children': ['114']}; {'id': '114', 'type': 'assignment', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'view_method_docstr'}; {'id': '116', 'type': 'attribute', 'children': ['117', '126']}; {'id': '117', 'type': 'call', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '119', 'type': 'argument_list', 'children': ['120', '125']}; {'id': '120', 'type': 'attribute', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'callback'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'view_class'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': '__doc__'}; {'id': '127', 'type': 'if_statement', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'view_method_docstr'}; {'id': '129', 'type': 'block', 'children': ['130', '154', '169']}; {'id': '130', 'type': 'if_statement', 'children': ['131', '137']}; {'id': '131', 'type': 'comparison_operator', 'children': ['132', '133'], 'value': 'in'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '133', 'type': 'list', 'children': ['134', '135', '136'], 'value': "['put', 'patch', 'delete']"}; {'id': '134', 'type': 'string', 'children': [], 'value': "'put'"}; {'id': '135', 'type': 'string', 'children': [], 'value': "'patch'"}; {'id': '136', 'type': 'string', 'children': [], 'value': "'delete'"}; {'id': '137', 'type': 'block', 'children': ['138', '153']}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'call', 'children': ['140', '145']}; {'id': '140', 'type': 'attribute', 'children': ['141', '144']}; {'id': '141', 'type': 'attribute', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'url_details'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '145', 'type': 'argument_list', 'children': ['146']}; {'id': '146', 'type': 'dictionary', 'children': ['147', '150']}; {'id': '147', 'type': 'pair', 'children': ['148', '149']}; {'id': '148', 'type': 'string', 'children': [], 'value': "'url'"}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'expected_url'}; {'id': '150', 'type': 'pair', 'children': ['151', '152']}; {'id': '151', 'type': 'string', 'children': [], 'value': "'method'"}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '153', 'type': 'continue_statement', 'children': []}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'assignment', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'findall'}; {'id': '161', 'type': 'argument_list', 'children': ['162', '163', '164']}; {'id': '162', 'type': 'string', 'children': [], 'value': "r'```(.*)```'"}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'view_method_docstr'}; {'id': '164', 'type': 'keyword_argument', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'DOTALL'}; {'id': '169', 'type': 'if_statement', 'children': ['170', '173']}; {'id': '170', 'type': 'comparison_operator', 'children': ['171', '172'], 'value': 'is'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '172', 'type': 'None', 'children': []}; {'id': '173', 'type': 'block', 'children': ['174']}; {'id': '174', 'type': 'for_statement', 'children': ['175', '176', '177']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '177', 'type': 'block', 'children': ['178', '186']}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'assignment', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'expected_json_response'}; {'id': '181', 'type': 'call', 'children': ['182', '185']}; {'id': '182', 'type': 'attribute', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '185', 'type': 'argument_list', 'children': []}; {'id': '186', 'type': 'if_statement', 'children': ['187', '194']}; {'id': '187', 'type': 'boolean_operator', 'children': ['188', '193'], 'value': 'and'}; {'id': '188', 'type': 'boolean_operator', 'children': ['189', '192'], 'value': 'and'}; {'id': '189', 'type': 'comparison_operator', 'children': ['190', '191'], 'value': 'is'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '191', 'type': 'None', 'children': []}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'expected_json_response'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'expected_url'}; {'id': '194', 'type': 'block', 'children': ['195', '213']}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'call', 'children': ['197', '202']}; {'id': '197', 'type': 'attribute', 'children': ['198', '201']}; {'id': '198', 'type': 'attribute', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'url_details'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '202', 'type': 'argument_list', 'children': ['203']}; {'id': '203', 'type': 'dictionary', 'children': ['204', '207', '210']}; {'id': '204', 'type': 'pair', 'children': ['205', '206']}; {'id': '205', 'type': 'string', 'children': [], 'value': "'url'"}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'expected_url'}; {'id': '207', 'type': 'pair', 'children': ['208', '209']}; {'id': '208', 'type': 'string', 'children': [], 'value': "'method'"}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '210', 'type': 'pair', 'children': ['211', '212']}; {'id': '211', 'type': 'string', 'children': [], 'value': "'response'"}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'expected_json_response'}; {'id': '213', 'type': 'continue_statement', 'children': []}; {'id': '214', 'type': 'except_clause', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'ViewDoesNotExist'}; {'id': '216', 'type': 'block', 'children': ['217']}; {'id': '217', 'type': 'pass_statement', 'children': []}; {'id': '218', 'type': 'elif_clause', 'children': ['219', '226']}; {'id': '219', 'type': 'call', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '221', 'type': 'argument_list', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '223', 'type': 'tuple', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'URLResolver'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'RegexURLResolver'}; {'id': '226', 'type': 'block', 'children': ['227', '239', '246', '252']}; {'id': '227', 'type': 'try_statement', 'children': ['228', '235']}; {'id': '228', 'type': 'block', 'children': ['229']}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'assignment', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'patterns'}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'url_patterns'}; {'id': '235', 'type': 'except_clause', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'ImportError'}; {'id': '237', 'type': 'block', 'children': ['238']}; {'id': '238', 'type': 'continue_statement', 'children': []}; {'id': '239', 'type': 'expression_statement', 'children': ['240']}; {'id': '240', 'type': 'assignment', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'd'}; {'id': '242', 'type': 'call', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'describe_pattern'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'pattern'}; {'id': '246', 'type': 'expression_statement', 'children': ['247']}; {'id': '247', 'type': 'assignment', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'current_full_url'}; {'id': '249', 'type': 'binary_operator', 'children': ['250', '251'], 'value': '+'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'd'}; {'id': '252', 'type': 'expression_statement', 'children': ['253']}; {'id': '253', 'type': 'call', 'children': ['254', '257']}; {'id': '254', 'type': 'attribute', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': '_get_view_details'}; {'id': '257', 'type': 'argument_list', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'patterns'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'current_full_url'}
Recursive function to extract all url details
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'get_map'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '19', '31', '43', '62', '72', '76', '80', '84', '88', '166', '205', '213', '221', '254', '264', '268', '283', '292', '296', '320', '344', '389']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '12']}; {'id': '7', 'type': 'subscript', 'children': ['8', '11']}; {'id': '8', 'type': 'attribute', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '11', 'type': 'string', 'children': [], 'value': "'map'"}; {'id': '12', 'type': 'block', 'children': ['13']}; {'id': '13', 'type': 'return_statement', 'children': ['14']}; {'id': '14', 'type': 'subscript', 'children': ['15', '18']}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '18', 'type': 'string', 'children': [], 'value': "'map'"}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '22', 'type': 'attribute', 'children': ['23', '30']}; {'id': '23', 'type': 'attribute', 'children': ['24', '29']}; {'id': '24', 'type': 'attribute', 'children': ['25', '28']}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': '_header'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'scenario'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'game_settings'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'instructions'}; {'id': '34', 'type': 'attribute', 'children': ['35', '42']}; {'id': '35', 'type': 'attribute', 'children': ['36', '41']}; {'id': '36', 'type': 'attribute', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': '_header'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'scenario'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'messages'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'instructions'}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'assignment', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '46', 'type': 'call', 'children': ['47', '54']}; {'id': '47', 'type': 'attribute', 'children': ['48', '53']}; {'id': '48', 'type': 'attribute', 'children': ['49', '52']}; {'id': '49', 'type': 'attribute', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'mgz'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'MAP_SIZES'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '54', 'type': 'argument_list', 'children': ['55']}; {'id': '55', 'type': 'attribute', 'children': ['56', '61']}; {'id': '56', 'type': 'attribute', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': '_header'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'map_info'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'size_x'}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'dimension'}; {'id': '65', 'type': 'attribute', 'children': ['66', '71']}; {'id': '66', 'type': 'attribute', 'children': ['67', '70']}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': '_header'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'map_info'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'size_x'}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'custom'}; {'id': '75', 'type': 'True', 'children': []}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '79', 'type': 'string', 'children': [], 'value': "'Unknown'"}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '83', 'type': 'None', 'children': []}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '87', 'type': 'string', 'children': [], 'value': "'unknown'"}; {'id': '88', 'type': 'for_statement', 'children': ['89', '90', '91']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'ENCODING_MARKERS'}; {'id': '91', 'type': 'block', 'children': ['92', '98', '104', '113']}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'marker'}; {'id': '95', 'type': 'subscript', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '97', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'assignment', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'test_encoding'}; {'id': '101', 'type': 'subscript', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '103', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '104', 'type': 'expression_statement', 'children': ['105']}; {'id': '105', 'type': 'assignment', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'e_m'}; {'id': '107', 'type': 'call', 'children': ['108', '111']}; {'id': '108', 'type': 'attribute', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'marker'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '111', 'type': 'argument_list', 'children': ['112']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'test_encoding'}; {'id': '113', 'type': 'for_statement', 'children': ['114', '115', '121']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '115', 'type': 'call', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'instructions'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'string', 'children': [], 'value': "b'\\n'"}; {'id': '121', 'type': 'block', 'children': ['122', '131']}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'assignment', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'pos'}; {'id': '125', 'type': 'call', 'children': ['126', '129']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '129', 'type': 'argument_list', 'children': ['130']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'e_m'}; {'id': '131', 'type': 'if_statement', 'children': ['132', '136']}; {'id': '132', 'type': 'comparison_operator', 'children': ['133', '134'], 'value': '>'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'pos'}; {'id': '134', 'type': 'unary_operator', 'children': ['135'], 'value': '-'}; {'id': '135', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '136', 'type': 'block', 'children': ['137', '141', '159', '165']}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'assignment', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'test_encoding'}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'assignment', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '144', 'type': 'call', 'children': ['145', '157']}; {'id': '145', 'type': 'attribute', 'children': ['146', '156']}; {'id': '146', 'type': 'subscript', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '148', 'type': 'slice', 'children': ['149', '155']}; {'id': '149', 'type': 'binary_operator', 'children': ['150', '151'], 'value': '+'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'pos'}; {'id': '151', 'type': 'call', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'e_m'}; {'id': '155', 'type': 'colon', 'children': []}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'decode'}; {'id': '157', 'type': 'argument_list', 'children': ['158']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '159', 'type': 'expression_statement', 'children': ['160']}; {'id': '160', 'type': 'assignment', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '162', 'type': 'subscript', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '164', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '165', 'type': 'break_statement', 'children': []}; {'id': '166', 'type': 'if_statement', 'children': ['167', '169']}; {'id': '167', 'type': 'not_operator', 'children': ['168']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '169', 'type': 'block', 'children': ['170', '174']}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'assignment', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '173', 'type': 'string', 'children': [], 'value': "'unknown'"}; {'id': '174', 'type': 'for_statement', 'children': ['175', '176', '177']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'LANGUAGE_MARKERS'}; {'id': '177', 'type': 'block', 'children': ['178']}; {'id': '178', 'type': 'if_statement', 'children': ['179', '197']}; {'id': '179', 'type': 'comparison_operator', 'children': ['180', '195'], 'value': '>'}; {'id': '180', 'type': 'call', 'children': ['181', '184']}; {'id': '181', 'type': 'attribute', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'instructions'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '191']}; {'id': '186', 'type': 'attribute', 'children': ['187', '190']}; {'id': '187', 'type': 'subscript', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '189', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '191', 'type': 'argument_list', 'children': ['192']}; {'id': '192', 'type': 'subscript', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '194', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '195', 'type': 'unary_operator', 'children': ['196'], 'value': '-'}; {'id': '196', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '197', 'type': 'block', 'children': ['198', '204']}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'assignment', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '201', 'type': 'subscript', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '203', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '204', 'type': 'break_statement', 'children': []}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'assignment', 'children': ['207', '212']}; {'id': '207', 'type': 'subscript', 'children': ['208', '211']}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '211', 'type': 'string', 'children': [], 'value': "'encoding'"}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '213', 'type': 'expression_statement', 'children': ['214']}; {'id': '214', 'type': 'assignment', 'children': ['215', '220']}; {'id': '215', 'type': 'subscript', 'children': ['216', '219']}; {'id': '216', 'type': 'attribute', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '219', 'type': 'string', 'children': [], 'value': "'language'"}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'language'}; {'id': '221', 'type': 'if_statement', 'children': ['222', '225']}; {'id': '222', 'type': 'comparison_operator', 'children': ['223', '224'], 'value': '!='}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '224', 'type': 'integer', 'children': [], 'value': '44'}; {'id': '225', 'type': 'block', 'children': ['226', '240', '250']}; {'id': '226', 'type': 'if_statement', 'children': ['227', '234']}; {'id': '227', 'type': 'comparison_operator', 'children': ['228', '229'], 'value': 'not'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '229', 'type': 'attribute', 'children': ['230', '233']}; {'id': '230', 'type': 'attribute', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'mgz'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'MAP_NAMES'}; {'id': '234', 'type': 'block', 'children': ['235']}; {'id': '235', 'type': 'raise_statement', 'children': ['236']}; {'id': '236', 'type': 'call', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '238', 'type': 'argument_list', 'children': ['239']}; {'id': '239', 'type': 'string', 'children': [], 'value': "'unspecified builtin map'"}; {'id': '240', 'type': 'expression_statement', 'children': ['241']}; {'id': '241', 'type': 'assignment', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '243', 'type': 'subscript', 'children': ['244', '249']}; {'id': '244', 'type': 'attribute', 'children': ['245', '248']}; {'id': '245', 'type': 'attribute', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'mgz'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'const'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'MAP_NAMES'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '250', 'type': 'expression_statement', 'children': ['251']}; {'id': '251', 'type': 'assignment', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'custom'}; {'id': '253', 'type': 'False', 'children': []}; {'id': '254', 'type': 'expression_statement', 'children': ['255']}; {'id': '255', 'type': 'assignment', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '257', 'type': 'call', 'children': ['258', '261']}; {'id': '258', 'type': 'attribute', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'search'}; {'id': '261', 'type': 'argument_list', 'children': ['262', '263']}; {'id': '262', 'type': 'string', 'children': [], 'value': "b'\\x00.*? (\\-?[0-9]+)\\x00.*?\\.rms'"}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'instructions'}; {'id': '264', 'type': 'expression_statement', 'children': ['265']}; {'id': '265', 'type': 'assignment', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'seed'}; {'id': '267', 'type': 'None', 'children': []}; {'id': '268', 'type': 'if_statement', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '270', 'type': 'block', 'children': ['271']}; {'id': '271', 'type': 'expression_statement', 'children': ['272']}; {'id': '272', 'type': 'assignment', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'seed'}; {'id': '274', 'type': 'call', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '276', 'type': 'argument_list', 'children': ['277']}; {'id': '277', 'type': 'call', 'children': ['278', '281']}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '281', 'type': 'argument_list', 'children': ['282']}; {'id': '282', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '283', 'type': 'expression_statement', 'children': ['284']}; {'id': '284', 'type': 'assignment', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'has_modes'}; {'id': '286', 'type': 'call', 'children': ['287', '290']}; {'id': '287', 'type': 'attribute', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '290', 'type': 'argument_list', 'children': ['291']}; {'id': '291', 'type': 'string', 'children': [], 'value': "': !'"}; {'id': '292', 'type': 'expression_statement', 'children': ['293']}; {'id': '293', 'type': 'assignment', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '295', 'type': 'string', 'children': [], 'value': "''"}; {'id': '296', 'type': 'if_statement', 'children': ['297', '301']}; {'id': '297', 'type': 'comparison_operator', 'children': ['298', '299'], 'value': '>'}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'has_modes'}; {'id': '299', 'type': 'unary_operator', 'children': ['300'], 'value': '-'}; {'id': '300', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '301', 'type': 'block', 'children': ['302', '312']}; {'id': '302', 'type': 'expression_statement', 'children': ['303']}; {'id': '303', 'type': 'assignment', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '305', 'type': 'subscript', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '307', 'type': 'slice', 'children': ['308', '311']}; {'id': '308', 'type': 'binary_operator', 'children': ['309', '310'], 'value': '+'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'has_modes'}; {'id': '310', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '311', 'type': 'colon', 'children': []}; {'id': '312', 'type': 'expression_statement', 'children': ['313']}; {'id': '313', 'type': 'assignment', 'children': ['314', '315']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '315', 'type': 'subscript', 'children': ['316', '317']}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '317', 'type': 'slice', 'children': ['318', '319']}; {'id': '318', 'type': 'colon', 'children': []}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'has_modes'}; {'id': '320', 'type': 'expression_statement', 'children': ['321']}; {'id': '321', 'type': 'assignment', 'children': ['322', '323']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'modes'}; {'id': '323', 'type': 'dictionary', 'children': ['324', '329', '334', '339']}; {'id': '324', 'type': 'pair', 'children': ['325', '326']}; {'id': '325', 'type': 'string', 'children': [], 'value': "'direct_placement'"}; {'id': '326', 'type': 'comparison_operator', 'children': ['327', '328'], 'value': 'in'}; {'id': '327', 'type': 'string', 'children': [], 'value': "'P'"}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '329', 'type': 'pair', 'children': ['330', '331']}; {'id': '330', 'type': 'string', 'children': [], 'value': "'effect_quantity'"}; {'id': '331', 'type': 'comparison_operator', 'children': ['332', '333'], 'value': 'in'}; {'id': '332', 'type': 'string', 'children': [], 'value': "'C'"}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '334', 'type': 'pair', 'children': ['335', '336']}; {'id': '335', 'type': 'string', 'children': [], 'value': "'guard_state'"}; {'id': '336', 'type': 'comparison_operator', 'children': ['337', '338'], 'value': 'in'}; {'id': '337', 'type': 'string', 'children': [], 'value': "'G'"}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '339', 'type': 'pair', 'children': ['340', '341']}; {'id': '340', 'type': 'string', 'children': [], 'value': "'fixed_positions'"}; {'id': '341', 'type': 'comparison_operator', 'children': ['342', '343'], 'value': 'in'}; {'id': '342', 'type': 'string', 'children': [], 'value': "'F'"}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'mode_string'}; {'id': '344', 'type': 'expression_statement', 'children': ['345']}; {'id': '345', 'type': 'assignment', 'children': ['346', '351']}; {'id': '346', 'type': 'subscript', 'children': ['347', '350']}; {'id': '347', 'type': 'attribute', 'children': ['348', '349']}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '349', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '350', 'type': 'string', 'children': [], 'value': "'map'"}; {'id': '351', 'type': 'dictionary', 'children': ['352', '359', '366', '369', '372', '375', '378', '381']}; {'id': '352', 'type': 'pair', 'children': ['353', '354']}; {'id': '353', 'type': 'string', 'children': [], 'value': "'id'"}; {'id': '354', 'type': 'conditional_expression', 'children': ['355', '356', '358'], 'value': 'if'}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'map_id'}; {'id': '356', 'type': 'not_operator', 'children': ['357']}; {'id': '357', 'type': 'identifier', 'children': [], 'value': 'custom'}; {'id': '358', 'type': 'None', 'children': []}; {'id': '359', 'type': 'pair', 'children': ['360', '361']}; {'id': '360', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '361', 'type': 'call', 'children': ['362', '365']}; {'id': '362', 'type': 'attribute', 'children': ['363', '364']}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '365', 'type': 'argument_list', 'children': []}; {'id': '366', 'type': 'pair', 'children': ['367', '368']}; {'id': '367', 'type': 'string', 'children': [], 'value': "'size'"}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'size'}; {'id': '369', 'type': 'pair', 'children': ['370', '371']}; {'id': '370', 'type': 'string', 'children': [], 'value': "'dimension'"}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'dimension'}; {'id': '372', 'type': 'pair', 'children': ['373', '374']}; {'id': '373', 'type': 'string', 'children': [], 'value': "'seed'"}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'seed'}; {'id': '375', 'type': 'pair', 'children': ['376', '377']}; {'id': '376', 'type': 'string', 'children': [], 'value': "'modes'"}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'modes'}; {'id': '378', 'type': 'pair', 'children': ['379', '380']}; {'id': '379', 'type': 'string', 'children': [], 'value': "'custom'"}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'custom'}; {'id': '381', 'type': 'pair', 'children': ['382', '383']}; {'id': '382', 'type': 'string', 'children': [], 'value': "'zr'"}; {'id': '383', 'type': 'call', 'children': ['384', '387']}; {'id': '384', 'type': 'attribute', 'children': ['385', '386']}; {'id': '385', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '386', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '387', 'type': 'argument_list', 'children': ['388']}; {'id': '388', 'type': 'string', 'children': [], 'value': "'ZR@'"}; {'id': '389', 'type': 'return_statement', 'children': ['390']}; {'id': '390', 'type': 'subscript', 'children': ['391', '394']}; {'id': '391', 'type': 'attribute', 'children': ['392', '393']}; {'id': '392', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '393', 'type': 'identifier', 'children': [], 'value': '_cache'}; {'id': '394', 'type': 'string', 'children': [], 'value': "'map'"}
Get the map metadata.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '4']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'main'}; {'id': '3', 'type': 'parameters', 'children': []}; {'id': '4', 'type': 'block', 'children': ['5', '11', '19', '25', '33', '43', '53', '140', '181', '194', '200', '296', '327', '338', '353']}; {'id': '5', 'type': 'expression_statement', 'children': ['6']}; {'id': '6', 'type': 'assignment', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '8', 'type': 'call', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'get_parser'}; {'id': '10', 'type': 'argument_list', 'children': []}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'assignment', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '14', 'type': 'call', 'children': ['15', '18']}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '18', 'type': 'argument_list', 'children': []}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'ARCHIVE'}; {'id': '22', 'type': 'attribute', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'archive_path'}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'archive'}; {'id': '28', 'type': '()', 'children': ['29']}; {'id': '29', 'type': 'not_operator', 'children': ['30']}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'no_archive'}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '40']}; {'id': '35', 'type': 'subscript', 'children': ['36', '39']}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '39', 'type': 'string', 'children': [], 'value': "'F2FORMAT_VERSION'"}; {'id': '40', 'type': 'attribute', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'python'}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'assignment', 'children': ['45', '50']}; {'id': '45', 'type': 'subscript', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '49', 'type': 'string', 'children': [], 'value': "'F2FORMAT_ENCODING'"}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '53', 'type': 'function_definition', 'children': ['54', '55', '57']}; {'id': '54', 'type': 'function_name', 'children': [], 'value': 'find'}; {'id': '55', 'type': 'parameters', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '57', 'type': 'block', 'children': ['58', '64', '73', '137']}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'assignment', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'flst'}; {'id': '61', 'type': 'call', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '63', 'type': 'argument_list', 'children': []}; {'id': '64', 'type': 'expression_statement', 'children': ['65']}; {'id': '65', 'type': 'assignment', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'temp'}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'listdir'}; {'id': '71', 'type': 'argument_list', 'children': ['72']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '73', 'type': 'for_statement', 'children': ['74', '75', '76']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'temp'}; {'id': '76', 'type': 'block', 'children': ['77', '89']}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'assignment', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '80', 'type': 'call', 'children': ['81', '86']}; {'id': '81', 'type': 'attribute', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '86', 'type': 'argument_list', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '89', 'type': 'if_statement', 'children': ['90', '98', '109', '126']}; {'id': '90', 'type': 'call', 'children': ['91', '96']}; {'id': '91', 'type': 'attribute', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'isdir'}; {'id': '96', 'type': 'argument_list', 'children': ['97']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '98', 'type': 'block', 'children': ['99']}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'call', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'flst'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'call', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '107', 'type': 'argument_list', 'children': ['108']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '109', 'type': 'elif_clause', 'children': ['110', '118']}; {'id': '110', 'type': 'call', 'children': ['111', '116']}; {'id': '111', 'type': 'attribute', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '116', 'type': 'argument_list', 'children': ['117']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '118', 'type': 'block', 'children': ['119']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'call', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'flst'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '126', 'type': 'elif_clause', 'children': ['127', '135']}; {'id': '127', 'type': 'call', 'children': ['128', '133']}; {'id': '128', 'type': 'attribute', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'islink'}; {'id': '133', 'type': 'argument_list', 'children': ['134']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '135', 'type': 'block', 'children': ['136']}; {'id': '136', 'type': 'continue_statement', 'children': []}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'yield', 'children': ['139']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'flst'}; {'id': '140', 'type': 'function_definition', 'children': ['141', '142', '144']}; {'id': '141', 'type': 'function_name', 'children': [], 'value': 'rename'}; {'id': '142', 'type': 'parameters', 'children': ['143']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '144', 'type': 'block', 'children': ['145', '158', '171']}; {'id': '145', 'type': 'expression_statement', 'children': ['146']}; {'id': '146', 'type': 'assignment', 'children': ['147', '150']}; {'id': '147', 'type': 'pattern_list', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'stem'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'ext'}; {'id': '150', 'type': 'call', 'children': ['151', '156']}; {'id': '151', 'type': 'attribute', 'children': ['152', '155']}; {'id': '152', 'type': 'attribute', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'splitext'}; {'id': '156', 'type': 'argument_list', 'children': ['157']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '158', 'type': 'expression_statement', 'children': ['159']}; {'id': '159', 'type': 'assignment', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '161', 'type': 'binary_operator', 'children': ['162', '163'], 'value': '%'}; {'id': '162', 'type': 'string', 'children': [], 'value': "'%s-%s%s'"}; {'id': '163', 'type': 'tuple', 'children': ['164', '165', '170']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'stem'}; {'id': '165', 'type': 'call', 'children': ['166', '169']}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'uuid'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'uuid4'}; {'id': '169', 'type': 'argument_list', 'children': []}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'ext'}; {'id': '171', 'type': 'return_statement', 'children': ['172']}; {'id': '172', 'type': 'call', 'children': ['173', '178']}; {'id': '173', 'type': 'attribute', 'children': ['174', '177']}; {'id': '174', 'type': 'attribute', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '178', 'type': 'argument_list', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'ARCHIVE'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '181', 'type': 'if_statement', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'archive'}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '189']}; {'id': '186', 'type': 'attribute', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'makedirs'}; {'id': '189', 'type': 'argument_list', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'ARCHIVE'}; {'id': '191', 'type': 'keyword_argument', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'exist_ok'}; {'id': '193', 'type': 'True', 'children': []}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'assignment', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '197', 'type': 'call', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '199', 'type': 'argument_list', 'children': []}; {'id': '200', 'type': 'for_statement', 'children': ['201', '202', '209']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '202', 'type': 'subscript', 'children': ['203', '206']}; {'id': '203', 'type': 'attribute', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '206', 'type': 'slice', 'children': ['207', '208']}; {'id': '207', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '208', 'type': 'colon', 'children': []}; {'id': '209', 'type': 'block', 'children': ['210', '262']}; {'id': '210', 'type': 'if_statement', 'children': ['211', '219']}; {'id': '211', 'type': 'call', 'children': ['212', '217']}; {'id': '212', 'type': 'attribute', 'children': ['213', '216']}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '217', 'type': 'argument_list', 'children': ['218']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '219', 'type': 'block', 'children': ['220', '255']}; {'id': '220', 'type': 'if_statement', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'archive'}; {'id': '222', 'type': 'block', 'children': ['223', '230', '247']}; {'id': '223', 'type': 'expression_statement', 'children': ['224']}; {'id': '224', 'type': 'assignment', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '226', 'type': 'call', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'rename'}; {'id': '228', 'type': 'argument_list', 'children': ['229']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '230', 'type': 'expression_statement', 'children': ['231']}; {'id': '231', 'type': 'call', 'children': ['232', '235']}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'makedirs'}; {'id': '235', 'type': 'argument_list', 'children': ['236', '244']}; {'id': '236', 'type': 'call', 'children': ['237', '242']}; {'id': '237', 'type': 'attribute', 'children': ['238', '241']}; {'id': '238', 'type': 'attribute', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '242', 'type': 'argument_list', 'children': ['243']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '244', 'type': 'keyword_argument', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'exist_ok'}; {'id': '246', 'type': 'True', 'children': []}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'call', 'children': ['249', '252']}; {'id': '249', 'type': 'attribute', 'children': ['250', '251']}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'shutil'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '252', 'type': 'argument_list', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '255', 'type': 'expression_statement', 'children': ['256']}; {'id': '256', 'type': 'call', 'children': ['257', '260']}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '260', 'type': 'argument_list', 'children': ['261']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '262', 'type': 'if_statement', 'children': ['263', '271']}; {'id': '263', 'type': 'call', 'children': ['264', '269']}; {'id': '264', 'type': 'attribute', 'children': ['265', '268']}; {'id': '265', 'type': 'attribute', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'isdir'}; {'id': '269', 'type': 'argument_list', 'children': ['270']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '271', 'type': 'block', 'children': ['272', '286']}; {'id': '272', 'type': 'if_statement', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'archive'}; {'id': '274', 'type': 'block', 'children': ['275']}; {'id': '275', 'type': 'expression_statement', 'children': ['276']}; {'id': '276', 'type': 'call', 'children': ['277', '280']}; {'id': '277', 'type': 'attribute', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'shutil'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'copytree'}; {'id': '280', 'type': 'argument_list', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '282', 'type': 'call', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'rename'}; {'id': '284', 'type': 'argument_list', 'children': ['285']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '286', 'type': 'expression_statement', 'children': ['287']}; {'id': '287', 'type': 'call', 'children': ['288', '291']}; {'id': '288', 'type': 'attribute', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '291', 'type': 'argument_list', 'children': ['292']}; {'id': '292', 'type': 'call', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'find'}; {'id': '294', 'type': 'argument_list', 'children': ['295']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '296', 'type': 'function_definition', 'children': ['297', '298', '300']}; {'id': '297', 'type': 'function_name', 'children': [], 'value': 'ispy'}; {'id': '298', 'type': 'parameters', 'children': ['299']}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '300', 'type': 'block', 'children': ['301']}; {'id': '301', 'type': 'return_statement', 'children': ['302']}; {'id': '302', 'type': '()', 'children': ['303']}; {'id': '303', 'type': 'boolean_operator', 'children': ['304', '312'], 'value': 'and'}; {'id': '304', 'type': 'call', 'children': ['305', '310']}; {'id': '305', 'type': 'attribute', 'children': ['306', '309']}; {'id': '306', 'type': 'attribute', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '310', 'type': 'argument_list', 'children': ['311']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '312', 'type': '()', 'children': ['313']}; {'id': '313', 'type': 'comparison_operator', 'children': ['314', '324'], 'value': 'in'}; {'id': '314', 'type': 'subscript', 'children': ['315', '323']}; {'id': '315', 'type': 'call', 'children': ['316', '321']}; {'id': '316', 'type': 'attribute', 'children': ['317', '320']}; {'id': '317', 'type': 'attribute', 'children': ['318', '319']}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'splitext'}; {'id': '321', 'type': 'argument_list', 'children': ['322']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '323', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '324', 'type': 'tuple', 'children': ['325', '326']}; {'id': '325', 'type': 'string', 'children': [], 'value': "'.py'"}; {'id': '326', 'type': 'string', 'children': [], 'value': "'.pyw'"}; {'id': '327', 'type': 'expression_statement', 'children': ['328']}; {'id': '328', 'type': 'assignment', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '330', 'type': 'call', 'children': ['331', '332']}; {'id': '331', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '332', 'type': 'argument_list', 'children': ['333']}; {'id': '333', 'type': 'call', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'filter'}; {'id': '335', 'type': 'argument_list', 'children': ['336', '337']}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'ispy'}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '338', 'type': 'if_statement', 'children': ['339', '345']}; {'id': '339', 'type': 'comparison_operator', 'children': ['340', '344'], 'value': '=='}; {'id': '340', 'type': 'call', 'children': ['341', '342']}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '342', 'type': 'argument_list', 'children': ['343']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '344', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '345', 'type': 'block', 'children': ['346']}; {'id': '346', 'type': 'expression_statement', 'children': ['347']}; {'id': '347', 'type': 'call', 'children': ['348', '351']}; {'id': '348', 'type': 'attribute', 'children': ['349', '350']}; {'id': '349', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '351', 'type': 'argument_list', 'children': ['352']}; {'id': '352', 'type': 'string', 'children': [], 'value': "'argument PATH: no valid source file found'"}; {'id': '353', 'type': 'if_statement', 'children': ['354', '361', '371']}; {'id': '354', 'type': 'boolean_operator', 'children': ['355', '358'], 'value': 'or'}; {'id': '355', 'type': 'comparison_operator', 'children': ['356', '357'], 'value': 'is'}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'mp'}; {'id': '357', 'type': 'None', 'children': []}; {'id': '358', 'type': 'comparison_operator', 'children': ['359', '360'], 'value': '<='}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'CPU_CNT'}; {'id': '360', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '361', 'type': 'block', 'children': ['362']}; {'id': '362', 'type': 'expression_statement', 'children': ['363']}; {'id': '363', 'type': 'list_comprehension', 'children': ['364', '368']}; {'id': '364', 'type': 'call', 'children': ['365', '366']}; {'id': '365', 'type': 'identifier', 'children': [], 'value': 'f2format'}; {'id': '366', 'type': 'argument_list', 'children': ['367']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '368', 'type': 'for_in_clause', 'children': ['369', '370']}; {'id': '369', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'filelist'}; {'id': '371', 'type': 'else_clause', 'children': ['372']}; {'id': '372', 'type': 'block', 'children': ['373']}; {'id': '373', 'type': 'expression_statement', 'children': ['374']}; {'id': '374', 'type': 'call', 'children': ['375', '385']}; {'id': '375', 'type': 'attribute', 'children': ['376', '384']}; {'id': '376', 'type': 'call', 'children': ['377', '380']}; {'id': '377', 'type': 'attribute', 'children': ['378', '379']}; {'id': '378', 'type': 'identifier', 'children': [], 'value': 'mp'}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'Pool'}; {'id': '380', 'type': 'argument_list', 'children': ['381']}; {'id': '381', 'type': 'keyword_argument', 'children': ['382', '383']}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'processes'}; {'id': '383', 'type': 'identifier', 'children': [], 'value': 'CPU_CNT'}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'map'}; {'id': '385', 'type': 'argument_list', 'children': ['386', '387']}; {'id': '386', 'type': 'identifier', 'children': [], 'value': 'f2format'}; {'id': '387', 'type': 'identifier', 'children': [], 'value': 'filelist'}
Entry point for f2format.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_check_triple'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'triple'}; {'id': '6', 'type': 'block', 'children': ['7', '14', '40', '44', '53', '62', '83', '95', '114', '146', '155', '169', '181', '188', '199', '211', '223', '235', '246', '253']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '13']}; {'id': '9', 'type': 'pattern_list', 'children': ['10', '11', '12']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'subj'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'triple'}; {'id': '14', 'type': 'if_statement', 'children': ['15', '21']}; {'id': '15', 'type': 'call', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': '_should_ignore_predicate'}; {'id': '19', 'type': 'argument_list', 'children': ['20']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '21', 'type': 'block', 'children': ['22', '39']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'call', 'children': ['24', '27']}; {'id': '24', 'type': 'attribute', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '27', 'type': 'argument_list', 'children': ['28']}; {'id': '28', 'type': 'call', 'children': ['29', '32']}; {'id': '29', 'type': 'attribute', 'children': ['30', '31']}; {'id': '30', 'type': 'string', 'children': [], 'value': '"Ignoring triple with predicate \'{}\'"'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '32', 'type': 'argument_list', 'children': ['33']}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': '_field_name_from_uri'}; {'id': '37', 'type': 'argument_list', 'children': ['38']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '39', 'type': 'return_statement', 'children': []}; {'id': '40', 'type': 'expression_statement', 'children': ['41']}; {'id': '41', 'type': 'assignment', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'classes'}; {'id': '43', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'call', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '49', 'type': 'argument_list', 'children': ['50']}; {'id': '50', 'type': 'binary_operator', 'children': ['51', '52'], 'value': '%'}; {'id': '51', 'type': 'string', 'children': [], 'value': '"Possible member %s found"'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '53', 'type': 'expression_statement', 'children': ['54']}; {'id': '54', 'type': 'assignment', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '56', 'type': 'call', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': '_expand_qname'}; {'id': '60', 'type': 'argument_list', 'children': ['61']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '62', 'type': 'if_statement', 'children': ['63', '73']}; {'id': '63', 'type': 'comparison_operator', 'children': ['64', '70'], 'value': 'not'}; {'id': '64', 'type': 'call', 'children': ['65', '68']}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': '_namespace_from_uri'}; {'id': '68', 'type': 'argument_list', 'children': ['69']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'allowed_namespaces'}; {'id': '73', 'type': 'block', 'children': ['74', '82']}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '79', 'type': 'argument_list', 'children': ['80', '81']}; {'id': '80', 'type': 'string', 'children': [], 'value': '"Member %s does not use an allowed namespace"'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '82', 'type': 'return_statement', 'children': []}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '86', 'type': 'call', 'children': ['87', '90']}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': '_is_instance'}; {'id': '90', 'type': 'argument_list', 'children': ['91']}; {'id': '91', 'type': 'tuple', 'children': ['92', '93', '94']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'subj'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '95', 'type': 'if_statement', 'children': ['96', '104']}; {'id': '96', 'type': 'comparison_operator', 'children': ['97', '101'], 'value': '=='}; {'id': '97', 'type': 'call', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '99', 'type': 'argument_list', 'children': ['100']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'rt'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'URIRef'}; {'id': '104', 'type': 'block', 'children': ['105']}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '108', 'type': 'call', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': '_expand_qname'}; {'id': '112', 'type': 'argument_list', 'children': ['113']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '114', 'type': 'if_statement', 'children': ['115', '130']}; {'id': '115', 'type': 'boolean_operator', 'children': ['116', '123', '124'], 'value': 'and'}; {'id': '116', 'type': 'call', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '118', 'type': 'argument_list', 'children': ['119', '122']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'schema_def'}; {'id': '122', 'type': 'string', 'children': [], 'value': '"attributes_by_class"'}; {'id': '123', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '124', 'type': 'not_operator', 'children': ['125']}; {'id': '125', 'type': 'attribute', 'children': ['126', '129']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'schema_def'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'attributes_by_class'}; {'id': '130', 'type': 'block', 'children': ['131', '138']}; {'id': '131', 'type': 'expression_statement', 'children': ['132']}; {'id': '132', 'type': 'call', 'children': ['133', '136']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '136', 'type': 'argument_list', 'children': ['137']}; {'id': '137', 'type': 'string', 'children': [], 'value': '"Parsed ontology not found. Parsing..."'}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'call', 'children': ['140', '145']}; {'id': '140', 'type': 'attribute', 'children': ['141', '144']}; {'id': '141', 'type': 'attribute', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'schema_def'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'parse_ontology'}; {'id': '145', 'type': 'argument_list', 'children': []}; {'id': '146', 'type': 'expression_statement', 'children': ['147']}; {'id': '147', 'type': 'assignment', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'class_invalid'}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': '_validate_class'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '155', 'type': 'if_statement', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'class_invalid'}; {'id': '157', 'type': 'block', 'children': ['158', '167']}; {'id': '158', 'type': 'expression_statement', 'children': ['159']}; {'id': '159', 'type': 'call', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '163', 'type': 'argument_list', 'children': ['164']}; {'id': '164', 'type': 'binary_operator', 'children': ['165', '166'], 'value': '%'}; {'id': '165', 'type': 'string', 'children': [], 'value': '"Invalid class %s"'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '167', 'type': 'return_statement', 'children': ['168']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'class_invalid'}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'assignment', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'classes'}; {'id': '172', 'type': 'call', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': '_superclasses_for_subject'}; {'id': '176', 'type': 'argument_list', 'children': ['177', '180']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'graph'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '181', 'type': 'expression_statement', 'children': ['182']}; {'id': '182', 'type': 'call', 'children': ['183', '186']}; {'id': '183', 'type': 'attribute', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'classes'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '186', 'type': 'argument_list', 'children': ['187']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'assignment', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'member_invalid'}; {'id': '191', 'type': 'call', 'children': ['192', '195']}; {'id': '192', 'type': 'attribute', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': '_validate_member'}; {'id': '195', 'type': 'argument_list', 'children': ['196', '197', '198']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'classes'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '199', 'type': 'if_statement', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'member_invalid'}; {'id': '201', 'type': 'block', 'children': ['202', '209']}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'call', 'children': ['204', '207']}; {'id': '204', 'type': 'attribute', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '207', 'type': 'argument_list', 'children': ['208']}; {'id': '208', 'type': 'string', 'children': [], 'value': '"Invalid member of class"'}; {'id': '209', 'type': 'return_statement', 'children': ['210']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'member_invalid'}; {'id': '211', 'type': 'expression_statement', 'children': ['212']}; {'id': '212', 'type': 'assignment', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'dupe_invalid'}; {'id': '214', 'type': 'call', 'children': ['215', '218']}; {'id': '215', 'type': 'attribute', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': '_validate_duplication'}; {'id': '218', 'type': 'argument_list', 'children': ['219', '222']}; {'id': '219', 'type': 'tuple', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'subj'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'instanceof'}; {'id': '223', 'type': 'if_statement', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'dupe_invalid'}; {'id': '225', 'type': 'block', 'children': ['226', '233']}; {'id': '226', 'type': 'expression_statement', 'children': ['227']}; {'id': '227', 'type': 'call', 'children': ['228', '231']}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '231', 'type': 'argument_list', 'children': ['232']}; {'id': '232', 'type': 'string', 'children': [], 'value': '"Duplication found"'}; {'id': '233', 'type': 'return_statement', 'children': ['234']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'dupe_invalid'}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'call', 'children': ['237', '242']}; {'id': '237', 'type': 'attribute', 'children': ['238', '241']}; {'id': '238', 'type': 'attribute', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'checked_attributes'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '242', 'type': 'argument_list', 'children': ['243']}; {'id': '243', 'type': 'tuple', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'subj'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'pred'}; {'id': '246', 'type': 'expression_statement', 'children': ['247']}; {'id': '247', 'type': 'call', 'children': ['248', '251']}; {'id': '248', 'type': 'attribute', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '251', 'type': 'argument_list', 'children': ['252']}; {'id': '252', 'type': 'string', 'children': [], 'value': '"successfully validated triple, no errors"'}; {'id': '253', 'type': 'return_statement', 'children': []}
compare triple to ontology, return error or None
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'either'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '13', '22']}; {'id': '7', 'type': 'not_operator', 'children': ['8']}; {'id': '8', 'type': 'call', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '10', 'type': 'argument_list', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '12', 'type': 'string', 'children': [], 'value': "'children'"}; {'id': '13', 'type': 'block', 'children': ['14']}; {'id': '14', 'type': 'return_statement', 'children': ['15']}; {'id': '15', 'type': 'call', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'Either'}; {'id': '17', 'type': 'argument_list', 'children': ['18']}; {'id': '18', 'type': 'call', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'Required'}; {'id': '20', 'type': 'argument_list', 'children': ['21']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '22', 'type': 'else_clause', 'children': ['23']}; {'id': '23', 'type': 'block', 'children': ['24', '28', '34', '262']}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'ret'}; {'id': '27', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '31', 'type': 'list', 'children': ['32'], 'value': '[[self]]'}; {'id': '32', 'type': 'list', 'children': ['33'], 'value': '[self]'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '34', 'type': 'while_statement', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '36', 'type': 'block', 'children': ['37', '46', '57']}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'assignment', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '40', 'type': 'call', 'children': ['41', '44']}; {'id': '41', 'type': 'attribute', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '44', 'type': 'argument_list', 'children': ['45']}; {'id': '45', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'assignment', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '49', 'type': 'list_comprehension', 'children': ['50', '54']}; {'id': '50', 'type': 'call', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '52', 'type': 'argument_list', 'children': ['53']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '54', 'type': 'for_in_clause', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '57', 'type': 'if_statement', 'children': ['58', '61', '107', '155', '203', '253']}; {'id': '58', 'type': 'comparison_operator', 'children': ['59', '60'], 'value': 'in'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'Either'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '61', 'type': 'block', 'children': ['62', '79', '91']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'either'}; {'id': '65', 'type': 'subscript', 'children': ['66', '78']}; {'id': '66', 'type': 'list_comprehension', 'children': ['67', '68', '71']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '68', 'type': 'for_in_clause', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '71', 'type': 'if_clause', 'children': ['72']}; {'id': '72', 'type': 'comparison_operator', 'children': ['73', '77'], 'value': 'is'}; {'id': '73', 'type': 'call', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'Either'}; {'id': '78', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'call', 'children': ['81', '84']}; {'id': '81', 'type': 'attribute', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'call', 'children': ['86', '89']}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'either'}; {'id': '91', 'type': 'for_statement', 'children': ['92', '93', '96']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '93', 'type': 'attribute', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'either'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '96', 'type': 'block', 'children': ['97']}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'call', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '102', 'type': 'argument_list', 'children': ['103']}; {'id': '103', 'type': 'binary_operator', 'children': ['104', '106'], 'value': '+'}; {'id': '104', 'type': 'list', 'children': ['105'], 'value': '[c]'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '107', 'type': 'elif_clause', 'children': ['108', '111']}; {'id': '108', 'type': 'comparison_operator', 'children': ['109', '110'], 'value': 'in'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'Required'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '111', 'type': 'block', 'children': ['112', '129', '141']}; {'id': '112', 'type': 'expression_statement', 'children': ['113']}; {'id': '113', 'type': 'assignment', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'required'}; {'id': '115', 'type': 'subscript', 'children': ['116', '128']}; {'id': '116', 'type': 'list_comprehension', 'children': ['117', '118', '121']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '118', 'type': 'for_in_clause', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '121', 'type': 'if_clause', 'children': ['122']}; {'id': '122', 'type': 'comparison_operator', 'children': ['123', '127'], 'value': 'is'}; {'id': '123', 'type': 'call', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'Required'}; {'id': '128', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '129', 'type': 'expression_statement', 'children': ['130']}; {'id': '130', 'type': 'call', 'children': ['131', '134']}; {'id': '131', 'type': 'attribute', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '139', 'type': 'argument_list', 'children': ['140']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'required'}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'call', 'children': ['143', '146']}; {'id': '143', 'type': 'attribute', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '146', 'type': 'argument_list', 'children': ['147']}; {'id': '147', 'type': 'binary_operator', 'children': ['148', '154'], 'value': '+'}; {'id': '148', 'type': 'call', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '150', 'type': 'argument_list', 'children': ['151']}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'required'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '155', 'type': 'elif_clause', 'children': ['156', '159']}; {'id': '156', 'type': 'comparison_operator', 'children': ['157', '158'], 'value': 'in'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'Optional'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '159', 'type': 'block', 'children': ['160', '177', '189']}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '163', 'type': 'subscript', 'children': ['164', '176']}; {'id': '164', 'type': 'list_comprehension', 'children': ['165', '166', '169']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '166', 'type': 'for_in_clause', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '169', 'type': 'if_clause', 'children': ['170']}; {'id': '170', 'type': 'comparison_operator', 'children': ['171', '175'], 'value': 'is'}; {'id': '171', 'type': 'call', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '173', 'type': 'argument_list', 'children': ['174']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'Optional'}; {'id': '176', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'call', 'children': ['179', '182']}; {'id': '179', 'type': 'attribute', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '182', 'type': 'argument_list', 'children': ['183']}; {'id': '183', 'type': 'call', 'children': ['184', '187']}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '189', 'type': 'expression_statement', 'children': ['190']}; {'id': '190', 'type': 'call', 'children': ['191', '194']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '194', 'type': 'argument_list', 'children': ['195']}; {'id': '195', 'type': 'binary_operator', 'children': ['196', '202'], 'value': '+'}; {'id': '196', 'type': 'call', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '198', 'type': 'argument_list', 'children': ['199']}; {'id': '199', 'type': 'attribute', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'optional'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '203', 'type': 'elif_clause', 'children': ['204', '207']}; {'id': '204', 'type': 'comparison_operator', 'children': ['205', '206'], 'value': 'in'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'OneOrMore'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '207', 'type': 'block', 'children': ['208', '225', '237']}; {'id': '208', 'type': 'expression_statement', 'children': ['209']}; {'id': '209', 'type': 'assignment', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'oneormore'}; {'id': '211', 'type': 'subscript', 'children': ['212', '224']}; {'id': '212', 'type': 'list_comprehension', 'children': ['213', '214', '217']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '214', 'type': 'for_in_clause', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '217', 'type': 'if_clause', 'children': ['218']}; {'id': '218', 'type': 'comparison_operator', 'children': ['219', '223'], 'value': 'is'}; {'id': '219', 'type': 'call', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '221', 'type': 'argument_list', 'children': ['222']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'OneOrMore'}; {'id': '224', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '225', 'type': 'expression_statement', 'children': ['226']}; {'id': '226', 'type': 'call', 'children': ['227', '230']}; {'id': '227', 'type': 'attribute', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '230', 'type': 'argument_list', 'children': ['231']}; {'id': '231', 'type': 'call', 'children': ['232', '235']}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '235', 'type': 'argument_list', 'children': ['236']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'oneormore'}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'call', 'children': ['239', '242']}; {'id': '239', 'type': 'attribute', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '242', 'type': 'argument_list', 'children': ['243']}; {'id': '243', 'type': 'binary_operator', 'children': ['244', '252'], 'value': '+'}; {'id': '244', 'type': 'binary_operator', 'children': ['245', '251'], 'value': '*'}; {'id': '245', 'type': 'call', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '247', 'type': 'argument_list', 'children': ['248']}; {'id': '248', 'type': 'attribute', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'oneormore'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '251', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '253', 'type': 'else_clause', 'children': ['254']}; {'id': '254', 'type': 'block', 'children': ['255']}; {'id': '255', 'type': 'expression_statement', 'children': ['256']}; {'id': '256', 'type': 'call', 'children': ['257', '260']}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'ret'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '260', 'type': 'argument_list', 'children': ['261']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'children'}; {'id': '262', 'type': 'return_statement', 'children': ['263']}; {'id': '263', 'type': 'call', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'Either'}; {'id': '265', 'type': 'argument_list', 'children': ['266']}; {'id': '266', 'type': 'list_splat', 'children': ['267']}; {'id': '267', 'type': 'list_comprehension', 'children': ['268', '273']}; {'id': '268', 'type': 'call', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'Required'}; {'id': '270', 'type': 'argument_list', 'children': ['271']}; {'id': '271', 'type': 'list_splat', 'children': ['272']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '273', 'type': 'for_in_clause', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'ret'}
Transform pattern into an equivalent, with only top-level Either.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'TranslateManagedObject'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'mObj'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'xlateOrg'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '7', 'type': 'block', 'children': ['8', '15', '20', '28', '39', '198', '352']}; {'id': '8', 'type': 'import_from_statement', 'children': ['9', '11', '13']}; {'id': '9', 'type': 'dotted_name', 'children': ['10']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'UcsBase'}; {'id': '11', 'type': 'dotted_name', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '13', 'type': 'dotted_name', 'children': ['14']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'WriteUcsWarning'}; {'id': '15', 'type': 'import_from_statement', 'children': ['16', '18']}; {'id': '16', 'type': 'dotted_name', 'children': ['17']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'Mos'}; {'id': '18', 'type': 'dotted_name', 'children': ['19']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'OrgOrg'}; {'id': '20', 'type': 'expression_statement', 'children': ['21']}; {'id': '21', 'type': 'assignment', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '23', 'type': 'call', 'children': ['24', '27']}; {'id': '24', 'type': 'attribute', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'mObj'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'Clone'}; {'id': '27', 'type': 'argument_list', 'children': []}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'call', 'children': ['30', '33']}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'SetHandle'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'call', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'mObj'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'GetHandle'}; {'id': '38', 'type': 'argument_list', 'children': []}; {'id': '39', 'type': 'if_statement', 'children': ['40', '44']}; {'id': '40', 'type': '()', 'children': ['41']}; {'id': '41', 'type': 'comparison_operator', 'children': ['42', '43'], 'value': '!='}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'xlateOrg'}; {'id': '43', 'type': 'None', 'children': []}; {'id': '44', 'type': 'block', 'children': ['45', '57']}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'assignment', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '48', 'type': 'call', 'children': ['49', '52']}; {'id': '49', 'type': 'attribute', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '52', 'type': 'argument_list', 'children': ['53', '54']}; {'id': '53', 'type': 'string', 'children': [], 'value': "r'^(org-[\\-\\.:_a-zA-Z0-9]{1,16}/)*org-[\\-\\.:_a-zA-Z0-9]{1,16}'"}; {'id': '54', 'type': 'attribute', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '57', 'type': 'if_statement', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '59', 'type': 'block', 'children': ['60']}; {'id': '60', 'type': 'if_statement', 'children': ['61', '75', '166']}; {'id': '61', 'type': 'comparison_operator', 'children': ['62', '70'], 'value': '=='}; {'id': '62', 'type': 'call', 'children': ['63', '66']}; {'id': '63', 'type': 'attribute', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'WordL'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '70', 'type': 'call', 'children': ['71', '74']}; {'id': '71', 'type': 'attribute', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'OrgOrg'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'ClassId'}; {'id': '74', 'type': 'argument_list', 'children': []}; {'id': '75', 'type': 'block', 'children': ['76', '95', '112', '124']}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'orgMoMeta'}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'GetUcsPropertyMeta'}; {'id': '83', 'type': 'argument_list', 'children': ['84', '94']}; {'id': '84', 'type': 'call', 'children': ['85', '88']}; {'id': '85', 'type': 'attribute', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '88', 'type': 'argument_list', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'OrgOrg'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'ClassId'}; {'id': '93', 'type': 'argument_list', 'children': []}; {'id': '94', 'type': 'string', 'children': [], 'value': '"Meta"'}; {'id': '95', 'type': 'if_statement', 'children': ['96', '99']}; {'id': '96', 'type': 'comparison_operator', 'children': ['97', '98'], 'value': '=='}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'orgMoMeta'}; {'id': '98', 'type': 'None', 'children': []}; {'id': '99', 'type': 'block', 'children': ['100', '110']}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'call', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'WriteUcsWarning'}; {'id': '103', 'type': 'argument_list', 'children': ['104']}; {'id': '104', 'type': 'binary_operator', 'children': ['105', '106'], 'value': '%'}; {'id': '105', 'type': 'string', 'children': [], 'value': "'[Warning]: Could not translate [%s]'"}; {'id': '106', 'type': '()', 'children': ['107']}; {'id': '107', 'type': 'attribute', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '110', 'type': 'return_statement', 'children': ['111']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '112', 'type': 'expression_statement', 'children': ['113']}; {'id': '113', 'type': 'assignment', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'matchObj1'}; {'id': '115', 'type': 'call', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'findall'}; {'id': '119', 'type': 'argument_list', 'children': ['120', '121']}; {'id': '120', 'type': 'string', 'children': [], 'value': "r'(\\[[^\\]]+\\])'"}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'orgMoMeta'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'rn'}; {'id': '124', 'type': 'if_statement', 'children': ['125', '126', '134']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'matchObj1'}; {'id': '126', 'type': 'block', 'children': ['127']}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'call', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'UpdateMoDnAlongWithNamingProperties'}; {'id': '130', 'type': 'argument_list', 'children': ['131', '132', '133']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'orgMoMeta'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'xlateOrg'}; {'id': '134', 'type': 'else_clause', 'children': ['135']}; {'id': '135', 'type': 'block', 'children': ['136', '160']}; {'id': '136', 'type': 'expression_statement', 'children': ['137']}; {'id': '137', 'type': 'assignment', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '139', 'type': 'call', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '143', 'type': 'argument_list', 'children': ['144', '153', '157']}; {'id': '144', 'type': 'binary_operator', 'children': ['145', '146'], 'value': '%'}; {'id': '145', 'type': 'string', 'children': [], 'value': '"%s"'}; {'id': '146', 'type': '()', 'children': ['147']}; {'id': '147', 'type': 'call', 'children': ['148', '151']}; {'id': '148', 'type': 'attribute', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '151', 'type': 'argument_list', 'children': ['152']}; {'id': '152', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '153', 'type': 'binary_operator', 'children': ['154', '155'], 'value': '%'}; {'id': '154', 'type': 'string', 'children': [], 'value': '"%s"'}; {'id': '155', 'type': '()', 'children': ['156']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'xlateOrg'}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '165']}; {'id': '162', 'type': 'attribute', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '166', 'type': 'else_clause', 'children': ['167']}; {'id': '167', 'type': 'block', 'children': ['168', '192']}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '175', 'type': 'argument_list', 'children': ['176', '185', '189']}; {'id': '176', 'type': 'binary_operator', 'children': ['177', '178'], 'value': '%'}; {'id': '177', 'type': 'string', 'children': [], 'value': '"^%s/"'}; {'id': '178', 'type': '()', 'children': ['179']}; {'id': '179', 'type': 'call', 'children': ['180', '183']}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '183', 'type': 'argument_list', 'children': ['184']}; {'id': '184', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '185', 'type': 'binary_operator', 'children': ['186', '187'], 'value': '%'}; {'id': '186', 'type': 'string', 'children': [], 'value': '"%s/"'}; {'id': '187', 'type': '()', 'children': ['188']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'xlateOrg'}; {'id': '189', 'type': 'attribute', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '197']}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '198', 'type': 'if_statement', 'children': ['199', '203']}; {'id': '199', 'type': '()', 'children': ['200']}; {'id': '200', 'type': 'comparison_operator', 'children': ['201', '202'], 'value': '!='}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '202', 'type': 'None', 'children': []}; {'id': '203', 'type': 'block', 'children': ['204', '210']}; {'id': '204', 'type': 'expression_statement', 'children': ['205']}; {'id': '205', 'type': 'assignment', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '210', 'type': 'if_statement', 'children': ['211', '214', '281']}; {'id': '211', 'type': 'comparison_operator', 'children': ['212', '213'], 'value': 'in'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '214', 'type': 'block', 'children': ['215', '232', '247', '259']}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'xMoMeta'}; {'id': '218', 'type': 'call', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'GetUcsPropertyMeta'}; {'id': '222', 'type': 'argument_list', 'children': ['223', '231']}; {'id': '223', 'type': 'call', 'children': ['224', '227']}; {'id': '224', 'type': 'attribute', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '227', 'type': 'argument_list', 'children': ['228']}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '231', 'type': 'string', 'children': [], 'value': '"Meta"'}; {'id': '232', 'type': 'if_statement', 'children': ['233', '236']}; {'id': '233', 'type': 'comparison_operator', 'children': ['234', '235'], 'value': '=='}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'xMoMeta'}; {'id': '235', 'type': 'None', 'children': []}; {'id': '236', 'type': 'block', 'children': ['237', '245']}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'call', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'WriteUcsWarning'}; {'id': '240', 'type': 'argument_list', 'children': ['241']}; {'id': '241', 'type': 'binary_operator', 'children': ['242', '243'], 'value': '%'}; {'id': '242', 'type': 'string', 'children': [], 'value': "'[Warning]: Could not translate [%s]'"}; {'id': '243', 'type': '()', 'children': ['244']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '245', 'type': 'return_statement', 'children': ['246']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'assignment', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '250', 'type': 'call', 'children': ['251', '254']}; {'id': '251', 'type': 'attribute', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'findall'}; {'id': '254', 'type': 'argument_list', 'children': ['255', '256']}; {'id': '255', 'type': 'string', 'children': [], 'value': "r'(\\[[^\\]]+\\])'"}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'xMoMeta'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'rn'}; {'id': '259', 'type': 'if_statement', 'children': ['260', '261', '271']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'matchObj'}; {'id': '261', 'type': 'block', 'children': ['262']}; {'id': '262', 'type': 'expression_statement', 'children': ['263']}; {'id': '263', 'type': 'call', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'UpdateMoDnAlongWithNamingProperties'}; {'id': '265', 'type': 'argument_list', 'children': ['266', '267', '268']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'xMoMeta'}; {'id': '268', 'type': 'subscript', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '271', 'type': 'else_clause', 'children': ['272']}; {'id': '272', 'type': 'block', 'children': ['273']}; {'id': '273', 'type': 'expression_statement', 'children': ['274']}; {'id': '274', 'type': 'assignment', 'children': ['275', '278']}; {'id': '275', 'type': 'attribute', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '278', 'type': 'subscript', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '281', 'type': 'else_clause', 'children': ['282']}; {'id': '282', 'type': 'block', 'children': ['283', '294']}; {'id': '283', 'type': 'expression_statement', 'children': ['284']}; {'id': '284', 'type': 'assignment', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '286', 'type': 'call', 'children': ['287', '290']}; {'id': '287', 'type': 'attribute', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '290', 'type': 'argument_list', 'children': ['291', '292', '293']}; {'id': '291', 'type': 'string', 'children': [], 'value': "r'[/]*[^/]+$'"}; {'id': '292', 'type': 'string', 'children': [], 'value': "''"}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '294', 'type': 'while_statement', 'children': ['295', '303']}; {'id': '295', 'type': '()', 'children': ['296']}; {'id': '296', 'type': 'boolean_operator', 'children': ['297', '300'], 'value': 'or'}; {'id': '297', 'type': 'comparison_operator', 'children': ['298', '299'], 'value': '!='}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '299', 'type': 'None', 'children': []}; {'id': '300', 'type': 'comparison_operator', 'children': ['301', '302'], 'value': '=='}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '302', 'type': 'string', 'children': [], 'value': '""'}; {'id': '303', 'type': 'block', 'children': ['304', '324', '345', '351']}; {'id': '304', 'type': 'if_statement', 'children': ['305', '311']}; {'id': '305', 'type': '()', 'children': ['306']}; {'id': '306', 'type': 'not_operator', 'children': ['307']}; {'id': '307', 'type': '()', 'children': ['308']}; {'id': '308', 'type': 'comparison_operator', 'children': ['309', '310'], 'value': 'in'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '311', 'type': 'block', 'children': ['312', '323']}; {'id': '312', 'type': 'expression_statement', 'children': ['313']}; {'id': '313', 'type': 'assignment', 'children': ['314', '315']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '315', 'type': 'call', 'children': ['316', '319']}; {'id': '316', 'type': 'attribute', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '319', 'type': 'argument_list', 'children': ['320', '321', '322']}; {'id': '320', 'type': 'string', 'children': [], 'value': "r'[/]*[^/]+$'"}; {'id': '321', 'type': 'string', 'children': [], 'value': "''"}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '323', 'type': 'continue_statement', 'children': []}; {'id': '324', 'type': 'expression_statement', 'children': ['325']}; {'id': '325', 'type': 'assignment', 'children': ['326', '327']}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '327', 'type': 'call', 'children': ['328', '331']}; {'id': '328', 'type': 'attribute', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '331', 'type': 'argument_list', 'children': ['332', '336', '342']}; {'id': '332', 'type': 'binary_operator', 'children': ['333', '334'], 'value': '%'}; {'id': '333', 'type': 'string', 'children': [], 'value': '"^%s/"'}; {'id': '334', 'type': '()', 'children': ['335']}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '336', 'type': 'binary_operator', 'children': ['337', '338'], 'value': '%'}; {'id': '337', 'type': 'string', 'children': [], 'value': '"%s/"'}; {'id': '338', 'type': '()', 'children': ['339']}; {'id': '339', 'type': 'subscript', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'xlateMap'}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'originalDn'}; {'id': '342', 'type': 'attribute', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '345', 'type': 'expression_statement', 'children': ['346']}; {'id': '346', 'type': 'assignment', 'children': ['347', '350']}; {'id': '347', 'type': 'attribute', 'children': ['348', '349']}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'xMO'}; {'id': '349', 'type': 'identifier', 'children': [], 'value': 'Dn'}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'newDn'}; {'id': '351', 'type': 'break_statement', 'children': []}; {'id': '352', 'type': 'return_statement', 'children': ['353']}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'xMO'}
Method used to translate a managedobject. This method is used in CompareManagedObject.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_set_suffix_links'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '8', '14']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'string', 'children': [], 'value': "'''\n Sets all suffix links in all nodes in this trie.\n '''"}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '13']}; {'id': '10', 'type': 'attribute', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': '_suffix_links_set'}; {'id': '13', 'type': 'True', 'children': []}; {'id': '14', 'type': 'for_statement', 'children': ['15', '18', '23']}; {'id': '15', 'type': 'pattern_list', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '18', 'type': 'call', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'bfs'}; {'id': '22', 'type': 'argument_list', 'children': []}; {'id': '23', 'type': 'block', 'children': ['24', '30', '38', '49', '55', '59', '103', '109', '125']}; {'id': '24', 'type': 'if_statement', 'children': ['25', '28']}; {'id': '25', 'type': 'comparison_operator', 'children': ['26', '27'], 'value': 'is'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '27', 'type': 'None', 'children': []}; {'id': '28', 'type': 'block', 'children': ['29']}; {'id': '29', 'type': 'continue_statement', 'children': []}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'longest_prefix'}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'longest_prefix'}; {'id': '38', 'type': 'if_statement', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'has_value'}; {'id': '42', 'type': 'block', 'children': ['43']}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'assignment', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'longest_prefix'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '49', 'type': 'if_statement', 'children': ['50', '53']}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'has_suffix'}; {'id': '53', 'type': 'block', 'children': ['54']}; {'id': '54', 'type': 'continue_statement', 'children': []}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '59', 'type': 'while_statement', 'children': ['60', '61']}; {'id': '60', 'type': 'True', 'children': []}; {'id': '61', 'type': 'block', 'children': ['62', '85']}; {'id': '62', 'type': 'if_statement', 'children': ['63', '67', '77']}; {'id': '63', 'type': 'not_operator', 'children': ['64']}; {'id': '64', 'type': 'attribute', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'has_suffix'}; {'id': '67', 'type': 'block', 'children': ['68', '76']}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '73']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '73', 'type': 'attribute', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '76', 'type': 'break_statement', 'children': []}; {'id': '77', 'type': 'else_clause', 'children': ['78']}; {'id': '78', 'type': 'block', 'children': ['79']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '85', 'type': 'if_statement', 'children': ['86', '91']}; {'id': '86', 'type': 'comparison_operator', 'children': ['87', '90'], 'value': 'in'}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'uplink'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '91', 'type': 'block', 'children': ['92', '102']}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '97']}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '97', 'type': 'subscript', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'uplink'}; {'id': '102', 'type': 'break_statement', 'children': []}; {'id': '103', 'type': 'expression_statement', 'children': ['104']}; {'id': '104', 'type': 'assignment', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '109', 'type': 'while_statement', 'children': ['110', '118']}; {'id': '110', 'type': 'boolean_operator', 'children': ['111', '115'], 'value': 'and'}; {'id': '111', 'type': 'not_operator', 'children': ['112']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'has_value'}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'has_suffix'}; {'id': '118', 'type': 'block', 'children': ['119']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'assignment', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '122', 'type': 'attribute', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '125', 'type': 'if_statement', 'children': ['126', '129']}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'suffix'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'has_value'}; {'id': '129', 'type': 'block', 'children': ['130']}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'assignment', 'children': ['132', '135']}; {'id': '132', 'type': 'attribute', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'dict_suffix'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'suffix'}
Sets all suffix links in all nodes in this trie.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_write_mo'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '27', '31', '35', '73', '84', '216', '270', '297', '301']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'classNotFound'}; {'id': '9', 'type': 'False', 'children': []}; {'id': '10', 'type': 'if_statement', 'children': ['11', '22']}; {'id': '11', 'type': '()', 'children': ['12']}; {'id': '12', 'type': 'comparison_operator', 'children': ['13', '21'], 'value': '=='}; {'id': '13', 'type': 'call', 'children': ['14', '17']}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'FindClassIdInMoMetaIgnoreCase'}; {'id': '17', 'type': 'argument_list', 'children': ['18']}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '21', 'type': 'None', 'children': []}; {'id': '22', 'type': 'block', 'children': ['23']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'classNotFound'}; {'id': '26', 'type': 'True', 'children': []}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'tabsize'}; {'id': '30', 'type': 'integer', 'children': [], 'value': '8'}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '34', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '35', 'type': 'if_statement', 'children': ['36', '37', '56']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'classNotFound'}; {'id': '37', 'type': 'block', 'children': ['38']}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'augmented_assignment', 'children': ['40', '41'], 'value': '+='}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '41', 'type': 'binary_operator', 'children': ['42', '55'], 'value': '+'}; {'id': '42', 'type': 'binary_operator', 'children': ['43', '44'], 'value': '+'}; {'id': '43', 'type': 'string', 'children': [], 'value': '"Managed Object\\t\\t\\t:\\t"'}; {'id': '44', 'type': 'call', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '46', 'type': 'argument_list', 'children': ['47']}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '55', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '56', 'type': 'else_clause', 'children': ['57']}; {'id': '57', 'type': 'block', 'children': ['58']}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'augmented_assignment', 'children': ['60', '61'], 'value': '+='}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '61', 'type': 'binary_operator', 'children': ['62', '72'], 'value': '+'}; {'id': '62', 'type': 'binary_operator', 'children': ['63', '64'], 'value': '+'}; {'id': '63', 'type': 'string', 'children': [], 'value': '"Managed Object\\t\\t\\t:\\t"'}; {'id': '64', 'type': 'call', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'attribute', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'propMoMeta'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '72', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'augmented_assignment', 'children': ['75', '76'], 'value': '+='}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '76', 'type': 'binary_operator', 'children': ['77', '83'], 'value': '+'}; {'id': '77', 'type': 'binary_operator', 'children': ['78', '79'], 'value': '*'}; {'id': '78', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '79', 'type': 'call', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '81', 'type': 'argument_list', 'children': ['82']}; {'id': '82', 'type': 'string', 'children': [], 'value': '"Managed Object"'}; {'id': '83', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '84', 'type': 'if_statement', 'children': ['85', '88', '159']}; {'id': '85', 'type': '()', 'children': ['86']}; {'id': '86', 'type': 'not_operator', 'children': ['87']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'classNotFound'}; {'id': '88', 'type': 'block', 'children': ['89']}; {'id': '89', 'type': 'for_statement', 'children': ['90', '91', '101']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '91', 'type': 'call', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'GetUcsPropertyMetaAttributeList'}; {'id': '95', 'type': 'argument_list', 'children': ['96']}; {'id': '96', 'type': 'attribute', 'children': ['97', '100']}; {'id': '97', 'type': 'attribute', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'propMoMeta'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '101', 'type': 'block', 'children': ['102', '116', '127', '136']}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'assignment', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'propMeta'}; {'id': '105', 'type': 'call', 'children': ['106', '109']}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'GetUcsPropertyMeta'}; {'id': '109', 'type': 'argument_list', 'children': ['110', '115']}; {'id': '110', 'type': 'attribute', 'children': ['111', '114']}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'propMoMeta'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '116', 'type': 'if_statement', 'children': ['117', '125']}; {'id': '117', 'type': '()', 'children': ['118']}; {'id': '118', 'type': 'comparison_operator', 'children': ['119', '122'], 'value': '=='}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'propMeta'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'access'}; {'id': '122', 'type': 'attribute', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'UcsPropertyMeta'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'Internal'}; {'id': '125', 'type': 'block', 'children': ['126']}; {'id': '126', 'type': 'continue_statement', 'children': []}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '130', 'type': 'call', 'children': ['131', '134']}; {'id': '131', 'type': 'attribute', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '136', 'type': 'expression_statement', 'children': ['137']}; {'id': '137', 'type': 'augmented_assignment', 'children': ['138', '139'], 'value': '+='}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '139', 'type': 'binary_operator', 'children': ['140', '158'], 'value': '+'}; {'id': '140', 'type': 'binary_operator', 'children': ['141', '154'], 'value': '+'}; {'id': '141', 'type': 'binary_operator', 'children': ['142', '153'], 'value': '+'}; {'id': '142', 'type': 'call', 'children': ['143', '149']}; {'id': '143', 'type': 'attribute', 'children': ['144', '148']}; {'id': '144', 'type': 'call', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '146', 'type': 'argument_list', 'children': ['147']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'ljust'}; {'id': '149', 'type': 'argument_list', 'children': ['150']}; {'id': '150', 'type': 'binary_operator', 'children': ['151', '152'], 'value': '*'}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'tabsize'}; {'id': '152', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '153', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '154', 'type': 'call', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '156', 'type': 'argument_list', 'children': ['157']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '158', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '159', 'type': 'else_clause', 'children': ['160']}; {'id': '160', 'type': 'block', 'children': ['161']}; {'id': '161', 'type': 'for_statement', 'children': ['162', '163', '166']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '166', 'type': 'block', 'children': ['167', '180', '188']}; {'id': '167', 'type': 'if_statement', 'children': ['168', '178']}; {'id': '168', 'type': '()', 'children': ['169']}; {'id': '169', 'type': 'comparison_operator', 'children': ['170', '171'], 'value': 'in'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '171', 'type': 'list', 'children': ['172', '173', '174', '175', '176', '177'], 'value': "['classId', 'XtraProperty', 'handle', 'propMoMeta', 'dirtyMask', 'child']"}; {'id': '172', 'type': 'string', 'children': [], 'value': "'classId'"}; {'id': '173', 'type': 'string', 'children': [], 'value': "'XtraProperty'"}; {'id': '174', 'type': 'string', 'children': [], 'value': "'handle'"}; {'id': '175', 'type': 'string', 'children': [], 'value': "'propMoMeta'"}; {'id': '176', 'type': 'string', 'children': [], 'value': "'dirtyMask'"}; {'id': '177', 'type': 'string', 'children': [], 'value': "'child'"}; {'id': '178', 'type': 'block', 'children': ['179']}; {'id': '179', 'type': 'continue_statement', 'children': []}; {'id': '180', 'type': 'expression_statement', 'children': ['181']}; {'id': '181', 'type': 'assignment', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '183', 'type': 'subscript', 'children': ['184', '187']}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'augmented_assignment', 'children': ['190', '191'], 'value': '+='}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '191', 'type': 'binary_operator', 'children': ['192', '215'], 'value': '+'}; {'id': '192', 'type': 'binary_operator', 'children': ['193', '211'], 'value': '+'}; {'id': '193', 'type': 'binary_operator', 'children': ['194', '210'], 'value': '+'}; {'id': '194', 'type': 'call', 'children': ['195', '206']}; {'id': '195', 'type': 'attribute', 'children': ['196', '205']}; {'id': '196', 'type': 'call', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '198', 'type': 'argument_list', 'children': ['199']}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'prop'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'ljust'}; {'id': '206', 'type': 'argument_list', 'children': ['207']}; {'id': '207', 'type': 'binary_operator', 'children': ['208', '209'], 'value': '*'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'tabsize'}; {'id': '209', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '210', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '211', 'type': 'call', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '213', 'type': 'argument_list', 'children': ['214']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '215', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '216', 'type': 'if_statement', 'children': ['217', '225']}; {'id': '217', 'type': 'call', 'children': ['218', '223']}; {'id': '218', 'type': 'attribute', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'has_key'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'string', 'children': [], 'value': "'XtraProperty'"}; {'id': '225', 'type': 'block', 'children': ['226']}; {'id': '226', 'type': 'for_statement', 'children': ['227', '228', '233']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'xtraProp'}; {'id': '228', 'type': 'subscript', 'children': ['229', '232']}; {'id': '229', 'type': 'attribute', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '232', 'type': 'string', 'children': [], 'value': "'XtraProperty'"}; {'id': '233', 'type': 'block', 'children': ['234']}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'augmented_assignment', 'children': ['236', '237'], 'value': '+='}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '237', 'type': 'binary_operator', 'children': ['238', '269'], 'value': '+'}; {'id': '238', 'type': 'binary_operator', 'children': ['239', '259'], 'value': '+'}; {'id': '239', 'type': 'binary_operator', 'children': ['240', '258'], 'value': '+'}; {'id': '240', 'type': 'binary_operator', 'children': ['241', '242'], 'value': '+'}; {'id': '241', 'type': 'string', 'children': [], 'value': "'[X]'"}; {'id': '242', 'type': 'call', 'children': ['243', '254']}; {'id': '243', 'type': 'attribute', 'children': ['244', '253']}; {'id': '244', 'type': 'call', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '246', 'type': 'argument_list', 'children': ['247']}; {'id': '247', 'type': 'call', 'children': ['248', '251']}; {'id': '248', 'type': 'attribute', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '251', 'type': 'argument_list', 'children': ['252']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'xtraProp'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'ljust'}; {'id': '254', 'type': 'argument_list', 'children': ['255']}; {'id': '255', 'type': 'binary_operator', 'children': ['256', '257'], 'value': '*'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'tabsize'}; {'id': '257', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '258', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '259', 'type': 'call', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '261', 'type': 'argument_list', 'children': ['262']}; {'id': '262', 'type': 'subscript', 'children': ['263', '268']}; {'id': '263', 'type': 'subscript', 'children': ['264', '267']}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '267', 'type': 'string', 'children': [], 'value': "'XtraProperty'"}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'xtraProp'}; {'id': '269', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '270', 'type': 'expression_statement', 'children': ['271']}; {'id': '271', 'type': 'augmented_assignment', 'children': ['272', '273'], 'value': '+='}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '273', 'type': 'binary_operator', 'children': ['274', '296'], 'value': '+'}; {'id': '274', 'type': 'binary_operator', 'children': ['275', '288'], 'value': '+'}; {'id': '275', 'type': 'binary_operator', 'children': ['276', '287'], 'value': '+'}; {'id': '276', 'type': 'call', 'children': ['277', '283']}; {'id': '277', 'type': 'attribute', 'children': ['278', '282']}; {'id': '278', 'type': 'call', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '280', 'type': 'argument_list', 'children': ['281']}; {'id': '281', 'type': 'string', 'children': [], 'value': '"Ucs"'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'ljust'}; {'id': '283', 'type': 'argument_list', 'children': ['284']}; {'id': '284', 'type': 'binary_operator', 'children': ['285', '286'], 'value': '*'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'tabsize'}; {'id': '286', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '287', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '288', 'type': 'call', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '290', 'type': 'argument_list', 'children': ['291']}; {'id': '291', 'type': 'attribute', 'children': ['292', '295']}; {'id': '292', 'type': 'attribute', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'mo'}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'handle'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': '_ucs'}; {'id': '296', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '297', 'type': 'expression_statement', 'children': ['298']}; {'id': '298', 'type': 'augmented_assignment', 'children': ['299', '300'], 'value': '+='}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'outstr'}; {'id': '300', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '301', 'type': 'return_statement', 'children': ['302']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'outstr'}
Method to return string representation of a managed object.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'LoadFromXml'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'handle'}; {'id': '7', 'type': 'block', 'children': ['8', '15', '183']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'call', 'children': ['10', '13']}; {'id': '10', 'type': 'attribute', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'SetHandle'}; {'id': '13', 'type': 'argument_list', 'children': ['14']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'handle'}; {'id': '15', 'type': 'if_statement', 'children': ['16', '21']}; {'id': '16', 'type': 'call', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'hasAttributes'}; {'id': '20', 'type': 'argument_list', 'children': []}; {'id': '21', 'type': 'block', 'children': ['22', '28', '35', '141']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'attributes'}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'attributes'}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'attCount'}; {'id': '31', 'type': 'call', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'attributes'}; {'id': '35', 'type': 'for_statement', 'children': ['36', '37', '41']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '37', 'type': 'call', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '39', 'type': 'argument_list', 'children': ['40']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'attCount'}; {'id': '41', 'type': 'block', 'children': ['42', '51', '62']}; {'id': '42', 'type': 'expression_statement', 'children': ['43']}; {'id': '43', 'type': 'assignment', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'attNode'}; {'id': '45', 'type': 'call', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'attributes'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '49', 'type': 'argument_list', 'children': ['50']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '54', 'type': 'call', 'children': ['55', '58']}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '58', 'type': 'argument_list', 'children': ['59']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'attNode'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'localName'}; {'id': '62', 'type': 'if_statement', 'children': ['63', '74', '121']}; {'id': '63', 'type': '()', 'children': ['64']}; {'id': '64', 'type': 'comparison_operator', 'children': ['65', '73'], 'value': '!='}; {'id': '65', 'type': 'call', 'children': ['66', '69']}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'FindClassIdInMoMetaIgnoreCase'}; {'id': '69', 'type': 'argument_list', 'children': ['70']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '73', 'type': 'None', 'children': []}; {'id': '74', 'type': 'block', 'children': ['75']}; {'id': '75', 'type': 'if_statement', 'children': ['76', '87', '101']}; {'id': '76', 'type': '()', 'children': ['77']}; {'id': '77', 'type': 'comparison_operator', 'children': ['78', '79'], 'value': 'in'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'GetUcsPropertyMetaAttributeList'}; {'id': '83', 'type': 'argument_list', 'children': ['84']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '87', 'type': 'block', 'children': ['88']}; {'id': '88', 'type': 'expression_statement', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'setattr'}; {'id': '93', 'type': 'argument_list', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '95', 'type': 'call', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '97', 'type': 'argument_list', 'children': ['98']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'attNode'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '101', 'type': 'else_clause', 'children': ['102']}; {'id': '102', 'type': 'block', 'children': ['103']}; {'id': '103', 'type': 'expression_statement', 'children': ['104']}; {'id': '104', 'type': 'call', 'children': ['105', '108']}; {'id': '105', 'type': 'attribute', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'setattr'}; {'id': '108', 'type': 'argument_list', 'children': ['109', '115']}; {'id': '109', 'type': 'call', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '113', 'type': 'argument_list', 'children': ['114']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '115', 'type': 'call', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '117', 'type': 'argument_list', 'children': ['118']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'attNode'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '121', 'type': 'else_clause', 'children': ['122']}; {'id': '122', 'type': 'block', 'children': ['123']}; {'id': '123', 'type': 'expression_statement', 'children': ['124']}; {'id': '124', 'type': 'call', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'setattr'}; {'id': '128', 'type': 'argument_list', 'children': ['129', '135']}; {'id': '129', 'type': 'call', 'children': ['130', '133']}; {'id': '130', 'type': 'attribute', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '133', 'type': 'argument_list', 'children': ['134']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'attr'}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'attNode'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '141', 'type': 'if_statement', 'children': ['142', '159']}; {'id': '142', 'type': 'boolean_operator', 'children': ['143', '151'], 'value': 'and'}; {'id': '143', 'type': 'comparison_operator', 'children': ['144', '150'], 'value': '=='}; {'id': '144', 'type': 'call', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'string', 'children': [], 'value': '"Rn"'}; {'id': '150', 'type': 'None', 'children': []}; {'id': '151', 'type': 'comparison_operator', 'children': ['152', '158'], 'value': '!='}; {'id': '152', 'type': 'call', 'children': ['153', '156']}; {'id': '153', 'type': 'attribute', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '156', 'type': 'argument_list', 'children': ['157']}; {'id': '157', 'type': 'string', 'children': [], 'value': '"Dn"'}; {'id': '158', 'type': 'None', 'children': []}; {'id': '159', 'type': 'block', 'children': ['160']}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'call', 'children': ['162', '165']}; {'id': '162', 'type': 'attribute', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'setattr'}; {'id': '165', 'type': 'argument_list', 'children': ['166', '167']}; {'id': '166', 'type': 'string', 'children': [], 'value': '"Rn"'}; {'id': '167', 'type': 'call', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'call', 'children': ['171', '174']}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '174', 'type': 'argument_list', 'children': ['175', '176', '177']}; {'id': '175', 'type': 'string', 'children': [], 'value': "r'^.*/'"}; {'id': '176', 'type': 'string', 'children': [], 'value': "''"}; {'id': '177', 'type': 'call', 'children': ['178', '181']}; {'id': '178', 'type': 'attribute', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '181', 'type': 'argument_list', 'children': ['182']}; {'id': '182', 'type': 'string', 'children': [], 'value': '"Dn"'}; {'id': '183', 'type': 'if_statement', 'children': ['184', '190']}; {'id': '184', 'type': '()', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '189']}; {'id': '186', 'type': 'attribute', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'hasChildNodes'}; {'id': '189', 'type': 'argument_list', 'children': []}; {'id': '190', 'type': 'block', 'children': ['191', '197', '204']}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'childList'}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'node'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'childNodes'}; {'id': '197', 'type': 'expression_statement', 'children': ['198']}; {'id': '198', 'type': 'assignment', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'childCount'}; {'id': '200', 'type': 'call', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '202', 'type': 'argument_list', 'children': ['203']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'childList'}; {'id': '204', 'type': 'for_statement', 'children': ['205', '206', '210']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '206', 'type': 'call', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'childCount'}; {'id': '210', 'type': 'block', 'children': ['211', '220', '231', '243', '257', '266']}; {'id': '211', 'type': 'expression_statement', 'children': ['212']}; {'id': '212', 'type': 'assignment', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'childNode'}; {'id': '214', 'type': 'call', 'children': ['215', '218']}; {'id': '215', 'type': 'attribute', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'childList'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '218', 'type': 'argument_list', 'children': ['219']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '220', 'type': 'if_statement', 'children': ['221', '229']}; {'id': '221', 'type': '()', 'children': ['222']}; {'id': '222', 'type': 'comparison_operator', 'children': ['223', '226'], 'value': '!='}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'childNode'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'nodeType'}; {'id': '226', 'type': 'attribute', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'Node'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'ELEMENT_NODE'}; {'id': '229', 'type': 'block', 'children': ['230']}; {'id': '230', 'type': 'continue_statement', 'children': []}; {'id': '231', 'type': 'if_statement', 'children': ['232', '241']}; {'id': '232', 'type': 'comparison_operator', 'children': ['233', '236'], 'value': 'in'}; {'id': '233', 'type': 'attribute', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'childNode'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'localName'}; {'id': '236', 'type': 'attribute', 'children': ['237', '240']}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'propMoMeta'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'fieldNames'}; {'id': '241', 'type': 'block', 'children': ['242']}; {'id': '242', 'type': 'pass_statement', 'children': []}; {'id': '243', 'type': 'expression_statement', 'children': ['244']}; {'id': '244', 'type': 'assignment', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '246', 'type': 'call', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'ManagedObject'}; {'id': '248', 'type': 'argument_list', 'children': ['249']}; {'id': '249', 'type': 'call', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'WordU'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'attribute', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'childNode'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'localName'}; {'id': '257', 'type': 'expression_statement', 'children': ['258']}; {'id': '258', 'type': 'call', 'children': ['259', '264']}; {'id': '259', 'type': 'attribute', 'children': ['260', '263']}; {'id': '260', 'type': 'attribute', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '264', 'type': 'argument_list', 'children': ['265']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '266', 'type': 'expression_statement', 'children': ['267']}; {'id': '267', 'type': 'call', 'children': ['268', '271']}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'LoadFromXml'}; {'id': '271', 'type': 'argument_list', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'childNode'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'handle'}
Method updates the object from the xml representation of the managed object.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '4']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'GetJavaInstallationPath'}; {'id': '3', 'type': 'parameters', 'children': []}; {'id': '4', 'type': 'block', 'children': ['5', '10']}; {'id': '5', 'type': 'import_statement', 'children': ['6', '8']}; {'id': '6', 'type': 'dotted_name', 'children': ['7']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '8', 'type': 'dotted_name', 'children': ['9']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'platform'}; {'id': '10', 'type': 'if_statement', 'children': ['11', '18', '85']}; {'id': '11', 'type': 'comparison_operator', 'children': ['12', '17'], 'value': '=='}; {'id': '12', 'type': 'call', 'children': ['13', '16']}; {'id': '13', 'type': 'attribute', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'platform'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'system'}; {'id': '16', 'type': 'argument_list', 'children': []}; {'id': '17', 'type': 'string', 'children': [], 'value': '"Linux"'}; {'id': '18', 'type': 'block', 'children': ['19', '30']}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'assignment', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '22', 'type': 'call', 'children': ['23', '28']}; {'id': '23', 'type': 'attribute', 'children': ['24', '27']}; {'id': '24', 'type': 'attribute', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '28', 'type': 'argument_list', 'children': ['29']}; {'id': '29', 'type': 'string', 'children': [], 'value': "'JAVA_HOME'"}; {'id': '30', 'type': 'if_statement', 'children': ['31', '33', '39']}; {'id': '31', 'type': 'not_operator', 'children': ['32']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'raise_statement', 'children': ['35']}; {'id': '35', 'type': 'call', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'UcsValidationException'}; {'id': '37', 'type': 'argument_list', 'children': ['38']}; {'id': '38', 'type': 'string', 'children': [], 'value': '"Please make sure JAVA is installed and variable JAVA_HOME is set properly."'}; {'id': '39', 'type': 'else_clause', 'children': ['40']}; {'id': '40', 'type': 'block', 'children': ['41', '53', '65']}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'assignment', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '44', 'type': 'call', 'children': ['45', '50']}; {'id': '45', 'type': 'attribute', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '50', 'type': 'argument_list', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '52', 'type': 'string', 'children': [], 'value': "'bin'"}; {'id': '53', 'type': 'expression_statement', 'children': ['54']}; {'id': '54', 'type': 'assignment', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '56', 'type': 'call', 'children': ['57', '62']}; {'id': '57', 'type': 'attribute', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '62', 'type': 'argument_list', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '64', 'type': 'string', 'children': [], 'value': "'javaws'"}; {'id': '65', 'type': 'if_statement', 'children': ['66', '75', '81']}; {'id': '66', 'type': 'not_operator', 'children': ['67']}; {'id': '67', 'type': 'call', 'children': ['68', '73']}; {'id': '68', 'type': 'attribute', 'children': ['69', '72']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'exists'}; {'id': '73', 'type': 'argument_list', 'children': ['74']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '75', 'type': 'block', 'children': ['76']}; {'id': '76', 'type': 'raise_statement', 'children': ['77']}; {'id': '77', 'type': 'call', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'UcsValidationException'}; {'id': '79', 'type': 'argument_list', 'children': ['80']}; {'id': '80', 'type': 'string', 'children': [], 'value': '"javaws is not installed on System."'}; {'id': '81', 'type': 'else_clause', 'children': ['82']}; {'id': '82', 'type': 'block', 'children': ['83']}; {'id': '83', 'type': 'return_statement', 'children': ['84']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '85', 'type': 'elif_clause', 'children': ['86', '101']}; {'id': '86', 'type': 'boolean_operator', 'children': ['87', '94'], 'value': 'or'}; {'id': '87', 'type': 'comparison_operator', 'children': ['88', '93'], 'value': '=='}; {'id': '88', 'type': 'call', 'children': ['89', '92']}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'platform'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'system'}; {'id': '92', 'type': 'argument_list', 'children': []}; {'id': '93', 'type': 'string', 'children': [], 'value': '"Windows"'}; {'id': '94', 'type': 'comparison_operator', 'children': ['95', '100'], 'value': '=='}; {'id': '95', 'type': 'call', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'platform'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'system'}; {'id': '99', 'type': 'argument_list', 'children': []}; {'id': '100', 'type': 'string', 'children': [], 'value': '"Microsoft"'}; {'id': '101', 'type': 'block', 'children': ['102', '113', '127', '141']}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'assignment', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '105', 'type': 'call', 'children': ['106', '111']}; {'id': '106', 'type': 'attribute', 'children': ['107', '110']}; {'id': '107', 'type': 'attribute', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '111', 'type': 'argument_list', 'children': ['112']}; {'id': '112', 'type': 'string', 'children': [], 'value': "'JAVA_HOME'"}; {'id': '113', 'type': 'if_statement', 'children': ['114', '117']}; {'id': '114', 'type': 'comparison_operator', 'children': ['115', '116'], 'value': '=='}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '116', 'type': 'None', 'children': []}; {'id': '117', 'type': 'block', 'children': ['118']}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'assignment', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '121', 'type': 'call', 'children': ['122', '125']}; {'id': '122', 'type': 'attribute', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'CheckRegistryKey'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'string', 'children': [], 'value': 'r"SOFTWARE\\\\JavaSoft\\\\Java Runtime Environment\\\\"'}; {'id': '127', 'type': 'if_statement', 'children': ['128', '131']}; {'id': '128', 'type': 'comparison_operator', 'children': ['129', '130'], 'value': '=='}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '130', 'type': 'None', 'children': []}; {'id': '131', 'type': 'block', 'children': ['132']}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'assignment', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'UcsUtils'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'CheckRegistryKey'}; {'id': '139', 'type': 'argument_list', 'children': ['140']}; {'id': '140', 'type': 'string', 'children': [], 'value': 'r"SOFTWARE\\\\Wow6432Node\\\\JavaSoft\\\\Java Runtime Environment"'}; {'id': '141', 'type': 'if_statement', 'children': ['142', '144', '150']}; {'id': '142', 'type': 'not_operator', 'children': ['143']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '144', 'type': 'block', 'children': ['145']}; {'id': '145', 'type': 'raise_statement', 'children': ['146']}; {'id': '146', 'type': 'call', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'UcsValidationException'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'string', 'children': [], 'value': '"Please make sure JAVA is installed."'}; {'id': '150', 'type': 'else_clause', 'children': ['151']}; {'id': '151', 'type': 'block', 'children': ['152', '164', '176']}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'assignment', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '155', 'type': 'call', 'children': ['156', '161']}; {'id': '156', 'type': 'attribute', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '161', 'type': 'argument_list', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '163', 'type': 'string', 'children': [], 'value': "'bin'"}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '167', 'type': 'call', 'children': ['168', '173']}; {'id': '168', 'type': 'attribute', 'children': ['169', '172']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '173', 'type': 'argument_list', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '175', 'type': 'string', 'children': [], 'value': "'javaws.exe'"}; {'id': '176', 'type': 'if_statement', 'children': ['177', '186', '192']}; {'id': '177', 'type': 'not_operator', 'children': ['178']}; {'id': '178', 'type': 'call', 'children': ['179', '184']}; {'id': '179', 'type': 'attribute', 'children': ['180', '183']}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'exists'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '186', 'type': 'block', 'children': ['187']}; {'id': '187', 'type': 'raise_statement', 'children': ['188']}; {'id': '188', 'type': 'call', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'UcsValidationException'}; {'id': '190', 'type': 'argument_list', 'children': ['191']}; {'id': '191', 'type': 'string', 'children': [], 'value': '"javaws.exe is not installed on System."'}; {'id': '192', 'type': 'else_clause', 'children': ['193']}; {'id': '193', 'type': 'block', 'children': ['194']}; {'id': '194', 'type': 'return_statement', 'children': ['195']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'path'}
Method returns the java installation path in the windows or Linux environment.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'GetSyncMoConfig'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'ConfigDoc'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '19', '245']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'moConfigMap'}; {'id': '9', 'type': 'dictionary', 'children': []}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'configList'}; {'id': '13', 'type': 'call', 'children': ['14', '17']}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'ConfigDoc'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'getElementsByTagName'}; {'id': '17', 'type': 'argument_list', 'children': ['18']}; {'id': '18', 'type': 'string', 'children': [], 'value': '"mo"'}; {'id': '19', 'type': 'for_statement', 'children': ['20', '21', '22']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'configList'}; {'id': '22', 'type': 'block', 'children': ['23', '27', '31', '35', '39', '43', '47', '51', '55', '72', '89', '106', '123', '140', '157', '174', '191', '195', '212']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '26', 'type': 'None', 'children': []}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'noun'}; {'id': '30', 'type': 'None', 'children': []}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '34', 'type': 'None', 'children': []}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'actionVersion'}; {'id': '38', 'type': 'None', 'children': []}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '42', 'type': 'None', 'children': []}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'assignment', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'ignoreReason'}; {'id': '46', 'type': 'None', 'children': []}; {'id': '47', 'type': 'expression_statement', 'children': ['48']}; {'id': '48', 'type': 'assignment', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'status'}; {'id': '50', 'type': 'None', 'children': []}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'excludeList'}; {'id': '54', 'type': 'None', 'children': []}; {'id': '55', 'type': 'if_statement', 'children': ['56', '62']}; {'id': '56', 'type': 'call', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '60', 'type': 'argument_list', 'children': ['61']}; {'id': '61', 'type': 'string', 'children': [], 'value': '"classid"'}; {'id': '62', 'type': 'block', 'children': ['63']}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'assignment', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '66', 'type': 'call', 'children': ['67', '70']}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '70', 'type': 'argument_list', 'children': ['71']}; {'id': '71', 'type': 'string', 'children': [], 'value': '"classid"'}; {'id': '72', 'type': 'if_statement', 'children': ['73', '79']}; {'id': '73', 'type': 'call', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'string', 'children': [], 'value': '"noun"'}; {'id': '79', 'type': 'block', 'children': ['80']}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'noun'}; {'id': '83', 'type': 'call', 'children': ['84', '87']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '87', 'type': 'argument_list', 'children': ['88']}; {'id': '88', 'type': 'string', 'children': [], 'value': '"noun"'}; {'id': '89', 'type': 'if_statement', 'children': ['90', '96']}; {'id': '90', 'type': 'call', 'children': ['91', '94']}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '94', 'type': 'argument_list', 'children': ['95']}; {'id': '95', 'type': 'string', 'children': [], 'value': '"version"'}; {'id': '96', 'type': 'block', 'children': ['97']}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '100', 'type': 'call', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'string', 'children': [], 'value': '"version"'}; {'id': '106', 'type': 'if_statement', 'children': ['107', '113']}; {'id': '107', 'type': 'call', 'children': ['108', '111']}; {'id': '108', 'type': 'attribute', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '111', 'type': 'argument_list', 'children': ['112']}; {'id': '112', 'type': 'string', 'children': [], 'value': '"actionVersion"'}; {'id': '113', 'type': 'block', 'children': ['114']}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'actionVersion'}; {'id': '117', 'type': 'call', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '121', 'type': 'argument_list', 'children': ['122']}; {'id': '122', 'type': 'string', 'children': [], 'value': '"actionVersion"'}; {'id': '123', 'type': 'if_statement', 'children': ['124', '130']}; {'id': '124', 'type': 'call', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '128', 'type': 'argument_list', 'children': ['129']}; {'id': '129', 'type': 'string', 'children': [], 'value': '"action"'}; {'id': '130', 'type': 'block', 'children': ['131']}; {'id': '131', 'type': 'expression_statement', 'children': ['132']}; {'id': '132', 'type': 'assignment', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '134', 'type': 'call', 'children': ['135', '138']}; {'id': '135', 'type': 'attribute', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '138', 'type': 'argument_list', 'children': ['139']}; {'id': '139', 'type': 'string', 'children': [], 'value': '"action"'}; {'id': '140', 'type': 'if_statement', 'children': ['141', '147']}; {'id': '141', 'type': 'call', 'children': ['142', '145']}; {'id': '142', 'type': 'attribute', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '145', 'type': 'argument_list', 'children': ['146']}; {'id': '146', 'type': 'string', 'children': [], 'value': '"ignoreReason"'}; {'id': '147', 'type': 'block', 'children': ['148']}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'assignment', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'ignoreReason'}; {'id': '151', 'type': 'call', 'children': ['152', '155']}; {'id': '152', 'type': 'attribute', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '155', 'type': 'argument_list', 'children': ['156']}; {'id': '156', 'type': 'string', 'children': [], 'value': '"ignoreReason"'}; {'id': '157', 'type': 'if_statement', 'children': ['158', '164']}; {'id': '158', 'type': 'call', 'children': ['159', '162']}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '162', 'type': 'argument_list', 'children': ['163']}; {'id': '163', 'type': 'string', 'children': [], 'value': '"status"'}; {'id': '164', 'type': 'block', 'children': ['165']}; {'id': '165', 'type': 'expression_statement', 'children': ['166']}; {'id': '166', 'type': 'assignment', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'status'}; {'id': '168', 'type': 'call', 'children': ['169', '172']}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '172', 'type': 'argument_list', 'children': ['173']}; {'id': '173', 'type': 'string', 'children': [], 'value': '"status"'}; {'id': '174', 'type': 'if_statement', 'children': ['175', '181']}; {'id': '175', 'type': 'call', 'children': ['176', '179']}; {'id': '176', 'type': 'attribute', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'hasAttribute'}; {'id': '179', 'type': 'argument_list', 'children': ['180']}; {'id': '180', 'type': 'string', 'children': [], 'value': '"excludeList"'}; {'id': '181', 'type': 'block', 'children': ['182']}; {'id': '182', 'type': 'expression_statement', 'children': ['183']}; {'id': '183', 'type': 'assignment', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'excludeList'}; {'id': '185', 'type': 'call', 'children': ['186', '189']}; {'id': '186', 'type': 'attribute', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'moConfigNode'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'getAttribute'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'string', 'children': [], 'value': '"excludeList"'}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'moConfig'}; {'id': '194', 'type': 'None', 'children': []}; {'id': '195', 'type': 'if_statement', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '197', 'type': 'block', 'children': ['198']}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'assignment', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'moConfig'}; {'id': '201', 'type': 'call', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'SyncMoConfig'}; {'id': '203', 'type': 'argument_list', 'children': ['204', '205', '206', '207', '208', '209', '210', '211']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'noun'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'actionVersion'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'ignoreReason'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'status'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'excludeList'}; {'id': '212', 'type': 'if_statement', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'moConfig'}; {'id': '214', 'type': 'block', 'children': ['215']}; {'id': '215', 'type': 'if_statement', 'children': ['216', '219', '226']}; {'id': '216', 'type': 'comparison_operator', 'children': ['217', '218'], 'value': 'in'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'moConfigMap'}; {'id': '219', 'type': 'block', 'children': ['220']}; {'id': '220', 'type': 'expression_statement', 'children': ['221']}; {'id': '221', 'type': 'assignment', 'children': ['222', '225']}; {'id': '222', 'type': 'subscript', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'moConfigMap'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'moConfig'}; {'id': '226', 'type': 'else_clause', 'children': ['227']}; {'id': '227', 'type': 'block', 'children': ['228', '232', '239']}; {'id': '228', 'type': 'expression_statement', 'children': ['229']}; {'id': '229', 'type': 'assignment', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'moConfigList'}; {'id': '231', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '232', 'type': 'expression_statement', 'children': ['233']}; {'id': '233', 'type': 'call', 'children': ['234', '237']}; {'id': '234', 'type': 'attribute', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'moConfigList'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '237', 'type': 'argument_list', 'children': ['238']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'moConfig'}; {'id': '239', 'type': 'expression_statement', 'children': ['240']}; {'id': '240', 'type': 'assignment', 'children': ['241', '244']}; {'id': '241', 'type': 'subscript', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'moConfigMap'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'classId'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'moConfigList'}; {'id': '245', 'type': 'return_statement', 'children': ['246']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'moConfigMap'}
Internal support method for SyncManagedObject.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'select_configuration'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'obresult'}; {'id': '6', 'type': 'block', 'children': ['7', '16', '23', '31', '41']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '10', 'type': 'call', 'children': ['11', '14']}; {'id': '11', 'type': 'attribute', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'logging'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'getLogger'}; {'id': '14', 'type': 'argument_list', 'children': ['15']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': '__name__'}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'call', 'children': ['18', '21']}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '21', 'type': 'argument_list', 'children': ['22']}; {'id': '22', 'type': 'string', 'children': [], 'value': "'calling default configuration selector'"}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'obresult'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'get_sample_frame'}; {'id': '30', 'type': 'argument_list', 'children': []}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'extr'}; {'id': '34', 'type': 'subscript', 'children': ['35', '40']}; {'id': '35', 'type': 'attribute', 'children': ['36', '39']}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'datamodel'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'extractor_map'}; {'id': '40', 'type': 'string', 'children': [], 'value': "'fits'"}; {'id': '41', 'type': 'if_statement', 'children': ['42', '43', '180']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '43', 'type': 'block', 'children': ['44', '54', '111', '121']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'extr'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'extract'}; {'id': '51', 'type': 'argument_list', 'children': ['52', '53']}; {'id': '52', 'type': 'string', 'children': [], 'value': "'insconf'"}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '54', 'type': 'if_statement', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '56', 'type': 'block', 'children': ['57', '65']}; {'id': '57', 'type': 'expression_statement', 'children': ['58']}; {'id': '58', 'type': 'call', 'children': ['59', '62']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '62', 'type': 'argument_list', 'children': ['63', '64']}; {'id': '63', 'type': 'string', 'children': [], 'value': "'found insconf config uuid=%s'"}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '65', 'type': 'if_statement', 'children': ['66', '71', '78']}; {'id': '66', 'type': 'comparison_operator', 'children': ['67', '68'], 'value': 'in'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'configurations'}; {'id': '71', 'type': 'block', 'children': ['72']}; {'id': '72', 'type': 'return_statement', 'children': ['73']}; {'id': '73', 'type': 'subscript', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'configurations'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '78', 'type': 'else_clause', 'children': ['79']}; {'id': '79', 'type': 'block', 'children': ['80']}; {'id': '80', 'type': 'for_statement', 'children': ['81', '82', '89', '99']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '82', 'type': 'call', 'children': ['83', '88']}; {'id': '83', 'type': 'attribute', 'children': ['84', '87']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'configurations'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '88', 'type': 'argument_list', 'children': []}; {'id': '89', 'type': 'block', 'children': ['90']}; {'id': '90', 'type': 'if_statement', 'children': ['91', '96']}; {'id': '91', 'type': 'comparison_operator', 'children': ['92', '95'], 'value': '=='}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '96', 'type': 'block', 'children': ['97']}; {'id': '97', 'type': 'return_statement', 'children': ['98']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '99', 'type': 'else_clause', 'children': ['100']}; {'id': '100', 'type': 'block', 'children': ['101']}; {'id': '101', 'type': 'raise_statement', 'children': ['102']}; {'id': '102', 'type': 'call', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'KeyError'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'call', 'children': ['106', '109']}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'string', 'children': [], 'value': "'insconf {} does not match any config'"}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '109', 'type': 'argument_list', 'children': ['110']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'date_obs'}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'extr'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'extract'}; {'id': '118', 'type': 'argument_list', 'children': ['119', '120']}; {'id': '119', 'type': 'string', 'children': [], 'value': "'observation_date'"}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'ref'}; {'id': '121', 'type': 'for_statement', 'children': ['122', '125', '132']}; {'id': '122', 'type': 'pattern_list', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '125', 'type': 'call', 'children': ['126', '131']}; {'id': '126', 'type': 'attribute', 'children': ['127', '130']}; {'id': '127', 'type': 'attribute', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'configurations'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '131', 'type': 'argument_list', 'children': []}; {'id': '132', 'type': 'block', 'children': ['133', '139', '160']}; {'id': '133', 'type': 'if_statement', 'children': ['134', '137']}; {'id': '134', 'type': 'comparison_operator', 'children': ['135', '136'], 'value': '=='}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '136', 'type': 'string', 'children': [], 'value': "'default'"}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'continue_statement', 'children': []}; {'id': '139', 'type': 'if_statement', 'children': ['140', '145', '154']}; {'id': '140', 'type': 'comparison_operator', 'children': ['141', '144'], 'value': 'is'}; {'id': '141', 'type': 'attribute', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'date_end'}; {'id': '144', 'type': 'None', 'children': []}; {'id': '145', 'type': 'block', 'children': ['146']}; {'id': '146', 'type': 'expression_statement', 'children': ['147']}; {'id': '147', 'type': 'assignment', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'upper_t'}; {'id': '149', 'type': 'comparison_operator', 'children': ['150', '151'], 'value': '<'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'date_obs'}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'date_end'}; {'id': '154', 'type': 'else_clause', 'children': ['155']}; {'id': '155', 'type': 'block', 'children': ['156']}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'assignment', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'upper_t'}; {'id': '159', 'type': 'True', 'children': []}; {'id': '160', 'type': 'if_statement', 'children': ['161', '169']}; {'id': '161', 'type': 'boolean_operator', 'children': ['162', '163'], 'value': 'and'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'upper_t'}; {'id': '163', 'type': '()', 'children': ['164']}; {'id': '164', 'type': 'comparison_operator', 'children': ['165', '166'], 'value': '>='}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'date_obs'}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'date_start'}; {'id': '169', 'type': 'block', 'children': ['170', '178']}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '175', 'type': 'argument_list', 'children': ['176', '177']}; {'id': '176', 'type': 'string', 'children': [], 'value': "'found date match, config uuid=%s'"}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '178', 'type': 'return_statement', 'children': ['179']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'conf'}; {'id': '180', 'type': 'else_clause', 'children': ['181']}; {'id': '181', 'type': 'block', 'children': ['182', '189']}; {'id': '182', 'type': 'expression_statement', 'children': ['183']}; {'id': '183', 'type': 'call', 'children': ['184', '187']}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'string', 'children': [], 'value': "'no match, using default configuration'"}; {'id': '189', 'type': 'return_statement', 'children': ['190']}; {'id': '190', 'type': 'subscript', 'children': ['191', '194']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'configurations'}; {'id': '194', 'type': 'string', 'children': [], 'value': "'default'"}
Select instrument configuration based on OB
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'build_recipe_input'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'ob'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'dal'}; {'id': '7', 'type': 'block', 'children': ['8', '12', '16', '20', '157', '166', '172', '212', '261', '331']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '11', 'type': 'dictionary', 'children': []}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'ob_query_skip'}; {'id': '15', 'type': 'False', 'children': []}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'assignment', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'ob_query_field'}; {'id': '19', 'type': 'string', 'children': [], 'value': "'obresult'"}; {'id': '20', 'type': 'if_statement', 'children': ['21', '26', '151']}; {'id': '21', 'type': 'call', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '23', 'type': 'argument_list', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'ob'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'ObservingBlock'}; {'id': '26', 'type': 'block', 'children': ['27', '34']}; {'id': '27', 'type': 'import_statement', 'children': ['28']}; {'id': '28', 'type': 'aliased_import', 'children': ['29', '33']}; {'id': '29', 'type': 'dotted_name', 'children': ['30', '31', '32']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'numina'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'obsresult'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'obtype'}; {'id': '34', 'type': 'for_statement', 'children': ['35', '38', '47', '145']}; {'id': '35', 'type': 'pattern_list', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '38', 'type': 'call', 'children': ['39', '46']}; {'id': '39', 'type': 'attribute', 'children': ['40', '45']}; {'id': '40', 'type': 'call', 'children': ['41', '44']}; {'id': '41', 'type': 'attribute', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'requirements'}; {'id': '44', 'type': 'argument_list', 'children': []}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '46', 'type': 'argument_list', 'children': []}; {'id': '47', 'type': 'block', 'children': ['48']}; {'id': '48', 'type': 'if_statement', 'children': ['49', '58']}; {'id': '49', 'type': 'call', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '51', 'type': 'argument_list', 'children': ['52', '55']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'obtype'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'ObservationResultType'}; {'id': '58', 'type': 'block', 'children': ['59', '63', '67', '78', '84', '92', '105', '113', '144']}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'ob_query_field'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'assignment', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'ob_query_skip'}; {'id': '66', 'type': 'True', 'children': []}; {'id': '67', 'type': 'expression_statement', 'children': ['68']}; {'id': '68', 'type': 'assignment', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'query_option'}; {'id': '70', 'type': 'call', 'children': ['71', '76']}; {'id': '71', 'type': 'attribute', 'children': ['72', '75']}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'query_options'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '76', 'type': 'argument_list', 'children': ['77']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '78', 'type': 'expression_statement', 'children': ['79']}; {'id': '79', 'type': 'assignment', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'new_or'}; {'id': '81', 'type': 'call', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'ObservationResult'}; {'id': '83', 'type': 'argument_list', 'children': []}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '89']}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'new_or'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'ob'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '95', 'type': 'call', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '99', 'type': 'argument_list', 'children': ['100', '101', '102']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'dal'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'new_or'}; {'id': '102', 'type': 'keyword_argument', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'query_option'}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'tagger'}; {'id': '108', 'type': 'attribute', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'mode'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'tagger'}; {'id': '113', 'type': 'if_statement', 'children': ['114', '117', '136']}; {'id': '114', 'type': 'comparison_operator', 'children': ['115', '116'], 'value': 'is'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'tagger'}; {'id': '116', 'type': 'None', 'children': []}; {'id': '117', 'type': 'block', 'children': ['118', '127']}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'call', 'children': ['120', '125']}; {'id': '120', 'type': 'attribute', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'string', 'children': [], 'value': "'Use mode tagger to fill tags in OB'"}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '132', 'type': 'call', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'tagger'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '136', 'type': 'else_clause', 'children': ['137']}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'assignment', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '143', 'type': 'None', 'children': []}; {'id': '144', 'type': 'break_statement', 'children': []}; {'id': '145', 'type': 'else_clause', 'children': ['146']}; {'id': '146', 'type': 'block', 'children': ['147']}; {'id': '147', 'type': 'expression_statement', 'children': ['148']}; {'id': '148', 'type': 'assignment', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'ob'}; {'id': '151', 'type': 'else_clause', 'children': ['152']}; {'id': '152', 'type': 'block', 'children': ['153']}; {'id': '153', 'type': 'expression_statement', 'children': ['154']}; {'id': '154', 'type': 'assignment', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'ob'}; {'id': '157', 'type': 'expression_statement', 'children': ['158']}; {'id': '158', 'type': 'call', 'children': ['159', '164']}; {'id': '159', 'type': 'attribute', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '164', 'type': 'argument_list', 'children': ['165']}; {'id': '165', 'type': 'string', 'children': [], 'value': "'getting query fields per REQ'"}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'assignment', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'qfields'}; {'id': '169', 'type': 'call', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '171', 'type': 'argument_list', 'children': []}; {'id': '172', 'type': 'for_statement', 'children': ['173', '176', '185']}; {'id': '173', 'type': 'pattern_list', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '176', 'type': 'call', 'children': ['177', '184']}; {'id': '177', 'type': 'attribute', 'children': ['178', '183']}; {'id': '178', 'type': 'call', 'children': ['179', '182']}; {'id': '179', 'type': 'attribute', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'requirements'}; {'id': '182', 'type': 'argument_list', 'children': []}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '184', 'type': 'argument_list', 'children': []}; {'id': '185', 'type': 'block', 'children': ['186', '194', '205']}; {'id': '186', 'type': 'expression_statement', 'children': ['187']}; {'id': '187', 'type': 'assignment', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'tag_n'}; {'id': '189', 'type': 'call', 'children': ['190', '193']}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'tag_names'}; {'id': '193', 'type': 'argument_list', 'children': []}; {'id': '194', 'type': 'expression_statement', 'children': ['195']}; {'id': '195', 'type': 'call', 'children': ['196', '201']}; {'id': '196', 'type': 'attribute', 'children': ['197', '200']}; {'id': '197', 'type': 'attribute', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '201', 'type': 'argument_list', 'children': ['202', '203', '204']}; {'id': '202', 'type': 'string', 'children': [], 'value': '"%s has these query fields %s"'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'tag_n'}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'call', 'children': ['207', '210']}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'qfields'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '210', 'type': 'argument_list', 'children': ['211']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'tag_n'}; {'id': '212', 'type': 'if_statement', 'children': ['213', '218']}; {'id': '213', 'type': 'comparison_operator', 'children': ['214', '217'], 'value': 'is'}; {'id': '214', 'type': 'attribute', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '217', 'type': 'None', 'children': []}; {'id': '218', 'type': 'block', 'children': ['219', '228', '238']}; {'id': '219', 'type': 'expression_statement', 'children': ['220']}; {'id': '220', 'type': 'call', 'children': ['221', '226']}; {'id': '221', 'type': 'attribute', 'children': ['222', '225']}; {'id': '222', 'type': 'attribute', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'string', 'children': [], 'value': "'running recipe tagger'"}; {'id': '228', 'type': 'expression_statement', 'children': ['229']}; {'id': '229', 'type': 'call', 'children': ['230', '235']}; {'id': '230', 'type': 'attribute', 'children': ['231', '234']}; {'id': '231', 'type': 'attribute', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '235', 'type': 'argument_list', 'children': ['236', '237']}; {'id': '236', 'type': 'string', 'children': [], 'value': "'with query fields %s'"}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'qfields'}; {'id': '238', 'type': 'if_statement', 'children': ['239', '240', '253']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'qfields'}; {'id': '240', 'type': 'block', 'children': ['241']}; {'id': '241', 'type': 'expression_statement', 'children': ['242']}; {'id': '242', 'type': 'assignment', 'children': ['243', '246']}; {'id': '243', 'type': 'attribute', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '246', 'type': 'call', 'children': ['247', '250']}; {'id': '247', 'type': 'attribute', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'obsres_extractor'}; {'id': '250', 'type': 'argument_list', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'qfields'}; {'id': '253', 'type': 'else_clause', 'children': ['254']}; {'id': '254', 'type': 'block', 'children': ['255']}; {'id': '255', 'type': 'expression_statement', 'children': ['256']}; {'id': '256', 'type': 'assignment', 'children': ['257', '260']}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '260', 'type': 'dictionary', 'children': []}; {'id': '261', 'type': 'for_statement', 'children': ['262', '265', '274']}; {'id': '262', 'type': 'pattern_list', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '265', 'type': 'call', 'children': ['266', '273']}; {'id': '266', 'type': 'attribute', 'children': ['267', '272']}; {'id': '267', 'type': 'call', 'children': ['268', '271']}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'requirements'}; {'id': '271', 'type': 'argument_list', 'children': []}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '273', 'type': 'argument_list', 'children': []}; {'id': '274', 'type': 'block', 'children': ['275']}; {'id': '275', 'type': 'try_statement', 'children': ['276', '318']}; {'id': '276', 'type': 'block', 'children': ['277', '288']}; {'id': '277', 'type': 'expression_statement', 'children': ['278']}; {'id': '278', 'type': 'assignment', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'query_option'}; {'id': '280', 'type': 'call', 'children': ['281', '286']}; {'id': '281', 'type': 'attribute', 'children': ['282', '285']}; {'id': '282', 'type': 'attribute', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'query_options'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '286', 'type': 'argument_list', 'children': ['287']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '288', 'type': 'if_statement', 'children': ['289', '294', '301']}; {'id': '289', 'type': 'boolean_operator', 'children': ['290', '293'], 'value': 'and'}; {'id': '290', 'type': 'comparison_operator', 'children': ['291', '292'], 'value': '=='}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'ob_query_field'}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'ob_query_skip'}; {'id': '294', 'type': 'block', 'children': ['295']}; {'id': '295', 'type': 'expression_statement', 'children': ['296']}; {'id': '296', 'type': 'assignment', 'children': ['297', '300']}; {'id': '297', 'type': 'subscript', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '299', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '301', 'type': 'else_clause', 'children': ['302']}; {'id': '302', 'type': 'block', 'children': ['303']}; {'id': '303', 'type': 'expression_statement', 'children': ['304']}; {'id': '304', 'type': 'assignment', 'children': ['305', '308']}; {'id': '305', 'type': 'subscript', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '308', 'type': 'call', 'children': ['309', '312']}; {'id': '309', 'type': 'attribute', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '312', 'type': 'argument_list', 'children': ['313', '314', '315']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'dal'}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'obsres'}; {'id': '315', 'type': 'keyword_argument', 'children': ['316', '317']}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'query_option'}; {'id': '318', 'type': 'except_clause', 'children': ['319', '323']}; {'id': '319', 'type': 'as_pattern', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'NoResultFound'}; {'id': '321', 'type': 'as_pattern_target', 'children': ['322']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'notfound'}; {'id': '323', 'type': 'block', 'children': ['324']}; {'id': '324', 'type': 'expression_statement', 'children': ['325']}; {'id': '325', 'type': 'call', 'children': ['326', '329']}; {'id': '326', 'type': 'attribute', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'on_query_not_found'}; {'id': '329', 'type': 'argument_list', 'children': ['330']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'notfound'}; {'id': '331', 'type': 'return_statement', 'children': ['332']}; {'id': '332', 'type': 'call', 'children': ['333', '336']}; {'id': '333', 'type': 'attribute', 'children': ['334', '335']}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'create_input'}; {'id': '336', 'type': 'argument_list', 'children': ['337']}; {'id': '337', 'type': 'dictionary_splat', 'children': ['338']}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'result'}
Build a RecipeInput object.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '10']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'get_default_terminal'}; {'id': '3', 'type': 'parameters', 'children': ['4', '7']}; {'id': '4', 'type': 'default_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '6', 'type': 'None', 'children': []}; {'id': '7', 'type': 'default_parameter', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'fallback'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': '_UNSPECIFIED'}; {'id': '10', 'type': 'block', 'children': ['11', '22', '31', '35', '44', '77', '90', '96', '103']}; {'id': '11', 'type': 'if_statement', 'children': ['12', '15']}; {'id': '12', 'type': 'comparison_operator', 'children': ['13', '14'], 'value': 'is'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '14', 'type': 'None', 'children': []}; {'id': '15', 'type': 'block', 'children': ['16']}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'assignment', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '22', 'type': 'if_statement', 'children': ['23', '26']}; {'id': '23', 'type': 'comparison_operator', 'children': ['24', '25'], 'value': 'in'}; {'id': '24', 'type': 'string', 'children': [], 'value': '"PIAS_OPT_TERMINAL"'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '26', 'type': 'block', 'children': ['27']}; {'id': '27', 'type': 'return_statement', 'children': ['28']}; {'id': '28', 'type': 'subscript', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '30', 'type': 'string', 'children': [], 'value': '"PIAS_OPT_TERMINAL"'}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'terminals'}; {'id': '34', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'colorterm'}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '42', 'type': 'argument_list', 'children': ['43']}; {'id': '43', 'type': 'string', 'children': [], 'value': '"COLORTERM"'}; {'id': '44', 'type': 'for_statement', 'children': ['45', '46', '51']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '46', 'type': 'tuple', 'children': ['47', '48', '49', '50']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'colorterm'}; {'id': '48', 'type': 'string', 'children': [], 'value': '"gnome-terminal"'}; {'id': '49', 'type': 'string', 'children': [], 'value': '"konsole"'}; {'id': '50', 'type': 'string', 'children': [], 'value': '"xterm"'}; {'id': '51', 'type': 'block', 'children': ['52']}; {'id': '52', 'type': 'if_statement', 'children': ['53', '56']}; {'id': '53', 'type': 'comparison_operator', 'children': ['54', '55'], 'value': 'is'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '55', 'type': 'None', 'children': []}; {'id': '56', 'type': 'block', 'children': ['57', '65']}; {'id': '57', 'type': 'expression_statement', 'children': ['58']}; {'id': '58', 'type': 'assignment', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'filepath'}; {'id': '60', 'type': 'call', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'find_executable'}; {'id': '62', 'type': 'argument_list', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'environ'}; {'id': '65', 'type': 'if_statement', 'children': ['66', '69']}; {'id': '66', 'type': 'comparison_operator', 'children': ['67', '68'], 'value': 'is'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'filepath'}; {'id': '68', 'type': 'None', 'children': []}; {'id': '69', 'type': 'block', 'children': ['70']}; {'id': '70', 'type': 'expression_statement', 'children': ['71']}; {'id': '71', 'type': 'call', 'children': ['72', '75']}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'terminals'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'filepath'}; {'id': '77', 'type': 'for_statement', 'children': ['78', '79', '82']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'ancestor'}; {'id': '79', 'type': 'call', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'get_ancestor_processes'}; {'id': '81', 'type': 'argument_list', 'children': []}; {'id': '82', 'type': 'block', 'children': ['83']}; {'id': '83', 'type': 'if_statement', 'children': ['84', '87']}; {'id': '84', 'type': 'comparison_operator', 'children': ['85', '86'], 'value': 'in'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'ancestor'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'terminals'}; {'id': '87', 'type': 'block', 'children': ['88']}; {'id': '88', 'type': 'return_statement', 'children': ['89']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'ancestor'}; {'id': '90', 'type': 'for_statement', 'children': ['91', '92', '93']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'term'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'terminals'}; {'id': '93', 'type': 'block', 'children': ['94']}; {'id': '94', 'type': 'return_statement', 'children': ['95']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'term'}; {'id': '96', 'type': 'if_statement', 'children': ['97', '100']}; {'id': '97', 'type': 'comparison_operator', 'children': ['98', '99'], 'value': 'is'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'fallback'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': '_UNSPECIFIED'}; {'id': '100', 'type': 'block', 'children': ['101']}; {'id': '101', 'type': 'return_statement', 'children': ['102']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'fallback'}; {'id': '103', 'type': 'raise_statement', 'children': ['104']}; {'id': '104', 'type': 'call', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '106', 'type': 'argument_list', 'children': ['107']}; {'id': '107', 'type': 'string', 'children': [], 'value': '"Could not find a terminal"'}
Get the user's default terminal program.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_split_refextract_authors_str'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'authors_str'}; {'id': '5', 'type': 'block', 'children': ['6', '25', '29', '33', '144', '154', '182', '202']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'author_seq'}; {'id': '9', 'type': 'generator_expression', 'children': ['10', '15', '23']}; {'id': '10', 'type': 'call', 'children': ['11', '14']}; {'id': '11', 'type': 'attribute', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '14', 'type': 'argument_list', 'children': []}; {'id': '15', 'type': 'for_in_clause', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '17', 'type': 'call', 'children': ['18', '21']}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'RE_SPLIT_AUTH'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '21', 'type': 'argument_list', 'children': ['22']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'authors_str'}; {'id': '23', 'type': 'if_clause', 'children': ['24']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '28', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '32', 'type': 'string', 'children': [], 'value': "''"}; {'id': '33', 'type': 'for_statement', 'children': ['34', '35', '36']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'author_seq'}; {'id': '36', 'type': 'block', 'children': ['37', '62', '76', '90', '104']}; {'id': '37', 'type': 'if_statement', 'children': ['38', '46']}; {'id': '38', 'type': 'not_operator', 'children': ['39']}; {'id': '39', 'type': 'call', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '41', 'type': 'argument_list', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'six'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'text_type'}; {'id': '46', 'type': 'block', 'children': ['47']}; {'id': '47', 'type': 'expression_statement', 'children': ['48']}; {'id': '48', 'type': 'assignment', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '50', 'type': 'call', 'children': ['51', '54']}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'six'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'text_type'}; {'id': '54', 'type': 'argument_list', 'children': ['55']}; {'id': '55', 'type': 'call', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'decode'}; {'id': '59', 'type': 'argument_list', 'children': ['60', '61']}; {'id': '60', 'type': 'string', 'children': [], 'value': "'utf8'"}; {'id': '61', 'type': 'string', 'children': [], 'value': "'ignore'"}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '65', 'type': 'call', 'children': ['66', '69']}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '69', 'type': 'argument_list', 'children': ['70', '71', '72', '73']}; {'id': '70', 'type': 'string', 'children': [], 'value': "r'\\(|\\)'"}; {'id': '71', 'type': 'string', 'children': [], 'value': "''"}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '73', 'type': 'attribute', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '83', 'type': 'argument_list', 'children': ['84', '85', '86', '87']}; {'id': '84', 'type': 'string', 'children': [], 'value': "r'^[\\W\\d]+'"}; {'id': '85', 'type': 'string', 'children': [], 'value': "''"}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'assignment', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '93', 'type': 'call', 'children': ['94', '97']}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'sub'}; {'id': '97', 'type': 'argument_list', 'children': ['98', '99', '100', '101']}; {'id': '98', 'type': 'string', 'children': [], 'value': "r'[^.\\w]+$'"}; {'id': '99', 'type': 'string', 'children': [], 'value': "''"}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'U'}; {'id': '104', 'type': 'if_statement', 'children': ['105', '111', '128']}; {'id': '105', 'type': 'call', 'children': ['106', '109']}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'RE_INITIALS_ONLY'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '109', 'type': 'argument_list', 'children': ['110']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '111', 'type': 'block', 'children': ['112']}; {'id': '112', 'type': 'expression_statement', 'children': ['113']}; {'id': '113', 'type': 'augmented_assignment', 'children': ['114', '115'], 'value': '+='}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '115', 'type': 'binary_operator', 'children': ['116', '117'], 'value': '+'}; {'id': '116', 'type': 'string', 'children': [], 'value': "', '"}; {'id': '117', 'type': 'call', 'children': ['118', '125']}; {'id': '118', 'type': 'attribute', 'children': ['119', '124']}; {'id': '119', 'type': 'call', 'children': ['120', '123']}; {'id': '120', 'type': 'attribute', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'strip'}; {'id': '123', 'type': 'argument_list', 'children': []}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '125', 'type': 'argument_list', 'children': ['126', '127']}; {'id': '126', 'type': 'string', 'children': [], 'value': "'. '"}; {'id': '127', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '128', 'type': 'else_clause', 'children': ['129']}; {'id': '129', 'type': 'block', 'children': ['130', '140']}; {'id': '130', 'type': 'if_statement', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '132', 'type': 'block', 'children': ['133']}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'call', 'children': ['135', '138']}; {'id': '135', 'type': 'attribute', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '138', 'type': 'argument_list', 'children': ['139']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'author'}; {'id': '144', 'type': 'if_statement', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '146', 'type': 'block', 'children': ['147']}; {'id': '147', 'type': 'expression_statement', 'children': ['148']}; {'id': '148', 'type': 'call', 'children': ['149', '152']}; {'id': '149', 'type': 'attribute', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'assignment', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'filters'}; {'id': '157', 'type': 'list', 'children': ['158', '164', '173'], 'value': "[\n lambda a: a == 'ed',\n lambda a: a.startswith(','),\n lambda a: len(a) == 1\n ]"}; {'id': '158', 'type': 'lambda', 'children': ['159', '161']}; {'id': '159', 'type': 'lambda_parameters', 'children': ['160']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '161', 'type': 'comparison_operator', 'children': ['162', '163'], 'value': '=='}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '163', 'type': 'string', 'children': [], 'value': "'ed'"}; {'id': '164', 'type': 'lambda', 'children': ['165', '167']}; {'id': '165', 'type': 'lambda_parameters', 'children': ['166']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '167', 'type': 'call', 'children': ['168', '171']}; {'id': '168', 'type': 'attribute', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '171', 'type': 'argument_list', 'children': ['172']}; {'id': '172', 'type': 'string', 'children': [], 'value': "','"}; {'id': '173', 'type': 'lambda', 'children': ['174', '176']}; {'id': '174', 'type': 'lambda_parameters', 'children': ['175']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '176', 'type': 'comparison_operator', 'children': ['177', '181'], 'value': '=='}; {'id': '177', 'type': 'call', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '179', 'type': 'argument_list', 'children': ['180']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '181', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '182', 'type': 'expression_statement', 'children': ['183']}; {'id': '183', 'type': 'assignment', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '185', 'type': 'list_comprehension', 'children': ['186', '187', '190']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '187', 'type': 'for_in_clause', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '190', 'type': 'if_clause', 'children': ['191']}; {'id': '191', 'type': 'call', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'all'}; {'id': '193', 'type': 'generator_expression', 'children': ['194', '199']}; {'id': '194', 'type': 'not_operator', 'children': ['195']}; {'id': '195', 'type': 'call', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '197', 'type': 'argument_list', 'children': ['198']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'r'}; {'id': '199', 'type': 'for_in_clause', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'filters'}; {'id': '202', 'type': 'return_statement', 'children': ['203']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'res'}
Extract author names out of refextract authors output.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'extract_atoms'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '5', 'type': 'block', 'children': ['6', '13', '24', '28', '107', '156', '233']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '10']}; {'id': '7', 'type': 'comparison_operator', 'children': ['8', '9'], 'value': '=='}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '9', 'type': 'string', 'children': [], 'value': "''"}; {'id': '10', 'type': 'block', 'children': ['11']}; {'id': '11', 'type': 'return_statement', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '13', 'type': 'try_statement', 'children': ['14', '20']}; {'id': '14', 'type': 'block', 'children': ['15']}; {'id': '15', 'type': 'return_statement', 'children': ['16']}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '18', 'type': 'argument_list', 'children': ['19']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '20', 'type': 'except_clause', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'BaseException'}; {'id': '22', 'type': 'block', 'children': ['23']}; {'id': '23', 'type': 'pass_statement', 'children': []}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '27', 'type': 'string', 'children': [], 'value': "''"}; {'id': '28', 'type': 'if_statement', 'children': ['29', '37', '97']}; {'id': '29', 'type': 'not_operator', 'children': ['30']}; {'id': '30', 'type': 'call', 'children': ['31', '36']}; {'id': '31', 'type': 'attribute', 'children': ['32', '35']}; {'id': '32', 'type': 'subscript', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '34', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'isalpha'}; {'id': '36', 'type': 'argument_list', 'children': []}; {'id': '37', 'type': 'block', 'children': ['38', '42', '56', '67', '89']}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '41', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '42', 'type': 'while_statement', 'children': ['43', '51']}; {'id': '43', 'type': 'not_operator', 'children': ['44']}; {'id': '44', 'type': 'call', 'children': ['45', '50']}; {'id': '45', 'type': 'attribute', 'children': ['46', '49']}; {'id': '46', 'type': 'subscript', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'isalpha'}; {'id': '50', 'type': 'argument_list', 'children': []}; {'id': '51', 'type': 'block', 'children': ['52']}; {'id': '52', 'type': 'expression_statement', 'children': ['53']}; {'id': '53', 'type': 'augmented_assignment', 'children': ['54', '55'], 'value': '+='}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '55', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '59', 'type': 'call', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '61', 'type': 'argument_list', 'children': ['62']}; {'id': '62', 'type': 'subscript', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '64', 'type': 'slice', 'children': ['65', '66']}; {'id': '65', 'type': 'colon', 'children': []}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '67', 'type': 'if_statement', 'children': ['68', '71', '83']}; {'id': '68', 'type': 'comparison_operator', 'children': ['69', '70'], 'value': '<'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '70', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '71', 'type': 'block', 'children': ['72', '79']}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '75', 'type': 'call', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'abs'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'sign'}; {'id': '82', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '83', 'type': 'else_clause', 'children': ['84']}; {'id': '84', 'type': 'block', 'children': ['85']}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'assignment', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'sign'}; {'id': '88', 'type': 'string', 'children': [], 'value': "''"}; {'id': '89', 'type': 'expression_statement', 'children': ['90']}; {'id': '90', 'type': 'assignment', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '92', 'type': 'subscript', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '94', 'type': 'slice', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '96', 'type': 'colon', 'children': []}; {'id': '97', 'type': 'else_clause', 'children': ['98']}; {'id': '98', 'type': 'block', 'children': ['99', '103']}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'assignment', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '102', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '103', 'type': 'expression_statement', 'children': ['104']}; {'id': '104', 'type': 'assignment', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'sign'}; {'id': '106', 'type': 'string', 'children': [], 'value': "''"}; {'id': '107', 'type': 'for_statement', 'children': ['108', '109', '116']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '109', 'type': 'call', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '111', 'type': 'argument_list', 'children': ['112']}; {'id': '112', 'type': 'call', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '114', 'type': 'argument_list', 'children': ['115']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '116', 'type': 'block', 'children': ['117']}; {'id': '117', 'type': 'if_statement', 'children': ['118', '125', '148']}; {'id': '118', 'type': 'call', 'children': ['119', '124']}; {'id': '119', 'type': 'attribute', 'children': ['120', '123']}; {'id': '120', 'type': 'subscript', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'isdigit'}; {'id': '124', 'type': 'argument_list', 'children': []}; {'id': '125', 'type': 'block', 'children': ['126']}; {'id': '126', 'type': 'for_statement', 'children': ['127', '128', '139']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'j'}; {'id': '128', 'type': 'call', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '130', 'type': 'argument_list', 'children': ['131']}; {'id': '131', 'type': 'binary_operator', 'children': ['132', '138'], 'value': '-'}; {'id': '132', 'type': 'call', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'subscript', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '138', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '139', 'type': 'block', 'children': ['140']}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'augmented_assignment', 'children': ['142', '143'], 'value': '+='}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '143', 'type': 'subscript', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '145', 'type': 'binary_operator', 'children': ['146', '147'], 'value': '-'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '147', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '148', 'type': 'else_clause', 'children': ['149']}; {'id': '149', 'type': 'block', 'children': ['150']}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'augmented_assignment', 'children': ['152', '153'], 'value': '+='}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '153', 'type': 'subscript', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'molecule'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '156', 'type': 'if_statement', 'children': ['157', '162', '170']}; {'id': '157', 'type': 'comparison_operator', 'children': ['158', '161'], 'value': '=='}; {'id': '158', 'type': 'binary_operator', 'children': ['159', '160'], 'value': '%'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '160', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '161', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '162', 'type': 'block', 'children': ['163']}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'augmented_assignment', 'children': ['165', '166'], 'value': '*='}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '166', 'type': 'call', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '168', 'type': 'argument_list', 'children': ['169']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '170', 'type': 'elif_clause', 'children': ['171', '176']}; {'id': '171', 'type': 'comparison_operator', 'children': ['172', '175'], 'value': '=='}; {'id': '172', 'type': 'binary_operator', 'children': ['173', '174'], 'value': '%'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '174', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '175', 'type': 'float', 'children': [], 'value': '0.5'}; {'id': '176', 'type': 'block', 'children': ['177', '184', '191', '195']}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'assignment', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'atoms_sort'}; {'id': '180', 'type': 'call', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '182', 'type': 'argument_list', 'children': ['183']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'assignment', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'N'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '194', 'type': 'string', 'children': [], 'value': "''"}; {'id': '195', 'type': 'for_statement', 'children': ['196', '197', '201']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '197', 'type': 'call', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '199', 'type': 'argument_list', 'children': ['200']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'N'}; {'id': '201', 'type': 'block', 'children': ['202', '220']}; {'id': '202', 'type': 'for_statement', 'children': ['203', '204', '213']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'm'}; {'id': '204', 'type': 'call', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '206', 'type': 'argument_list', 'children': ['207']}; {'id': '207', 'type': 'call', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '209', 'type': 'argument_list', 'children': ['210']}; {'id': '210', 'type': 'binary_operator', 'children': ['211', '212'], 'value': '-'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'prefactor'}; {'id': '212', 'type': 'float', 'children': [], 'value': '0.5'}; {'id': '213', 'type': 'block', 'children': ['214']}; {'id': '214', 'type': 'expression_statement', 'children': ['215']}; {'id': '215', 'type': 'augmented_assignment', 'children': ['216', '217'], 'value': '+='}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '217', 'type': 'subscript', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'atoms_sort'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '220', 'type': 'if_statement', 'children': ['221', '226']}; {'id': '221', 'type': 'comparison_operator', 'children': ['222', '225'], 'value': '=='}; {'id': '222', 'type': 'binary_operator', 'children': ['223', '224'], 'value': '%'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '224', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '225', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '226', 'type': 'block', 'children': ['227']}; {'id': '227', 'type': 'expression_statement', 'children': ['228']}; {'id': '228', 'type': 'augmented_assignment', 'children': ['229', '230'], 'value': '+='}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'atoms'}; {'id': '230', 'type': 'subscript', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'atoms_sort'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '233', 'type': 'return_statement', 'children': ['234']}; {'id': '234', 'type': 'binary_operator', 'children': ['235', '236'], 'value': '+'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'sign'}; {'id': '236', 'type': 'call', 'children': ['237', '240']}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'string', 'children': [], 'value': "''"}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '240', 'type': 'argument_list', 'children': ['241']}; {'id': '241', 'type': 'call', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '243', 'type': 'argument_list', 'children': ['244']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'atoms'}
Return a string with all atoms in molecule
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_generate_data_for_format'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '14', '216']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '9', 'type': 'dictionary', 'children': []}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'free_size_start'}; {'id': '13', 'type': 'False', 'children': []}; {'id': '14', 'type': 'for_statement', 'children': ['15', '20', '26']}; {'id': '15', 'type': 'pattern_list', 'children': ['16', '17', '18', '19']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'literal_text'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'field_name'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'conversion'}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'formatter'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'parse'}; {'id': '24', 'type': 'argument_list', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'fmt'}; {'id': '26', 'type': 'block', 'children': ['27', '34', '43', '66']}; {'id': '27', 'type': 'if_statement', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'literal_text'}; {'id': '29', 'type': 'block', 'children': ['30']}; {'id': '30', 'type': 'expression_statement', 'children': ['31']}; {'id': '31', 'type': 'assignment', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'free_size_start'}; {'id': '33', 'type': 'False', 'children': []}; {'id': '34', 'type': 'if_statement', 'children': ['35', '37']}; {'id': '35', 'type': 'not_operator', 'children': ['36']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'field_name'}; {'id': '37', 'type': 'block', 'children': ['38', '42']}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'free_size_start'}; {'id': '41', 'type': 'False', 'children': []}; {'id': '42', 'type': 'continue_statement', 'children': []}; {'id': '43', 'type': 'if_statement', 'children': ['44', '54']}; {'id': '44', 'type': 'boolean_operator', 'children': ['45', '51'], 'value': 'or'}; {'id': '45', 'type': 'boolean_operator', 'children': ['46', '48'], 'value': 'or'}; {'id': '46', 'type': 'not_operator', 'children': ['47']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '48', 'type': 'comparison_operator', 'children': ['49', '50'], 'value': '=='}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '50', 'type': 'string', 'children': [], 'value': '"s"'}; {'id': '51', 'type': 'comparison_operator', 'children': ['52', '53'], 'value': '=='}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '53', 'type': 'string', 'children': [], 'value': '"d"'}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'if_statement', 'children': ['56', '57', '60']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'free_size_start'}; {'id': '57', 'type': 'block', 'children': ['58']}; {'id': '58', 'type': 'return_statement', 'children': ['59']}; {'id': '59', 'type': 'None', 'children': []}; {'id': '60', 'type': 'else_clause', 'children': ['61']}; {'id': '61', 'type': 'block', 'children': ['62']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'free_size_start'}; {'id': '65', 'type': 'True', 'children': []}; {'id': '66', 'type': 'if_statement', 'children': ['67', '72', '114', '157']}; {'id': '67', 'type': 'boolean_operator', 'children': ['68', '69'], 'value': 'and'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '69', 'type': 'comparison_operator', 'children': ['70', '71'], 'value': 'in'}; {'id': '70', 'type': 'string', 'children': [], 'value': "'%'"}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '72', 'type': 'block', 'children': ['73', '83', '108']}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'assignment', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '76', 'type': 'call', 'children': ['77', '82']}; {'id': '77', 'type': 'attribute', 'children': ['78', '81']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'dt'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'now'}; {'id': '82', 'type': 'argument_list', 'children': []}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '86', 'type': 'subscript', 'children': ['87', '107']}; {'id': '87', 'type': 'call', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'parse'}; {'id': '89', 'type': 'argument_list', 'children': ['90', '95']}; {'id': '90', 'type': 'binary_operator', 'children': ['91', '94'], 'value': '+'}; {'id': '91', 'type': 'binary_operator', 'children': ['92', '93'], 'value': '+'}; {'id': '92', 'type': 'string', 'children': [], 'value': '"{t:"'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '94', 'type': 'string', 'children': [], 'value': '"}"'}; {'id': '95', 'type': 'call', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'compose'}; {'id': '97', 'type': 'argument_list', 'children': ['98', '103']}; {'id': '98', 'type': 'binary_operator', 'children': ['99', '102'], 'value': '+'}; {'id': '99', 'type': 'binary_operator', 'children': ['100', '101'], 'value': '+'}; {'id': '100', 'type': 'string', 'children': [], 'value': '"{t:"'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '102', 'type': 'string', 'children': [], 'value': '"}"'}; {'id': '103', 'type': 'dictionary', 'children': ['104']}; {'id': '104', 'type': 'pair', 'children': ['105', '106']}; {'id': '105', 'type': 'string', 'children': [], 'value': "'t'"}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '107', 'type': 'string', 'children': [], 'value': "'t'"}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'assignment', 'children': ['110', '113']}; {'id': '110', 'type': 'subscript', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'field_name'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 't'}; {'id': '114', 'type': 'elif_clause', 'children': ['115', '120']}; {'id': '115', 'type': 'boolean_operator', 'children': ['116', '117'], 'value': 'and'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '117', 'type': 'comparison_operator', 'children': ['118', '119'], 'value': 'in'}; {'id': '118', 'type': 'string', 'children': [], 'value': "'d'"}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '120', 'type': 'block', 'children': ['121', '140']}; {'id': '121', 'type': 'if_statement', 'children': ['122', '128', '136']}; {'id': '122', 'type': 'not_operator', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'isalpha'}; {'id': '127', 'type': 'argument_list', 'children': []}; {'id': '128', 'type': 'block', 'children': ['129']}; {'id': '129', 'type': 'expression_statement', 'children': ['130']}; {'id': '130', 'type': 'assignment', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '132', 'type': 'call', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': '_get_number_from_fmt'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '136', 'type': 'else_clause', 'children': ['137']}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'return_statement', 'children': ['139']}; {'id': '139', 'type': 'None', 'children': []}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '145']}; {'id': '142', 'type': 'subscript', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'field_name'}; {'id': '145', 'type': 'binary_operator', 'children': ['146', '153'], 'value': '%'}; {'id': '146', 'type': 'call', 'children': ['147', '150']}; {'id': '147', 'type': 'attribute', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'random'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'randint'}; {'id': '150', 'type': 'argument_list', 'children': ['151', '152']}; {'id': '151', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '152', 'type': 'integer', 'children': [], 'value': '99999999999999999'}; {'id': '153', 'type': '()', 'children': ['154']}; {'id': '154', 'type': 'binary_operator', 'children': ['155', '156'], 'value': '**'}; {'id': '155', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '157', 'type': 'else_clause', 'children': ['158']}; {'id': '158', 'type': 'block', 'children': ['159', '188', '192', '210']}; {'id': '159', 'type': 'if_statement', 'children': ['160', '163', '168', '182']}; {'id': '160', 'type': 'comparison_operator', 'children': ['161', '162'], 'value': 'is'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '162', 'type': 'None', 'children': []}; {'id': '163', 'type': 'block', 'children': ['164']}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '167', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '168', 'type': 'elif_clause', 'children': ['169', '174']}; {'id': '169', 'type': 'call', 'children': ['170', '173']}; {'id': '170', 'type': 'attribute', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'isalnum'}; {'id': '173', 'type': 'argument_list', 'children': []}; {'id': '174', 'type': 'block', 'children': ['175']}; {'id': '175', 'type': 'expression_statement', 'children': ['176']}; {'id': '176', 'type': 'assignment', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '178', 'type': 'call', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': '_get_number_from_fmt'}; {'id': '180', 'type': 'argument_list', 'children': ['181']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'format_spec'}; {'id': '182', 'type': 'else_clause', 'children': ['183']}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'assignment', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '187', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'assignment', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'randstri'}; {'id': '191', 'type': 'string', 'children': [], 'value': "''"}; {'id': '192', 'type': 'for_statement', 'children': ['193', '194', '198']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '194', 'type': 'call', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '196', 'type': 'argument_list', 'children': ['197']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'n'}; {'id': '198', 'type': 'block', 'children': ['199']}; {'id': '199', 'type': 'expression_statement', 'children': ['200']}; {'id': '200', 'type': 'augmented_assignment', 'children': ['201', '202'], 'value': '+='}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'randstri'}; {'id': '202', 'type': 'call', 'children': ['203', '206']}; {'id': '203', 'type': 'attribute', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'random'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'choice'}; {'id': '206', 'type': 'argument_list', 'children': ['207']}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'string'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'ascii_letters'}; {'id': '210', 'type': 'expression_statement', 'children': ['211']}; {'id': '211', 'type': 'assignment', 'children': ['212', '215']}; {'id': '212', 'type': 'subscript', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'data'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'field_name'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'randstri'}; {'id': '216', 'type': 'return_statement', 'children': ['217']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'data'}
Generate a fake data dictionary to fill in the provided format string.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'options'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '5', 'type': 'block', 'children': ['6']}; {'id': '6', 'type': 'return_statement', 'children': ['7']}; {'id': '7', 'type': 'call', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '9', 'type': 'generator_expression', 'children': ['10', '13', '24']}; {'id': '10', 'type': 'tuple', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '13', 'type': 'for_in_clause', 'children': ['14', '17']}; {'id': '14', 'type': 'tuple_pattern', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '17', 'type': 'call', 'children': ['18', '23']}; {'id': '18', 'type': 'attribute', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '23', 'type': 'argument_list', 'children': []}; {'id': '24', 'type': 'if_clause', 'children': ['25']}; {'id': '25', 'type': 'not_operator', 'children': ['26']}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'string', 'children': [], 'value': "'__'"}
Provide a sorted list of options.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'prepare_rapid_streamflow'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'path_to_rapid_qout'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'connection_list_file'}; {'id': '7', 'type': 'block', 'children': ['8', '21']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'ihg_filename'}; {'id': '11', 'type': 'call', 'children': ['12', '15']}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'string', 'children': [], 'value': "'{0}.ihg'"}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'attribute', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'project_manager'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '21', 'type': 'with_statement', 'children': ['22', '32']}; {'id': '22', 'type': 'with_clause', 'children': ['23']}; {'id': '23', 'type': 'with_item', 'children': ['24']}; {'id': '24', 'type': 'call', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'tmp_chdir'}; {'id': '26', 'type': 'argument_list', 'children': ['27']}; {'id': '27', 'type': 'attribute', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'project_manager'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'project_directory'}; {'id': '32', 'type': 'block', 'children': ['33', '37', '203']}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '36', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '37', 'type': 'with_statement', 'children': ['38', '52']}; {'id': '38', 'type': 'with_clause', 'children': ['39']}; {'id': '39', 'type': 'with_item', 'children': ['40']}; {'id': '40', 'type': 'as_pattern', 'children': ['41', '50']}; {'id': '41', 'type': 'call', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'RAPIDDataset'}; {'id': '43', 'type': 'argument_list', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'path_to_rapid_qout'}; {'id': '45', 'type': 'keyword_argument', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'out_tzinfo'}; {'id': '47', 'type': 'attribute', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'tz'}; {'id': '50', 'type': 'as_pattern_target', 'children': ['51']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'qout_nc'}; {'id': '52', 'type': 'block', 'children': ['53', '71', '134']}; {'id': '53', 'type': 'expression_statement', 'children': ['54']}; {'id': '54', 'type': 'assignment', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '56', 'type': 'call', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'qout_nc'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'get_time_index_range'}; {'id': '60', 'type': 'argument_list', 'children': ['61', '66']}; {'id': '61', 'type': 'keyword_argument', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'date_search_start'}; {'id': '63', 'type': 'attribute', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'simulation_start'}; {'id': '66', 'type': 'keyword_argument', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'date_search_end'}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '71', 'type': 'if_statement', 'children': ['72', '78']}; {'id': '72', 'type': 'comparison_operator', 'children': ['73', '77'], 'value': '>'}; {'id': '73', 'type': 'call', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '77', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '78', 'type': 'block', 'children': ['79', '93']}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '82', 'type': 'call', 'children': ['83', '86']}; {'id': '83', 'type': 'attribute', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'qout_nc'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'get_time_array'}; {'id': '86', 'type': 'argument_list', 'children': ['87', '90']}; {'id': '87', 'type': 'keyword_argument', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'return_datetime'}; {'id': '89', 'type': 'True', 'children': []}; {'id': '90', 'type': 'keyword_argument', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'time_index_array'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '93', 'type': 'if_statement', 'children': ['94', '99']}; {'id': '94', 'type': 'comparison_operator', 'children': ['95', '98'], 'value': 'is'}; {'id': '95', 'type': 'attribute', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'simulation_start'}; {'id': '98', 'type': 'None', 'children': []}; {'id': '99', 'type': 'block', 'children': ['100']}; {'id': '100', 'type': 'if_statement', 'children': ['101', '108']}; {'id': '101', 'type': 'comparison_operator', 'children': ['102', '105'], 'value': '=='}; {'id': '102', 'type': 'attribute', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'simulation_start'}; {'id': '105', 'type': 'subscript', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '107', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '108', 'type': 'block', 'children': ['109', '118', '126']}; {'id': '109', 'type': 'expression_statement', 'children': ['110']}; {'id': '110', 'type': 'call', 'children': ['111', '114']}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '114', 'type': 'argument_list', 'children': ['115']}; {'id': '115', 'type': 'concatenated_string', 'children': ['116', '117']}; {'id': '116', 'type': 'string', 'children': [], 'value': '"First timestep of streamflow skipped "'}; {'id': '117', 'type': 'string', 'children': [], 'value': '"in order for GSSHA to capture the streamflow."'}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'assignment', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '121', 'type': 'subscript', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '123', 'type': 'slice', 'children': ['124', '125']}; {'id': '124', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '125', 'type': 'colon', 'children': []}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'assignment', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '129', 'type': 'subscript', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '131', 'type': 'slice', 'children': ['132', '133']}; {'id': '132', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '133', 'type': 'colon', 'children': []}; {'id': '134', 'type': 'if_statement', 'children': ['135', '141', '194']}; {'id': '135', 'type': 'comparison_operator', 'children': ['136', '140'], 'value': '>'}; {'id': '136', 'type': 'call', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '138', 'type': 'argument_list', 'children': ['139']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '140', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '141', 'type': 'block', 'children': ['142', '148', '162', '178']}; {'id': '142', 'type': 'expression_statement', 'children': ['143']}; {'id': '143', 'type': 'assignment', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'start_datetime'}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '147', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '148', 'type': 'if_statement', 'children': ['149', '154']}; {'id': '149', 'type': 'comparison_operator', 'children': ['150', '153'], 'value': 'is'}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'simulation_start'}; {'id': '153', 'type': 'None', 'children': []}; {'id': '154', 'type': 'block', 'children': ['155']}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'call', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': '_update_simulation_start'}; {'id': '160', 'type': 'argument_list', 'children': ['161']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'start_datetime'}; {'id': '162', 'type': 'if_statement', 'children': ['163', '168']}; {'id': '163', 'type': 'comparison_operator', 'children': ['164', '167'], 'value': 'is'}; {'id': '164', 'type': 'attribute', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '167', 'type': 'None', 'children': []}; {'id': '168', 'type': 'block', 'children': ['169']}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'assignment', 'children': ['171', '174']}; {'id': '171', 'type': 'attribute', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '174', 'type': 'subscript', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'time_array'}; {'id': '176', 'type': 'unary_operator', 'children': ['177'], 'value': '-'}; {'id': '177', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'call', 'children': ['180', '183']}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'qout_nc'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'write_flows_to_gssha_time_series_ihg'}; {'id': '183', 'type': 'argument_list', 'children': ['184', '185', '186', '189']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'ihg_filename'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'connection_list_file'}; {'id': '186', 'type': 'keyword_argument', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'date_search_start'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'start_datetime'}; {'id': '189', 'type': 'keyword_argument', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'date_search_end'}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '194', 'type': 'else_clause', 'children': ['195']}; {'id': '195', 'type': 'block', 'children': ['196']}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'call', 'children': ['198', '201']}; {'id': '198', 'type': 'attribute', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '201', 'type': 'argument_list', 'children': ['202']}; {'id': '202', 'type': 'string', 'children': [], 'value': '"No streamflow values found in time range ..."'}; {'id': '203', 'type': 'if_statement', 'children': ['204', '210', '260']}; {'id': '204', 'type': 'comparison_operator', 'children': ['205', '209'], 'value': '>'}; {'id': '205', 'type': 'call', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '207', 'type': 'argument_list', 'children': ['208']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'time_index_range'}; {'id': '209', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '210', 'type': 'block', 'children': ['211', '217', '232', '241', '254']}; {'id': '211', 'type': 'expression_statement', 'children': ['212']}; {'id': '212', 'type': 'call', 'children': ['213', '216']}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': '_update_simulation_start_cards'}; {'id': '216', 'type': 'argument_list', 'children': []}; {'id': '217', 'type': 'expression_statement', 'children': ['218']}; {'id': '218', 'type': 'call', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': '_update_card'}; {'id': '222', 'type': 'argument_list', 'children': ['223', '224']}; {'id': '223', 'type': 'string', 'children': [], 'value': '"END_TIME"'}; {'id': '224', 'type': 'call', 'children': ['225', '230']}; {'id': '225', 'type': 'attribute', 'children': ['226', '229']}; {'id': '226', 'type': 'attribute', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'strftime'}; {'id': '230', 'type': 'argument_list', 'children': ['231']}; {'id': '231', 'type': 'string', 'children': [], 'value': '"%Y %m %d %H %M"'}; {'id': '232', 'type': 'expression_statement', 'children': ['233']}; {'id': '233', 'type': 'call', 'children': ['234', '237']}; {'id': '234', 'type': 'attribute', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': '_update_card'}; {'id': '237', 'type': 'argument_list', 'children': ['238', '239', '240']}; {'id': '238', 'type': 'string', 'children': [], 'value': '"CHAN_POINT_INPUT"'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'ihg_filename'}; {'id': '240', 'type': 'True', 'children': []}; {'id': '241', 'type': 'expression_statement', 'children': ['242']}; {'id': '242', 'type': 'call', 'children': ['243', '246']}; {'id': '243', 'type': 'attribute', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'set_simulation_duration'}; {'id': '246', 'type': 'argument_list', 'children': ['247']}; {'id': '247', 'type': 'binary_operator', 'children': ['248', '251'], 'value': '-'}; {'id': '248', 'type': 'attribute', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'simulation_end'}; {'id': '251', 'type': 'attribute', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'simulation_start'}; {'id': '254', 'type': 'expression_statement', 'children': ['255']}; {'id': '255', 'type': 'call', 'children': ['256', '259']}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': '_update_gmt'}; {'id': '259', 'type': 'argument_list', 'children': []}; {'id': '260', 'type': 'else_clause', 'children': ['261']}; {'id': '261', 'type': 'block', 'children': ['262', '269']}; {'id': '262', 'type': 'expression_statement', 'children': ['263']}; {'id': '263', 'type': 'call', 'children': ['264', '267']}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '267', 'type': 'argument_list', 'children': ['268']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'ihg_filename'}; {'id': '269', 'type': 'expression_statement', 'children': ['270']}; {'id': '270', 'type': 'call', 'children': ['271', '276']}; {'id': '271', 'type': 'attribute', 'children': ['272', '275']}; {'id': '272', 'type': 'attribute', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'project_manager'}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'deleteCard'}; {'id': '276', 'type': 'argument_list', 'children': ['277', '278']}; {'id': '277', 'type': 'string', 'children': [], 'value': "'CHAN_POINT_INPUT'"}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'db_session'}
Prepares RAPID streamflow for GSSHA simulation
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_write'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '8', 'type': 'block', 'children': ['9', '15']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'precipEvents'}; {'id': '15', 'type': 'for_statement', 'children': ['16', '17', '18']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'events'}; {'id': '18', 'type': 'block', 'children': ['19', '37']}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '24', 'type': 'argument_list', 'children': ['25']}; {'id': '25', 'type': 'binary_operator', 'children': ['26', '27'], 'value': '%'}; {'id': '26', 'type': 'string', 'children': [], 'value': '\'EVENT "%s"\\nNRGAG %s\\nNRPDS %s\\n\''}; {'id': '27', 'type': 'tuple', 'children': ['28', '31', '34']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '31', 'type': 'attribute', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'nrGag'}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'nrPds'}; {'id': '37', 'type': 'if_statement', 'children': ['38', '43']}; {'id': '38', 'type': 'comparison_operator', 'children': ['39', '42'], 'value': '>'}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'nrGag'}; {'id': '42', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '43', 'type': 'block', 'children': ['44', '50', '54', '87', '102', '134', '156']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '47', 'type': 'attribute', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '50', 'type': 'expression_statement', 'children': ['51']}; {'id': '51', 'type': 'assignment', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'valList'}; {'id': '53', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '54', 'type': 'for_statement', 'children': ['55', '56', '57']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '57', 'type': 'block', 'children': ['58']}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'call', 'children': ['60', '63']}; {'id': '60', 'type': 'attribute', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'valList'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '63', 'type': 'argument_list', 'children': ['64']}; {'id': '64', 'type': 'dictionary', 'children': ['65', '70', '75', '82']}; {'id': '65', 'type': 'pair', 'children': ['66', '67']}; {'id': '66', 'type': 'string', 'children': [], 'value': "'ValueType'"}; {'id': '67', 'type': 'attribute', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'valueType'}; {'id': '70', 'type': 'pair', 'children': ['71', '72']}; {'id': '71', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'dateTime'}; {'id': '75', 'type': 'pair', 'children': ['76', '77']}; {'id': '76', 'type': 'string', 'children': [], 'value': "'Gage'"}; {'id': '77', 'type': 'attribute', 'children': ['78', '81']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'gage'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'id'}; {'id': '82', 'type': 'pair', 'children': ['83', '84']}; {'id': '83', 'type': 'string', 'children': [], 'value': "'Value'"}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'pivotedValues'}; {'id': '90', 'type': 'call', 'children': ['91', '94']}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'pivot'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'pivot'}; {'id': '94', 'type': 'argument_list', 'children': ['95', '96', '99', '101']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'valList'}; {'id': '96', 'type': 'tuple', 'children': ['97', '98']}; {'id': '97', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '98', 'type': 'string', 'children': [], 'value': "'ValueType'"}; {'id': '99', 'type': 'tuple', 'children': ['100']}; {'id': '100', 'type': 'string', 'children': [], 'value': "'Gage'"}; {'id': '101', 'type': 'string', 'children': [], 'value': "'Value'"}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'assignment', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'gages'}; {'id': '105', 'type': 'call', 'children': ['106', '133']}; {'id': '106', 'type': 'attribute', 'children': ['107', '131', '132']}; {'id': '107', 'type': 'call', 'children': ['108', '127']}; {'id': '108', 'type': 'attribute', 'children': ['109', '125', '126']}; {'id': '109', 'type': 'call', 'children': ['110', '119']}; {'id': '110', 'type': 'attribute', 'children': ['111', '117', '118']}; {'id': '111', 'type': 'call', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '115', 'type': 'argument_list', 'children': ['116']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'PrecipGage'}; {'id': '117', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'filter'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'comparison_operator', 'children': ['121', '124'], 'value': '=='}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'PrecipGage'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '125', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'order_by'}; {'id': '127', 'type': 'argument_list', 'children': ['128']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'PrecipGage'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'id'}; {'id': '131', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'all'}; {'id': '133', 'type': 'argument_list', 'children': []}; {'id': '134', 'type': 'for_statement', 'children': ['135', '136', '137']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'gage'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'gages'}; {'id': '137', 'type': 'block', 'children': ['138']}; {'id': '138', 'type': 'expression_statement', 'children': ['139']}; {'id': '139', 'type': 'call', 'children': ['140', '143']}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '143', 'type': 'argument_list', 'children': ['144']}; {'id': '144', 'type': 'binary_operator', 'children': ['145', '146'], 'value': '%'}; {'id': '145', 'type': 'string', 'children': [], 'value': '\'COORD %s %s "%s"\\n\''}; {'id': '146', 'type': 'tuple', 'children': ['147', '150', '153']}; {'id': '147', 'type': 'attribute', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'gage'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'gage'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'y'}; {'id': '153', 'type': 'attribute', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'gage'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '156', 'type': 'for_statement', 'children': ['157', '158', '159']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'pivotedValues'}; {'id': '159', 'type': 'block', 'children': ['160', '164', '183', '206']}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'valString'}; {'id': '163', 'type': 'string', 'children': [], 'value': "''"}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '167', 'type': 'call', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'list_comprehension', 'children': ['171', '172', '175']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '172', 'type': 'for_in_clause', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '175', 'type': 'if_clause', 'children': ['176']}; {'id': '176', 'type': 'boolean_operator', 'children': ['177', '180'], 'value': 'and'}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '179'], 'value': '!='}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '179', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '180', 'type': 'comparison_operator', 'children': ['181', '182'], 'value': '!='}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '182', 'type': 'string', 'children': [], 'value': "'ValueType'"}; {'id': '183', 'type': 'for_statement', 'children': ['184', '185', '186']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'keys'}; {'id': '186', 'type': 'block', 'children': ['187']}; {'id': '187', 'type': 'if_statement', 'children': ['188', '195']}; {'id': '188', 'type': 'boolean_operator', 'children': ['189', '192'], 'value': 'and'}; {'id': '189', 'type': 'comparison_operator', 'children': ['190', '191'], 'value': '!='}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '191', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '192', 'type': 'comparison_operator', 'children': ['193', '194'], 'value': '!='}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '194', 'type': 'string', 'children': [], 'value': "'ValueType'"}; {'id': '195', 'type': 'block', 'children': ['196']}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'valString'}; {'id': '199', 'type': 'binary_operator', 'children': ['200', '201'], 'value': '%'}; {'id': '200', 'type': 'string', 'children': [], 'value': "'%s %.3f'"}; {'id': '201', 'type': 'tuple', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'valString'}; {'id': '203', 'type': 'subscript', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'call', 'children': ['208', '211']}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '211', 'type': 'argument_list', 'children': ['212']}; {'id': '212', 'type': 'binary_operator', 'children': ['213', '214'], 'value': '%'}; {'id': '213', 'type': 'string', 'children': [], 'value': "'%s %.4d %.2d %.2d %.2d %.2d%s\\n'"}; {'id': '214', 'type': 'tuple', 'children': ['215', '218', '223', '228', '233', '238', '243']}; {'id': '215', 'type': 'subscript', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '217', 'type': 'string', 'children': [], 'value': "'ValueType'"}; {'id': '218', 'type': 'attribute', 'children': ['219', '222']}; {'id': '219', 'type': 'subscript', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '221', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '223', 'type': 'attribute', 'children': ['224', '227']}; {'id': '224', 'type': 'subscript', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '226', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '228', 'type': 'attribute', 'children': ['229', '232']}; {'id': '229', 'type': 'subscript', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '231', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'day'}; {'id': '233', 'type': 'attribute', 'children': ['234', '237']}; {'id': '234', 'type': 'subscript', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '236', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'hour'}; {'id': '238', 'type': 'attribute', 'children': ['239', '242']}; {'id': '239', 'type': 'subscript', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '241', 'type': 'string', 'children': [], 'value': "'DateTime'"}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'minute'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'valString'}
Precipitation File Write to File Method
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '12']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_createGsshaPyObjects'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8', '9', '10', '11']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'mapTables'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'indexMaps'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'spatial'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'spatialReferenceID'}; {'id': '12', 'type': 'block', 'children': ['13']}; {'id': '13', 'type': 'for_statement', 'children': ['14', '15', '16']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'mapTables'}; {'id': '16', 'type': 'block', 'children': ['17']}; {'id': '17', 'type': 'try_statement', 'children': ['18', '295']}; {'id': '18', 'type': 'block', 'children': ['19', '32', '87', '93', '108']}; {'id': '19', 'type': 'if_statement', 'children': ['20', '25']}; {'id': '20', 'type': 'comparison_operator', 'children': ['21', '24'], 'value': 'is'}; {'id': '21', 'type': 'subscript', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '23', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '24', 'type': 'None', 'children': []}; {'id': '25', 'type': 'block', 'children': ['26']}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'subscript', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'indexMaps'}; {'id': '29', 'type': 'subscript', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '31', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'assignment', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '35', 'type': 'call', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'MapTable'}; {'id': '37', 'type': 'argument_list', 'children': ['38', '43', '50', '57', '67', '77']}; {'id': '38', 'type': 'keyword_argument', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '40', 'type': 'subscript', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '42', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '43', 'type': 'keyword_argument', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'numIDs'}; {'id': '45', 'type': 'subscript', 'children': ['46', '49']}; {'id': '46', 'type': 'subscript', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '48', 'type': 'string', 'children': [], 'value': "'numVars'"}; {'id': '49', 'type': 'string', 'children': [], 'value': "'NUM_IDS'"}; {'id': '50', 'type': 'keyword_argument', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'maxNumCells'}; {'id': '52', 'type': 'subscript', 'children': ['53', '56']}; {'id': '53', 'type': 'subscript', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '55', 'type': 'string', 'children': [], 'value': "'numVars'"}; {'id': '56', 'type': 'string', 'children': [], 'value': "'MAX_NUMBER_CELLS'"}; {'id': '57', 'type': 'keyword_argument', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'numSed'}; {'id': '59', 'type': 'call', 'children': ['60', '65']}; {'id': '60', 'type': 'attribute', 'children': ['61', '64']}; {'id': '61', 'type': 'subscript', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '63', 'type': 'string', 'children': [], 'value': "'numVars'"}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'string', 'children': [], 'value': "'NUM_SED'"}; {'id': '67', 'type': 'keyword_argument', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'numContam'}; {'id': '69', 'type': 'call', 'children': ['70', '75']}; {'id': '70', 'type': 'attribute', 'children': ['71', '74']}; {'id': '71', 'type': 'subscript', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '73', 'type': 'string', 'children': [], 'value': "'numVars'"}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'string', 'children': [], 'value': "'NUM_CONTAM'"}; {'id': '77', 'type': 'keyword_argument', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'maxSoilID'}; {'id': '79', 'type': 'call', 'children': ['80', '85']}; {'id': '80', 'type': 'attribute', 'children': ['81', '84']}; {'id': '81', 'type': 'subscript', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '83', 'type': 'string', 'children': [], 'value': "'numVars'"}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '85', 'type': 'argument_list', 'children': ['86']}; {'id': '86', 'type': 'string', 'children': [], 'value': "'MAX_SOIL_ID'"}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'assignment', 'children': ['89', '92']}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'mapTableFile'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '93', 'type': 'if_statement', 'children': ['94', '97']}; {'id': '94', 'type': 'subscript', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '96', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '97', 'type': 'block', 'children': ['98']}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'assignment', 'children': ['100', '103']}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '103', 'type': 'subscript', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'indexMaps'}; {'id': '105', 'type': 'subscript', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '107', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '108', 'type': 'if_statement', 'children': ['109', '114', '216', '269']}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '113'], 'value': '=='}; {'id': '110', 'type': 'subscript', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '112', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '113', 'type': 'string', 'children': [], 'value': "'CONTAMINANT_TRANSPORT'"}; {'id': '114', 'type': 'block', 'children': ['115']}; {'id': '115', 'type': 'for_statement', 'children': ['116', '117', '120']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '117', 'type': 'subscript', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '119', 'type': 'string', 'children': [], 'value': "'contaminants'"}; {'id': '120', 'type': 'block', 'children': ['121', '132', '175', '183', '189', '205']}; {'id': '121', 'type': 'expression_statement', 'children': ['122']}; {'id': '122', 'type': 'assignment', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'outputBaseFilename'}; {'id': '124', 'type': 'call', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': '_preprocessContaminantOutFilePath'}; {'id': '128', 'type': 'argument_list', 'children': ['129']}; {'id': '129', 'type': 'subscript', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '131', 'type': 'string', 'children': [], 'value': "'outPath'"}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'assignment', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'contaminant'}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'MTContaminant'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '143', '146', '157', '168']}; {'id': '138', 'type': 'keyword_argument', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '140', 'type': 'subscript', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '142', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '143', 'type': 'keyword_argument', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'outputFilename'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'outputBaseFilename'}; {'id': '146', 'type': 'keyword_argument', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'precipConc'}; {'id': '148', 'type': 'call', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'vrp'}; {'id': '150', 'type': 'argument_list', 'children': ['151', '156']}; {'id': '151', 'type': 'subscript', 'children': ['152', '155']}; {'id': '152', 'type': 'subscript', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '154', 'type': 'string', 'children': [], 'value': "'contamVars'"}; {'id': '155', 'type': 'string', 'children': [], 'value': "'PRECIP_CONC'"}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '157', 'type': 'keyword_argument', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'partition'}; {'id': '159', 'type': 'call', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'vrp'}; {'id': '161', 'type': 'argument_list', 'children': ['162', '167']}; {'id': '162', 'type': 'subscript', 'children': ['163', '166']}; {'id': '163', 'type': 'subscript', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '165', 'type': 'string', 'children': [], 'value': "'contamVars'"}; {'id': '166', 'type': 'string', 'children': [], 'value': "'PARTITION'"}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '168', 'type': 'keyword_argument', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'numIDs'}; {'id': '170', 'type': 'subscript', 'children': ['171', '174']}; {'id': '171', 'type': 'subscript', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '173', 'type': 'string', 'children': [], 'value': "'contamVars'"}; {'id': '174', 'type': 'string', 'children': [], 'value': "'NUM_IDS'"}; {'id': '175', 'type': 'expression_statement', 'children': ['176']}; {'id': '176', 'type': 'assignment', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '178', 'type': 'subscript', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'indexMaps'}; {'id': '180', 'type': 'subscript', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '182', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'assignment', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'contaminant'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '189', 'type': 'expression_statement', 'children': ['190']}; {'id': '190', 'type': 'call', 'children': ['191', '194']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': '_createValueObjects'}; {'id': '194', 'type': 'argument_list', 'children': ['195', '198', '201', '202', '203', '204']}; {'id': '195', 'type': 'subscript', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '197', 'type': 'string', 'children': [], 'value': "'valueList'"}; {'id': '198', 'type': 'subscript', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'contam'}; {'id': '200', 'type': 'string', 'children': [], 'value': "'varList'"}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'contaminant'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'call', 'children': ['207', '210']}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': '_readContaminantOutputFiles'}; {'id': '210', 'type': 'argument_list', 'children': ['211', '212', '213', '214', '215']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'directory'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'outputBaseFilename'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'spatial'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'spatialReferenceID'}; {'id': '216', 'type': 'elif_clause', 'children': ['217', '222']}; {'id': '217', 'type': 'comparison_operator', 'children': ['218', '221'], 'value': '=='}; {'id': '218', 'type': 'subscript', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '220', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '221', 'type': 'string', 'children': [], 'value': "'SEDIMENTS'"}; {'id': '222', 'type': 'block', 'children': ['223']}; {'id': '223', 'type': 'for_statement', 'children': ['224', '225', '228']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '225', 'type': 'subscript', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '227', 'type': 'string', 'children': [], 'value': "'valueList'"}; {'id': '228', 'type': 'block', 'children': ['229', '263']}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'assignment', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'sediment'}; {'id': '232', 'type': 'call', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'MTSediment'}; {'id': '234', 'type': 'argument_list', 'children': ['235', '240', '249', '258']}; {'id': '235', 'type': 'keyword_argument', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '237', 'type': 'subscript', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '239', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '240', 'type': 'keyword_argument', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'specificGravity'}; {'id': '242', 'type': 'call', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'vrp'}; {'id': '244', 'type': 'argument_list', 'children': ['245', '248']}; {'id': '245', 'type': 'subscript', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '247', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '249', 'type': 'keyword_argument', 'children': ['250', '251']}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'particleDiameter'}; {'id': '251', 'type': 'call', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'vrp'}; {'id': '253', 'type': 'argument_list', 'children': ['254', '257']}; {'id': '254', 'type': 'subscript', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '256', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '258', 'type': 'keyword_argument', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'outputFilename'}; {'id': '260', 'type': 'subscript', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '262', 'type': 'integer', 'children': [], 'value': '3'}; {'id': '263', 'type': 'expression_statement', 'children': ['264']}; {'id': '264', 'type': 'assignment', 'children': ['265', '268']}; {'id': '265', 'type': 'attribute', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'sediment'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '269', 'type': 'else_clause', 'children': ['270']}; {'id': '270', 'type': 'block', 'children': ['271', '279']}; {'id': '271', 'type': 'expression_statement', 'children': ['272']}; {'id': '272', 'type': 'assignment', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '274', 'type': 'subscript', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'indexMaps'}; {'id': '276', 'type': 'subscript', 'children': ['277', '278']}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '278', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '279', 'type': 'expression_statement', 'children': ['280']}; {'id': '280', 'type': 'call', 'children': ['281', '284']}; {'id': '281', 'type': 'attribute', 'children': ['282', '283']}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '283', 'type': 'identifier', 'children': [], 'value': '_createValueObjects'}; {'id': '284', 'type': 'argument_list', 'children': ['285', '288', '291', '292', '293', '294']}; {'id': '285', 'type': 'subscript', 'children': ['286', '287']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '287', 'type': 'string', 'children': [], 'value': "'valueList'"}; {'id': '288', 'type': 'subscript', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '290', 'type': 'string', 'children': [], 'value': "'varList'"}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'mapTable'}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'indexMap'}; {'id': '293', 'type': 'None', 'children': []}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'replaceParamFile'}; {'id': '295', 'type': 'except_clause', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'KeyError'}; {'id': '297', 'type': 'block', 'children': ['298']}; {'id': '298', 'type': 'expression_statement', 'children': ['299']}; {'id': '299', 'type': 'call', 'children': ['300', '303']}; {'id': '300', 'type': 'attribute', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '303', 'type': 'argument_list', 'children': ['304']}; {'id': '304', 'type': 'binary_operator', 'children': ['305', '309'], 'value': '%'}; {'id': '305', 'type': '()', 'children': ['306']}; {'id': '306', 'type': 'concatenated_string', 'children': ['307', '308']}; {'id': '307', 'type': 'string', 'children': [], 'value': '\'Index Map "%s" for Mapping Table "%s" not found in list of index maps in the mapping \''}; {'id': '308', 'type': 'string', 'children': [], 'value': "'table file. The Mapping Table was not read into the database.'"}; {'id': '309', 'type': 'tuple', 'children': ['310', '313']}; {'id': '310', 'type': 'subscript', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '312', 'type': 'string', 'children': [], 'value': "'indexMapName'"}; {'id': '313', 'type': 'subscript', 'children': ['314', '315']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'mt'}; {'id': '315', 'type': 'string', 'children': [], 'value': "'name'"}
Create GSSHAPY Mapping Table ORM Objects Method
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_write'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'maskMap'}; {'id': '8', 'type': 'block', 'children': ['9', '13', '20', '80', '94', '108', '122', '136', '140', '200', '269']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'FIRST_VALUE_INDEX'}; {'id': '12', 'type': 'integer', 'children': [], 'value': '12'}; {'id': '13', 'type': 'expression_statement', 'children': ['14']}; {'id': '14', 'type': 'call', 'children': ['15', '18']}; {'id': '15', 'type': 'attribute', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '18', 'type': 'argument_list', 'children': ['19']}; {'id': '19', 'type': 'string', 'children': [], 'value': "'DATASET\\r\\n'"}; {'id': '20', 'type': 'if_statement', 'children': ['21', '28', '50']}; {'id': '21', 'type': 'comparison_operator', 'children': ['22', '25'], 'value': '=='}; {'id': '22', 'type': 'attribute', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'SCALAR_TYPE'}; {'id': '28', 'type': 'block', 'children': ['29', '43']}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'call', 'children': ['31', '34']}; {'id': '31', 'type': 'attribute', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '34', 'type': 'argument_list', 'children': ['35']}; {'id': '35', 'type': 'call', 'children': ['36', '39']}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'string', 'children': [], 'value': "'OBJTYPE {0}\\r\\n'"}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '39', 'type': 'argument_list', 'children': ['40']}; {'id': '40', 'type': 'attribute', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'objectType'}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'call', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'string', 'children': [], 'value': "'BEGSCL\\r\\n'"}; {'id': '50', 'type': 'elif_clause', 'children': ['51', '58']}; {'id': '51', 'type': 'comparison_operator', 'children': ['52', '55'], 'value': '=='}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'VECTOR_TYPE'}; {'id': '58', 'type': 'block', 'children': ['59', '73']}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'call', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '64', 'type': 'argument_list', 'children': ['65']}; {'id': '65', 'type': 'call', 'children': ['66', '69']}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'string', 'children': [], 'value': "'VECTYPE {0}\\r\\n'"}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '69', 'type': 'argument_list', 'children': ['70']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'vectorType'}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'call', 'children': ['75', '78']}; {'id': '75', 'type': 'attribute', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'string', 'children': [], 'value': "'BEGVEC\\r\\n'"}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'call', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '85', 'type': 'argument_list', 'children': ['86']}; {'id': '86', 'type': 'call', 'children': ['87', '90']}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'string', 'children': [], 'value': "'OBJID {0}\\r\\n'"}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '90', 'type': 'argument_list', 'children': ['91']}; {'id': '91', 'type': 'attribute', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'objectID'}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'call', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '99', 'type': 'argument_list', 'children': ['100']}; {'id': '100', 'type': 'call', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'string', 'children': [], 'value': "'ND {0}\\r\\n'"}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '104', 'type': 'argument_list', 'children': ['105']}; {'id': '105', 'type': 'attribute', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'numberData'}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'call', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '113', 'type': 'argument_list', 'children': ['114']}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'string', 'children': [], 'value': "'NC {0}\\r\\n'"}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '118', 'type': 'argument_list', 'children': ['119']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'numberCells'}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '127', 'type': 'argument_list', 'children': ['128']}; {'id': '128', 'type': 'call', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'string', 'children': [], 'value': "'NAME {0}\\r\\n'"}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '132', 'type': 'argument_list', 'children': ['133']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '136', 'type': 'expression_statement', 'children': ['137']}; {'id': '137', 'type': 'assignment', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'statusString'}; {'id': '139', 'type': 'string', 'children': [], 'value': "''"}; {'id': '140', 'type': 'if_statement', 'children': ['141', '146']}; {'id': '141', 'type': 'call', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '143', 'type': 'argument_list', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'maskMap'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'RasterMapFile'}; {'id': '146', 'type': 'block', 'children': ['147', '156', '181']}; {'id': '147', 'type': 'expression_statement', 'children': ['148']}; {'id': '148', 'type': 'assignment', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'statusGrassRasterString'}; {'id': '150', 'type': 'call', 'children': ['151', '154']}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'maskMap'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'getAsGrassAsciiGrid'}; {'id': '154', 'type': 'argument_list', 'children': ['155']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '156', 'type': 'if_statement', 'children': ['157', '160', '169']}; {'id': '157', 'type': 'comparison_operator', 'children': ['158', '159'], 'value': 'is'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'statusGrassRasterString'}; {'id': '159', 'type': 'None', 'children': []}; {'id': '160', 'type': 'block', 'children': ['161']}; {'id': '161', 'type': 'expression_statement', 'children': ['162']}; {'id': '162', 'type': 'assignment', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'statusValues'}; {'id': '164', 'type': 'call', 'children': ['165', '168']}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'statusGrassRasterString'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '168', 'type': 'argument_list', 'children': []}; {'id': '169', 'type': 'else_clause', 'children': ['170']}; {'id': '170', 'type': 'block', 'children': ['171']}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'assignment', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'statusValues'}; {'id': '174', 'type': 'call', 'children': ['175', '180']}; {'id': '175', 'type': 'attribute', 'children': ['176', '179']}; {'id': '176', 'type': 'attribute', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'maskMap'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'rasterText'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '180', 'type': 'argument_list', 'children': []}; {'id': '181', 'type': 'for_statement', 'children': ['182', '183', '191']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '183', 'type': 'call', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '185', 'type': 'argument_list', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'FIRST_VALUE_INDEX'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'statusValues'}; {'id': '191', 'type': 'block', 'children': ['192']}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'augmented_assignment', 'children': ['194', '195'], 'value': '+='}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'statusString'}; {'id': '195', 'type': 'binary_operator', 'children': ['196', '199'], 'value': '+'}; {'id': '196', 'type': 'subscript', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'statusValues'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '199', 'type': 'string', 'children': [], 'value': "'\\r\\n'"}; {'id': '200', 'type': 'for_statement', 'children': ['201', '202', '205']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '202', 'type': 'attribute', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'rasters'}; {'id': '205', 'type': 'block', 'children': ['206', '223', '237', '246']}; {'id': '206', 'type': 'expression_statement', 'children': ['207']}; {'id': '207', 'type': 'call', 'children': ['208', '211']}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '211', 'type': 'argument_list', 'children': ['212']}; {'id': '212', 'type': 'call', 'children': ['213', '216']}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'string', 'children': [], 'value': "'TS {0} {1}\\r\\n'"}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '216', 'type': 'argument_list', 'children': ['217', '220']}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'iStatus'}; {'id': '220', 'type': 'attribute', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'timestamp'}; {'id': '223', 'type': 'if_statement', 'children': ['224', '229']}; {'id': '224', 'type': 'comparison_operator', 'children': ['225', '228'], 'value': '=='}; {'id': '225', 'type': 'attribute', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'iStatus'}; {'id': '228', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '229', 'type': 'block', 'children': ['230']}; {'id': '230', 'type': 'expression_statement', 'children': ['231']}; {'id': '231', 'type': 'call', 'children': ['232', '235']}; {'id': '232', 'type': 'attribute', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '235', 'type': 'argument_list', 'children': ['236']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'statusString'}; {'id': '237', 'type': 'expression_statement', 'children': ['238']}; {'id': '238', 'type': 'assignment', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'valueString'}; {'id': '240', 'type': 'call', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'getAsWmsDatasetString'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'session'}; {'id': '246', 'type': 'if_statement', 'children': ['247', '250', '258']}; {'id': '247', 'type': 'comparison_operator', 'children': ['248', '249'], 'value': 'is'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'valueString'}; {'id': '249', 'type': 'None', 'children': []}; {'id': '250', 'type': 'block', 'children': ['251']}; {'id': '251', 'type': 'expression_statement', 'children': ['252']}; {'id': '252', 'type': 'call', 'children': ['253', '256']}; {'id': '253', 'type': 'attribute', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '256', 'type': 'argument_list', 'children': ['257']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'valueString'}; {'id': '258', 'type': 'else_clause', 'children': ['259']}; {'id': '259', 'type': 'block', 'children': ['260']}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'call', 'children': ['262', '265']}; {'id': '262', 'type': 'attribute', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '265', 'type': 'argument_list', 'children': ['266']}; {'id': '266', 'type': 'attribute', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'timeStepRaster'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'rasterText'}; {'id': '269', 'type': 'expression_statement', 'children': ['270']}; {'id': '270', 'type': 'call', 'children': ['271', '274']}; {'id': '271', 'type': 'attribute', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'openFile'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '274', 'type': 'argument_list', 'children': ['275']}; {'id': '275', 'type': 'string', 'children': [], 'value': "'ENDDS\\r\\n'"}
WMS Dataset File Write to File Method
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'gene_list'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'default_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '6', 'type': 'None', 'children': []}; {'id': '7', 'type': 'block', 'children': ['8', '24', '76', '130', '267']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'all_case_ids'}; {'id': '11', 'type': 'list_comprehension', 'children': ['12', '15']}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'case_id'}; {'id': '15', 'type': 'for_in_clause', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '17', 'type': 'call', 'children': ['18', '23']}; {'id': '18', 'type': 'attribute', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'cases'}; {'id': '23', 'type': 'argument_list', 'children': []}; {'id': '24', 'type': 'if_statement', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '26', 'type': 'block', 'children': ['27', '38', '60']}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '30', 'type': 'call', 'children': ['31', '36']}; {'id': '31', 'type': 'attribute', 'children': ['32', '35']}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'gene_list'}; {'id': '36', 'type': 'argument_list', 'children': ['37']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'case_ids'}; {'id': '41', 'type': 'list_comprehension', 'children': ['42', '45', '54']}; {'id': '42', 'type': 'attribute', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'case_id'}; {'id': '45', 'type': 'for_in_clause', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '47', 'type': 'call', 'children': ['48', '53']}; {'id': '48', 'type': 'attribute', 'children': ['49', '52']}; {'id': '49', 'type': 'attribute', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'cases'}; {'id': '53', 'type': 'argument_list', 'children': []}; {'id': '54', 'type': 'if_clause', 'children': ['55']}; {'id': '55', 'type': 'comparison_operator', 'children': ['56', '57'], 'value': 'not'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'cases'}; {'id': '60', 'type': 'if_statement', 'children': ['61', '64']}; {'id': '61', 'type': 'comparison_operator', 'children': ['62', '63'], 'value': 'is'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '63', 'type': 'None', 'children': []}; {'id': '64', 'type': 'block', 'children': ['65']}; {'id': '65', 'type': 'return_statement', 'children': ['66']}; {'id': '66', 'type': 'call', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'abort'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '70']}; {'id': '69', 'type': 'integer', 'children': [], 'value': '404'}; {'id': '70', 'type': 'call', 'children': ['71', '74']}; {'id': '71', 'type': 'attribute', 'children': ['72', '73']}; {'id': '72', 'type': 'string', 'children': [], 'value': '"gene list not found: {}"'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '74', 'type': 'argument_list', 'children': ['75']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '76', 'type': 'if_statement', 'children': ['77', '82']}; {'id': '77', 'type': 'comparison_operator', 'children': ['78', '79'], 'value': 'in'}; {'id': '78', 'type': 'string', 'children': [], 'value': "'download'"}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '82', 'type': 'block', 'children': ['83', '97', '111', '120', '128']}; {'id': '83', 'type': 'expression_statement', 'children': ['84']}; {'id': '84', 'type': 'assignment', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'response'}; {'id': '86', 'type': 'call', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'make_response'}; {'id': '88', 'type': 'argument_list', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '93', 'type': 'argument_list', 'children': ['94']}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'gene_ids'}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '100', 'type': 'call', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'secure_filename'}; {'id': '102', 'type': 'argument_list', 'children': ['103']}; {'id': '103', 'type': 'call', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'string', 'children': [], 'value': '"{}.txt"'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '107', 'type': 'argument_list', 'children': ['108']}; {'id': '108', 'type': 'attribute', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'string', 'children': [], 'value': '"attachment; filename={}"'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '118', 'type': 'argument_list', 'children': ['119']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '120', 'type': 'expression_statement', 'children': ['121']}; {'id': '121', 'type': 'assignment', 'children': ['122', '127']}; {'id': '122', 'type': 'subscript', 'children': ['123', '126']}; {'id': '123', 'type': 'attribute', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'response'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'headers'}; {'id': '126', 'type': 'string', 'children': [], 'value': "'Content-Disposition'"}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '128', 'type': 'return_statement', 'children': ['129']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'response'}; {'id': '130', 'type': 'if_statement', 'children': ['131', '136']}; {'id': '131', 'type': 'comparison_operator', 'children': ['132', '135'], 'value': '=='}; {'id': '132', 'type': 'attribute', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'method'}; {'id': '135', 'type': 'string', 'children': [], 'value': "'POST'"}; {'id': '136', 'type': 'block', 'children': ['137']}; {'id': '137', 'type': 'if_statement', 'children': ['138', '139', '190']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'list_id'}; {'id': '139', 'type': 'block', 'children': ['140', '151']}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'case_ids'}; {'id': '143', 'type': 'call', 'children': ['144', '149']}; {'id': '144', 'type': 'attribute', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'form'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'getlist'}; {'id': '149', 'type': 'argument_list', 'children': ['150']}; {'id': '150', 'type': 'string', 'children': [], 'value': "'case_id'"}; {'id': '151', 'type': 'for_statement', 'children': ['152', '153', '154']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'case_id'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'case_ids'}; {'id': '154', 'type': 'block', 'children': ['155', '166']}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'assignment', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'case_obj'}; {'id': '158', 'type': 'call', 'children': ['159', '164']}; {'id': '159', 'type': 'attribute', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'case'}; {'id': '164', 'type': 'argument_list', 'children': ['165']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'case_id'}; {'id': '166', 'type': 'if_statement', 'children': ['167', '172']}; {'id': '167', 'type': 'comparison_operator', 'children': ['168', '169'], 'value': 'not'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'case_obj'}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'cases'}; {'id': '172', 'type': 'block', 'children': ['173', '182']}; {'id': '173', 'type': 'expression_statement', 'children': ['174']}; {'id': '174', 'type': 'call', 'children': ['175', '180']}; {'id': '175', 'type': 'attribute', 'children': ['176', '179']}; {'id': '176', 'type': 'attribute', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'cases'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '180', 'type': 'argument_list', 'children': ['181']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'case_obj'}; {'id': '182', 'type': 'expression_statement', 'children': ['183']}; {'id': '183', 'type': 'call', 'children': ['184', '189']}; {'id': '184', 'type': 'attribute', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'save'}; {'id': '189', 'type': 'argument_list', 'children': []}; {'id': '190', 'type': 'else_clause', 'children': ['191']}; {'id': '191', 'type': 'block', 'children': ['192', '200', '216', '232', '242']}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'req_file'}; {'id': '195', 'type': 'subscript', 'children': ['196', '199']}; {'id': '196', 'type': 'attribute', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'files'}; {'id': '199', 'type': 'string', 'children': [], 'value': "'file'"}; {'id': '200', 'type': 'expression_statement', 'children': ['201']}; {'id': '201', 'type': 'assignment', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'new_listid'}; {'id': '203', 'type': '()', 'children': ['204']}; {'id': '204', 'type': 'boolean_operator', 'children': ['205', '210'], 'value': 'or'}; {'id': '205', 'type': 'subscript', 'children': ['206', '209']}; {'id': '206', 'type': 'attribute', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'form'}; {'id': '209', 'type': 'string', 'children': [], 'value': "'list_id'"}; {'id': '210', 'type': 'call', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'secure_filename'}; {'id': '212', 'type': 'argument_list', 'children': ['213']}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'req_file'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '216', 'type': 'if_statement', 'children': ['217', '225']}; {'id': '217', 'type': 'call', 'children': ['218', '223']}; {'id': '218', 'type': 'attribute', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'gene_list'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'new_listid'}; {'id': '225', 'type': 'block', 'children': ['226']}; {'id': '226', 'type': 'return_statement', 'children': ['227']}; {'id': '227', 'type': 'call', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'abort'}; {'id': '229', 'type': 'argument_list', 'children': ['230', '231']}; {'id': '230', 'type': 'integer', 'children': [], 'value': '500'}; {'id': '231', 'type': 'string', 'children': [], 'value': "'Please provide a unique list name'"}; {'id': '232', 'type': 'if_statement', 'children': ['233', '235']}; {'id': '233', 'type': 'not_operator', 'children': ['234']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'req_file'}; {'id': '235', 'type': 'block', 'children': ['236']}; {'id': '236', 'type': 'return_statement', 'children': ['237']}; {'id': '237', 'type': 'call', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'abort'}; {'id': '239', 'type': 'argument_list', 'children': ['240', '241']}; {'id': '240', 'type': 'integer', 'children': [], 'value': '500'}; {'id': '241', 'type': 'string', 'children': [], 'value': "'Please provide a file for upload'"}; {'id': '242', 'type': 'ERROR', 'children': ['243', '244', '245', '250', '253', '254', '265', '266']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'gene_ids'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '245', 'type': 'for_in_clause', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '247', 'type': 'attribute', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'req_file'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'line'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '253', 'type': 'ERROR', 'children': []}; {'id': '254', 'type': 'keyword_argument', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '256', 'type': 'call', 'children': ['257', '262']}; {'id': '257', 'type': 'attribute', 'children': ['258', '261']}; {'id': '258', 'type': 'attribute', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'app'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'add_genelist'}; {'id': '262', 'type': 'argument_list', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'new_listid'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'gene_ids'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'case_ids'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'all_case_ids'}; {'id': '267', 'type': 'return_statement', 'children': ['268']}; {'id': '268', 'type': 'call', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'render_template'}; {'id': '270', 'type': 'argument_list', 'children': ['271', '272', '275']}; {'id': '271', 'type': 'string', 'children': [], 'value': "'gene_list.html'"}; {'id': '272', 'type': 'keyword_argument', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'gene_list'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'genelist_obj'}; {'id': '275', 'type': 'keyword_argument', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'case_ids'}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'case_ids'}
Display or add a gene list.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'get_functarguments'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '5', 'type': 'block', 'children': ['6', '15', '75', '91', '97', '101', '108', '153', '288']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '9', 'type': 'call', 'children': ['10', '13']}; {'id': '10', 'type': 'attribute', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'inspect'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'getargspec'}; {'id': '13', 'type': 'argument_list', 'children': ['14']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '15', 'type': 'if_statement', 'children': ['16', '21', '63']}; {'id': '16', 'type': 'comparison_operator', 'children': ['17', '20'], 'value': 'is'}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '20', 'type': 'None', 'children': []}; {'id': '21', 'type': 'block', 'children': ['22', '38']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '25', 'type': 'subscript', 'children': ['26', '29']}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '29', 'type': 'slice', 'children': ['30', '31']}; {'id': '30', 'type': 'colon', 'children': []}; {'id': '31', 'type': 'unary_operator', 'children': ['32'], 'value': '-'}; {'id': '32', 'type': 'call', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '34', 'type': 'argument_list', 'children': ['35']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '41', 'type': 'call', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '43', 'type': 'argument_list', 'children': ['44']}; {'id': '44', 'type': 'call', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '46', 'type': 'argument_list', 'children': ['47', '60']}; {'id': '47', 'type': 'subscript', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '51', 'type': 'slice', 'children': ['52', '59']}; {'id': '52', 'type': 'unary_operator', 'children': ['53'], 'value': '-'}; {'id': '53', 'type': 'call', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '55', 'type': 'argument_list', 'children': ['56']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '59', 'type': 'colon', 'children': []}; {'id': '60', 'type': 'attribute', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '63', 'type': 'else_clause', 'children': ['64']}; {'id': '64', 'type': 'block', 'children': ['65', '71']}; {'id': '65', 'type': 'expression_statement', 'children': ['66']}; {'id': '66', 'type': 'assignment', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'argspec'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '71', 'type': 'expression_statement', 'children': ['72']}; {'id': '72', 'type': 'assignment', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '74', 'type': 'dictionary', 'children': []}; {'id': '75', 'type': 'if_statement', 'children': ['76', '83']}; {'id': '76', 'type': 'boolean_operator', 'children': ['77', '78'], 'value': 'and'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '78', 'type': 'comparison_operator', 'children': ['79', '82'], 'value': '=='}; {'id': '79', 'type': 'subscript', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '81', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '82', 'type': 'string', 'children': [], 'value': "'self'"}; {'id': '83', 'type': 'block', 'children': ['84']}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'call', 'children': ['86', '89']}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '91', 'type': 'expression_statement', 'children': ['92']}; {'id': '92', 'type': 'assignment', 'children': ['93', '96']}; {'id': '93', 'type': 'attribute', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': '__named__'}; {'id': '96', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '100', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'assignment', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'shared'}; {'id': '104', 'type': 'call', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'get_shared'}; {'id': '106', 'type': 'argument_list', 'children': ['107']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '108', 'type': 'for_statement', 'children': ['109', '110', '111']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '111', 'type': 'block', 'children': ['112', '122', '134', '144']}; {'id': '112', 'type': 'if_statement', 'children': ['113', '120']}; {'id': '113', 'type': 'comparison_operator', 'children': ['114', '119'], 'value': 'is'}; {'id': '114', 'type': 'call', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'has_shared'}; {'id': '116', 'type': 'argument_list', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'shared'}; {'id': '119', 'type': 'False', 'children': []}; {'id': '120', 'type': 'block', 'children': ['121']}; {'id': '121', 'type': 'continue_statement', 'children': []}; {'id': '122', 'type': 'if_statement', 'children': ['123', '132']}; {'id': '123', 'type': 'comparison_operator', 'children': ['124', '131'], 'value': 'is'}; {'id': '124', 'type': 'call', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'has_argument'}; {'id': '126', 'type': 'argument_list', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '131', 'type': 'False', 'children': []}; {'id': '132', 'type': 'block', 'children': ['133']}; {'id': '133', 'type': 'continue_statement', 'children': []}; {'id': '134', 'type': 'expression_statement', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '139']}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '139', 'type': 'argument_list', 'children': ['140']}; {'id': '140', 'type': 'tuple', 'children': ['141', '143']}; {'id': '141', 'type': 'list', 'children': ['142'], 'value': '[arg]'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '143', 'type': 'dictionary', 'children': []}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'call', 'children': ['146', '151']}; {'id': '146', 'type': 'attribute', 'children': ['147', '150']}; {'id': '147', 'type': 'attribute', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': '__named__'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '151', 'type': 'argument_list', 'children': ['152']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '153', 'type': 'for_statement', 'children': ['154', '157', '162']}; {'id': '154', 'type': 'pattern_list', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '161', 'type': 'argument_list', 'children': []}; {'id': '162', 'type': 'block', 'children': ['163', '173', '185', '270', '279']}; {'id': '163', 'type': 'if_statement', 'children': ['164', '171']}; {'id': '164', 'type': 'comparison_operator', 'children': ['165', '170'], 'value': 'is'}; {'id': '165', 'type': 'call', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'has_shared'}; {'id': '167', 'type': 'argument_list', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'shared'}; {'id': '170', 'type': 'False', 'children': []}; {'id': '171', 'type': 'block', 'children': ['172']}; {'id': '172', 'type': 'continue_statement', 'children': []}; {'id': '173', 'type': 'if_statement', 'children': ['174', '183']}; {'id': '174', 'type': 'comparison_operator', 'children': ['175', '182'], 'value': 'is'}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'has_argument'}; {'id': '177', 'type': 'argument_list', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '179', 'type': 'attribute', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '182', 'type': 'False', 'children': []}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'continue_statement', 'children': []}; {'id': '185', 'type': 'if_statement', 'children': ['186', '191', '242']}; {'id': '186', 'type': 'call', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '188', 'type': 'argument_list', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '191', 'type': 'block', 'children': ['192', '205', '215', '231']}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '195', 'type': 'list', 'children': ['196'], 'value': "[val.pop('lflag', '--%s' % key)]"}; {'id': '196', 'type': 'call', 'children': ['197', '200']}; {'id': '197', 'type': 'attribute', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '200', 'type': 'argument_list', 'children': ['201', '202']}; {'id': '201', 'type': 'string', 'children': [], 'value': "'lflag'"}; {'id': '202', 'type': 'binary_operator', 'children': ['203', '204'], 'value': '%'}; {'id': '203', 'type': 'string', 'children': [], 'value': "'--%s'"}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'assignment', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'short'}; {'id': '208', 'type': 'call', 'children': ['209', '212']}; {'id': '209', 'type': 'attribute', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '212', 'type': 'argument_list', 'children': ['213', '214']}; {'id': '213', 'type': 'string', 'children': [], 'value': "'flag'"}; {'id': '214', 'type': 'None', 'children': []}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '218', 'type': 'call', 'children': ['219', '228']}; {'id': '219', 'type': 'attribute', 'children': ['220', '227']}; {'id': '220', 'type': 'call', 'children': ['221', '224']}; {'id': '221', 'type': 'attribute', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '224', 'type': 'argument_list', 'children': ['225', '226']}; {'id': '225', 'type': 'string', 'children': [], 'value': "'dest'"}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '228', 'type': 'argument_list', 'children': ['229', '230']}; {'id': '229', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '230', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '231', 'type': 'if_statement', 'children': ['232', '233']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'short'}; {'id': '233', 'type': 'block', 'children': ['234']}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'call', 'children': ['236', '239']}; {'id': '236', 'type': 'attribute', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'insert'}; {'id': '239', 'type': 'argument_list', 'children': ['240', '241']}; {'id': '240', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'short'}; {'id': '242', 'type': 'else_clause', 'children': ['243']}; {'id': '243', 'type': 'block', 'children': ['244', '251', '260']}; {'id': '244', 'type': 'expression_statement', 'children': ['245']}; {'id': '245', 'type': 'assignment', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '247', 'type': 'list', 'children': ['248'], 'value': "['--%s' % key]"}; {'id': '248', 'type': 'binary_operator', 'children': ['249', '250'], 'value': '%'}; {'id': '249', 'type': 'string', 'children': [], 'value': "'--%s'"}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '251', 'type': 'expression_statement', 'children': ['252']}; {'id': '252', 'type': 'assignment', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '254', 'type': 'call', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '256', 'type': 'argument_list', 'children': ['257']}; {'id': '257', 'type': 'keyword_argument', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'assignment', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '263', 'type': 'call', 'children': ['264', '267']}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '267', 'type': 'argument_list', 'children': ['268', '269']}; {'id': '268', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '269', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '270', 'type': 'expression_statement', 'children': ['271']}; {'id': '271', 'type': 'call', 'children': ['272', '277']}; {'id': '272', 'type': 'attribute', 'children': ['273', '276']}; {'id': '273', 'type': 'attribute', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '275', 'type': 'identifier', 'children': [], 'value': '__named__'}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '277', 'type': 'argument_list', 'children': ['278']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '279', 'type': 'expression_statement', 'children': ['280']}; {'id': '280', 'type': 'call', 'children': ['281', '284']}; {'id': '281', 'type': 'attribute', 'children': ['282', '283']}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '284', 'type': 'argument_list', 'children': ['285']}; {'id': '285', 'type': 'tuple', 'children': ['286', '287']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'flags'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '288', 'type': 'return_statement', 'children': ['289']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'arguments'}
Recupera gli argomenti dalla funzione stessa.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'sort_cyclic_graph_best_effort'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'graph'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'pick_first'}; {'id': '7', 'type': 'string', 'children': [], 'value': "'head'"}; {'id': '8', 'type': 'block', 'children': ['9', '13', '19', '42', '46', '84', '88', '126']}; {'id': '9', 'type': 'expression_statement', 'children': ['10']}; {'id': '10', 'type': 'assignment', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'ordered'}; {'id': '12', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '13', 'type': 'expression_statement', 'children': ['14']}; {'id': '14', 'type': 'assignment', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'visited'}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '18', 'type': 'argument_list', 'children': []}; {'id': '19', 'type': 'if_statement', 'children': ['20', '23', '32']}; {'id': '20', 'type': 'comparison_operator', 'children': ['21', '22'], 'value': '=='}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'pick_first'}; {'id': '22', 'type': 'string', 'children': [], 'value': "'head'"}; {'id': '23', 'type': 'block', 'children': ['24']}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '29']}; {'id': '26', 'type': 'pattern_list', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'fst_attr'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'snd_attr'}; {'id': '29', 'type': 'tuple', 'children': ['30', '31']}; {'id': '30', 'type': 'string', 'children': [], 'value': "'head_node'"}; {'id': '31', 'type': 'string', 'children': [], 'value': "'update_node'"}; {'id': '32', 'type': 'else_clause', 'children': ['33']}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'expression_statement', 'children': ['35']}; {'id': '35', 'type': 'assignment', 'children': ['36', '39']}; {'id': '36', 'type': 'pattern_list', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'fst_attr'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'snd_attr'}; {'id': '39', 'type': 'tuple', 'children': ['40', '41']}; {'id': '40', 'type': 'string', 'children': [], 'value': "'update_node'"}; {'id': '41', 'type': 'string', 'children': [], 'value': "'head_node'"}; {'id': '42', 'type': 'expression_statement', 'children': ['43']}; {'id': '43', 'type': 'assignment', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'FIRST'}; {'id': '46', 'type': 'while_statement', 'children': ['47', '50']}; {'id': '47', 'type': 'comparison_operator', 'children': ['48', '49'], 'value': 'is'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '49', 'type': 'None', 'children': []}; {'id': '50', 'type': 'block', 'children': ['51', '58', '68']}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'call', 'children': ['53', '56']}; {'id': '53', 'type': 'attribute', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'visited'}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '56', 'type': 'argument_list', 'children': ['57']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '58', 'type': 'expression_statement', 'children': ['59']}; {'id': '59', 'type': 'assignment', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '61', 'type': 'call', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '63', 'type': 'argument_list', 'children': ['64', '67']}; {'id': '64', 'type': 'subscript', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'graph'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'fst_attr'}; {'id': '68', 'type': 'if_statement', 'children': ['69', '76']}; {'id': '69', 'type': 'boolean_operator', 'children': ['70', '73'], 'value': 'and'}; {'id': '70', 'type': 'comparison_operator', 'children': ['71', '72'], 'value': 'not'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'visited'}; {'id': '73', 'type': 'comparison_operator', 'children': ['74', '75'], 'value': 'is'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '75', 'type': 'None', 'children': []}; {'id': '76', 'type': 'block', 'children': ['77']}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'call', 'children': ['79', '82']}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'ordered'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '82', 'type': 'argument_list', 'children': ['83']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'FIRST'}; {'id': '88', 'type': 'while_statement', 'children': ['89', '92']}; {'id': '89', 'type': 'comparison_operator', 'children': ['90', '91'], 'value': 'is'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '91', 'type': 'None', 'children': []}; {'id': '92', 'type': 'block', 'children': ['93', '100', '110']}; {'id': '93', 'type': 'expression_statement', 'children': ['94']}; {'id': '94', 'type': 'call', 'children': ['95', '98']}; {'id': '95', 'type': 'attribute', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'visited'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '98', 'type': 'argument_list', 'children': ['99']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'assignment', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '103', 'type': 'call', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '105', 'type': 'argument_list', 'children': ['106', '109']}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'graph'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'snd_attr'}; {'id': '110', 'type': 'if_statement', 'children': ['111', '118']}; {'id': '111', 'type': 'boolean_operator', 'children': ['112', '115'], 'value': 'and'}; {'id': '112', 'type': 'comparison_operator', 'children': ['113', '114'], 'value': 'not'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'visited'}; {'id': '115', 'type': 'comparison_operator', 'children': ['116', '117'], 'value': 'is'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '117', 'type': 'None', 'children': []}; {'id': '118', 'type': 'block', 'children': ['119']}; {'id': '119', 'type': 'expression_statement', 'children': ['120']}; {'id': '120', 'type': 'call', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'ordered'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'current'}; {'id': '126', 'type': 'return_statement', 'children': ['127']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'ordered'}
Fallback for cases in which the graph has cycles.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'distance_function_match'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'thresh'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'dist_fn'}; {'id': '8', 'type': 'default_parameter', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'norm_funcs'}; {'id': '10', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '11', 'type': 'block', 'children': ['12', '16', '26', '36', '92', '112', '118', '156', '230']}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'common'}; {'id': '15', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'assignment', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '19', 'type': 'call', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '21', 'type': 'argument_list', 'children': ['22']}; {'id': '22', 'type': 'call', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '24', 'type': 'argument_list', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '29', 'type': 'call', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '31', 'type': 'argument_list', 'children': ['32']}; {'id': '32', 'type': 'call', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '34', 'type': 'argument_list', 'children': ['35']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '36', 'type': 'for_statement', 'children': ['37', '38', '39']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'norm_fn'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'norm_funcs'}; {'id': '39', 'type': 'block', 'children': ['40', '74']}; {'id': '40', 'type': 'expression_statement', 'children': ['41']}; {'id': '41', 'type': 'assignment', 'children': ['42', '46']}; {'id': '42', 'type': 'pattern_list', 'children': ['43', '44', '45']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'new_common'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '46', 'type': 'call', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': '_match_by_norm_func'}; {'id': '48', 'type': 'argument_list', 'children': ['49', '50', '51', '60', '73']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '51', 'type': 'lambda', 'children': ['52', '54']}; {'id': '52', 'type': 'lambda_parameters', 'children': ['53']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '54', 'type': 'call', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'norm_fn'}; {'id': '56', 'type': 'argument_list', 'children': ['57']}; {'id': '57', 'type': 'subscript', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'a'}; {'id': '59', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '60', 'type': 'lambda', 'children': ['61', '64']}; {'id': '61', 'type': 'lambda_parameters', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'a1'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'a2'}; {'id': '64', 'type': 'call', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'dist_fn'}; {'id': '66', 'type': 'argument_list', 'children': ['67', '70']}; {'id': '67', 'type': 'subscript', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'a1'}; {'id': '69', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '70', 'type': 'subscript', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'a2'}; {'id': '72', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'thresh'}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'common'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '79', 'type': 'generator_expression', 'children': ['80', '87']}; {'id': '80', 'type': 'tuple', 'children': ['81', '84']}; {'id': '81', 'type': 'subscript', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'c1'}; {'id': '83', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '84', 'type': 'subscript', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'c2'}; {'id': '86', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '87', 'type': 'for_in_clause', 'children': ['88', '91']}; {'id': '88', 'type': 'pattern_list', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'c1'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'c2'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'new_common'}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'dist_matrix'}; {'id': '95', 'type': 'list_comprehension', 'children': ['96', '107']}; {'id': '96', 'type': 'list_comprehension', 'children': ['97', '102']}; {'id': '97', 'type': 'call', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'dist_fn'}; {'id': '99', 'type': 'argument_list', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'e1'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'e2'}; {'id': '102', 'type': 'for_in_clause', 'children': ['103', '106']}; {'id': '103', 'type': 'pattern_list', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'i2'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'e2'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '107', 'type': 'for_in_clause', 'children': ['108', '111']}; {'id': '108', 'type': 'pattern_list', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'i1'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'e1'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '112', 'type': 'expression_statement', 'children': ['113']}; {'id': '113', 'type': 'assignment', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'components'}; {'id': '115', 'type': 'call', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'BipartiteConnectedComponents'}; {'id': '117', 'type': 'argument_list', 'children': []}; {'id': '118', 'type': 'for_statement', 'children': ['119', '120', '127']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'l1_i'}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '122', 'type': 'argument_list', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '127', 'type': 'block', 'children': ['128']}; {'id': '128', 'type': 'for_statement', 'children': ['129', '130', '137']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'l2_i'}; {'id': '130', 'type': 'call', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '132', 'type': 'argument_list', 'children': ['133']}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '135', 'type': 'argument_list', 'children': ['136']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '137', 'type': 'block', 'children': ['138', '148']}; {'id': '138', 'type': 'if_statement', 'children': ['139', '146']}; {'id': '139', 'type': 'comparison_operator', 'children': ['140', '145'], 'value': '>'}; {'id': '140', 'type': 'subscript', 'children': ['141', '144']}; {'id': '141', 'type': 'subscript', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'dist_matrix'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'l1_i'}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'l2_i'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'thresh'}; {'id': '146', 'type': 'block', 'children': ['147']}; {'id': '147', 'type': 'continue_statement', 'children': []}; {'id': '148', 'type': 'expression_statement', 'children': ['149']}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'components'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'add_edge'}; {'id': '153', 'type': 'argument_list', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'l1_i'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'l2_i'}; {'id': '156', 'type': 'for_statement', 'children': ['157', '160', '165']}; {'id': '157', 'type': 'pattern_list', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'l1_indices'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'l2_indices'}; {'id': '160', 'type': 'call', 'children': ['161', '164']}; {'id': '161', 'type': 'attribute', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'components'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'get_connected_components'}; {'id': '164', 'type': 'argument_list', 'children': []}; {'id': '165', 'type': 'block', 'children': ['166', '176', '186', '202', '212']}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'assignment', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'part_l1'}; {'id': '169', 'type': 'list_comprehension', 'children': ['170', '173']}; {'id': '170', 'type': 'subscript', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'l1'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '173', 'type': 'for_in_clause', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'l1_indices'}; {'id': '176', 'type': 'expression_statement', 'children': ['177']}; {'id': '177', 'type': 'assignment', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'part_l2'}; {'id': '179', 'type': 'list_comprehension', 'children': ['180', '183']}; {'id': '180', 'type': 'subscript', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'l2'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '183', 'type': 'for_in_clause', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'l2_indices'}; {'id': '186', 'type': 'expression_statement', 'children': ['187']}; {'id': '187', 'type': 'assignment', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'part_dist_matrix'}; {'id': '189', 'type': 'list_comprehension', 'children': ['190', '199']}; {'id': '190', 'type': 'list_comprehension', 'children': ['191', '196']}; {'id': '191', 'type': 'subscript', 'children': ['192', '195']}; {'id': '192', 'type': 'subscript', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'dist_matrix'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'l1_i'}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'l2_i'}; {'id': '196', 'type': 'for_in_clause', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'l2_i'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'l2_indices'}; {'id': '199', 'type': 'for_in_clause', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'l1_i'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'l1_indices'}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'part_cmn'}; {'id': '205', 'type': 'call', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': '_match_munkres'}; {'id': '207', 'type': 'argument_list', 'children': ['208', '209', '210', '211']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'part_l1'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'part_l2'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'part_dist_matrix'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'thresh'}; {'id': '212', 'type': 'expression_statement', 'children': ['213']}; {'id': '213', 'type': 'call', 'children': ['214', '217']}; {'id': '214', 'type': 'attribute', 'children': ['215', '216']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'common'}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '217', 'type': 'generator_expression', 'children': ['218', '225']}; {'id': '218', 'type': 'tuple', 'children': ['219', '222']}; {'id': '219', 'type': 'subscript', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'c1'}; {'id': '221', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '222', 'type': 'subscript', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'c2'}; {'id': '224', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '225', 'type': 'for_in_clause', 'children': ['226', '229']}; {'id': '226', 'type': 'pattern_list', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'c1'}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'c2'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'part_cmn'}; {'id': '230', 'type': 'return_statement', 'children': ['231']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'common'}
Returns pairs of matching indices from l1 and l2.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '8']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'arg'}; {'id': '3', 'type': 'parameters', 'children': ['4', '6']}; {'id': '4', 'type': 'list_splat_pattern', 'children': ['5']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '6', 'type': 'dictionary_splat_pattern', 'children': ['7']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '8', 'type': 'block', 'children': ['9', '182']}; {'id': '9', 'type': 'function_definition', 'children': ['10', '11', '13']}; {'id': '10', 'type': 'function_name', 'children': [], 'value': 'decorate'}; {'id': '11', 'type': 'parameters', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '13', 'type': 'block', 'children': ['14', '33', '43', '62', '137', '180']}; {'id': '14', 'type': 'expression_statement', 'children': ['15']}; {'id': '15', 'type': 'assignment', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '19', 'type': 'call', 'children': ['20', '23']}; {'id': '20', 'type': 'attribute', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '23', 'type': 'argument_list', 'children': ['24', '25']}; {'id': '24', 'type': 'string', 'children': [], 'value': "'cmd_name'"}; {'id': '25', 'type': 'call', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '27', 'type': 'argument_list', 'children': ['28', '29', '30']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '29', 'type': 'string', 'children': [], 'value': "'__cmd_name__'"}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': '__name__'}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'utils'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'check_class'}; {'id': '42', 'type': 'argument_list', 'children': []}; {'id': '43', 'type': 'if_statement', 'children': ['44', '50']}; {'id': '44', 'type': 'not_operator', 'children': ['45']}; {'id': '45', 'type': 'call', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '47', 'type': 'argument_list', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '49', 'type': 'string', 'children': [], 'value': "'__arguments__'"}; {'id': '50', 'type': 'block', 'children': ['51']}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '56']}; {'id': '53', 'type': 'attribute', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '55', 'type': 'identifier', 'children': [], 'value': '__arguments__'}; {'id': '56', 'type': 'call', 'children': ['57', '60']}; {'id': '57', 'type': 'attribute', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'utils'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'get_functarguments'}; {'id': '60', 'type': 'argument_list', 'children': ['61']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '62', 'type': 'if_statement', 'children': ['63', '72']}; {'id': '63', 'type': 'boolean_operator', 'children': ['64', '68'], 'value': 'or'}; {'id': '64', 'type': 'call', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '68', 'type': 'call', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '70', 'type': 'argument_list', 'children': ['71']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '72', 'type': 'block', 'children': ['73', '97', '126']}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'assignment', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'arg_name'}; {'id': '76', 'type': 'call', 'children': ['77', '80']}; {'id': '77', 'type': 'attribute', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '80', 'type': 'argument_list', 'children': ['81', '82']}; {'id': '81', 'type': 'string', 'children': [], 'value': "'dest'"}; {'id': '82', 'type': 'call', 'children': ['83', '94']}; {'id': '83', 'type': 'attribute', 'children': ['84', '93']}; {'id': '84', 'type': 'call', 'children': ['85', '91']}; {'id': '85', 'type': 'attribute', 'children': ['86', '90']}; {'id': '86', 'type': 'subscript', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '88', 'type': 'unary_operator', 'children': ['89'], 'value': '-'}; {'id': '89', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'lstrip'}; {'id': '91', 'type': 'argument_list', 'children': ['92']}; {'id': '92', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '94', 'type': 'argument_list', 'children': ['95', '96']}; {'id': '95', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '96', 'type': 'string', 'children': [], 'value': "'_'"}; {'id': '97', 'type': 'try_statement', 'children': ['98', '122']}; {'id': '98', 'type': 'block', 'children': ['99', '110', '116']}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'assignment', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '102', 'type': 'call', 'children': ['103', '108']}; {'id': '103', 'type': 'attribute', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': '__named__'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '108', 'type': 'argument_list', 'children': ['109']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'arg_name'}; {'id': '110', 'type': 'delete_statement', 'children': ['111']}; {'id': '111', 'type': 'subscript', 'children': ['112', '115']}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': '__named__'}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '116', 'type': 'delete_statement', 'children': ['117']}; {'id': '117', 'type': 'subscript', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': '__arguments__'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'idx'}; {'id': '122', 'type': 'except_clause', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '124', 'type': 'block', 'children': ['125']}; {'id': '125', 'type': 'pass_statement', 'children': []}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'call', 'children': ['128', '133']}; {'id': '128', 'type': 'attribute', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': '__arguments__'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '133', 'type': 'argument_list', 'children': ['134']}; {'id': '134', 'type': 'tuple', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '137', 'type': 'if_statement', 'children': ['138', '151']}; {'id': '138', 'type': 'boolean_operator', 'children': ['139', '144'], 'value': 'and'}; {'id': '139', 'type': 'comparison_operator', 'children': ['140', '143'], 'value': 'is'}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '143', 'type': 'None', 'children': []}; {'id': '144', 'type': 'call', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '146', 'type': 'argument_list', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '148', 'type': 'attribute', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'types'}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'FunctionType'}; {'id': '151', 'type': 'block', 'children': ['152', '161']}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'assignment', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '155', 'type': 'call', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'ArgParseInator'}; {'id': '157', 'type': 'argument_list', 'children': ['158']}; {'id': '158', 'type': 'keyword_argument', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'skip_init'}; {'id': '160', 'type': 'True', 'children': []}; {'id': '161', 'type': 'if_statement', 'children': ['162', '169']}; {'id': '162', 'type': 'comparison_operator', 'children': ['163', '166'], 'value': 'not'}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '166', 'type': 'attribute', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '169', 'type': 'block', 'children': ['170']}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'assignment', 'children': ['172', '179']}; {'id': '172', 'type': 'subscript', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '176', 'type': 'attribute', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '180', 'type': 'return_statement', 'children': ['181']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '182', 'type': 'return_statement', 'children': ['183']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'decorate'}
Dcorates a function or a class method to add to the argument parser
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'class_args'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '5', 'type': 'block', 'children': ['6', '15', '23', '29', '33', '44', '92', '150']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '9', 'type': 'call', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'ArgParseInator'}; {'id': '11', 'type': 'argument_list', 'children': ['12']}; {'id': '12', 'type': 'keyword_argument', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'skip_init'}; {'id': '14', 'type': 'True', 'children': []}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'call', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'utils'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'collect_appendvars'}; {'id': '20', 'type': 'argument_list', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '28']}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'cmds'}; {'id': '32', 'type': 'dictionary', 'children': []}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': '__arguments__'}; {'id': '38', 'type': 'call', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '40', 'type': 'argument_list', 'children': ['41', '42', '43']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '42', 'type': 'string', 'children': [], 'value': "'__arguments__'"}; {'id': '43', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '44', 'type': 'for_statement', 'children': ['45', '46', '71']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '46', 'type': 'list_comprehension', 'children': ['47', '48', '57']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '48', 'type': 'for_in_clause', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '50', 'type': 'call', 'children': ['51', '56']}; {'id': '51', 'type': 'attribute', 'children': ['52', '55']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '56', 'type': 'argument_list', 'children': []}; {'id': '57', 'type': 'if_clause', 'children': ['58']}; {'id': '58', 'type': 'boolean_operator', 'children': ['59', '64'], 'value': 'and'}; {'id': '59', 'type': 'call', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '61', 'type': 'argument_list', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '63', 'type': 'string', 'children': [], 'value': "'__cmd_name__'"}; {'id': '64', 'type': 'not_operator', 'children': ['65']}; {'id': '65', 'type': 'call', 'children': ['66', '69']}; {'id': '66', 'type': 'attribute', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'inspect'}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'isclass'}; {'id': '69', 'type': 'argument_list', 'children': ['70']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '71', 'type': 'block', 'children': ['72', '78', '84']}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': '__subcommands__'}; {'id': '77', 'type': 'None', 'children': []}; {'id': '78', 'type': 'expression_statement', 'children': ['79']}; {'id': '79', 'type': 'assignment', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': '__cls__'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '91']}; {'id': '86', 'type': 'subscript', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'cmds'}; {'id': '88', 'type': 'attribute', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '92', 'type': 'if_statement', 'children': ['93', '106', '123']}; {'id': '93', 'type': 'boolean_operator', 'children': ['94', '99'], 'value': 'and'}; {'id': '94', 'type': 'call', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '96', 'type': 'argument_list', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '98', 'type': 'string', 'children': [], 'value': "'__cmd_name__'"}; {'id': '99', 'type': 'comparison_operator', 'children': ['100', '103'], 'value': 'not'}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '106', 'type': 'block', 'children': ['107', '113']}; {'id': '107', 'type': 'expression_statement', 'children': ['108']}; {'id': '108', 'type': 'assignment', 'children': ['109', '112']}; {'id': '109', 'type': 'attribute', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '111', 'type': 'identifier', 'children': [], 'value': '__subcommands__'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'cmds'}; {'id': '113', 'type': 'expression_statement', 'children': ['114']}; {'id': '114', 'type': 'assignment', 'children': ['115', '122']}; {'id': '115', 'type': 'subscript', 'children': ['116', '119']}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': '__cmd_name__'}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'cls'}; {'id': '123', 'type': 'else_clause', 'children': ['124']}; {'id': '124', 'type': 'block', 'children': ['125']}; {'id': '125', 'type': 'for_statement', 'children': ['126', '129', '134']}; {'id': '126', 'type': 'pattern_list', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '129', 'type': 'call', 'children': ['130', '133']}; {'id': '130', 'type': 'attribute', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'cmds'}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '133', 'type': 'argument_list', 'children': []}; {'id': '134', 'type': 'block', 'children': ['135']}; {'id': '135', 'type': 'if_statement', 'children': ['136', '141']}; {'id': '136', 'type': 'comparison_operator', 'children': ['137', '138'], 'value': 'not'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '141', 'type': 'block', 'children': ['142']}; {'id': '142', 'type': 'expression_statement', 'children': ['143']}; {'id': '143', 'type': 'assignment', 'children': ['144', '149']}; {'id': '144', 'type': 'subscript', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'ap_'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'commands'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'func'}; {'id': '150', 'type': 'return_statement', 'children': ['151']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'cls'}
Decorates a class to handle the arguments parser.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'do_step'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '7', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'xy_values'}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'coeff'}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'width'}; {'id': '9', 'type': 'block', 'children': ['10', '25', '196', '215', '233']}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '13', 'type': 'dictionary_comprehension', 'children': ['14', '17']}; {'id': '14', 'type': 'pair', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '16', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '17', 'type': 'for_in_clause', 'children': ['18', '21']}; {'id': '18', 'type': 'pattern_list', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '21', 'type': 'call', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '23', 'type': 'argument_list', 'children': ['24']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'xy_values'}; {'id': '25', 'type': 'for_statement', 'children': ['26', '33', '41']}; {'id': '26', 'type': 'pattern_list', 'children': ['27', '30']}; {'id': '27', 'type': 'tuple_pattern', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'value1'}; {'id': '30', 'type': 'tuple_pattern', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'value2'}; {'id': '33', 'type': 'call', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'combinations'}; {'id': '35', 'type': 'argument_list', 'children': ['36', '40']}; {'id': '36', 'type': 'call', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '38', 'type': 'argument_list', 'children': ['39']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'xy_values'}; {'id': '40', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '41', 'type': 'block', 'children': ['42', '63']}; {'id': '42', 'type': 'expression_statement', 'children': ['43']}; {'id': '43', 'type': 'assignment', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '45', 'type': 'call', 'children': ['46', '49']}; {'id': '46', 'type': 'attribute', 'children': ['47', '48']}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'calc_2d_forces'}; {'id': '49', 'type': 'argument_list', 'children': ['50', '53', '56', '59', '62']}; {'id': '50', 'type': 'subscript', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'value1'}; {'id': '52', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '53', 'type': 'subscript', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'value1'}; {'id': '55', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '56', 'type': 'subscript', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'value2'}; {'id': '58', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '59', 'type': 'subscript', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'value2'}; {'id': '61', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'width'}; {'id': '63', 'type': 'if_statement', 'children': ['64', '71', '133']}; {'id': '64', 'type': 'comparison_operator', 'children': ['65', '68'], 'value': '<'}; {'id': '65', 'type': 'subscript', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'coeff'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '68', 'type': 'subscript', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'coeff'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '71', 'type': 'block', 'children': ['72']}; {'id': '72', 'type': 'if_statement', 'children': ['73', '86', '109']}; {'id': '73', 'type': 'comparison_operator', 'children': ['74', '81'], 'value': '<'}; {'id': '74', 'type': 'binary_operator', 'children': ['75', '78'], 'value': '-'}; {'id': '75', 'type': 'attribute', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'b_lenght'}; {'id': '78', 'type': 'subscript', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'coeff'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '81', 'type': 'binary_operator', 'children': ['82', '85'], 'value': '/'}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'b_lenght'}; {'id': '85', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '86', 'type': 'block', 'children': ['87', '98']}; {'id': '87', 'type': 'expression_statement', 'children': ['88']}; {'id': '88', 'type': 'call', 'children': ['89', '94']}; {'id': '89', 'type': 'attribute', 'children': ['90', '93']}; {'id': '90', 'type': 'subscript', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '94', 'type': 'argument_list', 'children': ['95']}; {'id': '95', 'type': 'subscript', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '97', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '98', 'type': 'expression_statement', 'children': ['99']}; {'id': '99', 'type': 'call', 'children': ['100', '105']}; {'id': '100', 'type': 'attribute', 'children': ['101', '104']}; {'id': '101', 'type': 'subscript', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '105', 'type': 'argument_list', 'children': ['106']}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '108', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '109', 'type': 'else_clause', 'children': ['110']}; {'id': '110', 'type': 'block', 'children': ['111', '122']}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'call', 'children': ['113', '118']}; {'id': '113', 'type': 'attribute', 'children': ['114', '117']}; {'id': '114', 'type': 'subscript', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '118', 'type': 'argument_list', 'children': ['119']}; {'id': '119', 'type': 'subscript', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '121', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '129']}; {'id': '124', 'type': 'attribute', 'children': ['125', '128']}; {'id': '125', 'type': 'subscript', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '129', 'type': 'argument_list', 'children': ['130']}; {'id': '130', 'type': 'subscript', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '132', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '133', 'type': 'else_clause', 'children': ['134']}; {'id': '134', 'type': 'block', 'children': ['135']}; {'id': '135', 'type': 'if_statement', 'children': ['136', '149', '172']}; {'id': '136', 'type': 'comparison_operator', 'children': ['137', '144'], 'value': '<'}; {'id': '137', 'type': 'binary_operator', 'children': ['138', '141'], 'value': '-'}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'b_lenght'}; {'id': '141', 'type': 'subscript', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'coeff'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '144', 'type': 'binary_operator', 'children': ['145', '148'], 'value': '/'}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'b_lenght'}; {'id': '148', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '149', 'type': 'block', 'children': ['150', '161']}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'call', 'children': ['152', '157']}; {'id': '152', 'type': 'attribute', 'children': ['153', '156']}; {'id': '153', 'type': 'subscript', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '157', 'type': 'argument_list', 'children': ['158']}; {'id': '158', 'type': 'subscript', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '160', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '161', 'type': 'expression_statement', 'children': ['162']}; {'id': '162', 'type': 'call', 'children': ['163', '168']}; {'id': '163', 'type': 'attribute', 'children': ['164', '167']}; {'id': '164', 'type': 'subscript', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '168', 'type': 'argument_list', 'children': ['169']}; {'id': '169', 'type': 'subscript', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '171', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '172', 'type': 'else_clause', 'children': ['173']}; {'id': '173', 'type': 'block', 'children': ['174', '185']}; {'id': '174', 'type': 'expression_statement', 'children': ['175']}; {'id': '175', 'type': 'call', 'children': ['176', '181']}; {'id': '176', 'type': 'attribute', 'children': ['177', '180']}; {'id': '177', 'type': 'subscript', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'index1'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '181', 'type': 'argument_list', 'children': ['182']}; {'id': '182', 'type': 'subscript', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '184', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '185', 'type': 'expression_statement', 'children': ['186']}; {'id': '186', 'type': 'call', 'children': ['187', '192']}; {'id': '187', 'type': 'attribute', 'children': ['188', '191']}; {'id': '188', 'type': 'subscript', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'index2'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '192', 'type': 'argument_list', 'children': ['193']}; {'id': '193', 'type': 'subscript', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '195', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '199', 'type': 'dictionary_comprehension', 'children': ['200', '206']}; {'id': '200', 'type': 'pair', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '202', 'type': 'call', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '204', 'type': 'argument_list', 'children': ['205']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '206', 'type': 'for_in_clause', 'children': ['207', '210']}; {'id': '207', 'type': 'pattern_list', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '210', 'type': 'call', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '214', 'type': 'argument_list', 'children': []}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'energy'}; {'id': '218', 'type': 'call', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '220', 'type': 'argument_list', 'children': ['221']}; {'id': '221', 'type': 'list_comprehension', 'children': ['222', '226']}; {'id': '222', 'type': 'call', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'abs'}; {'id': '224', 'type': 'argument_list', 'children': ['225']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '226', 'type': 'for_in_clause', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '228', 'type': 'call', 'children': ['229', '232']}; {'id': '229', 'type': 'attribute', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '232', 'type': 'argument_list', 'children': []}; {'id': '233', 'type': 'return_statement', 'children': ['234']}; {'id': '234', 'type': 'expression_list', 'children': ['235', '252']}; {'id': '235', 'type': 'list_comprehension', 'children': ['236', '244']}; {'id': '236', 'type': '()', 'children': ['237']}; {'id': '237', 'type': 'binary_operator', 'children': ['238', '243'], 'value': '+'}; {'id': '238', 'type': 'binary_operator', 'children': ['239', '242'], 'value': '/'}; {'id': '239', 'type': 'subscript', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'forces'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '242', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '244', 'type': 'for_in_clause', 'children': ['245', '248']}; {'id': '245', 'type': 'pattern_list', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '248', 'type': 'call', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '250', 'type': 'argument_list', 'children': ['251']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'energy'}
Calculates forces between two diagrams and pushes them apart by tenth of width
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'run'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '8', '14', '32', '43', '49', '55', '64', '80', '100', '123', '243', '303']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'string', 'children': [], 'value': "'''Run the LaTeX compilation.'''"}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '13']}; {'id': '10', 'type': 'attribute', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'old_dir'}; {'id': '13', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '14', 'type': 'if_statement', 'children': ['15', '20']}; {'id': '15', 'type': 'attribute', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'opt'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'clean'}; {'id': '20', 'type': 'block', 'children': ['21']}; {'id': '21', 'type': 'expression_statement', 'children': ['22']}; {'id': '22', 'type': 'assignment', 'children': ['23', '26']}; {'id': '23', 'type': 'attribute', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'old_dir'}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'listdir'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'assignment', 'children': ['34', '38']}; {'id': '34', 'type': 'pattern_list', 'children': ['35', '36', '37']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'cite_counter'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'toc_file'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'gloss_files'}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': '_read_latex_files'}; {'id': '42', 'type': 'argument_list', 'children': []}; {'id': '43', 'type': 'expression_statement', 'children': ['44']}; {'id': '44', 'type': 'call', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'latex_run'}; {'id': '48', 'type': 'argument_list', 'children': []}; {'id': '49', 'type': 'expression_statement', 'children': ['50']}; {'id': '50', 'type': 'call', 'children': ['51', '54']}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'read_glossaries'}; {'id': '54', 'type': 'argument_list', 'children': []}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'gloss_changed'}; {'id': '58', 'type': 'call', 'children': ['59', '62']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'makeindex_runs'}; {'id': '62', 'type': 'argument_list', 'children': ['63']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'gloss_files'}; {'id': '64', 'type': 'if_statement', 'children': ['65', '73']}; {'id': '65', 'type': 'boolean_operator', 'children': ['66', '67'], 'value': 'or'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'gloss_changed'}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': '_is_toc_changed'}; {'id': '71', 'type': 'argument_list', 'children': ['72']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'toc_file'}; {'id': '73', 'type': 'block', 'children': ['74']}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'latex_run'}; {'id': '79', 'type': 'argument_list', 'children': []}; {'id': '80', 'type': 'if_statement', 'children': ['81', '87']}; {'id': '81', 'type': 'call', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': '_need_bib_run'}; {'id': '85', 'type': 'argument_list', 'children': ['86']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'cite_counter'}; {'id': '87', 'type': 'block', 'children': ['88', '94']}; {'id': '88', 'type': 'expression_statement', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'bibtex_run'}; {'id': '93', 'type': 'argument_list', 'children': []}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'call', 'children': ['96', '99']}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'latex_run'}; {'id': '99', 'type': 'argument_list', 'children': []}; {'id': '100', 'type': 'while_statement', 'children': ['101', '107']}; {'id': '101', 'type': '()', 'children': ['102']}; {'id': '102', 'type': 'comparison_operator', 'children': ['103', '106'], 'value': '<'}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'latex_run_counter'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'MAX_RUNS'}; {'id': '107', 'type': 'block', 'children': ['108', '117']}; {'id': '108', 'type': 'if_statement', 'children': ['109', '115']}; {'id': '109', 'type': 'not_operator', 'children': ['110']}; {'id': '110', 'type': 'call', 'children': ['111', '114']}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'need_latex_rerun'}; {'id': '114', 'type': 'argument_list', 'children': []}; {'id': '115', 'type': 'block', 'children': ['116']}; {'id': '116', 'type': 'break_statement', 'children': []}; {'id': '117', 'type': 'expression_statement', 'children': ['118']}; {'id': '118', 'type': 'call', 'children': ['119', '122']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'latex_run'}; {'id': '122', 'type': 'argument_list', 'children': []}; {'id': '123', 'type': 'if_statement', 'children': ['124', '129']}; {'id': '124', 'type': 'attribute', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'opt'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'check_cite'}; {'id': '129', 'type': 'block', 'children': ['130', '136', '159', '185', '208']}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'assignment', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'cites'}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'set'}; {'id': '135', 'type': 'argument_list', 'children': []}; {'id': '136', 'type': 'with_statement', 'children': ['137', '150']}; {'id': '137', 'type': 'with_clause', 'children': ['138']}; {'id': '138', 'type': 'with_item', 'children': ['139']}; {'id': '139', 'type': 'as_pattern', 'children': ['140', '148']}; {'id': '140', 'type': 'call', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '142', 'type': 'argument_list', 'children': ['143']}; {'id': '143', 'type': 'binary_operator', 'children': ['144', '145'], 'value': '%'}; {'id': '144', 'type': 'string', 'children': [], 'value': "'%s.aux'"}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'project_name'}; {'id': '148', 'type': 'as_pattern_target', 'children': ['149']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'fobj'}; {'id': '150', 'type': 'block', 'children': ['151']}; {'id': '151', 'type': 'expression_statement', 'children': ['152']}; {'id': '152', 'type': 'assignment', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'aux_content'}; {'id': '154', 'type': 'call', 'children': ['155', '158']}; {'id': '155', 'type': 'attribute', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'fobj'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'read'}; {'id': '158', 'type': 'argument_list', 'children': []}; {'id': '159', 'type': 'for_statement', 'children': ['160', '161', '167']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '161', 'type': 'call', 'children': ['162', '165']}; {'id': '162', 'type': 'attribute', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'BIBCITE_PATTERN'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'finditer'}; {'id': '165', 'type': 'argument_list', 'children': ['166']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'aux_content'}; {'id': '167', 'type': 'block', 'children': ['168', '178']}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '171', 'type': 'subscript', 'children': ['172', '177']}; {'id': '172', 'type': 'call', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '176', 'type': 'argument_list', 'children': []}; {'id': '177', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '178', 'type': 'expression_statement', 'children': ['179']}; {'id': '179', 'type': 'call', 'children': ['180', '183']}; {'id': '180', 'type': 'attribute', 'children': ['181', '182']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'cites'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '183', 'type': 'argument_list', 'children': ['184']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '185', 'type': 'with_statement', 'children': ['186', '199']}; {'id': '186', 'type': 'with_clause', 'children': ['187']}; {'id': '187', 'type': 'with_item', 'children': ['188']}; {'id': '188', 'type': 'as_pattern', 'children': ['189', '197']}; {'id': '189', 'type': 'call', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '191', 'type': 'argument_list', 'children': ['192']}; {'id': '192', 'type': 'binary_operator', 'children': ['193', '194'], 'value': '%'}; {'id': '193', 'type': 'string', 'children': [], 'value': "'%s.bib'"}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'bib_file'}; {'id': '197', 'type': 'as_pattern_target', 'children': ['198']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'fobj'}; {'id': '199', 'type': 'block', 'children': ['200']}; {'id': '200', 'type': 'expression_statement', 'children': ['201']}; {'id': '201', 'type': 'assignment', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'bib_content'}; {'id': '203', 'type': 'call', 'children': ['204', '207']}; {'id': '204', 'type': 'attribute', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'fobj'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'read'}; {'id': '207', 'type': 'argument_list', 'children': []}; {'id': '208', 'type': 'for_statement', 'children': ['209', '210', '216']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '210', 'type': 'call', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'BIBENTRY_PATTERN'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'finditer'}; {'id': '214', 'type': 'argument_list', 'children': ['215']}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'bib_content'}; {'id': '216', 'type': 'block', 'children': ['217', '227']}; {'id': '217', 'type': 'expression_statement', 'children': ['218']}; {'id': '218', 'type': 'assignment', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '220', 'type': 'subscript', 'children': ['221', '226']}; {'id': '221', 'type': 'call', 'children': ['222', '225']}; {'id': '222', 'type': 'attribute', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '225', 'type': 'argument_list', 'children': []}; {'id': '226', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '227', 'type': 'if_statement', 'children': ['228', '231']}; {'id': '228', 'type': 'comparison_operator', 'children': ['229', '230'], 'value': 'not'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'cites'}; {'id': '231', 'type': 'block', 'children': ['232']}; {'id': '232', 'type': 'expression_statement', 'children': ['233']}; {'id': '233', 'type': 'call', 'children': ['234', '239']}; {'id': '234', 'type': 'attribute', 'children': ['235', '238']}; {'id': '235', 'type': 'attribute', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '239', 'type': 'argument_list', 'children': ['240']}; {'id': '240', 'type': 'binary_operator', 'children': ['241', '242'], 'value': '%'}; {'id': '241', 'type': 'string', 'children': [], 'value': '\'Bib entry not cited: "%s"\''}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '243', 'type': 'if_statement', 'children': ['244', '249']}; {'id': '244', 'type': 'attribute', 'children': ['245', '248']}; {'id': '245', 'type': 'attribute', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'opt'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'clean'}; {'id': '249', 'type': 'block', 'children': ['250', '254', '265']}; {'id': '250', 'type': 'expression_statement', 'children': ['251']}; {'id': '251', 'type': 'assignment', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'ending'}; {'id': '253', 'type': 'string', 'children': [], 'value': "'.dvi'"}; {'id': '254', 'type': 'if_statement', 'children': ['255', '260']}; {'id': '255', 'type': 'attribute', 'children': ['256', '259']}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'opt'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'pdf'}; {'id': '260', 'type': 'block', 'children': ['261']}; {'id': '261', 'type': 'expression_statement', 'children': ['262']}; {'id': '262', 'type': 'assignment', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'ending'}; {'id': '264', 'type': 'string', 'children': [], 'value': "'.pdf'"}; {'id': '265', 'type': 'for_statement', 'children': ['266', '267', '273']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'fname'}; {'id': '267', 'type': 'call', 'children': ['268', '271']}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'listdir'}; {'id': '271', 'type': 'argument_list', 'children': ['272']}; {'id': '272', 'type': 'string', 'children': [], 'value': "'.'"}; {'id': '273', 'type': 'block', 'children': ['274']}; {'id': '274', 'type': 'if_statement', 'children': ['275', '289']}; {'id': '275', 'type': 'not_operator', 'children': ['276']}; {'id': '276', 'type': '()', 'children': ['277']}; {'id': '277', 'type': 'boolean_operator', 'children': ['278', '283'], 'value': 'or'}; {'id': '278', 'type': 'comparison_operator', 'children': ['279', '280'], 'value': 'in'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'fname'}; {'id': '280', 'type': 'attribute', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'old_dir'}; {'id': '283', 'type': 'call', 'children': ['284', '287']}; {'id': '284', 'type': 'attribute', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'fname'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'endswith'}; {'id': '287', 'type': 'argument_list', 'children': ['288']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'ending'}; {'id': '289', 'type': 'block', 'children': ['290']}; {'id': '290', 'type': 'try_statement', 'children': ['291', '299']}; {'id': '291', 'type': 'block', 'children': ['292']}; {'id': '292', 'type': 'expression_statement', 'children': ['293']}; {'id': '293', 'type': 'call', 'children': ['294', '297']}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '297', 'type': 'argument_list', 'children': ['298']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'fname'}; {'id': '299', 'type': 'except_clause', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'IOError'}; {'id': '301', 'type': 'block', 'children': ['302']}; {'id': '302', 'type': 'pass_statement', 'children': []}; {'id': '303', 'type': 'if_statement', 'children': ['304', '309']}; {'id': '304', 'type': 'attribute', 'children': ['305', '308']}; {'id': '305', 'type': 'attribute', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'opt'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'preview'}; {'id': '309', 'type': 'block', 'children': ['310']}; {'id': '310', 'type': 'expression_statement', 'children': ['311']}; {'id': '311', 'type': 'call', 'children': ['312', '315']}; {'id': '312', 'type': 'attribute', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'open_preview'}; {'id': '315', 'type': 'argument_list', 'children': []}
Run the LaTeX compilation.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'time_stops'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '14']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '11']}; {'id': '7', 'type': 'not_operator', 'children': ['8']}; {'id': '8', 'type': 'attribute', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'supports_time'}; {'id': '11', 'type': 'block', 'children': ['12']}; {'id': '12', 'type': 'return_statement', 'children': ['13']}; {'id': '13', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '14', 'type': 'if_statement', 'children': ['15', '22', '325']}; {'id': '15', 'type': 'comparison_operator', 'children': ['16', '21'], 'value': '=='}; {'id': '16', 'type': 'attribute', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'service'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'calendar'}; {'id': '21', 'type': 'string', 'children': [], 'value': "'standard'"}; {'id': '22', 'type': 'block', 'children': ['23', '31', '39', '46', '288', '323']}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '26', 'type': 'attribute', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'service'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'time_interval_units'}; {'id': '31', 'type': 'expression_statement', 'children': ['32']}; {'id': '32', 'type': 'assignment', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '34', 'type': 'attribute', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'service'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'time_interval'}; {'id': '39', 'type': 'expression_statement', 'children': ['40']}; {'id': '40', 'type': 'assignment', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'steps'}; {'id': '42', 'type': 'list', 'children': ['43'], 'value': '[self.time_start]'}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'time_start'}; {'id': '46', 'type': 'if_statement', 'children': ['47', '53', '100', '177']}; {'id': '47', 'type': 'comparison_operator', 'children': ['48', '49'], 'value': 'in'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '49', 'type': 'tuple', 'children': ['50', '51', '52']}; {'id': '50', 'type': 'string', 'children': [], 'value': "'years'"}; {'id': '51', 'type': 'string', 'children': [], 'value': "'decades'"}; {'id': '52', 'type': 'string', 'children': [], 'value': "'centuries'"}; {'id': '53', 'type': 'block', 'children': ['54', '82']}; {'id': '54', 'type': 'if_statement', 'children': ['55', '58', '63', '74']}; {'id': '55', 'type': 'comparison_operator', 'children': ['56', '57'], 'value': '=='}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '57', 'type': 'string', 'children': [], 'value': "'years'"}; {'id': '58', 'type': 'block', 'children': ['59']}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'years'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '63', 'type': 'elif_clause', 'children': ['64', '67']}; {'id': '64', 'type': 'comparison_operator', 'children': ['65', '66'], 'value': '=='}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '66', 'type': 'string', 'children': [], 'value': "'decades'"}; {'id': '67', 'type': 'block', 'children': ['68']}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'years'}; {'id': '71', 'type': 'binary_operator', 'children': ['72', '73'], 'value': '*'}; {'id': '72', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '74', 'type': 'else_clause', 'children': ['75']}; {'id': '75', 'type': 'block', 'children': ['76']}; {'id': '76', 'type': 'expression_statement', 'children': ['77']}; {'id': '77', 'type': 'assignment', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'years'}; {'id': '79', 'type': 'binary_operator', 'children': ['80', '81'], 'value': '*'}; {'id': '80', 'type': 'integer', 'children': [], 'value': '100'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '82', 'type': 'expression_statement', 'children': ['83']}; {'id': '83', 'type': 'assignment', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'next_value'}; {'id': '85', 'type': 'lambda', 'children': ['86', '88']}; {'id': '86', 'type': 'lambda_parameters', 'children': ['87']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '88', 'type': 'call', 'children': ['89', '92']}; {'id': '89', 'type': 'attribute', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '92', 'type': 'argument_list', 'children': ['93']}; {'id': '93', 'type': 'keyword_argument', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '95', 'type': 'binary_operator', 'children': ['96', '99'], 'value': '+'}; {'id': '96', 'type': 'attribute', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'years'}; {'id': '100', 'type': 'elif_clause', 'children': ['101', '104']}; {'id': '101', 'type': 'comparison_operator', 'children': ['102', '103'], 'value': '=='}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '103', 'type': 'string', 'children': [], 'value': "'months'"}; {'id': '104', 'type': 'block', 'children': ['105', '173']}; {'id': '105', 'type': 'function_definition', 'children': ['106', '107', '109']}; {'id': '106', 'type': 'function_name', 'children': [], 'value': '_fn'}; {'id': '107', 'type': 'parameters', 'children': ['108']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '109', 'type': 'block', 'children': ['110', '127', '140', '158']}; {'id': '110', 'type': 'expression_statement', 'children': ['111']}; {'id': '111', 'type': 'assignment', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '113', 'type': 'binary_operator', 'children': ['114', '117'], 'value': '+'}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '117', 'type': 'binary_operator', 'children': ['118', '126'], 'value': '//'}; {'id': '118', 'type': '()', 'children': ['119']}; {'id': '119', 'type': 'binary_operator', 'children': ['120', '125'], 'value': '-'}; {'id': '120', 'type': 'binary_operator', 'children': ['121', '124'], 'value': '+'}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '125', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '126', 'type': 'integer', 'children': [], 'value': '12'}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '130', 'type': 'boolean_operator', 'children': ['131', '139'], 'value': 'or'}; {'id': '131', 'type': 'binary_operator', 'children': ['132', '138'], 'value': '%'}; {'id': '132', 'type': '()', 'children': ['133']}; {'id': '133', 'type': 'binary_operator', 'children': ['134', '137'], 'value': '+'}; {'id': '134', 'type': 'attribute', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '138', 'type': 'integer', 'children': [], 'value': '12'}; {'id': '139', 'type': 'integer', 'children': [], 'value': '12'}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'day'}; {'id': '143', 'type': 'call', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '145', 'type': 'argument_list', 'children': ['146', '149']}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'day'}; {'id': '149', 'type': 'subscript', 'children': ['150', '157']}; {'id': '150', 'type': 'call', 'children': ['151', '154']}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'calendar'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'monthrange'}; {'id': '154', 'type': 'argument_list', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '157', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '158', 'type': 'return_statement', 'children': ['159']}; {'id': '159', 'type': 'call', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '163', 'type': 'argument_list', 'children': ['164', '167', '170']}; {'id': '164', 'type': 'keyword_argument', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'year'}; {'id': '167', 'type': 'keyword_argument', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'month'}; {'id': '170', 'type': 'keyword_argument', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'day'}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'day'}; {'id': '173', 'type': 'expression_statement', 'children': ['174']}; {'id': '174', 'type': 'assignment', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'next_value'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': '_fn'}; {'id': '177', 'type': 'else_clause', 'children': ['178']}; {'id': '178', 'type': 'block', 'children': ['179', '279']}; {'id': '179', 'type': 'if_statement', 'children': ['180', '183', '193', '207', '221', '235', '249', '263']}; {'id': '180', 'type': 'comparison_operator', 'children': ['181', '182'], 'value': '=='}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '182', 'type': 'string', 'children': [], 'value': "'milliseconds'"}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'assignment', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'keyword_argument', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'milliseconds'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '193', 'type': 'elif_clause', 'children': ['194', '197']}; {'id': '194', 'type': 'comparison_operator', 'children': ['195', '196'], 'value': '=='}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '196', 'type': 'string', 'children': [], 'value': "'seconds'"}; {'id': '197', 'type': 'block', 'children': ['198']}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'assignment', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '201', 'type': 'call', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'keyword_argument', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'seconds'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '207', 'type': 'elif_clause', 'children': ['208', '211']}; {'id': '208', 'type': 'comparison_operator', 'children': ['209', '210'], 'value': '=='}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '210', 'type': 'string', 'children': [], 'value': "'minutes'"}; {'id': '211', 'type': 'block', 'children': ['212']}; {'id': '212', 'type': 'expression_statement', 'children': ['213']}; {'id': '213', 'type': 'assignment', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '215', 'type': 'call', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '217', 'type': 'argument_list', 'children': ['218']}; {'id': '218', 'type': 'keyword_argument', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'minutes'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '221', 'type': 'elif_clause', 'children': ['222', '225']}; {'id': '222', 'type': 'comparison_operator', 'children': ['223', '224'], 'value': '=='}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '224', 'type': 'string', 'children': [], 'value': "'hours'"}; {'id': '225', 'type': 'block', 'children': ['226']}; {'id': '226', 'type': 'expression_statement', 'children': ['227']}; {'id': '227', 'type': 'assignment', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '229', 'type': 'call', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '231', 'type': 'argument_list', 'children': ['232']}; {'id': '232', 'type': 'keyword_argument', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'hours'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '235', 'type': 'elif_clause', 'children': ['236', '239']}; {'id': '236', 'type': 'comparison_operator', 'children': ['237', '238'], 'value': '=='}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '238', 'type': 'string', 'children': [], 'value': "'days'"}; {'id': '239', 'type': 'block', 'children': ['240']}; {'id': '240', 'type': 'expression_statement', 'children': ['241']}; {'id': '241', 'type': 'assignment', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '243', 'type': 'call', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '245', 'type': 'argument_list', 'children': ['246']}; {'id': '246', 'type': 'keyword_argument', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'days'}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '249', 'type': 'elif_clause', 'children': ['250', '253']}; {'id': '250', 'type': 'comparison_operator', 'children': ['251', '252'], 'value': '=='}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'units'}; {'id': '252', 'type': 'string', 'children': [], 'value': "'weeks'"}; {'id': '253', 'type': 'block', 'children': ['254']}; {'id': '254', 'type': 'expression_statement', 'children': ['255']}; {'id': '255', 'type': 'assignment', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '257', 'type': 'call', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '259', 'type': 'argument_list', 'children': ['260']}; {'id': '260', 'type': 'keyword_argument', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'weeks'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'interval'}; {'id': '263', 'type': 'else_clause', 'children': ['264']}; {'id': '264', 'type': 'block', 'children': ['265']}; {'id': '265', 'type': 'raise_statement', 'children': ['266']}; {'id': '266', 'type': 'call', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'ValidationError'}; {'id': '268', 'type': 'argument_list', 'children': ['269']}; {'id': '269', 'type': 'call', 'children': ['270', '273']}; {'id': '270', 'type': 'attribute', 'children': ['271', '272']}; {'id': '271', 'type': 'string', 'children': [], 'value': '"Service has an invalid time_interval_units: {}"'}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '273', 'type': 'argument_list', 'children': ['274']}; {'id': '274', 'type': 'attribute', 'children': ['275', '278']}; {'id': '275', 'type': 'attribute', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'service'}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'time_interval_units'}; {'id': '279', 'type': 'expression_statement', 'children': ['280']}; {'id': '280', 'type': 'assignment', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'next_value'}; {'id': '282', 'type': 'lambda', 'children': ['283', '285']}; {'id': '283', 'type': 'lambda_parameters', 'children': ['284']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '285', 'type': 'binary_operator', 'children': ['286', '287'], 'value': '+'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'x'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'delta'}; {'id': '288', 'type': 'while_statement', 'children': ['289', '297']}; {'id': '289', 'type': 'comparison_operator', 'children': ['290', '294'], 'value': '<'}; {'id': '290', 'type': 'subscript', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'steps'}; {'id': '292', 'type': 'unary_operator', 'children': ['293'], 'value': '-'}; {'id': '293', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'time_end'}; {'id': '297', 'type': 'block', 'children': ['298', '308', '316']}; {'id': '298', 'type': 'expression_statement', 'children': ['299']}; {'id': '299', 'type': 'assignment', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '301', 'type': 'call', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'next_value'}; {'id': '303', 'type': 'argument_list', 'children': ['304']}; {'id': '304', 'type': 'subscript', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'steps'}; {'id': '306', 'type': 'unary_operator', 'children': ['307'], 'value': '-'}; {'id': '307', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '308', 'type': 'if_statement', 'children': ['309', '314']}; {'id': '309', 'type': 'comparison_operator', 'children': ['310', '311'], 'value': '>'}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '311', 'type': 'attribute', 'children': ['312', '313']}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'time_end'}; {'id': '314', 'type': 'block', 'children': ['315']}; {'id': '315', 'type': 'break_statement', 'children': []}; {'id': '316', 'type': 'expression_statement', 'children': ['317']}; {'id': '317', 'type': 'call', 'children': ['318', '321']}; {'id': '318', 'type': 'attribute', 'children': ['319', '320']}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'steps'}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '321', 'type': 'argument_list', 'children': ['322']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '323', 'type': 'return_statement', 'children': ['324']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'steps'}; {'id': '325', 'type': 'else_clause', 'children': ['326']}; {'id': '326', 'type': 'block', 'children': ['327']}; {'id': '327', 'type': 'raise_statement', 'children': ['328']}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'NotImplementedError'}
Valid time steps for this service as a list of datetime objects.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '6']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'best_fit'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '6', 'type': 'block', 'children': ['7', '24', '36']}; {'id': '7', 'type': 'expression_statement', 'children': ['8']}; {'id': '8', 'type': 'assignment', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '10', 'type': 'call', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '12', 'type': 'argument_list', 'children': ['13', '18']}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'bisect_left'}; {'id': '15', 'type': 'argument_list', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '18', 'type': 'binary_operator', 'children': ['19', '23'], 'value': '-'}; {'id': '19', 'type': 'call', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '21', 'type': 'argument_list', 'children': ['22']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '23', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '24', 'type': 'if_statement', 'children': ['25', '33']}; {'id': '25', 'type': 'comparison_operator', 'children': ['26', '27'], 'value': 'in'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '27', 'type': 'tuple', 'children': ['28', '29']}; {'id': '28', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '29', 'type': 'call', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '31', 'type': 'argument_list', 'children': ['32']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'return_statement', 'children': ['35']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '36', 'type': 'if_statement', 'children': ['37', '50', '53']}; {'id': '37', 'type': 'comparison_operator', 'children': ['38', '43'], 'value': '<'}; {'id': '38', 'type': 'binary_operator', 'children': ['39', '42'], 'value': '-'}; {'id': '39', 'type': 'subscript', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '43', 'type': 'binary_operator', 'children': ['44', '45'], 'value': '-'}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '45', 'type': 'subscript', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'li'}; {'id': '47', 'type': 'binary_operator', 'children': ['48', '49'], 'value': '-'}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '49', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '50', 'type': 'block', 'children': ['51']}; {'id': '51', 'type': 'return_statement', 'children': ['52']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '53', 'type': 'else_clause', 'children': ['54']}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'return_statement', 'children': ['56']}; {'id': '56', 'type': 'binary_operator', 'children': ['57', '58'], 'value': '-'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '58', 'type': 'integer', 'children': [], 'value': '1'}
For a sorted list li, returns the closest item to value
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'letter_scales'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'counts'}; {'id': '5', 'type': 'block', 'children': ['6', '26', '46', '60']}; {'id': '6', 'type': 'try_statement', 'children': ['7', '21']}; {'id': '7', 'type': 'block', 'children': ['8']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'scale'}; {'id': '11', 'type': 'binary_operator', 'children': ['12', '13'], 'value': '/'}; {'id': '12', 'type': 'float', 'children': [], 'value': '1.0'}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'call', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'counts'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '20', 'type': 'argument_list', 'children': []}; {'id': '21', 'type': 'except_clause', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'ZeroDivisionError'}; {'id': '23', 'type': 'block', 'children': ['24']}; {'id': '24', 'type': 'return_statement', 'children': ['25']}; {'id': '25', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'freqs'}; {'id': '29', 'type': 'list_comprehension', 'children': ['30', '35', '44']}; {'id': '30', 'type': 'tuple', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'aa'}; {'id': '32', 'type': 'binary_operator', 'children': ['33', '34'], 'value': '*'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'cnt'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'scale'}; {'id': '35', 'type': 'for_in_clause', 'children': ['36', '39']}; {'id': '36', 'type': 'pattern_list', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'aa'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'cnt'}; {'id': '39', 'type': 'call', 'children': ['40', '43']}; {'id': '40', 'type': 'attribute', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'counts'}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'iteritems'}; {'id': '43', 'type': 'argument_list', 'children': []}; {'id': '44', 'type': 'if_clause', 'children': ['45']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'cnt'}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'freqs'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'sort'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'keyword_argument', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '54', 'type': 'lambda', 'children': ['55', '57']}; {'id': '55', 'type': 'lambda_parameters', 'children': ['56']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '57', 'type': 'subscript', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'pair'}; {'id': '59', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '60', 'type': 'return_statement', 'children': ['61']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'freqs'}
Convert letter counts to frequencies, sorted increasing.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'cmd_debug'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '7', 'type': 'block', 'children': ['8', '26', '32', '54', '71', '88', '105', '122', '145', '154', '163', '171', '181', '315', '345']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '11', 'type': 'call', 'children': ['12', '15']}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'argparse'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'ArgumentParser'}; {'id': '15', 'type': 'argument_list', 'children': ['16', '23']}; {'id': '16', 'type': 'keyword_argument', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'prog'}; {'id': '18', 'type': 'binary_operator', 'children': ['19', '20'], 'value': '%'}; {'id': '19', 'type': 'string', 'children': [], 'value': '"%s debug"'}; {'id': '20', 'type': 'attribute', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'progname'}; {'id': '23', 'type': 'keyword_argument', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '29', 'type': 'attribute', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '37', 'type': 'argument_list', 'children': ['38', '39', '42', '45', '48']}; {'id': '38', 'type': 'string', 'children': [], 'value': '"instance"'}; {'id': '39', 'type': 'keyword_argument', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'nargs'}; {'id': '41', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '42', 'type': 'keyword_argument', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'metavar'}; {'id': '44', 'type': 'string', 'children': [], 'value': '"instance"'}; {'id': '45', 'type': 'keyword_argument', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '47', 'type': 'string', 'children': [], 'value': '"Name of the instance from the config."'}; {'id': '48', 'type': 'keyword_argument', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'choices'}; {'id': '50', 'type': 'call', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '52', 'type': 'argument_list', 'children': ['53']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'call', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '59', 'type': 'argument_list', 'children': ['60', '61', '62', '65', '68']}; {'id': '60', 'type': 'string', 'children': [], 'value': '"-v"'}; {'id': '61', 'type': 'string', 'children': [], 'value': '"--verbose"'}; {'id': '62', 'type': 'keyword_argument', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '64', 'type': 'string', 'children': [], 'value': '"verbose"'}; {'id': '65', 'type': 'keyword_argument', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '67', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '68', 'type': 'keyword_argument', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '70', 'type': 'string', 'children': [], 'value': '"Print more info and output the startup script"'}; {'id': '71', 'type': 'expression_statement', 'children': ['72']}; {'id': '72', 'type': 'call', 'children': ['73', '76']}; {'id': '73', 'type': 'attribute', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '76', 'type': 'argument_list', 'children': ['77', '78', '79', '82', '85']}; {'id': '77', 'type': 'string', 'children': [], 'value': '"-c"'}; {'id': '78', 'type': 'string', 'children': [], 'value': '"--console-output"'}; {'id': '79', 'type': 'keyword_argument', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '81', 'type': 'string', 'children': [], 'value': '"console_output"'}; {'id': '82', 'type': 'keyword_argument', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '84', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '85', 'type': 'keyword_argument', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '87', 'type': 'string', 'children': [], 'value': '"Prints the console output of the instance if available"'}; {'id': '88', 'type': 'expression_statement', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '93', 'type': 'argument_list', 'children': ['94', '95', '96', '99', '102']}; {'id': '94', 'type': 'string', 'children': [], 'value': '"-i"'}; {'id': '95', 'type': 'string', 'children': [], 'value': '"--interactive"'}; {'id': '96', 'type': 'keyword_argument', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '98', 'type': 'string', 'children': [], 'value': '"interactive"'}; {'id': '99', 'type': 'keyword_argument', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '101', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '102', 'type': 'keyword_argument', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '104', 'type': 'string', 'children': [], 'value': '"Creates a connection and drops you into an interactive Python session"'}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'call', 'children': ['107', '110']}; {'id': '107', 'type': 'attribute', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '110', 'type': 'argument_list', 'children': ['111', '112', '113', '116', '119']}; {'id': '111', 'type': 'string', 'children': [], 'value': '"-r"'}; {'id': '112', 'type': 'string', 'children': [], 'value': '"--raw"'}; {'id': '113', 'type': 'keyword_argument', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '115', 'type': 'string', 'children': [], 'value': '"raw"'}; {'id': '116', 'type': 'keyword_argument', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '118', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '119', 'type': 'keyword_argument', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '121', 'type': 'string', 'children': [], 'value': '"Outputs the raw possibly compressed startup script"'}; {'id': '122', 'type': 'expression_statement', 'children': ['123']}; {'id': '123', 'type': 'call', 'children': ['124', '127']}; {'id': '124', 'type': 'attribute', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '127', 'type': 'argument_list', 'children': ['128', '129', '130', '133', '136', '139', '142']}; {'id': '128', 'type': 'string', 'children': [], 'value': '"-o"'}; {'id': '129', 'type': 'string', 'children': [], 'value': '"--override"'}; {'id': '130', 'type': 'keyword_argument', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'nargs'}; {'id': '132', 'type': 'string', 'children': [], 'value': '"*"'}; {'id': '133', 'type': 'keyword_argument', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '136', 'type': 'keyword_argument', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '138', 'type': 'string', 'children': [], 'value': '"overrides"'}; {'id': '139', 'type': 'keyword_argument', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'metavar'}; {'id': '141', 'type': 'string', 'children': [], 'value': '"OVERRIDE"'}; {'id': '142', 'type': 'keyword_argument', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '144', 'type': 'string', 'children': [], 'value': '"Option to override instance config for startup script (name=value)."'}; {'id': '145', 'type': 'expression_statement', 'children': ['146']}; {'id': '146', 'type': 'assignment', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '148', 'type': 'call', 'children': ['149', '152']}; {'id': '149', 'type': 'attribute', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '152', 'type': 'argument_list', 'children': ['153']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'assignment', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'overrides'}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': '_parse_overrides'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'assignment', 'children': ['165', '168']}; {'id': '165', 'type': 'subscript', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'overrides'}; {'id': '167', 'type': 'string', 'children': [], 'value': "'instances'"}; {'id': '168', 'type': 'attribute', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'assignment', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '174', 'type': 'subscript', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '176', 'type': 'subscript', 'children': ['177', '180']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '180', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '181', 'type': 'if_statement', 'children': ['182', '187']}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '184', 'type': 'argument_list', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '186', 'type': 'string', 'children': [], 'value': "'startup_script'"}; {'id': '187', 'type': 'block', 'children': ['188', '202', '213', '227', '285']}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'assignment', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '191', 'type': 'call', 'children': ['192', '195']}; {'id': '192', 'type': 'attribute', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '195', 'type': 'argument_list', 'children': ['196', '199']}; {'id': '196', 'type': 'keyword_argument', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'overrides'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'overrides'}; {'id': '199', 'type': 'keyword_argument', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '201', 'type': 'True', 'children': []}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'max_size'}; {'id': '205', 'type': 'call', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '207', 'type': 'argument_list', 'children': ['208', '209', '210']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '209', 'type': 'string', 'children': [], 'value': "'max_startup_script_size'"}; {'id': '210', 'type': 'binary_operator', 'children': ['211', '212'], 'value': '*'}; {'id': '211', 'type': 'integer', 'children': [], 'value': '16'}; {'id': '212', 'type': 'integer', 'children': [], 'value': '1024'}; {'id': '213', 'type': 'expression_statement', 'children': ['214']}; {'id': '214', 'type': 'call', 'children': ['215', '218']}; {'id': '215', 'type': 'attribute', 'children': ['216', '217']}; {'id': '216', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '218', 'type': 'argument_list', 'children': ['219', '220', '226']}; {'id': '219', 'type': 'string', 'children': [], 'value': '"Length of startup script: %s/%s"'}; {'id': '220', 'type': 'call', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '222', 'type': 'argument_list', 'children': ['223']}; {'id': '223', 'type': 'subscript', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '225', 'type': 'string', 'children': [], 'value': "'raw'"}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'max_size'}; {'id': '227', 'type': 'if_statement', 'children': ['228', '231']}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'verbose'}; {'id': '231', 'type': 'block', 'children': ['232']}; {'id': '232', 'type': 'if_statement', 'children': ['233', '238', '276']}; {'id': '233', 'type': 'comparison_operator', 'children': ['234', '235'], 'value': 'in'}; {'id': '234', 'type': 'string', 'children': [], 'value': "'startup_script'"}; {'id': '235', 'type': 'attribute', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '238', 'type': 'block', 'children': ['239']}; {'id': '239', 'type': 'if_statement', 'children': ['240', '247', '255', '267']}; {'id': '240', 'type': 'comparison_operator', 'children': ['241', '244'], 'value': '=='}; {'id': '241', 'type': 'subscript', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '243', 'type': 'string', 'children': [], 'value': "'original'"}; {'id': '244', 'type': 'subscript', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '246', 'type': 'string', 'children': [], 'value': "'raw'"}; {'id': '247', 'type': 'block', 'children': ['248']}; {'id': '248', 'type': 'expression_statement', 'children': ['249']}; {'id': '249', 'type': 'call', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'string', 'children': [], 'value': '"Startup script:"'}; {'id': '255', 'type': 'elif_clause', 'children': ['256', '259']}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'raw'}; {'id': '259', 'type': 'block', 'children': ['260']}; {'id': '260', 'type': 'expression_statement', 'children': ['261']}; {'id': '261', 'type': 'call', 'children': ['262', '265']}; {'id': '262', 'type': 'attribute', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '265', 'type': 'argument_list', 'children': ['266']}; {'id': '266', 'type': 'string', 'children': [], 'value': '"Compressed startup script:"'}; {'id': '267', 'type': 'else_clause', 'children': ['268']}; {'id': '268', 'type': 'block', 'children': ['269']}; {'id': '269', 'type': 'expression_statement', 'children': ['270']}; {'id': '270', 'type': 'call', 'children': ['271', '274']}; {'id': '271', 'type': 'attribute', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '274', 'type': 'argument_list', 'children': ['275']}; {'id': '275', 'type': 'string', 'children': [], 'value': '"Uncompressed startup script:"'}; {'id': '276', 'type': 'else_clause', 'children': ['277']}; {'id': '277', 'type': 'block', 'children': ['278']}; {'id': '278', 'type': 'expression_statement', 'children': ['279']}; {'id': '279', 'type': 'call', 'children': ['280', '283']}; {'id': '280', 'type': 'attribute', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '282', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '283', 'type': 'argument_list', 'children': ['284']}; {'id': '284', 'type': 'string', 'children': [], 'value': '"No startup script specified"'}; {'id': '285', 'type': 'if_statement', 'children': ['286', '289', '300']}; {'id': '286', 'type': 'attribute', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'raw'}; {'id': '289', 'type': 'block', 'children': ['290']}; {'id': '290', 'type': 'expression_statement', 'children': ['291']}; {'id': '291', 'type': 'call', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '293', 'type': 'argument_list', 'children': ['294', '297']}; {'id': '294', 'type': 'subscript', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '296', 'type': 'string', 'children': [], 'value': "'raw'"}; {'id': '297', 'type': 'keyword_argument', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '299', 'type': 'string', 'children': [], 'value': "''"}; {'id': '300', 'type': 'elif_clause', 'children': ['301', '304']}; {'id': '301', 'type': 'attribute', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'verbose'}; {'id': '304', 'type': 'block', 'children': ['305']}; {'id': '305', 'type': 'expression_statement', 'children': ['306']}; {'id': '306', 'type': 'call', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '308', 'type': 'argument_list', 'children': ['309', '312']}; {'id': '309', 'type': 'subscript', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'startup_script'}; {'id': '311', 'type': 'string', 'children': [], 'value': "'original'"}; {'id': '312', 'type': 'keyword_argument', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '314', 'type': 'string', 'children': [], 'value': "''"}; {'id': '315', 'type': 'if_statement', 'children': ['316', '319']}; {'id': '316', 'type': 'attribute', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'console_output'}; {'id': '319', 'type': 'block', 'children': ['320']}; {'id': '320', 'type': 'if_statement', 'children': ['321', '326', '336']}; {'id': '321', 'type': 'call', 'children': ['322', '323']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '323', 'type': 'argument_list', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '325', 'type': 'string', 'children': [], 'value': "'get_console_output'"}; {'id': '326', 'type': 'block', 'children': ['327']}; {'id': '327', 'type': 'expression_statement', 'children': ['328']}; {'id': '328', 'type': 'call', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '330', 'type': 'argument_list', 'children': ['331']}; {'id': '331', 'type': 'call', 'children': ['332', '335']}; {'id': '332', 'type': 'attribute', 'children': ['333', '334']}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'get_console_output'}; {'id': '335', 'type': 'argument_list', 'children': []}; {'id': '336', 'type': 'else_clause', 'children': ['337']}; {'id': '337', 'type': 'block', 'children': ['338']}; {'id': '338', 'type': 'expression_statement', 'children': ['339']}; {'id': '339', 'type': 'call', 'children': ['340', '343']}; {'id': '340', 'type': 'attribute', 'children': ['341', '342']}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '343', 'type': 'argument_list', 'children': ['344']}; {'id': '344', 'type': 'string', 'children': [], 'value': '"The instance doesn\'t support console output."'}; {'id': '345', 'type': 'if_statement', 'children': ['346', '349']}; {'id': '346', 'type': 'attribute', 'children': ['347', '348']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'interactive'}; {'id': '349', 'type': 'block', 'children': ['350', '353', '358', '378', '385', '408']}; {'id': '350', 'type': 'import_statement', 'children': ['351']}; {'id': '351', 'type': 'dotted_name', 'children': ['352']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'readline'}; {'id': '353', 'type': 'import_from_statement', 'children': ['354', '356']}; {'id': '354', 'type': 'dotted_name', 'children': ['355']}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'pprint'}; {'id': '356', 'type': 'dotted_name', 'children': ['357']}; {'id': '357', 'type': 'identifier', 'children': [], 'value': 'pprint'}; {'id': '358', 'type': 'expression_statement', 'children': ['359']}; {'id': '359', 'type': 'assignment', 'children': ['360', '361']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'local'}; {'id': '361', 'type': 'call', 'children': ['362', '363']}; {'id': '362', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '363', 'type': 'argument_list', 'children': ['364', '367', '372', '375']}; {'id': '364', 'type': 'keyword_argument', 'children': ['365', '366']}; {'id': '365', 'type': 'identifier', 'children': [], 'value': 'ctrl'}; {'id': '366', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '367', 'type': 'keyword_argument', 'children': ['368', '369']}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '369', 'type': 'attribute', 'children': ['370', '371']}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '372', 'type': 'keyword_argument', 'children': ['373', '374']}; {'id': '373', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '375', 'type': 'keyword_argument', 'children': ['376', '377']}; {'id': '376', 'type': 'identifier', 'children': [], 'value': 'pprint'}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'pprint'}; {'id': '378', 'type': 'expression_statement', 'children': ['379']}; {'id': '379', 'type': 'call', 'children': ['380', '383']}; {'id': '380', 'type': 'attribute', 'children': ['381', '382']}; {'id': '381', 'type': 'identifier', 'children': [], 'value': 'readline'}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'parse_and_bind'}; {'id': '383', 'type': 'argument_list', 'children': ['384']}; {'id': '384', 'type': 'string', 'children': [], 'value': "'tab: complete'"}; {'id': '385', 'type': 'try_statement', 'children': ['386', '404']}; {'id': '386', 'type': 'block', 'children': ['387', '390']}; {'id': '387', 'type': 'import_statement', 'children': ['388']}; {'id': '388', 'type': 'dotted_name', 'children': ['389']}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'rlcompleter'}; {'id': '390', 'type': 'expression_statement', 'children': ['391']}; {'id': '391', 'type': 'call', 'children': ['392', '395']}; {'id': '392', 'type': 'attribute', 'children': ['393', '394']}; {'id': '393', 'type': 'identifier', 'children': [], 'value': 'readline'}; {'id': '394', 'type': 'identifier', 'children': [], 'value': 'set_completer'}; {'id': '395', 'type': 'argument_list', 'children': ['396']}; {'id': '396', 'type': 'attribute', 'children': ['397', '403']}; {'id': '397', 'type': 'call', 'children': ['398', '401']}; {'id': '398', 'type': 'attribute', 'children': ['399', '400']}; {'id': '399', 'type': 'identifier', 'children': [], 'value': 'rlcompleter'}; {'id': '400', 'type': 'identifier', 'children': [], 'value': 'Completer'}; {'id': '401', 'type': 'argument_list', 'children': ['402']}; {'id': '402', 'type': 'identifier', 'children': [], 'value': 'local'}; {'id': '403', 'type': 'identifier', 'children': [], 'value': 'complete'}; {'id': '404', 'type': 'except_clause', 'children': ['405', '406']}; {'id': '405', 'type': 'identifier', 'children': [], 'value': 'ImportError'}; {'id': '406', 'type': 'block', 'children': ['407']}; {'id': '407', 'type': 'pass_statement', 'children': []}; {'id': '408', 'type': 'expression_statement', 'children': ['409']}; {'id': '409', 'type': 'call', 'children': ['410', '416']}; {'id': '410', 'type': 'attribute', 'children': ['411', '415']}; {'id': '411', 'type': 'call', 'children': ['412', '413']}; {'id': '412', 'type': 'identifier', 'children': [], 'value': '__import__'}; {'id': '413', 'type': 'argument_list', 'children': ['414']}; {'id': '414', 'type': 'string', 'children': [], 'value': '"code"'}; {'id': '415', 'type': 'identifier', 'children': [], 'value': 'interact'}; {'id': '416', 'type': 'argument_list', 'children': ['417']}; {'id': '417', 'type': 'keyword_argument', 'children': ['418', '419']}; {'id': '418', 'type': 'identifier', 'children': [], 'value': 'local'}; {'id': '419', 'type': 'identifier', 'children': [], 'value': 'local'}
Prints some debug info for this script
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'cmd_ssh'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '7', 'type': 'block', 'children': ['8', '26', '37', '59', '74', '81', '85', '89', '146', '191', '197', '213', '271', '277', '289', '295', '311', '321']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '11', 'type': 'call', 'children': ['12', '15']}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'argparse'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'ArgumentParser'}; {'id': '15', 'type': 'argument_list', 'children': ['16', '23']}; {'id': '16', 'type': 'keyword_argument', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'prog'}; {'id': '18', 'type': 'binary_operator', 'children': ['19', '20'], 'value': '%'}; {'id': '19', 'type': 'string', 'children': [], 'value': '"%s ssh"'}; {'id': '20', 'type': 'attribute', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'progname'}; {'id': '23', 'type': 'keyword_argument', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '29', 'type': 'call', 'children': ['30', '33']}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'get_instances'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'keyword_argument', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'command'}; {'id': '36', 'type': 'string', 'children': [], 'value': "'init_ssh_key'"}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '42', 'type': 'argument_list', 'children': ['43', '44', '47', '50', '53']}; {'id': '43', 'type': 'string', 'children': [], 'value': '"instance"'}; {'id': '44', 'type': 'keyword_argument', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'nargs'}; {'id': '46', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '47', 'type': 'keyword_argument', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'metavar'}; {'id': '49', 'type': 'string', 'children': [], 'value': '"instance"'}; {'id': '50', 'type': 'keyword_argument', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '52', 'type': 'string', 'children': [], 'value': '"Name of the instance from the config."'}; {'id': '53', 'type': 'keyword_argument', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'choices'}; {'id': '55', 'type': 'call', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '57', 'type': 'argument_list', 'children': ['58']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'call', 'children': ['61', '64']}; {'id': '61', 'type': 'attribute', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '64', 'type': 'argument_list', 'children': ['65', '66', '71']}; {'id': '65', 'type': 'string', 'children': [], 'value': '"..."'}; {'id': '66', 'type': 'keyword_argument', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'nargs'}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'argparse'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'REMAINDER'}; {'id': '71', 'type': 'keyword_argument', 'children': ['72', '73']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '73', 'type': 'string', 'children': [], 'value': '"ssh options"'}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'assignment', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'iargs'}; {'id': '77', 'type': 'call', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '79', 'type': 'argument_list', 'children': ['80']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '81', 'type': 'expression_statement', 'children': ['82']}; {'id': '82', 'type': 'assignment', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '84', 'type': 'None', 'children': []}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'assignment', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '88', 'type': 'None', 'children': []}; {'id': '89', 'type': 'for_statement', 'children': ['90', '93', '94']}; {'id': '90', 'type': 'pattern_list', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'iargs'}; {'id': '94', 'type': 'block', 'children': ['95', '109']}; {'id': '95', 'type': 'if_statement', 'children': ['96', '103']}; {'id': '96', 'type': 'not_operator', 'children': ['97']}; {'id': '97', 'type': 'call', 'children': ['98', '101']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '101', 'type': 'argument_list', 'children': ['102']}; {'id': '102', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '103', 'type': 'block', 'children': ['104', '108']}; {'id': '104', 'type': 'expression_statement', 'children': ['105']}; {'id': '105', 'type': 'assignment', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '108', 'type': 'break_statement', 'children': []}; {'id': '109', 'type': 'if_statement', 'children': ['110', '115', '117']}; {'id': '110', 'type': 'comparison_operator', 'children': ['111', '114'], 'value': 'in'}; {'id': '111', 'type': 'subscript', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '113', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '114', 'type': 'string', 'children': [], 'value': "'1246AaCfgKkMNnqsTtVvXxYy'"}; {'id': '115', 'type': 'block', 'children': ['116']}; {'id': '116', 'type': 'continue_statement', 'children': []}; {'id': '117', 'type': 'elif_clause', 'children': ['118', '123']}; {'id': '118', 'type': 'comparison_operator', 'children': ['119', '122'], 'value': 'in'}; {'id': '119', 'type': 'subscript', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '121', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '122', 'type': 'string', 'children': [], 'value': "'bcDeFiLlmOopRSw'"}; {'id': '123', 'type': 'block', 'children': ['124', '132', '145']}; {'id': '124', 'type': 'expression_statement', 'children': ['125']}; {'id': '125', 'type': 'assignment', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '127', 'type': 'call', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'iargs'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'next'}; {'id': '131', 'type': 'argument_list', 'children': []}; {'id': '132', 'type': 'if_statement', 'children': ['133', '138']}; {'id': '133', 'type': 'comparison_operator', 'children': ['134', '137'], 'value': '=='}; {'id': '134', 'type': 'subscript', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '136', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '137', 'type': 'string', 'children': [], 'value': "'l'"}; {'id': '138', 'type': 'block', 'children': ['139']}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'assignment', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '142', 'type': 'subscript', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '144', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '145', 'type': 'continue_statement', 'children': []}; {'id': '146', 'type': 'if_statement', 'children': ['147', '150', '158']}; {'id': '147', 'type': 'comparison_operator', 'children': ['148', '149'], 'value': 'is'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '149', 'type': 'None', 'children': []}; {'id': '150', 'type': 'block', 'children': ['151']}; {'id': '151', 'type': 'expression_statement', 'children': ['152']}; {'id': '152', 'type': 'call', 'children': ['153', '156']}; {'id': '153', 'type': 'attribute', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '156', 'type': 'argument_list', 'children': ['157']}; {'id': '157', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '158', 'type': 'else_clause', 'children': ['159']}; {'id': '159', 'type': 'block', 'children': ['160', '166', '183']}; {'id': '160', 'type': 'expression_statement', 'children': ['161']}; {'id': '161', 'type': 'assignment', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '163', 'type': 'subscript', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '166', 'type': 'if_statement', 'children': ['167', '170']}; {'id': '167', 'type': 'comparison_operator', 'children': ['168', '169'], 'value': 'in'}; {'id': '168', 'type': 'string', 'children': [], 'value': "'@'"}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '170', 'type': 'block', 'children': ['171']}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'assignment', 'children': ['173', '176']}; {'id': '173', 'type': 'pattern_list', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '176', 'type': 'call', 'children': ['177', '180']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '180', 'type': 'argument_list', 'children': ['181', '182']}; {'id': '181', 'type': 'string', 'children': [], 'value': "'@'"}; {'id': '182', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'call', 'children': ['185', '188']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '188', 'type': 'argument_list', 'children': ['189']}; {'id': '189', 'type': 'list', 'children': ['190'], 'value': '[sid]'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'assignment', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '194', 'type': 'subscript', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'instances'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'sid'}; {'id': '197', 'type': 'if_statement', 'children': ['198', '201']}; {'id': '198', 'type': 'comparison_operator', 'children': ['199', '200'], 'value': 'is'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '200', 'type': 'None', 'children': []}; {'id': '201', 'type': 'block', 'children': ['202']}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '205', 'type': 'call', 'children': ['206', '211']}; {'id': '206', 'type': 'attribute', 'children': ['207', '210']}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '211', 'type': 'argument_list', 'children': ['212']}; {'id': '212', 'type': 'string', 'children': [], 'value': "'user'"}; {'id': '213', 'type': 'try_statement', 'children': ['214', '226']}; {'id': '214', 'type': 'block', 'children': ['215']}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'ssh_info'}; {'id': '218', 'type': 'call', 'children': ['219', '222']}; {'id': '219', 'type': 'attribute', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'init_ssh_key'}; {'id': '222', 'type': 'argument_list', 'children': ['223']}; {'id': '223', 'type': 'keyword_argument', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '226', 'type': 'except_clause', 'children': ['227', '239']}; {'id': '227', 'type': 'as_pattern', 'children': ['228', '237']}; {'id': '228', 'type': 'tuple', 'children': ['229', '234']}; {'id': '229', 'type': 'attribute', 'children': ['230', '233']}; {'id': '230', 'type': 'attribute', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'paramiko'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'SSHException'}; {'id': '234', 'type': 'attribute', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'socket'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '237', 'type': 'as_pattern_target', 'children': ['238']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '239', 'type': 'block', 'children': ['240', '247', '257', '264']}; {'id': '240', 'type': 'expression_statement', 'children': ['241']}; {'id': '241', 'type': 'call', 'children': ['242', '245']}; {'id': '242', 'type': 'attribute', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '245', 'type': 'argument_list', 'children': ['246']}; {'id': '246', 'type': 'string', 'children': [], 'value': '"Couldn\'t validate fingerprint for ssh connection."'}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'call', 'children': ['249', '252']}; {'id': '249', 'type': 'attribute', 'children': ['250', '251']}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '252', 'type': 'argument_list', 'children': ['253']}; {'id': '253', 'type': 'call', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'unicode'}; {'id': '255', 'type': 'argument_list', 'children': ['256']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '257', 'type': 'expression_statement', 'children': ['258']}; {'id': '258', 'type': 'call', 'children': ['259', '262']}; {'id': '259', 'type': 'attribute', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'log'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '262', 'type': 'argument_list', 'children': ['263']}; {'id': '263', 'type': 'string', 'children': [], 'value': '"Is the instance finished starting up?"'}; {'id': '264', 'type': 'expression_statement', 'children': ['265']}; {'id': '265', 'type': 'call', 'children': ['266', '269']}; {'id': '266', 'type': 'attribute', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '269', 'type': 'argument_list', 'children': ['270']}; {'id': '270', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '271', 'type': 'expression_statement', 'children': ['272']}; {'id': '272', 'type': 'assignment', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'client'}; {'id': '274', 'type': 'subscript', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'ssh_info'}; {'id': '276', 'type': 'string', 'children': [], 'value': "'client'"}; {'id': '277', 'type': 'expression_statement', 'children': ['278']}; {'id': '278', 'type': 'call', 'children': ['279', '288']}; {'id': '279', 'type': 'attribute', 'children': ['280', '287']}; {'id': '280', 'type': 'attribute', 'children': ['281', '286']}; {'id': '281', 'type': 'call', 'children': ['282', '285']}; {'id': '282', 'type': 'attribute', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'client'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'get_transport'}; {'id': '285', 'type': 'argument_list', 'children': []}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'sock'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '288', 'type': 'argument_list', 'children': []}; {'id': '289', 'type': 'expression_statement', 'children': ['290']}; {'id': '290', 'type': 'call', 'children': ['291', '294']}; {'id': '291', 'type': 'attribute', 'children': ['292', '293']}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'client'}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '294', 'type': 'argument_list', 'children': []}; {'id': '295', 'type': 'expression_statement', 'children': ['296']}; {'id': '296', 'type': 'assignment', 'children': ['297', '305']}; {'id': '297', 'type': 'subscript', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '299', 'type': 'slice', 'children': ['300', '301', '302']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '301', 'type': 'colon', 'children': []}; {'id': '302', 'type': 'binary_operator', 'children': ['303', '304'], 'value': '+'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'sid_index'}; {'id': '304', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '305', 'type': 'call', 'children': ['306', '309']}; {'id': '306', 'type': 'attribute', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'instance'}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'ssh_args_from_info'}; {'id': '309', 'type': 'argument_list', 'children': ['310']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'ssh_info'}; {'id': '311', 'type': 'expression_statement', 'children': ['312']}; {'id': '312', 'type': 'assignment', 'children': ['313', '319']}; {'id': '313', 'type': 'subscript', 'children': ['314', '315']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '315', 'type': 'slice', 'children': ['316', '317', '318']}; {'id': '316', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '317', 'type': 'colon', 'children': []}; {'id': '318', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '319', 'type': 'list', 'children': ['320'], 'value': "['ssh']"}; {'id': '320', 'type': 'string', 'children': [], 'value': "'ssh'"}; {'id': '321', 'type': 'expression_statement', 'children': ['322']}; {'id': '322', 'type': 'call', 'children': ['323', '326']}; {'id': '323', 'type': 'attribute', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'execvp'}; {'id': '326', 'type': 'argument_list', 'children': ['327', '328']}; {'id': '327', 'type': 'string', 'children': [], 'value': "'ssh'"}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'argv'}
Log into the instance with ssh using the automatically generated known hosts
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_gen_vevent'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '7', 'type': 'block', 'children': ['8', '23', '41', '54', '67', '85', '112', '130', '148', '281']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '18']}; {'id': '10', 'type': 'attribute', 'children': ['11', '17']}; {'id': '11', 'type': 'call', 'children': ['12', '15']}; {'id': '12', 'type': 'attribute', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '18', 'type': 'subscript', 'children': ['19', '22']}; {'id': '19', 'type': 'subscript', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '21', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '22', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '23', 'type': 'expression_statement', 'children': ['24']}; {'id': '24', 'type': 'assignment', 'children': ['25', '33']}; {'id': '25', 'type': 'attribute', 'children': ['26', '32']}; {'id': '26', 'type': 'call', 'children': ['27', '30']}; {'id': '27', 'type': 'attribute', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'string', 'children': [], 'value': "'dtstamp'"}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'fromtimestamp'}; {'id': '37', 'type': 'argument_list', 'children': ['38']}; {'id': '38', 'type': 'attribute', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': '_mtime'}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'assignment', 'children': ['43', '51']}; {'id': '43', 'type': 'attribute', 'children': ['44', '50']}; {'id': '44', 'type': 'call', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'string', 'children': [], 'value': "'summary'"}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '51', 'type': 'subscript', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '53', 'type': 'string', 'children': [], 'value': "'msg'"}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'assignment', 'children': ['56', '64']}; {'id': '56', 'type': 'attribute', 'children': ['57', '63']}; {'id': '57', 'type': 'call', 'children': ['58', '61']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '61', 'type': 'argument_list', 'children': ['62']}; {'id': '62', 'type': 'string', 'children': [], 'value': "'uid'"}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '64', 'type': 'subscript', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '66', 'type': 'string', 'children': [], 'value': "'uid'"}; {'id': '67', 'type': 'if_statement', 'children': ['68', '71']}; {'id': '68', 'type': 'comparison_operator', 'children': ['69', '70'], 'value': 'in'}; {'id': '69', 'type': 'string', 'children': [], 'value': "'class'"}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '71', 'type': 'block', 'children': ['72']}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '82']}; {'id': '74', 'type': 'attribute', 'children': ['75', '81']}; {'id': '75', 'type': 'call', 'children': ['76', '79']}; {'id': '76', 'type': 'attribute', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '79', 'type': 'argument_list', 'children': ['80']}; {'id': '80', 'type': 'string', 'children': [], 'value': "'class'"}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '82', 'type': 'subscript', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '84', 'type': 'string', 'children': [], 'value': "'class'"}; {'id': '85', 'type': 'if_statement', 'children': ['86', '98']}; {'id': '86', 'type': 'boolean_operator', 'children': ['87', '90'], 'value': 'and'}; {'id': '87', 'type': 'comparison_operator', 'children': ['88', '89'], 'value': 'in'}; {'id': '88', 'type': 'string', 'children': [], 'value': "'categories'"}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '90', 'type': 'comparison_operator', 'children': ['91', '97'], 'value': '>'}; {'id': '91', 'type': 'call', 'children': ['92', '93']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '93', 'type': 'argument_list', 'children': ['94']}; {'id': '94', 'type': 'subscript', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '96', 'type': 'string', 'children': [], 'value': "'categories'"}; {'id': '97', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '98', 'type': 'block', 'children': ['99']}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'assignment', 'children': ['101', '109']}; {'id': '101', 'type': 'attribute', 'children': ['102', '108']}; {'id': '102', 'type': 'call', 'children': ['103', '106']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '106', 'type': 'argument_list', 'children': ['107']}; {'id': '107', 'type': 'string', 'children': [], 'value': "'categories'"}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '109', 'type': 'subscript', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '111', 'type': 'string', 'children': [], 'value': "'categories'"}; {'id': '112', 'type': 'if_statement', 'children': ['113', '116']}; {'id': '113', 'type': 'comparison_operator', 'children': ['114', '115'], 'value': 'in'}; {'id': '114', 'type': 'string', 'children': [], 'value': "'location'"}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '116', 'type': 'block', 'children': ['117']}; {'id': '117', 'type': 'expression_statement', 'children': ['118']}; {'id': '118', 'type': 'assignment', 'children': ['119', '127']}; {'id': '119', 'type': 'attribute', 'children': ['120', '126']}; {'id': '120', 'type': 'call', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'string', 'children': [], 'value': "'location'"}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '127', 'type': 'subscript', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '129', 'type': 'string', 'children': [], 'value': "'location'"}; {'id': '130', 'type': 'if_statement', 'children': ['131', '134']}; {'id': '131', 'type': 'comparison_operator', 'children': ['132', '133'], 'value': 'in'}; {'id': '132', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '134', 'type': 'block', 'children': ['135']}; {'id': '135', 'type': 'expression_statement', 'children': ['136']}; {'id': '136', 'type': 'assignment', 'children': ['137', '145']}; {'id': '137', 'type': 'attribute', 'children': ['138', '144']}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '142', 'type': 'argument_list', 'children': ['143']}; {'id': '143', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '147', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '148', 'type': 'if_statement', 'children': ['149', '158', '249']}; {'id': '149', 'type': 'call', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '151', 'type': 'argument_list', 'children': ['152', '157']}; {'id': '152', 'type': 'subscript', 'children': ['153', '156']}; {'id': '153', 'type': 'subscript', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '155', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '156', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '158', 'type': 'block', 'children': ['159', '214']}; {'id': '159', 'type': 'if_statement', 'children': ['160', '167']}; {'id': '160', 'type': 'comparison_operator', 'children': ['161', '164'], 'value': '!='}; {'id': '161', 'type': 'attribute', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': '_alarm'}; {'id': '164', 'type': 'call', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '166', 'type': 'argument_list', 'children': []}; {'id': '167', 'type': 'block', 'children': ['168', '177', '190', '201']}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'valarm'}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '175', 'type': 'argument_list', 'children': ['176']}; {'id': '176', 'type': 'string', 'children': [], 'value': "'valarm'"}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'assignment', 'children': ['179', '187']}; {'id': '179', 'type': 'attribute', 'children': ['180', '186']}; {'id': '180', 'type': 'call', 'children': ['181', '184']}; {'id': '181', 'type': 'attribute', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'valarm'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'string', 'children': [], 'value': "'trigger'"}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '187', 'type': 'attribute', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': '_alarm'}; {'id': '190', 'type': 'expression_statement', 'children': ['191']}; {'id': '191', 'type': 'assignment', 'children': ['192', '200']}; {'id': '192', 'type': 'attribute', 'children': ['193', '199']}; {'id': '193', 'type': 'call', 'children': ['194', '197']}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'valarm'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '197', 'type': 'argument_list', 'children': ['198']}; {'id': '198', 'type': 'string', 'children': [], 'value': "'action'"}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '200', 'type': 'string', 'children': [], 'value': "'DISPLAY'"}; {'id': '201', 'type': 'expression_statement', 'children': ['202']}; {'id': '202', 'type': 'assignment', 'children': ['203', '211']}; {'id': '203', 'type': 'attribute', 'children': ['204', '210']}; {'id': '204', 'type': 'call', 'children': ['205', '208']}; {'id': '205', 'type': 'attribute', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'valarm'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '211', 'type': 'subscript', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '213', 'type': 'string', 'children': [], 'value': "'msg'"}; {'id': '214', 'type': 'if_statement', 'children': ['215', '218', '232']}; {'id': '215', 'type': 'comparison_operator', 'children': ['216', '217'], 'value': 'in'}; {'id': '216', 'type': 'string', 'children': [], 'value': "'duration'"}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '218', 'type': 'block', 'children': ['219']}; {'id': '219', 'type': 'expression_statement', 'children': ['220']}; {'id': '220', 'type': 'assignment', 'children': ['221', '229']}; {'id': '221', 'type': 'attribute', 'children': ['222', '228']}; {'id': '222', 'type': 'call', 'children': ['223', '226']}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'string', 'children': [], 'value': "'duration'"}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '229', 'type': 'subscript', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '231', 'type': 'string', 'children': [], 'value': "'duration'"}; {'id': '232', 'type': 'else_clause', 'children': ['233']}; {'id': '233', 'type': 'block', 'children': ['234']}; {'id': '234', 'type': 'expression_statement', 'children': ['235']}; {'id': '235', 'type': 'assignment', 'children': ['236', '244']}; {'id': '236', 'type': 'attribute', 'children': ['237', '243']}; {'id': '237', 'type': 'call', 'children': ['238', '241']}; {'id': '238', 'type': 'attribute', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '241', 'type': 'argument_list', 'children': ['242']}; {'id': '242', 'type': 'string', 'children': [], 'value': "'dtend'"}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '244', 'type': 'subscript', 'children': ['245', '248']}; {'id': '245', 'type': 'subscript', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '247', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '248', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '249', 'type': 'elif_clause', 'children': ['250', '258']}; {'id': '250', 'type': 'comparison_operator', 'children': ['251', '257'], 'value': '=='}; {'id': '251', 'type': 'call', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'subscript', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '256', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '257', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '258', 'type': 'block', 'children': ['259']}; {'id': '259', 'type': 'expression_statement', 'children': ['260']}; {'id': '260', 'type': 'assignment', 'children': ['261', '269']}; {'id': '261', 'type': 'attribute', 'children': ['262', '268']}; {'id': '262', 'type': 'call', 'children': ['263', '266']}; {'id': '263', 'type': 'attribute', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '266', 'type': 'argument_list', 'children': ['267']}; {'id': '267', 'type': 'string', 'children': [], 'value': "'dtend'"}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '269', 'type': 'binary_operator', 'children': ['270', '275'], 'value': '+'}; {'id': '270', 'type': 'subscript', 'children': ['271', '274']}; {'id': '271', 'type': 'subscript', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '273', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '274', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '275', 'type': 'call', 'children': ['276', '277']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '277', 'type': 'argument_list', 'children': ['278']}; {'id': '278', 'type': 'keyword_argument', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'days'}; {'id': '280', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '281', 'type': 'if_statement', 'children': ['282', '290']}; {'id': '282', 'type': 'comparison_operator', 'children': ['283', '289'], 'value': '>'}; {'id': '283', 'type': 'call', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '285', 'type': 'argument_list', 'children': ['286']}; {'id': '286', 'type': 'subscript', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '288', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '289', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '290', 'type': 'block', 'children': ['291']}; {'id': '291', 'type': 'expression_statement', 'children': ['292']}; {'id': '292', 'type': 'call', 'children': ['293', '296']}; {'id': '293', 'type': 'attribute', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': '_gen_dtend_rrule'}; {'id': '296', 'type': 'argument_list', 'children': ['297', '300']}; {'id': '297', 'type': 'subscript', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'event'}; {'id': '299', 'type': 'string', 'children': [], 'value': "'dtstart'"}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'vevent'}
Generate vevent from given event
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '27']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'to_remind'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6', '9', '12', '15', '18', '21', '24']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '6', 'type': 'default_parameter', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'label'}; {'id': '8', 'type': 'None', 'children': []}; {'id': '9', 'type': 'default_parameter', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'priority'}; {'id': '11', 'type': 'None', 'children': []}; {'id': '12', 'type': 'default_parameter', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '14', 'type': 'None', 'children': []}; {'id': '15', 'type': 'default_parameter', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '17', 'type': 'None', 'children': []}; {'id': '18', 'type': 'default_parameter', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '20', 'type': 'string', 'children': [], 'value': '" "'}; {'id': '21', 'type': 'default_parameter', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'postdate'}; {'id': '23', 'type': 'None', 'children': []}; {'id': '24', 'type': 'default_parameter', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'posttime'}; {'id': '26', 'type': 'None', 'children': []}; {'id': '27', 'type': 'block', 'children': ['28', '33', '37', '55', '63', '85', '89', '104', '126', '159', '169', '181', '195', '204', '257', '320', '357', '383', '404', '437', '452']}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '31', 'type': 'list', 'children': ['32'], 'value': "['REM']"}; {'id': '32', 'type': 'string', 'children': [], 'value': "'REM'"}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '36', 'type': 'None', 'children': []}; {'id': '37', 'type': 'if_statement', 'children': ['38', '43']}; {'id': '38', 'type': 'call', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '40', 'type': 'argument_list', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '42', 'type': 'string', 'children': [], 'value': "'rrule'"}; {'id': '43', 'type': 'block', 'children': ['44']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': '_parse_rruleset'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'attribute', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'rruleset'}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '58', 'type': 'attribute', 'children': ['59', '62']}; {'id': '59', 'type': 'attribute', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '63', 'type': 'if_statement', 'children': ['64', '73']}; {'id': '64', 'type': 'boolean_operator', 'children': ['65', '70'], 'value': 'and'}; {'id': '65', 'type': 'call', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '67', 'type': 'argument_list', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '73', 'type': 'block', 'children': ['74']}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'assignment', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '77', 'type': 'call', 'children': ['78', '81']}; {'id': '78', 'type': 'attribute', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'astimezone'}; {'id': '81', 'type': 'argument_list', 'children': ['82']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': '_localtz'}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'assignment', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '88', 'type': 'None', 'children': []}; {'id': '89', 'type': 'if_statement', 'children': ['90', '95']}; {'id': '90', 'type': 'call', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '92', 'type': 'argument_list', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '94', 'type': 'string', 'children': [], 'value': "'dtend'"}; {'id': '95', 'type': 'block', 'children': ['96']}; {'id': '96', 'type': 'expression_statement', 'children': ['97']}; {'id': '97', 'type': 'assignment', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '99', 'type': 'attribute', 'children': ['100', '103']}; {'id': '100', 'type': 'attribute', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '104', 'type': 'if_statement', 'children': ['105', '114']}; {'id': '105', 'type': 'boolean_operator', 'children': ['106', '111'], 'value': 'and'}; {'id': '106', 'type': 'call', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '108', 'type': 'argument_list', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '111', 'type': 'attribute', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'tzinfo'}; {'id': '114', 'type': 'block', 'children': ['115']}; {'id': '115', 'type': 'expression_statement', 'children': ['116']}; {'id': '116', 'type': 'assignment', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '118', 'type': 'call', 'children': ['119', '122']}; {'id': '119', 'type': 'attribute', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'astimezone'}; {'id': '122', 'type': 'argument_list', 'children': ['123']}; {'id': '123', 'type': 'attribute', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': '_localtz'}; {'id': '126', 'type': 'if_statement', 'children': ['127', '140']}; {'id': '127', 'type': 'boolean_operator', 'children': ['128', '134'], 'value': 'and'}; {'id': '128', 'type': 'not_operator', 'children': ['129']}; {'id': '129', 'type': 'call', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '131', 'type': 'argument_list', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '133', 'type': 'string', 'children': [], 'value': "'rdate'"}; {'id': '134', 'type': 'not_operator', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '140', 'type': 'block', 'children': ['141']}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'call', 'children': ['143', '146']}; {'id': '143', 'type': 'attribute', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '146', 'type': 'argument_list', 'children': ['147']}; {'id': '147', 'type': 'call', 'children': ['148', '156']}; {'id': '148', 'type': 'attribute', 'children': ['149', '155']}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'strftime'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'string', 'children': [], 'value': "'%b %d %Y'"}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '156', 'type': 'argument_list', 'children': ['157', '158']}; {'id': '157', 'type': 'string', 'children': [], 'value': "' 0'"}; {'id': '158', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '159', 'type': 'if_statement', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'postdate'}; {'id': '161', 'type': 'block', 'children': ['162']}; {'id': '162', 'type': 'expression_statement', 'children': ['163']}; {'id': '163', 'type': 'call', 'children': ['164', '167']}; {'id': '164', 'type': 'attribute', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '167', 'type': 'argument_list', 'children': ['168']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'postdate'}; {'id': '169', 'type': 'if_statement', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'priority'}; {'id': '171', 'type': 'block', 'children': ['172']}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'call', 'children': ['174', '177']}; {'id': '174', 'type': 'attribute', 'children': ['175', '176']}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '177', 'type': 'argument_list', 'children': ['178']}; {'id': '178', 'type': 'binary_operator', 'children': ['179', '180'], 'value': '%'}; {'id': '179', 'type': 'string', 'children': [], 'value': "'PRIORITY %s'"}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'priority'}; {'id': '181', 'type': 'if_statement', 'children': ['182', '187']}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '184', 'type': 'argument_list', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '187', 'type': 'block', 'children': ['188']}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'call', 'children': ['190', '193']}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '193', 'type': 'argument_list', 'children': ['194']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'assignment', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'duration'}; {'id': '198', 'type': 'call', 'children': ['199', '202']}; {'id': '199', 'type': 'attribute', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': '_event_duration'}; {'id': '202', 'type': 'argument_list', 'children': ['203']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '204', 'type': 'if_statement', 'children': ['205', '217']}; {'id': '205', 'type': 'boolean_operator', 'children': ['206', '212'], 'value': 'and'}; {'id': '206', 'type': 'comparison_operator', 'children': ['207', '211'], 'value': 'is'}; {'id': '207', 'type': 'call', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '209', 'type': 'argument_list', 'children': ['210']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'date'}; {'id': '212', 'type': 'comparison_operator', 'children': ['213', '216'], 'value': '>'}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'duration'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'days'}; {'id': '216', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '217', 'type': 'block', 'children': ['218', '225']}; {'id': '218', 'type': 'expression_statement', 'children': ['219']}; {'id': '219', 'type': 'call', 'children': ['220', '223']}; {'id': '220', 'type': 'attribute', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'string', 'children': [], 'value': "'*1'"}; {'id': '225', 'type': 'if_statement', 'children': ['226', '229']}; {'id': '226', 'type': 'comparison_operator', 'children': ['227', '228'], 'value': 'is'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '228', 'type': 'None', 'children': []}; {'id': '229', 'type': 'block', 'children': ['230', '239']}; {'id': '230', 'type': 'expression_statement', 'children': ['231']}; {'id': '231', 'type': 'augmented_assignment', 'children': ['232', '233'], 'value': '-='}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '233', 'type': 'call', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'timedelta'}; {'id': '235', 'type': 'argument_list', 'children': ['236']}; {'id': '236', 'type': 'keyword_argument', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'days'}; {'id': '238', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '239', 'type': 'expression_statement', 'children': ['240']}; {'id': '240', 'type': 'call', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '244', 'type': 'argument_list', 'children': ['245']}; {'id': '245', 'type': 'call', 'children': ['246', '254']}; {'id': '246', 'type': 'attribute', 'children': ['247', '253']}; {'id': '247', 'type': 'call', 'children': ['248', '251']}; {'id': '248', 'type': 'attribute', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'dtend'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'strftime'}; {'id': '251', 'type': 'argument_list', 'children': ['252']}; {'id': '252', 'type': 'string', 'children': [], 'value': "'UNTIL %b %d %Y'"}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '254', 'type': 'argument_list', 'children': ['255', '256']}; {'id': '255', 'type': 'string', 'children': [], 'value': "' 0'"}; {'id': '256', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '257', 'type': 'if_statement', 'children': ['258', '263']}; {'id': '258', 'type': 'call', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '260', 'type': 'argument_list', 'children': ['261', '262']}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'datetime'}; {'id': '263', 'type': 'block', 'children': ['264', '282', '292']}; {'id': '264', 'type': 'expression_statement', 'children': ['265']}; {'id': '265', 'type': 'call', 'children': ['266', '269']}; {'id': '266', 'type': 'attribute', 'children': ['267', '268']}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '269', 'type': 'argument_list', 'children': ['270']}; {'id': '270', 'type': 'call', 'children': ['271', '279']}; {'id': '271', 'type': 'attribute', 'children': ['272', '278']}; {'id': '272', 'type': 'call', 'children': ['273', '276']}; {'id': '273', 'type': 'attribute', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'dtstart'}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'strftime'}; {'id': '276', 'type': 'argument_list', 'children': ['277']}; {'id': '277', 'type': 'string', 'children': [], 'value': "'AT %H:%M'"}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'replace'}; {'id': '279', 'type': 'argument_list', 'children': ['280', '281']}; {'id': '280', 'type': 'string', 'children': [], 'value': "' 0'"}; {'id': '281', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '282', 'type': 'if_statement', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'posttime'}; {'id': '284', 'type': 'block', 'children': ['285']}; {'id': '285', 'type': 'expression_statement', 'children': ['286']}; {'id': '286', 'type': 'call', 'children': ['287', '290']}; {'id': '287', 'type': 'attribute', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '290', 'type': 'argument_list', 'children': ['291']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'posttime'}; {'id': '292', 'type': 'if_statement', 'children': ['293', '300']}; {'id': '293', 'type': 'comparison_operator', 'children': ['294', '299'], 'value': '>'}; {'id': '294', 'type': 'call', 'children': ['295', '298']}; {'id': '295', 'type': 'attribute', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'duration'}; {'id': '297', 'type': 'identifier', 'children': [], 'value': 'total_seconds'}; {'id': '298', 'type': 'argument_list', 'children': []}; {'id': '299', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '300', 'type': 'block', 'children': ['301']}; {'id': '301', 'type': 'expression_statement', 'children': ['302']}; {'id': '302', 'type': 'call', 'children': ['303', '306']}; {'id': '303', 'type': 'attribute', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '306', 'type': 'argument_list', 'children': ['307']}; {'id': '307', 'type': 'binary_operator', 'children': ['308', '309'], 'value': '%'}; {'id': '308', 'type': 'string', 'children': [], 'value': "'DURATION %d:%02d'"}; {'id': '309', 'type': 'call', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'divmod'}; {'id': '311', 'type': 'argument_list', 'children': ['312', '319']}; {'id': '312', 'type': 'binary_operator', 'children': ['313', '318'], 'value': '/'}; {'id': '313', 'type': 'call', 'children': ['314', '317']}; {'id': '314', 'type': 'attribute', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'duration'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'total_seconds'}; {'id': '317', 'type': 'argument_list', 'children': []}; {'id': '318', 'type': 'integer', 'children': [], 'value': '60'}; {'id': '319', 'type': 'integer', 'children': [], 'value': '60'}; {'id': '320', 'type': 'if_statement', 'children': ['321', '326', '343']}; {'id': '321', 'type': 'call', 'children': ['322', '323']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '323', 'type': 'argument_list', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '325', 'type': 'string', 'children': [], 'value': "'rdate'"}; {'id': '326', 'type': 'block', 'children': ['327']}; {'id': '327', 'type': 'expression_statement', 'children': ['328']}; {'id': '328', 'type': 'call', 'children': ['329', '332']}; {'id': '329', 'type': 'attribute', 'children': ['330', '331']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '331', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '332', 'type': 'argument_list', 'children': ['333']}; {'id': '333', 'type': 'call', 'children': ['334', '337']}; {'id': '334', 'type': 'attribute', 'children': ['335', '336']}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '336', 'type': 'identifier', 'children': [], 'value': '_parse_rdate'}; {'id': '337', 'type': 'argument_list', 'children': ['338']}; {'id': '338', 'type': 'attribute', 'children': ['339', '342']}; {'id': '339', 'type': 'attribute', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'rdate'}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '343', 'type': 'elif_clause', 'children': ['344', '349']}; {'id': '344', 'type': 'call', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '346', 'type': 'argument_list', 'children': ['347', '348']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '349', 'type': 'block', 'children': ['350']}; {'id': '350', 'type': 'expression_statement', 'children': ['351']}; {'id': '351', 'type': 'call', 'children': ['352', '355']}; {'id': '352', 'type': 'attribute', 'children': ['353', '354']}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '354', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '355', 'type': 'argument_list', 'children': ['356']}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'trigdates'}; {'id': '357', 'type': 'if_statement', 'children': ['358', '363']}; {'id': '358', 'type': 'call', 'children': ['359', '360']}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '360', 'type': 'argument_list', 'children': ['361', '362']}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '362', 'type': 'string', 'children': [], 'value': "'class'"}; {'id': '363', 'type': 'block', 'children': ['364']}; {'id': '364', 'type': 'expression_statement', 'children': ['365']}; {'id': '365', 'type': 'call', 'children': ['366', '369']}; {'id': '366', 'type': 'attribute', 'children': ['367', '368']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '369', 'type': 'argument_list', 'children': ['370']}; {'id': '370', 'type': 'binary_operator', 'children': ['371', '372'], 'value': '%'}; {'id': '371', 'type': 'string', 'children': [], 'value': "'TAG %s'"}; {'id': '372', 'type': 'call', 'children': ['373', '376']}; {'id': '373', 'type': 'attribute', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': '_abbr_tag'}; {'id': '376', 'type': 'argument_list', 'children': ['377']}; {'id': '377', 'type': 'call', 'children': ['378', '381']}; {'id': '378', 'type': 'attribute', 'children': ['379', '380']}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'getChildValue'}; {'id': '381', 'type': 'argument_list', 'children': ['382']}; {'id': '382', 'type': 'string', 'children': [], 'value': "'class'"}; {'id': '383', 'type': 'if_statement', 'children': ['384', '385']}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '385', 'type': 'block', 'children': ['386']}; {'id': '386', 'type': 'expression_statement', 'children': ['387']}; {'id': '387', 'type': 'call', 'children': ['388', '391']}; {'id': '388', 'type': 'attribute', 'children': ['389', '390']}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '390', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '391', 'type': 'argument_list', 'children': ['392']}; {'id': '392', 'type': 'list_comprehension', 'children': ['393', '401']}; {'id': '393', 'type': 'binary_operator', 'children': ['394', '395'], 'value': '%'}; {'id': '394', 'type': 'string', 'children': [], 'value': "'TAG %s'"}; {'id': '395', 'type': 'call', 'children': ['396', '399']}; {'id': '396', 'type': 'attribute', 'children': ['397', '398']}; {'id': '397', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '398', 'type': 'identifier', 'children': [], 'value': '_abbr_tag'}; {'id': '399', 'type': 'argument_list', 'children': ['400']}; {'id': '400', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '401', 'type': 'for_in_clause', 'children': ['402', '403']}; {'id': '402', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '403', 'type': 'identifier', 'children': [], 'value': 'tags'}; {'id': '404', 'type': 'if_statement', 'children': ['405', '410']}; {'id': '405', 'type': 'call', 'children': ['406', '407']}; {'id': '406', 'type': 'identifier', 'children': [], 'value': 'hasattr'}; {'id': '407', 'type': 'argument_list', 'children': ['408', '409']}; {'id': '408', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '409', 'type': 'string', 'children': [], 'value': "'categories_list'"}; {'id': '410', 'type': 'block', 'children': ['411']}; {'id': '411', 'type': 'for_statement', 'children': ['412', '413', '416']}; {'id': '412', 'type': 'identifier', 'children': [], 'value': 'categories'}; {'id': '413', 'type': 'attribute', 'children': ['414', '415']}; {'id': '414', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '415', 'type': 'identifier', 'children': [], 'value': 'categories_list'}; {'id': '416', 'type': 'block', 'children': ['417']}; {'id': '417', 'type': 'for_statement', 'children': ['418', '419', '422']}; {'id': '418', 'type': 'identifier', 'children': [], 'value': 'category'}; {'id': '419', 'type': 'attribute', 'children': ['420', '421']}; {'id': '420', 'type': 'identifier', 'children': [], 'value': 'categories'}; {'id': '421', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '422', 'type': 'block', 'children': ['423']}; {'id': '423', 'type': 'expression_statement', 'children': ['424']}; {'id': '424', 'type': 'call', 'children': ['425', '428']}; {'id': '425', 'type': 'attribute', 'children': ['426', '427']}; {'id': '426', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '427', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '428', 'type': 'argument_list', 'children': ['429']}; {'id': '429', 'type': 'binary_operator', 'children': ['430', '431'], 'value': '%'}; {'id': '430', 'type': 'string', 'children': [], 'value': "'TAG %s'"}; {'id': '431', 'type': 'call', 'children': ['432', '435']}; {'id': '432', 'type': 'attribute', 'children': ['433', '434']}; {'id': '433', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '434', 'type': 'identifier', 'children': [], 'value': '_abbr_tag'}; {'id': '435', 'type': 'argument_list', 'children': ['436']}; {'id': '436', 'type': 'identifier', 'children': [], 'value': 'category'}; {'id': '437', 'type': 'expression_statement', 'children': ['438']}; {'id': '438', 'type': 'call', 'children': ['439', '442']}; {'id': '439', 'type': 'attribute', 'children': ['440', '441']}; {'id': '440', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '441', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '442', 'type': 'argument_list', 'children': ['443']}; {'id': '443', 'type': 'call', 'children': ['444', '447']}; {'id': '444', 'type': 'attribute', 'children': ['445', '446']}; {'id': '445', 'type': 'identifier', 'children': [], 'value': 'Remind'}; {'id': '446', 'type': 'identifier', 'children': [], 'value': '_gen_msg'}; {'id': '447', 'type': 'argument_list', 'children': ['448', '449', '450', '451']}; {'id': '448', 'type': 'identifier', 'children': [], 'value': 'vevent'}; {'id': '449', 'type': 'identifier', 'children': [], 'value': 'label'}; {'id': '450', 'type': 'identifier', 'children': [], 'value': 'tail'}; {'id': '451', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '452', 'type': 'return_statement', 'children': ['453']}; {'id': '453', 'type': 'binary_operator', 'children': ['454', '460'], 'value': '+'}; {'id': '454', 'type': 'call', 'children': ['455', '458']}; {'id': '455', 'type': 'attribute', 'children': ['456', '457']}; {'id': '456', 'type': 'string', 'children': [], 'value': "' '"}; {'id': '457', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '458', 'type': 'argument_list', 'children': ['459']}; {'id': '459', 'type': 'identifier', 'children': [], 'value': 'remind'}; {'id': '460', 'type': 'string', 'children': [], 'value': "'\\n'"}
Generate a Remind command from the given vevent
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'blocks'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'threshold'}; {'id': '7', 'type': 'float', 'children': [], 'value': '0.5'}; {'id': '8', 'type': 'default_parameter', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '10', 'type': 'None', 'children': []}; {'id': '11', 'type': 'block', 'children': ['12', '17', '108', '121', '140', '150', '171', '175', '205']}; {'id': '12', 'type': 'assert_statement', 'children': ['13']}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '15', 'type': 'argument_list', 'children': ['16']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '17', 'type': 'if_statement', 'children': ['18', '21', '45']}; {'id': '18', 'type': 'comparison_operator', 'children': ['19', '20'], 'value': '=='}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '20', 'type': 'False', 'children': []}; {'id': '21', 'type': 'block', 'children': ['22']}; {'id': '22', 'type': 'function_definition', 'children': ['23', '24', '26']}; {'id': '23', 'type': 'function_name', 'children': [], 'value': 'pct_nongaps'}; {'id': '24', 'type': 'parameters', 'children': ['25']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '26', 'type': 'block', 'children': ['27']}; {'id': '27', 'type': 'return_statement', 'children': ['28']}; {'id': '28', 'type': 'binary_operator', 'children': ['29', '30'], 'value': '-'}; {'id': '29', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '30', 'type': '()', 'children': ['31']}; {'id': '31', 'type': 'binary_operator', 'children': ['32', '41'], 'value': '/'}; {'id': '32', 'type': 'call', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'float'}; {'id': '34', 'type': 'argument_list', 'children': ['35']}; {'id': '35', 'type': 'call', 'children': ['36', '39']}; {'id': '36', 'type': 'attribute', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'count'}; {'id': '39', 'type': 'argument_list', 'children': ['40']}; {'id': '40', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '41', 'type': 'call', 'children': ['42', '43']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '43', 'type': 'argument_list', 'children': ['44']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '45', 'type': 'else_clause', 'children': ['46']}; {'id': '46', 'type': 'block', 'children': ['47', '62']}; {'id': '47', 'type': 'if_statement', 'children': ['48', '53']}; {'id': '48', 'type': 'comparison_operator', 'children': ['49', '50'], 'value': 'in'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '50', 'type': 'tuple', 'children': ['51', '52']}; {'id': '51', 'type': 'None', 'children': []}; {'id': '52', 'type': 'True', 'children': []}; {'id': '53', 'type': 'block', 'children': ['54']}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'assignment', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '57', 'type': 'call', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'sequence_weights'}; {'id': '59', 'type': 'argument_list', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '61', 'type': 'string', 'children': [], 'value': "'avg1'"}; {'id': '62', 'type': 'function_definition', 'children': ['63', '64', '66']}; {'id': '63', 'type': 'function_name', 'children': [], 'value': 'pct_nongaps'}; {'id': '64', 'type': 'parameters', 'children': ['65']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '66', 'type': 'block', 'children': ['67', '77', '98']}; {'id': '67', 'type': 'assert_statement', 'children': ['68']}; {'id': '68', 'type': 'comparison_operator', 'children': ['69', '73'], 'value': '=='}; {'id': '69', 'type': 'call', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '71', 'type': 'argument_list', 'children': ['72']}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '73', 'type': 'call', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '75', 'type': 'argument_list', 'children': ['76']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'assignment', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'ngaps'}; {'id': '80', 'type': 'call', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '82', 'type': 'generator_expression', 'children': ['83', '89']}; {'id': '83', 'type': 'binary_operator', 'children': ['84', '85'], 'value': '*'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'wt'}; {'id': '85', 'type': '()', 'children': ['86']}; {'id': '86', 'type': 'comparison_operator', 'children': ['87', '88'], 'value': '=='}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '88', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '89', 'type': 'for_in_clause', 'children': ['90', '93']}; {'id': '90', 'type': 'pattern_list', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'wt'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'c'}; {'id': '93', 'type': 'call', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '95', 'type': 'argument_list', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'weights'}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '98', 'type': 'return_statement', 'children': ['99']}; {'id': '99', 'type': 'binary_operator', 'children': ['100', '101'], 'value': '-'}; {'id': '100', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '101', 'type': '()', 'children': ['102']}; {'id': '102', 'type': 'binary_operator', 'children': ['103', '104'], 'value': '/'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'ngaps'}; {'id': '104', 'type': 'call', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '106', 'type': 'argument_list', 'children': ['107']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'assignment', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'seqstrs'}; {'id': '111', 'type': 'list_comprehension', 'children': ['112', '118']}; {'id': '112', 'type': 'call', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '114', 'type': 'argument_list', 'children': ['115']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'rec'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '118', 'type': 'for_in_clause', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'rec'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '121', 'type': 'expression_statement', 'children': ['122']}; {'id': '122', 'type': 'assignment', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'clean_cols'}; {'id': '124', 'type': 'list_comprehension', 'children': ['125', '126', '133']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '126', 'type': 'for_in_clause', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '128', 'type': 'call', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '130', 'type': 'argument_list', 'children': ['131']}; {'id': '131', 'type': 'list_splat', 'children': ['132']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'seqstrs'}; {'id': '133', 'type': 'if_clause', 'children': ['134']}; {'id': '134', 'type': 'comparison_operator', 'children': ['135', '139'], 'value': '>='}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'pct_nongaps'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'threshold'}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'alphabet'}; {'id': '143', 'type': 'attribute', 'children': ['144', '149']}; {'id': '144', 'type': 'attribute', 'children': ['145', '148']}; {'id': '145', 'type': 'subscript', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '147', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'alphabet'}; {'id': '150', 'type': 'expression_statement', 'children': ['151']}; {'id': '151', 'type': 'assignment', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'clean_seqs'}; {'id': '153', 'type': 'list_comprehension', 'children': ['154', '164']}; {'id': '154', 'type': 'call', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'Seq'}; {'id': '156', 'type': 'argument_list', 'children': ['157', '163']}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'string', 'children': [], 'value': "''"}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'alphabet'}; {'id': '164', 'type': 'for_in_clause', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '166', 'type': 'call', 'children': ['167', '168']}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '168', 'type': 'argument_list', 'children': ['169']}; {'id': '169', 'type': 'list_splat', 'children': ['170']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'clean_cols'}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'assignment', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'clean_recs'}; {'id': '174', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '175', 'type': 'for_statement', 'children': ['176', '179', '184']}; {'id': '176', 'type': 'pattern_list', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'rec'}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '179', 'type': 'call', 'children': ['180', '181']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'zip'}; {'id': '181', 'type': 'argument_list', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'aln'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'clean_seqs'}; {'id': '184', 'type': 'block', 'children': ['185', '192', '198']}; {'id': '185', 'type': 'expression_statement', 'children': ['186']}; {'id': '186', 'type': 'assignment', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'newrec'}; {'id': '188', 'type': 'call', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'deepcopy'}; {'id': '190', 'type': 'argument_list', 'children': ['191']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'rec'}; {'id': '192', 'type': 'expression_statement', 'children': ['193']}; {'id': '193', 'type': 'assignment', 'children': ['194', '197']}; {'id': '194', 'type': 'attribute', 'children': ['195', '196']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'newrec'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'seq'}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'call', 'children': ['200', '203']}; {'id': '200', 'type': 'attribute', 'children': ['201', '202']}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'clean_recs'}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'newrec'}; {'id': '205', 'type': 'return_statement', 'children': ['206']}; {'id': '206', 'type': 'call', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'MultipleSeqAlignment'}; {'id': '208', 'type': 'argument_list', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'clean_recs'}; {'id': '210', 'type': 'keyword_argument', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'alphabet'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'alphabet'}
Remove gappy columns from an alignment.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'refresh_instruments'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '21', '118', '127', '156']}; {'id': '6', 'type': 'function_definition', 'children': ['7', '8', '11']}; {'id': '7', 'type': 'function_name', 'children': [], 'value': 'list_access_nested_dict'}; {'id': '8', 'type': 'parameters', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'somelist'}; {'id': '11', 'type': 'block', 'children': ['12']}; {'id': '12', 'type': 'return_statement', 'children': ['13']}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'reduce'}; {'id': '15', 'type': 'argument_list', 'children': ['16', '19', '20']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'operator'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'getitem'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'somelist'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '21', 'type': 'function_definition', 'children': ['22', '23', '25']}; {'id': '22', 'type': 'function_name', 'children': [], 'value': 'update'}; {'id': '23', 'type': 'parameters', 'children': ['24']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '25', 'type': 'block', 'children': ['26']}; {'id': '26', 'type': 'if_statement', 'children': ['27', '32']}; {'id': '27', 'type': 'call', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'isExpanded'}; {'id': '31', 'type': 'argument_list', 'children': []}; {'id': '32', 'type': 'block', 'children': ['33']}; {'id': '33', 'type': 'for_statement', 'children': ['34', '35', '43']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '35', 'type': 'call', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '37', 'type': 'argument_list', 'children': ['38']}; {'id': '38', 'type': 'call', 'children': ['39', '42']}; {'id': '39', 'type': 'attribute', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'childCount'}; {'id': '42', 'type': 'argument_list', 'children': []}; {'id': '43', 'type': 'block', 'children': ['44', '53']}; {'id': '44', 'type': 'expression_statement', 'children': ['45']}; {'id': '45', 'type': 'assignment', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '51', 'type': 'argument_list', 'children': ['52']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '53', 'type': 'if_statement', 'children': ['54', '61', '111']}; {'id': '54', 'type': 'comparison_operator', 'children': ['55', '60'], 'value': '=='}; {'id': '55', 'type': 'call', 'children': ['56', '59']}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'childCount'}; {'id': '59', 'type': 'argument_list', 'children': []}; {'id': '60', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '61', 'type': 'block', 'children': ['62', '72', '78', '105']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '67']}; {'id': '64', 'type': 'pattern_list', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'instrument'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'path_to_instrument'}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'get_instrument'}; {'id': '71', 'type': 'argument_list', 'children': []}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'call', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'path_to_instrument'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'reverse'}; {'id': '77', 'type': 'argument_list', 'children': []}; {'id': '78', 'type': 'try_statement', 'children': ['79', '92']}; {'id': '79', 'type': 'block', 'children': ['80']}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '83', 'type': 'call', 'children': ['84', '87']}; {'id': '84', 'type': 'attribute', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'instrument'}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'read_probes'}; {'id': '87', 'type': 'argument_list', 'children': ['88']}; {'id': '88', 'type': 'subscript', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'path_to_instrument'}; {'id': '90', 'type': 'unary_operator', 'children': ['91'], 'value': '-'}; {'id': '91', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '92', 'type': 'except_clause', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'AssertionError'}; {'id': '94', 'type': 'block', 'children': ['95']}; {'id': '95', 'type': 'expression_statement', 'children': ['96']}; {'id': '96', 'type': 'assignment', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '98', 'type': 'call', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'list_access_nested_dict'}; {'id': '100', 'type': 'argument_list', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'instrument'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'settings'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'path_to_instrument'}; {'id': '105', 'type': 'expression_statement', 'children': ['106']}; {'id': '106', 'type': 'assignment', 'children': ['107', '110']}; {'id': '107', 'type': 'attribute', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '111', 'type': 'else_clause', 'children': ['112']}; {'id': '112', 'type': 'block', 'children': ['113']}; {'id': '113', 'type': 'expression_statement', 'children': ['114']}; {'id': '114', 'type': 'call', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '116', 'type': 'argument_list', 'children': ['117']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'child'}; {'id': '118', 'type': 'expression_statement', 'children': ['119']}; {'id': '119', 'type': 'call', 'children': ['120', '125']}; {'id': '120', 'type': 'attribute', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'tree_settings'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'blockSignals'}; {'id': '125', 'type': 'argument_list', 'children': ['126']}; {'id': '126', 'type': 'True', 'children': []}; {'id': '127', 'type': 'for_statement', 'children': ['128', '129', '139']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '129', 'type': 'call', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '131', 'type': 'argument_list', 'children': ['132']}; {'id': '132', 'type': 'call', 'children': ['133', '138']}; {'id': '133', 'type': 'attribute', 'children': ['134', '137']}; {'id': '134', 'type': 'attribute', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'tree_settings'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'topLevelItemCount'}; {'id': '138', 'type': 'argument_list', 'children': []}; {'id': '139', 'type': 'block', 'children': ['140', '151']}; {'id': '140', 'type': 'expression_statement', 'children': ['141']}; {'id': '141', 'type': 'assignment', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'instrument'}; {'id': '143', 'type': 'call', 'children': ['144', '149']}; {'id': '144', 'type': 'attribute', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'tree_settings'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'topLevelItem'}; {'id': '149', 'type': 'argument_list', 'children': ['150']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '151', 'type': 'expression_statement', 'children': ['152']}; {'id': '152', 'type': 'call', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '154', 'type': 'argument_list', 'children': ['155']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'instrument'}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'call', 'children': ['158', '163']}; {'id': '158', 'type': 'attribute', 'children': ['159', '162']}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'tree_settings'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'blockSignals'}; {'id': '163', 'type': 'argument_list', 'children': ['164']}; {'id': '164', 'type': 'False', 'children': []}
if self.tree_settings has been expanded, ask instruments for their actual values
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'get_contents_static'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'block_alias'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'context'}; {'id': '7', 'type': 'block', 'children': ['8', '15', '23', '66', '72', '79', '88', '270', '276', '287', '296', '306', '327', '331', '387']}; {'id': '8', 'type': 'if_statement', 'children': ['9', '12']}; {'id': '9', 'type': 'comparison_operator', 'children': ['10', '11'], 'value': 'not'}; {'id': '10', 'type': 'string', 'children': [], 'value': "'request'"}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'context'}; {'id': '12', 'type': 'block', 'children': ['13']}; {'id': '13', 'type': 'return_statement', 'children': ['14']}; {'id': '14', 'type': 'string', 'children': [], 'value': "''"}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'current_url'}; {'id': '18', 'type': 'attribute', 'children': ['19', '22']}; {'id': '19', 'type': 'subscript', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'context'}; {'id': '21', 'type': 'string', 'children': [], 'value': "'request'"}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '23', 'type': 'try_statement', 'children': ['24', '59']}; {'id': '24', 'type': 'block', 'children': ['25', '32', '36', '49']}; {'id': '25', 'type': 'expression_statement', 'children': ['26']}; {'id': '26', 'type': 'assignment', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'resolver_match'}; {'id': '28', 'type': 'call', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'resolve'}; {'id': '30', 'type': 'argument_list', 'children': ['31']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'current_url'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'assignment', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'namespace'}; {'id': '35', 'type': 'string', 'children': [], 'value': "''"}; {'id': '36', 'type': 'if_statement', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'resolver_match'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'namespaces'}; {'id': '40', 'type': 'block', 'children': ['41']}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'assignment', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'namespace'}; {'id': '44', 'type': 'subscript', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'resolver_match'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'namespaces'}; {'id': '48', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '49', 'type': 'expression_statement', 'children': ['50']}; {'id': '50', 'type': 'assignment', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'resolved_view_name'}; {'id': '52', 'type': 'binary_operator', 'children': ['53', '54'], 'value': '%'}; {'id': '53', 'type': 'string', 'children': [], 'value': "':%s:%s'"}; {'id': '54', 'type': 'tuple', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'namespace'}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'resolver_match'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'url_name'}; {'id': '59', 'type': 'except_clause', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'Resolver404'}; {'id': '61', 'type': 'block', 'children': ['62']}; {'id': '62', 'type': 'expression_statement', 'children': ['63']}; {'id': '63', 'type': 'assignment', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'resolved_view_name'}; {'id': '65', 'type': 'None', 'children': []}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'call', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': '_cache_init'}; {'id': '71', 'type': 'argument_list', 'children': []}; {'id': '72', 'type': 'expression_statement', 'children': ['73']}; {'id': '73', 'type': 'assignment', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'cache_entry_name'}; {'id': '75', 'type': 'call', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'cache_get_key'}; {'id': '77', 'type': 'argument_list', 'children': ['78']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'block_alias'}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'assignment', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '82', 'type': 'call', 'children': ['83', '86']}; {'id': '83', 'type': 'attribute', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': '_cache_get'}; {'id': '86', 'type': 'argument_list', 'children': ['87']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'cache_entry_name'}; {'id': '88', 'type': 'if_statement', 'children': ['89', '91']}; {'id': '89', 'type': 'not_operator', 'children': ['90']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '91', 'type': 'block', 'children': ['92', '114', '126', '262']}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'blocks'}; {'id': '95', 'type': 'call', 'children': ['96', '111']}; {'id': '96', 'type': 'attribute', 'children': ['97', '110']}; {'id': '97', 'type': 'call', 'children': ['98', '103']}; {'id': '98', 'type': 'attribute', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'Block'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'objects'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'filter'}; {'id': '103', 'type': 'argument_list', 'children': ['104', '107']}; {'id': '104', 'type': 'keyword_argument', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'alias'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'block_alias'}; {'id': '107', 'type': 'keyword_argument', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'hidden'}; {'id': '109', 'type': 'False', 'children': []}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'only'}; {'id': '111', 'type': 'argument_list', 'children': ['112', '113']}; {'id': '112', 'type': 'string', 'children': [], 'value': "'url'"}; {'id': '113', 'type': 'string', 'children': [], 'value': "'contents'"}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '117', 'type': 'list', 'children': ['118', '122'], 'value': '[defaultdict(list), defaultdict(list)]'}; {'id': '118', 'type': 'call', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'defaultdict'}; {'id': '120', 'type': 'argument_list', 'children': ['121']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '122', 'type': 'call', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'defaultdict'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '126', 'type': 'for_statement', 'children': ['127', '128', '129']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'blocks'}; {'id': '129', 'type': 'block', 'children': ['130', '190']}; {'id': '130', 'type': 'if_statement', 'children': ['131', '136', '143', '175']}; {'id': '131', 'type': 'comparison_operator', 'children': ['132', '135'], 'value': '=='}; {'id': '132', 'type': 'attribute', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '135', 'type': 'string', 'children': [], 'value': "'*'"}; {'id': '136', 'type': 'block', 'children': ['137']}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'assignment', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '140', 'type': 'attribute', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '143', 'type': 'elif_clause', 'children': ['144', '152']}; {'id': '144', 'type': 'call', 'children': ['145', '150']}; {'id': '145', 'type': 'attribute', 'children': ['146', '149']}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '150', 'type': 'argument_list', 'children': ['151']}; {'id': '151', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '152', 'type': 'block', 'children': ['153', '159']}; {'id': '153', 'type': 'expression_statement', 'children': ['154']}; {'id': '154', 'type': 'assignment', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '156', 'type': 'attribute', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '159', 'type': 'if_statement', 'children': ['160', '168']}; {'id': '160', 'type': 'comparison_operator', 'children': ['161', '167'], 'value': '=='}; {'id': '161', 'type': 'call', 'children': ['162', '165']}; {'id': '162', 'type': 'attribute', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'count'}; {'id': '165', 'type': 'argument_list', 'children': ['166']}; {'id': '166', 'type': 'string', 'children': [], 'value': "':'"}; {'id': '167', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '168', 'type': 'block', 'children': ['169']}; {'id': '169', 'type': 'expression_statement', 'children': ['170']}; {'id': '170', 'type': 'assignment', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '172', 'type': 'binary_operator', 'children': ['173', '174'], 'value': '%'}; {'id': '173', 'type': 'string', 'children': [], 'value': "':%s'"}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '175', 'type': 'else_clause', 'children': ['176']}; {'id': '176', 'type': 'block', 'children': ['177']}; {'id': '177', 'type': 'expression_statement', 'children': ['178']}; {'id': '178', 'type': 'assignment', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '180', 'type': 'call', 'children': ['181', '184']}; {'id': '181', 'type': 'attribute', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 're'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'compile'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'binary_operator', 'children': ['186', '187'], 'value': '%'}; {'id': '186', 'type': 'string', 'children': [], 'value': "r'%s'"}; {'id': '187', 'type': 'attribute', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '190', 'type': 'if_statement', 'children': ['191', '194', '210', '230']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'access_guest'}; {'id': '194', 'type': 'block', 'children': ['195']}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'call', 'children': ['197', '206']}; {'id': '197', 'type': 'attribute', 'children': ['198', '205']}; {'id': '198', 'type': 'subscript', 'children': ['199', '204']}; {'id': '199', 'type': 'subscript', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '201', 'type': 'attribute', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'IDX_GUEST'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '206', 'type': 'argument_list', 'children': ['207']}; {'id': '207', 'type': 'attribute', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '210', 'type': 'elif_clause', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'access_loggedin'}; {'id': '214', 'type': 'block', 'children': ['215']}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'call', 'children': ['217', '226']}; {'id': '217', 'type': 'attribute', 'children': ['218', '225']}; {'id': '218', 'type': 'subscript', 'children': ['219', '224']}; {'id': '219', 'type': 'subscript', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '221', 'type': 'attribute', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'IDX_AUTH'}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'attribute', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '230', 'type': 'else_clause', 'children': ['231']}; {'id': '231', 'type': 'block', 'children': ['232', '247']}; {'id': '232', 'type': 'expression_statement', 'children': ['233']}; {'id': '233', 'type': 'call', 'children': ['234', '243']}; {'id': '234', 'type': 'attribute', 'children': ['235', '242']}; {'id': '235', 'type': 'subscript', 'children': ['236', '241']}; {'id': '236', 'type': 'subscript', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '238', 'type': 'attribute', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'IDX_GUEST'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '243', 'type': 'argument_list', 'children': ['244']}; {'id': '244', 'type': 'attribute', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '247', 'type': 'expression_statement', 'children': ['248']}; {'id': '248', 'type': 'call', 'children': ['249', '258']}; {'id': '249', 'type': 'attribute', 'children': ['250', '257']}; {'id': '250', 'type': 'subscript', 'children': ['251', '256']}; {'id': '251', 'type': 'subscript', 'children': ['252', '253']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '253', 'type': 'attribute', 'children': ['254', '255']}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'IDX_AUTH'}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'url_re'}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '258', 'type': 'argument_list', 'children': ['259']}; {'id': '259', 'type': 'attribute', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'block'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '262', 'type': 'expression_statement', 'children': ['263']}; {'id': '263', 'type': 'call', 'children': ['264', '267']}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': '_cache_set'}; {'id': '267', 'type': 'argument_list', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'cache_entry_name'}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '270', 'type': 'expression_statement', 'children': ['271']}; {'id': '271', 'type': 'call', 'children': ['272', '275']}; {'id': '272', 'type': 'attribute', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': '_cache_save'}; {'id': '275', 'type': 'argument_list', 'children': []}; {'id': '276', 'type': 'expression_statement', 'children': ['277']}; {'id': '277', 'type': 'assignment', 'children': ['278', '279']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '279', 'type': 'call', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '281', 'type': 'argument_list', 'children': ['282', '285', '286']}; {'id': '282', 'type': 'subscript', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'context'}; {'id': '284', 'type': 'string', 'children': [], 'value': "'request'"}; {'id': '285', 'type': 'string', 'children': [], 'value': "'user'"}; {'id': '286', 'type': 'None', 'children': []}; {'id': '287', 'type': 'expression_statement', 'children': ['288']}; {'id': '288', 'type': 'assignment', 'children': ['289', '290']}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'is_authenticated'}; {'id': '290', 'type': 'call', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'getattr'}; {'id': '292', 'type': 'argument_list', 'children': ['293', '294', '295']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '294', 'type': 'string', 'children': [], 'value': "'is_authenticated'"}; {'id': '295', 'type': 'False', 'children': []}; {'id': '296', 'type': 'if_statement', 'children': ['297', '299']}; {'id': '297', 'type': 'not_operator', 'children': ['298']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'DJANGO_2'}; {'id': '299', 'type': 'block', 'children': ['300']}; {'id': '300', 'type': 'expression_statement', 'children': ['301']}; {'id': '301', 'type': 'assignment', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'is_authenticated'}; {'id': '303', 'type': 'call', 'children': ['304', '305']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'is_authenticated'}; {'id': '305', 'type': 'argument_list', 'children': []}; {'id': '306', 'type': 'if_statement', 'children': ['307', '308', '317']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'is_authenticated'}; {'id': '308', 'type': 'block', 'children': ['309']}; {'id': '309', 'type': 'expression_statement', 'children': ['310']}; {'id': '310', 'type': 'assignment', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '312', 'type': 'subscript', 'children': ['313', '314']}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '314', 'type': 'attribute', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'IDX_AUTH'}; {'id': '317', 'type': 'else_clause', 'children': ['318']}; {'id': '318', 'type': 'block', 'children': ['319']}; {'id': '319', 'type': 'expression_statement', 'children': ['320']}; {'id': '320', 'type': 'assignment', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '322', 'type': 'subscript', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'siteblocks_static'}; {'id': '324', 'type': 'attribute', 'children': ['325', '326']}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'IDX_GUEST'}; {'id': '327', 'type': 'expression_statement', 'children': ['328']}; {'id': '328', 'type': 'assignment', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'static_block_contents'}; {'id': '330', 'type': 'string', 'children': [], 'value': "''"}; {'id': '331', 'type': 'if_statement', 'children': ['332', '335', '345', '359']}; {'id': '332', 'type': 'comparison_operator', 'children': ['333', '334'], 'value': 'in'}; {'id': '333', 'type': 'string', 'children': [], 'value': "'*'"}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '335', 'type': 'block', 'children': ['336']}; {'id': '336', 'type': 'expression_statement', 'children': ['337']}; {'id': '337', 'type': 'assignment', 'children': ['338', '339']}; {'id': '338', 'type': 'identifier', 'children': [], 'value': 'static_block_contents'}; {'id': '339', 'type': 'call', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'choice'}; {'id': '341', 'type': 'argument_list', 'children': ['342']}; {'id': '342', 'type': 'subscript', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '344', 'type': 'string', 'children': [], 'value': "'*'"}; {'id': '345', 'type': 'elif_clause', 'children': ['346', '349']}; {'id': '346', 'type': 'comparison_operator', 'children': ['347', '348'], 'value': 'in'}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'resolved_view_name'}; {'id': '348', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '349', 'type': 'block', 'children': ['350']}; {'id': '350', 'type': 'expression_statement', 'children': ['351']}; {'id': '351', 'type': 'assignment', 'children': ['352', '353']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'static_block_contents'}; {'id': '353', 'type': 'call', 'children': ['354', '355']}; {'id': '354', 'type': 'identifier', 'children': [], 'value': 'choice'}; {'id': '355', 'type': 'argument_list', 'children': ['356']}; {'id': '356', 'type': 'subscript', 'children': ['357', '358']}; {'id': '357', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '358', 'type': 'identifier', 'children': [], 'value': 'resolved_view_name'}; {'id': '359', 'type': 'else_clause', 'children': ['360']}; {'id': '360', 'type': 'block', 'children': ['361']}; {'id': '361', 'type': 'for_statement', 'children': ['362', '365', '370']}; {'id': '362', 'type': 'pattern_list', 'children': ['363', '364']}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '365', 'type': 'call', 'children': ['366', '369']}; {'id': '366', 'type': 'attribute', 'children': ['367', '368']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'lookup_area'}; {'id': '368', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '369', 'type': 'argument_list', 'children': []}; {'id': '370', 'type': 'block', 'children': ['371']}; {'id': '371', 'type': 'if_statement', 'children': ['372', '378']}; {'id': '372', 'type': 'call', 'children': ['373', '376']}; {'id': '373', 'type': 'attribute', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'match'}; {'id': '376', 'type': 'argument_list', 'children': ['377']}; {'id': '377', 'type': 'identifier', 'children': [], 'value': 'current_url'}; {'id': '378', 'type': 'block', 'children': ['379', '386']}; {'id': '379', 'type': 'expression_statement', 'children': ['380']}; {'id': '380', 'type': 'assignment', 'children': ['381', '382']}; {'id': '381', 'type': 'identifier', 'children': [], 'value': 'static_block_contents'}; {'id': '382', 'type': 'call', 'children': ['383', '384']}; {'id': '383', 'type': 'identifier', 'children': [], 'value': 'choice'}; {'id': '384', 'type': 'argument_list', 'children': ['385']}; {'id': '385', 'type': 'identifier', 'children': [], 'value': 'contents'}; {'id': '386', 'type': 'break_statement', 'children': []}; {'id': '387', 'type': 'return_statement', 'children': ['388']}; {'id': '388', 'type': 'identifier', 'children': [], 'value': 'static_block_contents'}
Returns contents of a static block.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_sort_cards'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'typed_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'cards'}; {'id': '7', 'type': 'type', 'children': ['8']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'Generator'}; {'id': '9', 'type': 'type', 'children': ['10']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '11', 'type': 'block', 'children': ['12', '14']}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'string', 'children': [], 'value': "'''sort cards by blocknum and blockseq'''"}; {'id': '14', 'type': 'return_statement', 'children': ['15']}; {'id': '15', 'type': 'call', 'children': ['16', '17']}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '17', 'type': 'argument_list', 'children': ['18', '25']}; {'id': '18', 'type': 'list_comprehension', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'card'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '22', 'type': 'for_in_clause', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'card'}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'cards'}; {'id': '25', 'type': 'keyword_argument', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '27', 'type': 'call', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'itemgetter'}; {'id': '29', 'type': 'argument_list', 'children': ['30', '31', '32']}; {'id': '30', 'type': 'string', 'children': [], 'value': "'blocknum'"}; {'id': '31', 'type': 'string', 'children': [], 'value': "'blockseq'"}; {'id': '32', 'type': 'string', 'children': [], 'value': "'cardseq'"}
sort cards by blocknum and blockseq
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'set_config'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'dictionary_splat_pattern', 'children': ['6']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '7', 'type': 'block', 'children': ['8', '12', '41', '72', '103', '119', '150', '181', '214', '245', '261', '277', '308', '332', '366']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '11', 'type': 'False', 'children': []}; {'id': '12', 'type': 'if_statement', 'children': ['13', '16']}; {'id': '13', 'type': 'comparison_operator', 'children': ['14', '15'], 'value': 'in'}; {'id': '14', 'type': 'string', 'children': [], 'value': "'stdopt'"}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '16', 'type': 'block', 'children': ['17', '26', '35']}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'stdopt'}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '24', 'type': 'argument_list', 'children': ['25']}; {'id': '25', 'type': 'string', 'children': [], 'value': "'stdopt'"}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '29', 'type': '()', 'children': ['30']}; {'id': '30', 'type': 'comparison_operator', 'children': ['31', '32'], 'value': '!='}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'stdopt'}; {'id': '32', 'type': 'attribute', 'children': ['33', '34']}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'stdopt'}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'stdopt'}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'stdopt'}; {'id': '41', 'type': 'if_statement', 'children': ['42', '45']}; {'id': '42', 'type': 'comparison_operator', 'children': ['43', '44'], 'value': 'in'}; {'id': '43', 'type': 'string', 'children': [], 'value': "'attachopt'"}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '45', 'type': 'block', 'children': ['46', '55', '66']}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'assignment', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'attachopt'}; {'id': '49', 'type': 'call', 'children': ['50', '53']}; {'id': '50', 'type': 'attribute', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '53', 'type': 'argument_list', 'children': ['54']}; {'id': '54', 'type': 'string', 'children': [], 'value': "'attachopt'"}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '58', 'type': 'boolean_operator', 'children': ['59', '60'], 'value': 'or'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '60', 'type': '()', 'children': ['61']}; {'id': '61', 'type': 'comparison_operator', 'children': ['62', '63'], 'value': '!='}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'attachopt'}; {'id': '63', 'type': 'attribute', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'attachopt'}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'assignment', 'children': ['68', '71']}; {'id': '68', 'type': 'attribute', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'attachopt'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'attachopt'}; {'id': '72', 'type': 'if_statement', 'children': ['73', '76']}; {'id': '73', 'type': 'comparison_operator', 'children': ['74', '75'], 'value': 'in'}; {'id': '74', 'type': 'string', 'children': [], 'value': "'attachvalue'"}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '76', 'type': 'block', 'children': ['77', '86', '97']}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'assignment', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'attachvalue'}; {'id': '80', 'type': 'call', 'children': ['81', '84']}; {'id': '81', 'type': 'attribute', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '84', 'type': 'argument_list', 'children': ['85']}; {'id': '85', 'type': 'string', 'children': [], 'value': "'attachvalue'"}; {'id': '86', 'type': 'expression_statement', 'children': ['87']}; {'id': '87', 'type': 'assignment', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '89', 'type': 'boolean_operator', 'children': ['90', '91'], 'value': 'or'}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '91', 'type': '()', 'children': ['92']}; {'id': '92', 'type': 'comparison_operator', 'children': ['93', '94'], 'value': '!='}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'attachvalue'}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'attachvalue'}; {'id': '97', 'type': 'expression_statement', 'children': ['98']}; {'id': '98', 'type': 'assignment', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'attachvalue'}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'attachvalue'}; {'id': '103', 'type': 'if_statement', 'children': ['104', '107']}; {'id': '104', 'type': 'comparison_operator', 'children': ['105', '106'], 'value': 'in'}; {'id': '105', 'type': 'string', 'children': [], 'value': "'auto2dashes'"}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '107', 'type': 'block', 'children': ['108']}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'assignment', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'auto2dashes'}; {'id': '113', 'type': 'call', 'children': ['114', '117']}; {'id': '114', 'type': 'attribute', 'children': ['115', '116']}; {'id': '115', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '117', 'type': 'argument_list', 'children': ['118']}; {'id': '118', 'type': 'string', 'children': [], 'value': "'auto2dashes'"}; {'id': '119', 'type': 'if_statement', 'children': ['120', '123']}; {'id': '120', 'type': 'comparison_operator', 'children': ['121', '122'], 'value': 'in'}; {'id': '121', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '123', 'type': 'block', 'children': ['124', '133', '144']}; {'id': '124', 'type': 'expression_statement', 'children': ['125']}; {'id': '125', 'type': 'assignment', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '127', 'type': 'call', 'children': ['128', '131']}; {'id': '128', 'type': 'attribute', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '131', 'type': 'argument_list', 'children': ['132']}; {'id': '132', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'assignment', 'children': ['135', '136']}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '136', 'type': 'boolean_operator', 'children': ['137', '138'], 'value': 'or'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '138', 'type': '()', 'children': ['139']}; {'id': '139', 'type': 'comparison_operator', 'children': ['140', '141'], 'value': '!='}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '141', 'type': 'attribute', 'children': ['142', '143']}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '149']}; {'id': '146', 'type': 'attribute', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '150', 'type': 'if_statement', 'children': ['151', '154']}; {'id': '151', 'type': 'comparison_operator', 'children': ['152', '153'], 'value': 'in'}; {'id': '152', 'type': 'string', 'children': [], 'value': "'help'"}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '154', 'type': 'block', 'children': ['155', '166']}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'assignment', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '160', 'type': 'call', 'children': ['161', '164']}; {'id': '161', 'type': 'attribute', 'children': ['162', '163']}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '164', 'type': 'argument_list', 'children': ['165']}; {'id': '165', 'type': 'string', 'children': [], 'value': "'help'"}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'call', 'children': ['168', '171']}; {'id': '168', 'type': 'attribute', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': '_set_or_remove_extra_handler'}; {'id': '171', 'type': 'argument_list', 'children': ['172', '175', '178']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '175', 'type': 'tuple', 'children': ['176', '177']}; {'id': '176', 'type': 'string', 'children': [], 'value': "'--help'"}; {'id': '177', 'type': 'string', 'children': [], 'value': "'-h'"}; {'id': '178', 'type': 'attribute', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'help_handler'}; {'id': '181', 'type': 'if_statement', 'children': ['182', '185']}; {'id': '182', 'type': 'comparison_operator', 'children': ['183', '184'], 'value': 'in'}; {'id': '183', 'type': 'string', 'children': [], 'value': "'version'"}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '185', 'type': 'block', 'children': ['186', '197']}; {'id': '186', 'type': 'expression_statement', 'children': ['187']}; {'id': '187', 'type': 'assignment', 'children': ['188', '191']}; {'id': '188', 'type': 'attribute', 'children': ['189', '190']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '191', 'type': 'call', 'children': ['192', '195']}; {'id': '192', 'type': 'attribute', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '195', 'type': 'argument_list', 'children': ['196']}; {'id': '196', 'type': 'string', 'children': [], 'value': "'version'"}; {'id': '197', 'type': 'expression_statement', 'children': ['198']}; {'id': '198', 'type': 'call', 'children': ['199', '202']}; {'id': '199', 'type': 'attribute', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': '_set_or_remove_extra_handler'}; {'id': '202', 'type': 'argument_list', 'children': ['203', '208', '211']}; {'id': '203', 'type': 'comparison_operator', 'children': ['204', '207'], 'value': 'is'}; {'id': '204', 'type': 'attribute', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '207', 'type': 'None', 'children': []}; {'id': '208', 'type': 'tuple', 'children': ['209', '210']}; {'id': '209', 'type': 'string', 'children': [], 'value': "'--version'"}; {'id': '210', 'type': 'string', 'children': [], 'value': "'-v'"}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'version_handler'}; {'id': '214', 'type': 'if_statement', 'children': ['215', '218']}; {'id': '215', 'type': 'comparison_operator', 'children': ['216', '217'], 'value': 'in'}; {'id': '216', 'type': 'string', 'children': [], 'value': "'case_sensitive'"}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '218', 'type': 'block', 'children': ['219', '228', '239']}; {'id': '219', 'type': 'expression_statement', 'children': ['220']}; {'id': '220', 'type': 'assignment', 'children': ['221', '222']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'case_sensitive'}; {'id': '222', 'type': 'call', 'children': ['223', '226']}; {'id': '223', 'type': 'attribute', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '226', 'type': 'argument_list', 'children': ['227']}; {'id': '227', 'type': 'string', 'children': [], 'value': "'case_sensitive'"}; {'id': '228', 'type': 'expression_statement', 'children': ['229']}; {'id': '229', 'type': 'assignment', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '231', 'type': 'boolean_operator', 'children': ['232', '233'], 'value': 'or'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '233', 'type': '()', 'children': ['234']}; {'id': '234', 'type': 'comparison_operator', 'children': ['235', '236'], 'value': '!='}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'case_sensitive'}; {'id': '236', 'type': 'attribute', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'case_sensitive'}; {'id': '239', 'type': 'expression_statement', 'children': ['240']}; {'id': '240', 'type': 'assignment', 'children': ['241', '244']}; {'id': '241', 'type': 'attribute', 'children': ['242', '243']}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'case_sensitive'}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'case_sensitive'}; {'id': '245', 'type': 'if_statement', 'children': ['246', '249']}; {'id': '246', 'type': 'comparison_operator', 'children': ['247', '248'], 'value': 'in'}; {'id': '247', 'type': 'string', 'children': [], 'value': "'optionsfirst'"}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '249', 'type': 'block', 'children': ['250']}; {'id': '250', 'type': 'expression_statement', 'children': ['251']}; {'id': '251', 'type': 'assignment', 'children': ['252', '255']}; {'id': '252', 'type': 'attribute', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'options_first'}; {'id': '255', 'type': 'call', 'children': ['256', '259']}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '259', 'type': 'argument_list', 'children': ['260']}; {'id': '260', 'type': 'string', 'children': [], 'value': "'optionsfirst'"}; {'id': '261', 'type': 'if_statement', 'children': ['262', '265']}; {'id': '262', 'type': 'comparison_operator', 'children': ['263', '264'], 'value': 'in'}; {'id': '263', 'type': 'string', 'children': [], 'value': "'appearedonly'"}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '265', 'type': 'block', 'children': ['266']}; {'id': '266', 'type': 'expression_statement', 'children': ['267']}; {'id': '267', 'type': 'assignment', 'children': ['268', '271']}; {'id': '268', 'type': 'attribute', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'appeared_only'}; {'id': '271', 'type': 'call', 'children': ['272', '275']}; {'id': '272', 'type': 'attribute', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '275', 'type': 'argument_list', 'children': ['276']}; {'id': '276', 'type': 'string', 'children': [], 'value': "'appearedonly'"}; {'id': '277', 'type': 'if_statement', 'children': ['278', '281']}; {'id': '278', 'type': 'comparison_operator', 'children': ['279', '280'], 'value': 'in'}; {'id': '279', 'type': 'string', 'children': [], 'value': "'namedoptions'"}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '281', 'type': 'block', 'children': ['282', '291', '302']}; {'id': '282', 'type': 'expression_statement', 'children': ['283']}; {'id': '283', 'type': 'assignment', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'namedoptions'}; {'id': '285', 'type': 'call', 'children': ['286', '289']}; {'id': '286', 'type': 'attribute', 'children': ['287', '288']}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '289', 'type': 'argument_list', 'children': ['290']}; {'id': '290', 'type': 'string', 'children': [], 'value': "'namedoptions'"}; {'id': '291', 'type': 'expression_statement', 'children': ['292']}; {'id': '292', 'type': 'assignment', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '294', 'type': 'boolean_operator', 'children': ['295', '296'], 'value': 'or'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '296', 'type': '()', 'children': ['297']}; {'id': '297', 'type': 'comparison_operator', 'children': ['298', '299'], 'value': '!='}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'namedoptions'}; {'id': '299', 'type': 'attribute', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'namedoptions'}; {'id': '302', 'type': 'expression_statement', 'children': ['303']}; {'id': '303', 'type': 'assignment', 'children': ['304', '307']}; {'id': '304', 'type': 'attribute', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'namedoptions'}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'namedoptions'}; {'id': '308', 'type': 'if_statement', 'children': ['309', '312']}; {'id': '309', 'type': 'comparison_operator', 'children': ['310', '311'], 'value': 'in'}; {'id': '310', 'type': 'string', 'children': [], 'value': "'extra'"}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '312', 'type': 'block', 'children': ['313']}; {'id': '313', 'type': 'expression_statement', 'children': ['314']}; {'id': '314', 'type': 'call', 'children': ['315', '320']}; {'id': '315', 'type': 'attribute', 'children': ['316', '319']}; {'id': '316', 'type': 'attribute', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'extra'}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '320', 'type': 'argument_list', 'children': ['321']}; {'id': '321', 'type': 'call', 'children': ['322', '325']}; {'id': '322', 'type': 'attribute', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '324', 'type': 'identifier', 'children': [], 'value': '_formal_extra'}; {'id': '325', 'type': 'argument_list', 'children': ['326']}; {'id': '326', 'type': 'call', 'children': ['327', '330']}; {'id': '327', 'type': 'attribute', 'children': ['328', '329']}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '330', 'type': 'argument_list', 'children': ['331']}; {'id': '331', 'type': 'string', 'children': [], 'value': "'extra'"}; {'id': '332', 'type': 'if_statement', 'children': ['333', '334']}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '334', 'type': 'block', 'children': ['335']}; {'id': '335', 'type': 'raise_statement', 'children': ['336']}; {'id': '336', 'type': 'call', 'children': ['337', '338']}; {'id': '337', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '338', 'type': 'argument_list', 'children': ['339']}; {'id': '339', 'type': 'binary_operator', 'children': ['340', '341'], 'value': '%'}; {'id': '340', 'type': 'string', 'children': [], 'value': "'`%s` %s not accepted key argument%s'"}; {'id': '341', 'type': 'tuple', 'children': ['342', '348', '357']}; {'id': '342', 'type': 'call', 'children': ['343', '346']}; {'id': '343', 'type': 'attribute', 'children': ['344', '345']}; {'id': '344', 'type': 'string', 'children': [], 'value': "'`, `'"}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '346', 'type': 'argument_list', 'children': ['347']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '348', 'type': 'conditional_expression', 'children': ['349', '350', '356'], 'value': 'if'}; {'id': '349', 'type': 'string', 'children': [], 'value': "'is'"}; {'id': '350', 'type': 'comparison_operator', 'children': ['351', '355'], 'value': '=='}; {'id': '351', 'type': 'call', 'children': ['352', '353']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '353', 'type': 'argument_list', 'children': ['354']}; {'id': '354', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '355', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '356', 'type': 'string', 'children': [], 'value': "'are'"}; {'id': '357', 'type': 'conditional_expression', 'children': ['358', '359', '365'], 'value': 'if'}; {'id': '358', 'type': 'string', 'children': [], 'value': "''"}; {'id': '359', 'type': 'comparison_operator', 'children': ['360', '364'], 'value': '=='}; {'id': '360', 'type': 'call', 'children': ['361', '362']}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '362', 'type': 'argument_list', 'children': ['363']}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '364', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '365', 'type': 'string', 'children': [], 'value': "'s'"}; {'id': '366', 'type': 'if_statement', 'children': ['367', '374']}; {'id': '367', 'type': 'boolean_operator', 'children': ['368', '373'], 'value': 'and'}; {'id': '368', 'type': 'comparison_operator', 'children': ['369', '372'], 'value': 'is'}; {'id': '369', 'type': 'attribute', 'children': ['370', '371']}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'doc'}; {'id': '372', 'type': 'None', 'children': []}; {'id': '373', 'type': 'identifier', 'children': [], 'value': 'reinit'}; {'id': '374', 'type': 'block', 'children': ['375', '384']}; {'id': '375', 'type': 'expression_statement', 'children': ['376']}; {'id': '376', 'type': 'call', 'children': ['377', '380']}; {'id': '377', 'type': 'attribute', 'children': ['378', '379']}; {'id': '378', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '380', 'type': 'argument_list', 'children': ['381']}; {'id': '381', 'type': 'concatenated_string', 'children': ['382', '383']}; {'id': '382', 'type': 'string', 'children': [], 'value': "'You changed the config that requires re-initialized'"}; {'id': '383', 'type': 'string', 'children': [], 'value': "' `Docpie` object. Create a new one instead'"}; {'id': '384', 'type': 'expression_statement', 'children': ['385']}; {'id': '385', 'type': 'call', 'children': ['386', '389']}; {'id': '386', 'type': 'attribute', 'children': ['387', '388']}; {'id': '387', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '388', 'type': 'identifier', 'children': [], 'value': '_init'}; {'id': '389', 'type': 'argument_list', 'children': []}
Shadow all the current config.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '10']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'preview'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '7', 'type': 'attribute', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'stdout'}; {'id': '10', 'type': 'block', 'children': ['11', '17', '33', '38', '49', '54', '61', '66', '72', '94', '99', '110', '119', '132', '137', '196', '207', '216', '229', '234', '293', '304', '309']}; {'id': '11', 'type': 'expression_statement', 'children': ['12']}; {'id': '12', 'type': 'assignment', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '14', 'type': 'attribute', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'stream'}; {'id': '16', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'call', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '20', 'type': 'argument_list', 'children': ['21']}; {'id': '21', 'type': 'call', 'children': ['22', '30']}; {'id': '22', 'type': 'attribute', 'children': ['23', '29']}; {'id': '23', 'type': '()', 'children': ['24']}; {'id': '24', 'type': 'binary_operator', 'children': ['25', '26'], 'value': '%'}; {'id': '25', 'type': 'string', 'children': [], 'value': "'[Quick preview of Docpie %s]'"}; {'id': '26', 'type': 'attribute', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': '_version'}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'center'}; {'id': '30', 'type': 'argument_list', 'children': ['31', '32']}; {'id': '31', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '32', 'type': 'string', 'children': [], 'value': "'='"}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'call', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '36', 'type': 'argument_list', 'children': ['37']}; {'id': '37', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'call', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '41', 'type': 'argument_list', 'children': ['42']}; {'id': '42', 'type': 'call', 'children': ['43', '46']}; {'id': '43', 'type': 'attribute', 'children': ['44', '45']}; {'id': '44', 'type': 'string', 'children': [], 'value': "' sections '"}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'center'}; {'id': '46', 'type': 'argument_list', 'children': ['47', '48']}; {'id': '47', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '48', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '49', 'type': 'expression_statement', 'children': ['50']}; {'id': '50', 'type': 'call', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '52', 'type': 'argument_list', 'children': ['53']}; {'id': '53', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '54', 'type': 'expression_statement', 'children': ['55']}; {'id': '55', 'type': 'call', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '57', 'type': 'argument_list', 'children': ['58']}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'usage_text'}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'call', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '64', 'type': 'argument_list', 'children': ['65']}; {'id': '65', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '66', 'type': 'expression_statement', 'children': ['67']}; {'id': '67', 'type': 'assignment', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'option_sections'}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'option_sections'}; {'id': '72', 'type': 'if_statement', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'option_sections'}; {'id': '74', 'type': 'block', 'children': ['75', '80']}; {'id': '75', 'type': 'expression_statement', 'children': ['76']}; {'id': '76', 'type': 'call', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'call', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '83', 'type': 'argument_list', 'children': ['84']}; {'id': '84', 'type': 'call', 'children': ['85', '88']}; {'id': '85', 'type': 'attribute', 'children': ['86', '87']}; {'id': '86', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '88', 'type': 'argument_list', 'children': ['89']}; {'id': '89', 'type': 'call', 'children': ['90', '93']}; {'id': '90', 'type': 'attribute', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'option_sections'}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '93', 'type': 'argument_list', 'children': []}; {'id': '94', 'type': 'expression_statement', 'children': ['95']}; {'id': '95', 'type': 'call', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '97', 'type': 'argument_list', 'children': ['98']}; {'id': '98', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '99', 'type': 'expression_statement', 'children': ['100']}; {'id': '100', 'type': 'call', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '102', 'type': 'argument_list', 'children': ['103']}; {'id': '103', 'type': 'call', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'string', 'children': [], 'value': "' str '"}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'center'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109']}; {'id': '108', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '109', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '110', 'type': 'expression_statement', 'children': ['111']}; {'id': '111', 'type': 'call', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '113', 'type': 'argument_list', 'children': ['114']}; {'id': '114', 'type': 'binary_operator', 'children': ['115', '116'], 'value': '%'}; {'id': '115', 'type': 'string', 'children': [], 'value': "'\\n[%s]\\n'"}; {'id': '116', 'type': 'attribute', 'children': ['117', '118']}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'usage_name'}; {'id': '119', 'type': 'for_statement', 'children': ['120', '121', '124']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'usages'}; {'id': '124', 'type': 'block', 'children': ['125']}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'call', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '128', 'type': 'argument_list', 'children': ['129']}; {'id': '129', 'type': 'binary_operator', 'children': ['130', '131'], 'value': '%'}; {'id': '130', 'type': 'string', 'children': [], 'value': "' %s\\n'"}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '132', 'type': 'expression_statement', 'children': ['133']}; {'id': '133', 'type': 'call', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '135', 'type': 'argument_list', 'children': ['136']}; {'id': '136', 'type': 'string', 'children': [], 'value': "'\\n[Options:]\\n\\n'"}; {'id': '137', 'type': 'for_statement', 'children': ['138', '141', '148']}; {'id': '138', 'type': 'pattern_list', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'sections'}; {'id': '141', 'type': 'call', 'children': ['142', '147']}; {'id': '142', 'type': 'attribute', 'children': ['143', '146']}; {'id': '143', 'type': 'attribute', 'children': ['144', '145']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '147', 'type': 'argument_list', 'children': []}; {'id': '148', 'type': 'block', 'children': ['149', '170', '175', '180', '191']}; {'id': '149', 'type': 'if_statement', 'children': ['150', '151', '162']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '151', 'type': 'block', 'children': ['152']}; {'id': '152', 'type': 'expression_statement', 'children': ['153']}; {'id': '153', 'type': 'assignment', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '155', 'type': 'binary_operator', 'children': ['156', '157'], 'value': '%'}; {'id': '156', 'type': 'string', 'children': [], 'value': "'%s %s'"}; {'id': '157', 'type': 'tuple', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'option_name'}; {'id': '162', 'type': 'else_clause', 'children': ['163']}; {'id': '163', 'type': 'block', 'children': ['164']}; {'id': '164', 'type': 'expression_statement', 'children': ['165']}; {'id': '165', 'type': 'assignment', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '167', 'type': 'attribute', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'option_name'}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '173', 'type': 'argument_list', 'children': ['174']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '175', 'type': 'expression_statement', 'children': ['176']}; {'id': '176', 'type': 'call', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '178', 'type': 'argument_list', 'children': ['179']}; {'id': '179', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '180', 'type': 'for_statement', 'children': ['181', '182', '183']}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'sections'}; {'id': '183', 'type': 'block', 'children': ['184']}; {'id': '184', 'type': 'expression_statement', 'children': ['185']}; {'id': '185', 'type': 'call', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '187', 'type': 'argument_list', 'children': ['188']}; {'id': '188', 'type': 'binary_operator', 'children': ['189', '190'], 'value': '%'}; {'id': '189', 'type': 'string', 'children': [], 'value': "' %s\\n'"}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '191', 'type': 'expression_statement', 'children': ['192']}; {'id': '192', 'type': 'call', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '194', 'type': 'argument_list', 'children': ['195']}; {'id': '195', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'call', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '199', 'type': 'argument_list', 'children': ['200']}; {'id': '200', 'type': 'call', 'children': ['201', '204']}; {'id': '201', 'type': 'attribute', 'children': ['202', '203']}; {'id': '202', 'type': 'string', 'children': [], 'value': "' repr '"}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'center'}; {'id': '204', 'type': 'argument_list', 'children': ['205', '206']}; {'id': '205', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '206', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '207', 'type': 'expression_statement', 'children': ['208']}; {'id': '208', 'type': 'call', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '210', 'type': 'argument_list', 'children': ['211']}; {'id': '211', 'type': 'binary_operator', 'children': ['212', '213'], 'value': '%'}; {'id': '212', 'type': 'string', 'children': [], 'value': "'\\n[%s]\\n'"}; {'id': '213', 'type': 'attribute', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'usage_name'}; {'id': '216', 'type': 'for_statement', 'children': ['217', '218', '221']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '218', 'type': 'attribute', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'usages'}; {'id': '221', 'type': 'block', 'children': ['222']}; {'id': '222', 'type': 'expression_statement', 'children': ['223']}; {'id': '223', 'type': 'call', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '225', 'type': 'argument_list', 'children': ['226']}; {'id': '226', 'type': 'binary_operator', 'children': ['227', '228'], 'value': '%'}; {'id': '227', 'type': 'string', 'children': [], 'value': "' %r\\n'"}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'call', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '232', 'type': 'argument_list', 'children': ['233']}; {'id': '233', 'type': 'string', 'children': [], 'value': "'\\n[Options:]\\n\\n'"}; {'id': '234', 'type': 'for_statement', 'children': ['235', '238', '245']}; {'id': '235', 'type': 'pattern_list', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'sections'}; {'id': '238', 'type': 'call', 'children': ['239', '244']}; {'id': '239', 'type': 'attribute', 'children': ['240', '243']}; {'id': '240', 'type': 'attribute', 'children': ['241', '242']}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'options'}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '244', 'type': 'argument_list', 'children': []}; {'id': '245', 'type': 'block', 'children': ['246', '267', '272', '277', '288']}; {'id': '246', 'type': 'if_statement', 'children': ['247', '248', '259']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '248', 'type': 'block', 'children': ['249']}; {'id': '249', 'type': 'expression_statement', 'children': ['250']}; {'id': '250', 'type': 'assignment', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '252', 'type': 'binary_operator', 'children': ['253', '254'], 'value': '%'}; {'id': '253', 'type': 'string', 'children': [], 'value': "'%s %s'"}; {'id': '254', 'type': 'tuple', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'title'}; {'id': '256', 'type': 'attribute', 'children': ['257', '258']}; {'id': '257', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'option_name'}; {'id': '259', 'type': 'else_clause', 'children': ['260']}; {'id': '260', 'type': 'block', 'children': ['261']}; {'id': '261', 'type': 'expression_statement', 'children': ['262']}; {'id': '262', 'type': 'assignment', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'option_name'}; {'id': '267', 'type': 'expression_statement', 'children': ['268']}; {'id': '268', 'type': 'call', 'children': ['269', '270']}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '270', 'type': 'argument_list', 'children': ['271']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'full_title'}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'call', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '275', 'type': 'argument_list', 'children': ['276']}; {'id': '276', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '277', 'type': 'for_statement', 'children': ['278', '279', '280']}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'sections'}; {'id': '280', 'type': 'block', 'children': ['281']}; {'id': '281', 'type': 'expression_statement', 'children': ['282']}; {'id': '282', 'type': 'call', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '284', 'type': 'argument_list', 'children': ['285']}; {'id': '285', 'type': 'binary_operator', 'children': ['286', '287'], 'value': '%'}; {'id': '286', 'type': 'string', 'children': [], 'value': "' %r\\n'"}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'each'}; {'id': '288', 'type': 'expression_statement', 'children': ['289']}; {'id': '289', 'type': 'call', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '291', 'type': 'argument_list', 'children': ['292']}; {'id': '292', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '293', 'type': 'expression_statement', 'children': ['294']}; {'id': '294', 'type': 'call', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '296', 'type': 'argument_list', 'children': ['297']}; {'id': '297', 'type': 'call', 'children': ['298', '301']}; {'id': '298', 'type': 'attribute', 'children': ['299', '300']}; {'id': '299', 'type': 'string', 'children': [], 'value': "' auto handlers '"}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'center'}; {'id': '301', 'type': 'argument_list', 'children': ['302', '303']}; {'id': '302', 'type': 'integer', 'children': [], 'value': '80'}; {'id': '303', 'type': 'string', 'children': [], 'value': "'-'"}; {'id': '304', 'type': 'expression_statement', 'children': ['305']}; {'id': '305', 'type': 'call', 'children': ['306', '307']}; {'id': '306', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '307', 'type': 'argument_list', 'children': ['308']}; {'id': '308', 'type': 'string', 'children': [], 'value': "'\\n'"}; {'id': '309', 'type': 'for_statement', 'children': ['310', '313', '320']}; {'id': '310', 'type': 'pattern_list', 'children': ['311', '312']}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '313', 'type': 'call', 'children': ['314', '319']}; {'id': '314', 'type': 'attribute', 'children': ['315', '318']}; {'id': '315', 'type': 'attribute', 'children': ['316', '317']}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'extra'}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '319', 'type': 'argument_list', 'children': []}; {'id': '320', 'type': 'block', 'children': ['321']}; {'id': '321', 'type': 'expression_statement', 'children': ['322']}; {'id': '322', 'type': 'call', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '324', 'type': 'argument_list', 'children': ['325']}; {'id': '325', 'type': 'binary_operator', 'children': ['326', '327'], 'value': '%'}; {'id': '326', 'type': 'string', 'children': [], 'value': "'%s %s\\n'"}; {'id': '327', 'type': 'tuple', 'children': ['328', '329']}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'value'}
A quick preview of docpie. Print all the parsed object
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'parts'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '16', '20', '24', '28', '38', '42', '110', '180', '207', '242', '251']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '9', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '10', 'type': 'expression_statement', 'children': ['11']}; {'id': '11', 'type': 'assignment', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '13', 'type': 'call', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '15', 'type': 'argument_list', 'children': []}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'assignment', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '19', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '20', 'type': 'expression_statement', 'children': ['21']}; {'id': '21', 'type': 'assignment', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'max_upload_size'}; {'id': '23', 'type': 'integer', 'children': [], 'value': '700000'}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'base_part_size'}; {'id': '27', 'type': 'integer', 'children': [], 'value': '118'}; {'id': '28', 'type': 'if_statement', 'children': ['29', '33']}; {'id': '29', 'type': 'not_operator', 'children': ['30']}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '33', 'type': 'block', 'children': ['34']}; {'id': '34', 'type': 'expression_statement', 'children': ['35']}; {'id': '35', 'type': 'augmented_assignment', 'children': ['36', '37'], 'value': '+='}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'base_part_size'}; {'id': '37', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'base_part_size'}; {'id': '42', 'type': 'for_statement', 'children': ['43', '44', '47']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '44', 'type': 'attribute', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '47', 'type': 'block', 'children': ['48', '88', '102']}; {'id': '48', 'type': 'if_statement', 'children': ['49', '59']}; {'id': '49', 'type': 'comparison_operator', 'children': ['50', '58'], 'value': '>='}; {'id': '50', 'type': '()', 'children': ['51']}; {'id': '51', 'type': 'binary_operator', 'children': ['52', '53'], 'value': '+'}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '53', 'type': 'subscript', 'children': ['54', '57']}; {'id': '54', 'type': 'attribute', 'children': ['55', '56']}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'upserts_size'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'max_upload_size'}; {'id': '59', 'type': 'block', 'children': ['60', '74', '80', '84']}; {'id': '60', 'type': 'expression_statement', 'children': ['61']}; {'id': '61', 'type': 'call', 'children': ['62', '65']}; {'id': '62', 'type': 'attribute', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '65', 'type': 'argument_list', 'children': ['66']}; {'id': '66', 'type': 'call', 'children': ['67', '68']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'BatchPart'}; {'id': '68', 'type': 'argument_list', 'children': ['69', '72', '73']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'assignment', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '77', 'type': 'call', 'children': ['78', '79']}; {'id': '78', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '79', 'type': 'argument_list', 'children': []}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '83', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '84', 'type': 'expression_statement', 'children': ['85']}; {'id': '85', 'type': 'assignment', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'base_part_size'}; {'id': '88', 'type': 'expression_statement', 'children': ['89']}; {'id': '89', 'type': 'assignment', 'children': ['90', '97']}; {'id': '90', 'type': 'subscript', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '92', 'type': 'subscript', 'children': ['93', '96']}; {'id': '93', 'type': 'attribute', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'lower_val_to_val'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '97', 'type': 'subscript', 'children': ['98', '101']}; {'id': '98', 'type': 'attribute', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'augmented_assignment', 'children': ['104', '105'], 'value': '+='}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '105', 'type': 'subscript', 'children': ['106', '109']}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'upserts_size'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '110', 'type': 'for_statement', 'children': ['111', '112', '115']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '112', 'type': 'attribute', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '115', 'type': 'block', 'children': ['116', '157', '171']}; {'id': '116', 'type': 'if_statement', 'children': ['117', '128']}; {'id': '117', 'type': 'comparison_operator', 'children': ['118', '127'], 'value': '>='}; {'id': '118', 'type': '()', 'children': ['119']}; {'id': '119', 'type': 'binary_operator', 'children': ['120', '126'], 'value': '+'}; {'id': '120', 'type': 'binary_operator', 'children': ['121', '122'], 'value': '+'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '122', 'type': 'call', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '126', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'max_upload_size'}; {'id': '128', 'type': 'block', 'children': ['129', '143', '149', '153']}; {'id': '129', 'type': 'expression_statement', 'children': ['130']}; {'id': '130', 'type': 'call', 'children': ['131', '134']}; {'id': '131', 'type': 'attribute', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '134', 'type': 'argument_list', 'children': ['135']}; {'id': '135', 'type': 'call', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'BatchPart'}; {'id': '137', 'type': 'argument_list', 'children': ['138', '141', '142']}; {'id': '138', 'type': 'attribute', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'assignment', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '146', 'type': 'call', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '148', 'type': 'argument_list', 'children': []}; {'id': '149', 'type': 'expression_statement', 'children': ['150']}; {'id': '150', 'type': 'assignment', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '152', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '153', 'type': 'expression_statement', 'children': ['154']}; {'id': '154', 'type': 'assignment', 'children': ['155', '156']}; {'id': '155', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'base_part_size'}; {'id': '157', 'type': 'expression_statement', 'children': ['158']}; {'id': '158', 'type': 'call', 'children': ['159', '162']}; {'id': '159', 'type': 'attribute', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '162', 'type': 'argument_list', 'children': ['163']}; {'id': '163', 'type': 'dictionary', 'children': ['164']}; {'id': '164', 'type': 'pair', 'children': ['165', '166']}; {'id': '165', 'type': 'string', 'children': [], 'value': "'value'"}; {'id': '166', 'type': 'subscript', 'children': ['167', '170']}; {'id': '167', 'type': 'attribute', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'lower_val_to_val'}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'augmented_assignment', 'children': ['173', '174'], 'value': '+='}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'part_size'}; {'id': '174', 'type': 'binary_operator', 'children': ['175', '179'], 'value': '+'}; {'id': '175', 'type': 'call', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '177', 'type': 'argument_list', 'children': ['178']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '179', 'type': 'integer', 'children': [], 'value': '4'}; {'id': '180', 'type': 'if_statement', 'children': ['181', '192']}; {'id': '181', 'type': 'comparison_operator', 'children': ['182', '191'], 'value': '>'}; {'id': '182', 'type': 'binary_operator', 'children': ['183', '187'], 'value': '+'}; {'id': '183', 'type': 'call', 'children': ['184', '185']}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '185', 'type': 'argument_list', 'children': ['186']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '191', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '192', 'type': 'block', 'children': ['193']}; {'id': '193', 'type': 'expression_statement', 'children': ['194']}; {'id': '194', 'type': 'call', 'children': ['195', '198']}; {'id': '195', 'type': 'attribute', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '198', 'type': 'argument_list', 'children': ['199']}; {'id': '199', 'type': 'call', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'BatchPart'}; {'id': '201', 'type': 'argument_list', 'children': ['202', '205', '206']}; {'id': '202', 'type': 'attribute', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'upserts'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'deletes'}; {'id': '207', 'type': 'if_statement', 'children': ['208', '214']}; {'id': '208', 'type': 'comparison_operator', 'children': ['209', '213'], 'value': '=='}; {'id': '209', 'type': 'call', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '211', 'type': 'argument_list', 'children': ['212']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '213', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '214', 'type': 'block', 'children': ['215', '226']}; {'id': '215', 'type': 'if_statement', 'children': ['216', '220']}; {'id': '216', 'type': 'not_operator', 'children': ['217']}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '220', 'type': 'block', 'children': ['221']}; {'id': '221', 'type': 'raise_statement', 'children': ['222']}; {'id': '222', 'type': 'call', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '224', 'type': 'argument_list', 'children': ['225']}; {'id': '225', 'type': 'string', 'children': [], 'value': '"Batch has no data, and \'replace_all\' is False"'}; {'id': '226', 'type': 'expression_statement', 'children': ['227']}; {'id': '227', 'type': 'call', 'children': ['228', '231']}; {'id': '228', 'type': 'attribute', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '231', 'type': 'argument_list', 'children': ['232']}; {'id': '232', 'type': 'call', 'children': ['233', '234']}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'BatchPart'}; {'id': '234', 'type': 'argument_list', 'children': ['235', '238', '241']}; {'id': '235', 'type': 'attribute', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'replace_all'}; {'id': '238', 'type': 'call', 'children': ['239', '240']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '240', 'type': 'argument_list', 'children': []}; {'id': '241', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '242', 'type': 'expression_statement', 'children': ['243']}; {'id': '243', 'type': 'call', 'children': ['244', '250']}; {'id': '244', 'type': 'attribute', 'children': ['245', '249']}; {'id': '245', 'type': 'subscript', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'parts'}; {'id': '247', 'type': 'unary_operator', 'children': ['248'], 'value': '-'}; {'id': '248', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'set_last_part'}; {'id': '250', 'type': 'argument_list', 'children': []}; {'id': '251', 'type': 'return_statement', 'children': ['252']}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'parts'}
Return an array of batch parts to submit
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'SplitString'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '5', 'type': 'block', 'children': ['6', '13', '22', '29', '33', '83', '246']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'string_length'}; {'id': '9', 'type': 'call', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '11', 'type': 'argument_list', 'children': ['12']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '13', 'type': 'expression_statement', 'children': ['14']}; {'id': '14', 'type': 'assignment', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'chunks'}; {'id': '16', 'type': 'call', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '18', 'type': 'argument_list', 'children': ['19']}; {'id': '19', 'type': 'binary_operator', 'children': ['20', '21'], 'value': '/'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'string_length'}; {'id': '21', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '25', 'type': 'call', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '27', 'type': 'argument_list', 'children': ['28']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '29', 'type': 'expression_statement', 'children': ['30']}; {'id': '30', 'type': 'assignment', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '32', 'type': 'string', 'children': [], 'value': '""'}; {'id': '33', 'type': 'if_statement', 'children': ['34', '37']}; {'id': '34', 'type': 'comparison_operator', 'children': ['35', '36'], 'value': '>'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'chunks'}; {'id': '36', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '37', 'type': 'block', 'children': ['38', '42', '79']}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '41', 'type': 'string', 'children': [], 'value': '"\\\\markup { \\n\\r \\column { "'}; {'id': '42', 'type': 'for_statement', 'children': ['43', '44', '51']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '44', 'type': 'call', 'children': ['45', '46']}; {'id': '45', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '46', 'type': 'argument_list', 'children': ['47']}; {'id': '47', 'type': 'call', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '49', 'type': 'argument_list', 'children': ['50']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'chunks'}; {'id': '51', 'type': 'block', 'children': ['52', '56', '62', '75']}; {'id': '52', 'type': 'expression_statement', 'children': ['53']}; {'id': '53', 'type': 'augmented_assignment', 'children': ['54', '55'], 'value': '+='}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '55', 'type': 'string', 'children': [], 'value': '"\\n\\r\\r \\\\line { \\""'}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '59', 'type': 'binary_operator', 'children': ['60', '61'], 'value': '*'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '61', 'type': 'integer', 'children': [], 'value': '10'}; {'id': '62', 'type': 'for_statement', 'children': ['63', '64', '68']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '64', 'type': 'call', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'index'}; {'id': '68', 'type': 'block', 'children': ['69']}; {'id': '69', 'type': 'expression_statement', 'children': ['70']}; {'id': '70', 'type': 'augmented_assignment', 'children': ['71', '72'], 'value': '+='}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '72', 'type': 'subscript', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '75', 'type': 'expression_statement', 'children': ['76']}; {'id': '76', 'type': 'augmented_assignment', 'children': ['77', '78'], 'value': '+='}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '78', 'type': 'string', 'children': [], 'value': '"\\" \\r\\r}"'}; {'id': '79', 'type': 'expression_statement', 'children': ['80']}; {'id': '80', 'type': 'augmented_assignment', 'children': ['81', '82'], 'value': '+='}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '82', 'type': 'string', 'children': [], 'value': '"\\n\\r } \\n }"'}; {'id': '83', 'type': 'if_statement', 'children': ['84', '87']}; {'id': '84', 'type': 'comparison_operator', 'children': ['85', '86'], 'value': '=='}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '86', 'type': 'string', 'children': [], 'value': '""'}; {'id': '87', 'type': 'block', 'children': ['88', '114', '118']}; {'id': '88', 'type': 'expression_statement', 'children': ['89']}; {'id': '89', 'type': 'assignment', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '91', 'type': 'list_comprehension', 'children': ['92', '93', '102']}; {'id': '92', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '93', 'type': 'for_in_clause', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '95', 'type': 'call', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '97', 'type': 'argument_list', 'children': ['98']}; {'id': '98', 'type': 'call', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '100', 'type': 'argument_list', 'children': ['101']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '102', 'type': 'if_clause', 'children': ['103']}; {'id': '103', 'type': 'boolean_operator', 'children': ['104', '109'], 'value': 'or'}; {'id': '104', 'type': 'comparison_operator', 'children': ['105', '108'], 'value': '=='}; {'id': '105', 'type': 'subscript', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '108', 'type': 'string', 'children': [], 'value': '"\\r"'}; {'id': '109', 'type': 'comparison_operator', 'children': ['110', '113'], 'value': '=='}; {'id': '110', 'type': 'subscript', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '113', 'type': 'string', 'children': [], 'value': '"\\n"'}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '117', 'type': 'string', 'children': [], 'value': '"\\\\markup { \\n\\r \\column { "'}; {'id': '118', 'type': 'if_statement', 'children': ['119', '125', '139']}; {'id': '119', 'type': 'comparison_operator', 'children': ['120', '124'], 'value': '=='}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '122', 'type': 'argument_list', 'children': ['123']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '124', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '125', 'type': 'block', 'children': ['126']}; {'id': '126', 'type': 'expression_statement', 'children': ['127']}; {'id': '127', 'type': 'augmented_assignment', 'children': ['128', '129'], 'value': '+='}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '129', 'type': 'binary_operator', 'children': ['130', '138'], 'value': '+'}; {'id': '130', 'type': 'binary_operator', 'children': ['131', '132'], 'value': '+'}; {'id': '131', 'type': 'string', 'children': [], 'value': '"\\n\\r\\r \\\\line { \\""'}; {'id': '132', 'type': 'call', 'children': ['133', '136']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'string', 'children': [], 'value': '""'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '136', 'type': 'argument_list', 'children': ['137']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '138', 'type': 'string', 'children': [], 'value': '"\\" \\n\\r\\r } \\n\\r } \\n }"'}; {'id': '139', 'type': 'else_clause', 'children': ['140']}; {'id': '140', 'type': 'block', 'children': ['141', '145', '155', '162', '221', '242']}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'assignment', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'rows'}; {'id': '144', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '145', 'type': 'expression_statement', 'children': ['146']}; {'id': '146', 'type': 'assignment', 'children': ['147', '148']}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'row_1'}; {'id': '148', 'type': 'subscript', 'children': ['149', '150']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '150', 'type': 'slice', 'children': ['151', '152']}; {'id': '151', 'type': 'colon', 'children': []}; {'id': '152', 'type': 'subscript', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '154', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '155', 'type': 'expression_statement', 'children': ['156']}; {'id': '156', 'type': 'call', 'children': ['157', '160']}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'rows'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '160', 'type': 'argument_list', 'children': ['161']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'row_1'}; {'id': '162', 'type': 'for_statement', 'children': ['163', '164', '171']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '164', 'type': 'call', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'range'}; {'id': '166', 'type': 'argument_list', 'children': ['167']}; {'id': '167', 'type': 'call', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '169', 'type': 'argument_list', 'children': ['170']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '171', 'type': 'block', 'children': ['172', '178', '205', '214']}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'assignment', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '175', 'type': 'subscript', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '178', 'type': 'if_statement', 'children': ['179', '187', '196']}; {'id': '179', 'type': 'comparison_operator', 'children': ['180', '181'], 'value': '!='}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '181', 'type': 'binary_operator', 'children': ['182', '186'], 'value': '-'}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '186', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '187', 'type': 'block', 'children': ['188']}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'assignment', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '191', 'type': 'subscript', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'indexes'}; {'id': '193', 'type': 'binary_operator', 'children': ['194', '195'], 'value': '+'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '195', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '196', 'type': 'else_clause', 'children': ['197']}; {'id': '197', 'type': 'block', 'children': ['198']}; {'id': '198', 'type': 'expression_statement', 'children': ['199']}; {'id': '199', 'type': 'assignment', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '201', 'type': 'call', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'assignment', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '208', 'type': 'subscript', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'string_list'}; {'id': '210', 'type': 'slice', 'children': ['211', '212', '213']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '212', 'type': 'colon', 'children': []}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'end'}; {'id': '214', 'type': 'expression_statement', 'children': ['215']}; {'id': '215', 'type': 'call', 'children': ['216', '219']}; {'id': '216', 'type': 'attribute', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'rows'}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '219', 'type': 'argument_list', 'children': ['220']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '221', 'type': 'for_statement', 'children': ['222', '223', '224']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'rows'}; {'id': '224', 'type': 'block', 'children': ['225', '229', '238']}; {'id': '225', 'type': 'expression_statement', 'children': ['226']}; {'id': '226', 'type': 'augmented_assignment', 'children': ['227', '228'], 'value': '+='}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '228', 'type': 'string', 'children': [], 'value': '"\\n\\r\\r \\\\line { \\""'}; {'id': '229', 'type': 'expression_statement', 'children': ['230']}; {'id': '230', 'type': 'augmented_assignment', 'children': ['231', '232'], 'value': '+='}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '232', 'type': 'call', 'children': ['233', '236']}; {'id': '233', 'type': 'attribute', 'children': ['234', '235']}; {'id': '234', 'type': 'string', 'children': [], 'value': '""'}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'row'}; {'id': '238', 'type': 'expression_statement', 'children': ['239']}; {'id': '239', 'type': 'augmented_assignment', 'children': ['240', '241'], 'value': '+='}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '241', 'type': 'string', 'children': [], 'value': '"\\" \\r\\r}"'}; {'id': '242', 'type': 'expression_statement', 'children': ['243']}; {'id': '243', 'type': 'augmented_assignment', 'children': ['244', '245'], 'value': '+='}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'lstring'}; {'id': '245', 'type': 'string', 'children': [], 'value': '"\\n\\r } \\n }"'}; {'id': '246', 'type': 'return_statement', 'children': ['247']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'lstring'}
simple method that puts in spaces every 10 characters
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'taskinfo'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'block', 'children': ['6', '21', '38', '46', '60', '74', '88', '104', '120', '137', '144', '150', '480']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'task_input'}; {'id': '9', 'type': 'dictionary', 'children': ['10', '13']}; {'id': '10', 'type': 'pair', 'children': ['11', '12']}; {'id': '11', 'type': 'string', 'children': [], 'value': "'taskName'"}; {'id': '12', 'type': 'string', 'children': [], 'value': "'QueryTask'"}; {'id': '13', 'type': 'pair', 'children': ['14', '15']}; {'id': '14', 'type': 'string', 'children': [], 'value': "'inputParameters'"}; {'id': '15', 'type': 'dictionary', 'children': ['16']}; {'id': '16', 'type': 'pair', 'children': ['17', '18']}; {'id': '17', 'type': 'string', 'children': [], 'value': '"Task_Name"'}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': '_name'}; {'id': '21', 'type': 'expression_statement', 'children': ['22']}; {'id': '22', 'type': 'assignment', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '24', 'type': 'call', 'children': ['25', '28']}; {'id': '25', 'type': 'attribute', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'taskengine'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'execute'}; {'id': '28', 'type': 'argument_list', 'children': ['29', '30', '33']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'task_input'}; {'id': '30', 'type': 'attribute', 'children': ['31', '32']}; {'id': '31', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': '_engine'}; {'id': '33', 'type': 'keyword_argument', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'cwd'}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '37', 'type': 'identifier', 'children': [], 'value': '_cwd'}; {'id': '38', 'type': 'expression_statement', 'children': ['39']}; {'id': '39', 'type': 'assignment', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '41', 'type': 'subscript', 'children': ['42', '45']}; {'id': '42', 'type': 'subscript', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '44', 'type': 'string', 'children': [], 'value': "'outputParameters'"}; {'id': '45', 'type': 'string', 'children': [], 'value': "'DEFINITION'"}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'assignment', 'children': ['48', '51']}; {'id': '48', 'type': 'subscript', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '50', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '51', 'type': 'call', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '53', 'type': 'argument_list', 'children': ['54']}; {'id': '54', 'type': 'call', 'children': ['55', '58']}; {'id': '55', 'type': 'attribute', 'children': ['56', '57']}; {'id': '56', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '58', 'type': 'argument_list', 'children': ['59']}; {'id': '59', 'type': 'string', 'children': [], 'value': "'NAME'"}; {'id': '60', 'type': 'expression_statement', 'children': ['61']}; {'id': '61', 'type': 'assignment', 'children': ['62', '65']}; {'id': '62', 'type': 'subscript', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '64', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '65', 'type': 'call', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '67', 'type': 'argument_list', 'children': ['68']}; {'id': '68', 'type': 'call', 'children': ['69', '72']}; {'id': '69', 'type': 'attribute', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '72', 'type': 'argument_list', 'children': ['73']}; {'id': '73', 'type': 'string', 'children': [], 'value': "'DESCRIPTION'"}; {'id': '74', 'type': 'expression_statement', 'children': ['75']}; {'id': '75', 'type': 'assignment', 'children': ['76', '79']}; {'id': '76', 'type': 'subscript', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '78', 'type': 'string', 'children': [], 'value': "'displayName'"}; {'id': '79', 'type': 'call', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '81', 'type': 'argument_list', 'children': ['82']}; {'id': '82', 'type': 'call', 'children': ['83', '86']}; {'id': '83', 'type': 'attribute', 'children': ['84', '85']}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '86', 'type': 'argument_list', 'children': ['87']}; {'id': '87', 'type': 'string', 'children': [], 'value': "'DISPLAY_NAME'"}; {'id': '88', 'type': 'if_statement', 'children': ['89', '92']}; {'id': '89', 'type': 'comparison_operator', 'children': ['90', '91'], 'value': 'in'}; {'id': '90', 'type': 'string', 'children': [], 'value': "'COMMUTE_ON_SUBSET'"}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '92', 'type': 'block', 'children': ['93']}; {'id': '93', 'type': 'expression_statement', 'children': ['94']}; {'id': '94', 'type': 'assignment', 'children': ['95', '98']}; {'id': '95', 'type': 'subscript', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '97', 'type': 'string', 'children': [], 'value': "'commute_on_subset'"}; {'id': '98', 'type': 'call', 'children': ['99', '102']}; {'id': '99', 'type': 'attribute', 'children': ['100', '101']}; {'id': '100', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '102', 'type': 'argument_list', 'children': ['103']}; {'id': '103', 'type': 'string', 'children': [], 'value': "'COMMUTE_ON_SUBSET'"}; {'id': '104', 'type': 'if_statement', 'children': ['105', '108']}; {'id': '105', 'type': 'comparison_operator', 'children': ['106', '107'], 'value': 'in'}; {'id': '106', 'type': 'string', 'children': [], 'value': "'COMMUTE_ON_DOWNSAMPLE'"}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '108', 'type': 'block', 'children': ['109']}; {'id': '109', 'type': 'expression_statement', 'children': ['110']}; {'id': '110', 'type': 'assignment', 'children': ['111', '114']}; {'id': '111', 'type': 'subscript', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '113', 'type': 'string', 'children': [], 'value': "'commute_on_downsample'"}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '118', 'type': 'argument_list', 'children': ['119']}; {'id': '119', 'type': 'string', 'children': [], 'value': "'COMMUTE_ON_DOWNSAMPLE'"}; {'id': '120', 'type': 'expression_statement', 'children': ['121']}; {'id': '121', 'type': 'assignment', 'children': ['122', '125', '126']}; {'id': '122', 'type': 'subscript', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '124', 'type': 'string', 'children': [], 'value': "'parameters'"}; {'id': '125', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '126', 'type': 'list_comprehension', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '128', 'type': 'for_in_clause', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '130', 'type': 'call', 'children': ['131', '136']}; {'id': '131', 'type': 'attribute', 'children': ['132', '135']}; {'id': '132', 'type': 'subscript', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '134', 'type': 'string', 'children': [], 'value': "'PARAMETERS'"}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '136', 'type': 'argument_list', 'children': []}; {'id': '137', 'type': 'expression_statement', 'children': ['138']}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '142', 'type': 'argument_list', 'children': ['143']}; {'id': '143', 'type': 'string', 'children': [], 'value': "'PARAMETERS'"}; {'id': '144', 'type': 'expression_statement', 'children': ['145']}; {'id': '145', 'type': 'assignment', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'parameters'}; {'id': '147', 'type': 'subscript', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'task_def'}; {'id': '149', 'type': 'string', 'children': [], 'value': "'parameters'"}; {'id': '150', 'type': 'for_statement', 'children': ['151', '152', '153']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'parameters'}; {'id': '153', 'type': 'block', 'children': ['154', '168', '182', '196', '210', '226', '242', '316', '332', '352', '384', '416', '432', '448', '464']}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'assignment', 'children': ['156', '159']}; {'id': '156', 'type': 'subscript', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '158', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '159', 'type': 'call', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'call', 'children': ['163', '166']}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '166', 'type': 'argument_list', 'children': ['167']}; {'id': '167', 'type': 'string', 'children': [], 'value': "'NAME'"}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '173']}; {'id': '170', 'type': 'subscript', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '172', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '173', 'type': 'call', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '175', 'type': 'argument_list', 'children': ['176']}; {'id': '176', 'type': 'call', 'children': ['177', '180']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '180', 'type': 'argument_list', 'children': ['181']}; {'id': '181', 'type': 'string', 'children': [], 'value': "'DESCRIPTION'"}; {'id': '182', 'type': 'expression_statement', 'children': ['183']}; {'id': '183', 'type': 'assignment', 'children': ['184', '187']}; {'id': '184', 'type': 'subscript', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '186', 'type': 'string', 'children': [], 'value': "'display_name'"}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'call', 'children': ['191', '194']}; {'id': '191', 'type': 'attribute', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '194', 'type': 'argument_list', 'children': ['195']}; {'id': '195', 'type': 'string', 'children': [], 'value': "'DISPLAY_NAME'"}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '201']}; {'id': '198', 'type': 'subscript', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '200', 'type': 'string', 'children': [], 'value': "'required'"}; {'id': '201', 'type': 'call', 'children': ['202', '203']}; {'id': '202', 'type': 'identifier', 'children': [], 'value': 'bool'}; {'id': '203', 'type': 'argument_list', 'children': ['204']}; {'id': '204', 'type': 'call', 'children': ['205', '208']}; {'id': '205', 'type': 'attribute', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'string', 'children': [], 'value': "'REQUIRED'"}; {'id': '210', 'type': 'if_statement', 'children': ['211', '214']}; {'id': '211', 'type': 'comparison_operator', 'children': ['212', '213'], 'value': 'in'}; {'id': '212', 'type': 'string', 'children': [], 'value': "'MIN'"}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '214', 'type': 'block', 'children': ['215']}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'assignment', 'children': ['217', '220']}; {'id': '217', 'type': 'subscript', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '219', 'type': 'string', 'children': [], 'value': "'min'"}; {'id': '220', 'type': 'call', 'children': ['221', '224']}; {'id': '221', 'type': 'attribute', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '224', 'type': 'argument_list', 'children': ['225']}; {'id': '225', 'type': 'string', 'children': [], 'value': "'MIN'"}; {'id': '226', 'type': 'if_statement', 'children': ['227', '230']}; {'id': '227', 'type': 'comparison_operator', 'children': ['228', '229'], 'value': 'in'}; {'id': '228', 'type': 'string', 'children': [], 'value': "'MAX'"}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '230', 'type': 'block', 'children': ['231']}; {'id': '231', 'type': 'expression_statement', 'children': ['232']}; {'id': '232', 'type': 'assignment', 'children': ['233', '236']}; {'id': '233', 'type': 'subscript', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '235', 'type': 'string', 'children': [], 'value': "'max'"}; {'id': '236', 'type': 'call', 'children': ['237', '240']}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '240', 'type': 'argument_list', 'children': ['241']}; {'id': '241', 'type': 'string', 'children': [], 'value': "'MAX'"}; {'id': '242', 'type': 'if_statement', 'children': ['243', '251', '293']}; {'id': '243', 'type': 'call', 'children': ['244', '249']}; {'id': '244', 'type': 'attribute', 'children': ['245', '248']}; {'id': '245', 'type': 'subscript', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '247', 'type': 'string', 'children': [], 'value': "'TYPE'"}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'count'}; {'id': '249', 'type': 'argument_list', 'children': ['250']}; {'id': '250', 'type': 'string', 'children': [], 'value': "'['"}; {'id': '251', 'type': 'block', 'children': ['252', '272', '282']}; {'id': '252', 'type': 'expression_statement', 'children': ['253']}; {'id': '253', 'type': 'assignment', 'children': ['254', '261']}; {'id': '254', 'type': 'pattern_list', 'children': ['255', '258']}; {'id': '255', 'type': 'subscript', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '257', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '258', 'type': 'subscript', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '260', 'type': 'string', 'children': [], 'value': "'dimensions'"}; {'id': '261', 'type': 'call', 'children': ['262', '270']}; {'id': '262', 'type': 'attribute', 'children': ['263', '269']}; {'id': '263', 'type': 'call', 'children': ['264', '267']}; {'id': '264', 'type': 'attribute', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '267', 'type': 'argument_list', 'children': ['268']}; {'id': '268', 'type': 'string', 'children': [], 'value': "'TYPE'"}; {'id': '269', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '270', 'type': 'argument_list', 'children': ['271']}; {'id': '271', 'type': 'string', 'children': [], 'value': "'['"}; {'id': '272', 'type': 'expression_statement', 'children': ['273']}; {'id': '273', 'type': 'assignment', 'children': ['274', '277']}; {'id': '274', 'type': 'subscript', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '276', 'type': 'string', 'children': [], 'value': "'dimensions'"}; {'id': '277', 'type': 'binary_operator', 'children': ['278', '279'], 'value': '+'}; {'id': '278', 'type': 'string', 'children': [], 'value': "'['"}; {'id': '279', 'type': 'subscript', 'children': ['280', '281']}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '281', 'type': 'string', 'children': [], 'value': "'dimensions'"}; {'id': '282', 'type': 'expression_statement', 'children': ['283']}; {'id': '283', 'type': 'assignment', 'children': ['284', '287']}; {'id': '284', 'type': 'subscript', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '286', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '287', 'type': 'call', 'children': ['288', '289']}; {'id': '288', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '289', 'type': 'argument_list', 'children': ['290']}; {'id': '290', 'type': 'subscript', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '292', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '293', 'type': 'else_clause', 'children': ['294']}; {'id': '294', 'type': 'block', 'children': ['295']}; {'id': '295', 'type': 'expression_statement', 'children': ['296']}; {'id': '296', 'type': 'assignment', 'children': ['297', '300']}; {'id': '297', 'type': 'subscript', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '299', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '300', 'type': 'call', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '302', 'type': 'argument_list', 'children': ['303']}; {'id': '303', 'type': 'subscript', 'children': ['304', '315']}; {'id': '304', 'type': 'call', 'children': ['305', '313']}; {'id': '305', 'type': 'attribute', 'children': ['306', '312']}; {'id': '306', 'type': 'call', 'children': ['307', '310']}; {'id': '307', 'type': 'attribute', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '310', 'type': 'argument_list', 'children': ['311']}; {'id': '311', 'type': 'string', 'children': [], 'value': "'TYPE'"}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'split'}; {'id': '313', 'type': 'argument_list', 'children': ['314']}; {'id': '314', 'type': 'string', 'children': [], 'value': "'ARRAY'"}; {'id': '315', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '316', 'type': 'if_statement', 'children': ['317', '320']}; {'id': '317', 'type': 'comparison_operator', 'children': ['318', '319'], 'value': 'in'}; {'id': '318', 'type': 'string', 'children': [], 'value': "'DIMENSIONS'"}; {'id': '319', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '320', 'type': 'block', 'children': ['321']}; {'id': '321', 'type': 'expression_statement', 'children': ['322']}; {'id': '322', 'type': 'assignment', 'children': ['323', '326']}; {'id': '323', 'type': 'subscript', 'children': ['324', '325']}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '325', 'type': 'string', 'children': [], 'value': "'dimensions'"}; {'id': '326', 'type': 'call', 'children': ['327', '330']}; {'id': '327', 'type': 'attribute', 'children': ['328', '329']}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '330', 'type': 'argument_list', 'children': ['331']}; {'id': '331', 'type': 'string', 'children': [], 'value': "'DIMENSIONS'"}; {'id': '332', 'type': 'if_statement', 'children': ['333', '336']}; {'id': '333', 'type': 'comparison_operator', 'children': ['334', '335'], 'value': 'in'}; {'id': '334', 'type': 'string', 'children': [], 'value': "'DIRECTION'"}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '336', 'type': 'block', 'children': ['337']}; {'id': '337', 'type': 'expression_statement', 'children': ['338']}; {'id': '338', 'type': 'assignment', 'children': ['339', '342']}; {'id': '339', 'type': 'subscript', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '341', 'type': 'string', 'children': [], 'value': "'direction'"}; {'id': '342', 'type': 'call', 'children': ['343', '351']}; {'id': '343', 'type': 'attribute', 'children': ['344', '350']}; {'id': '344', 'type': 'call', 'children': ['345', '348']}; {'id': '345', 'type': 'attribute', 'children': ['346', '347']}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '348', 'type': 'argument_list', 'children': ['349']}; {'id': '349', 'type': 'string', 'children': [], 'value': "'DIRECTION'"}; {'id': '350', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '351', 'type': 'argument_list', 'children': []}; {'id': '352', 'type': 'if_statement', 'children': ['353', '356']}; {'id': '353', 'type': 'comparison_operator', 'children': ['354', '355'], 'value': 'in'}; {'id': '354', 'type': 'string', 'children': [], 'value': "'DEFAULT'"}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '356', 'type': 'block', 'children': ['357']}; {'id': '357', 'type': 'if_statement', 'children': ['358', '363', '375']}; {'id': '358', 'type': 'comparison_operator', 'children': ['359', '362'], 'value': 'is'}; {'id': '359', 'type': 'subscript', 'children': ['360', '361']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '361', 'type': 'string', 'children': [], 'value': "'DEFAULT'"}; {'id': '362', 'type': 'None', 'children': []}; {'id': '363', 'type': 'block', 'children': ['364']}; {'id': '364', 'type': 'expression_statement', 'children': ['365']}; {'id': '365', 'type': 'assignment', 'children': ['366', '369']}; {'id': '366', 'type': 'subscript', 'children': ['367', '368']}; {'id': '367', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '368', 'type': 'string', 'children': [], 'value': "'default_value'"}; {'id': '369', 'type': 'call', 'children': ['370', '373']}; {'id': '370', 'type': 'attribute', 'children': ['371', '372']}; {'id': '371', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '372', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '373', 'type': 'argument_list', 'children': ['374']}; {'id': '374', 'type': 'string', 'children': [], 'value': "'DEFAULT'"}; {'id': '375', 'type': 'else_clause', 'children': ['376']}; {'id': '376', 'type': 'block', 'children': ['377']}; {'id': '377', 'type': 'expression_statement', 'children': ['378']}; {'id': '378', 'type': 'call', 'children': ['379', '382']}; {'id': '379', 'type': 'attribute', 'children': ['380', '381']}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '381', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '382', 'type': 'argument_list', 'children': ['383']}; {'id': '383', 'type': 'string', 'children': [], 'value': "'DEFAULT'"}; {'id': '384', 'type': 'if_statement', 'children': ['385', '388']}; {'id': '385', 'type': 'comparison_operator', 'children': ['386', '387'], 'value': 'in'}; {'id': '386', 'type': 'string', 'children': [], 'value': "'CHOICE_LIST'"}; {'id': '387', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '388', 'type': 'block', 'children': ['389']}; {'id': '389', 'type': 'if_statement', 'children': ['390', '395', '407']}; {'id': '390', 'type': 'comparison_operator', 'children': ['391', '394'], 'value': 'is'}; {'id': '391', 'type': 'subscript', 'children': ['392', '393']}; {'id': '392', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '393', 'type': 'string', 'children': [], 'value': "'CHOICE_LIST'"}; {'id': '394', 'type': 'None', 'children': []}; {'id': '395', 'type': 'block', 'children': ['396']}; {'id': '396', 'type': 'expression_statement', 'children': ['397']}; {'id': '397', 'type': 'assignment', 'children': ['398', '401']}; {'id': '398', 'type': 'subscript', 'children': ['399', '400']}; {'id': '399', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '400', 'type': 'string', 'children': [], 'value': "'choice_list'"}; {'id': '401', 'type': 'call', 'children': ['402', '405']}; {'id': '402', 'type': 'attribute', 'children': ['403', '404']}; {'id': '403', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '404', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '405', 'type': 'argument_list', 'children': ['406']}; {'id': '406', 'type': 'string', 'children': [], 'value': "'CHOICE_LIST'"}; {'id': '407', 'type': 'else_clause', 'children': ['408']}; {'id': '408', 'type': 'block', 'children': ['409']}; {'id': '409', 'type': 'expression_statement', 'children': ['410']}; {'id': '410', 'type': 'call', 'children': ['411', '414']}; {'id': '411', 'type': 'attribute', 'children': ['412', '413']}; {'id': '412', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '413', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '414', 'type': 'argument_list', 'children': ['415']}; {'id': '415', 'type': 'string', 'children': [], 'value': "'CHOICE_LIST'"}; {'id': '416', 'type': 'if_statement', 'children': ['417', '420']}; {'id': '417', 'type': 'comparison_operator', 'children': ['418', '419'], 'value': 'in'}; {'id': '418', 'type': 'string', 'children': [], 'value': "'FOLD_CASE'"}; {'id': '419', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '420', 'type': 'block', 'children': ['421']}; {'id': '421', 'type': 'expression_statement', 'children': ['422']}; {'id': '422', 'type': 'assignment', 'children': ['423', '426']}; {'id': '423', 'type': 'subscript', 'children': ['424', '425']}; {'id': '424', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '425', 'type': 'string', 'children': [], 'value': "'fold_case'"}; {'id': '426', 'type': 'call', 'children': ['427', '430']}; {'id': '427', 'type': 'attribute', 'children': ['428', '429']}; {'id': '428', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '429', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '430', 'type': 'argument_list', 'children': ['431']}; {'id': '431', 'type': 'string', 'children': [], 'value': "'FOLD_CASE'"}; {'id': '432', 'type': 'if_statement', 'children': ['433', '436']}; {'id': '433', 'type': 'comparison_operator', 'children': ['434', '435'], 'value': 'in'}; {'id': '434', 'type': 'string', 'children': [], 'value': "'AUTO_EXTENSION'"}; {'id': '435', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '436', 'type': 'block', 'children': ['437']}; {'id': '437', 'type': 'expression_statement', 'children': ['438']}; {'id': '438', 'type': 'assignment', 'children': ['439', '442']}; {'id': '439', 'type': 'subscript', 'children': ['440', '441']}; {'id': '440', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '441', 'type': 'string', 'children': [], 'value': "'auto_extension'"}; {'id': '442', 'type': 'call', 'children': ['443', '446']}; {'id': '443', 'type': 'attribute', 'children': ['444', '445']}; {'id': '444', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '445', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '446', 'type': 'argument_list', 'children': ['447']}; {'id': '447', 'type': 'string', 'children': [], 'value': "'AUTO_EXTENSION'"}; {'id': '448', 'type': 'if_statement', 'children': ['449', '452']}; {'id': '449', 'type': 'comparison_operator', 'children': ['450', '451'], 'value': 'in'}; {'id': '450', 'type': 'string', 'children': [], 'value': "'IS_TEMPORARY'"}; {'id': '451', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '452', 'type': 'block', 'children': ['453']}; {'id': '453', 'type': 'expression_statement', 'children': ['454']}; {'id': '454', 'type': 'assignment', 'children': ['455', '458']}; {'id': '455', 'type': 'subscript', 'children': ['456', '457']}; {'id': '456', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '457', 'type': 'string', 'children': [], 'value': "'is_temporary'"}; {'id': '458', 'type': 'call', 'children': ['459', '462']}; {'id': '459', 'type': 'attribute', 'children': ['460', '461']}; {'id': '460', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '461', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '462', 'type': 'argument_list', 'children': ['463']}; {'id': '463', 'type': 'string', 'children': [], 'value': "'IS_TEMPORARY'"}; {'id': '464', 'type': 'if_statement', 'children': ['465', '468']}; {'id': '465', 'type': 'comparison_operator', 'children': ['466', '467'], 'value': 'in'}; {'id': '466', 'type': 'string', 'children': [], 'value': "'IS_DIRECTORY'"}; {'id': '467', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '468', 'type': 'block', 'children': ['469']}; {'id': '469', 'type': 'expression_statement', 'children': ['470']}; {'id': '470', 'type': 'assignment', 'children': ['471', '474']}; {'id': '471', 'type': 'subscript', 'children': ['472', '473']}; {'id': '472', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '473', 'type': 'string', 'children': [], 'value': "'is_directory'"}; {'id': '474', 'type': 'call', 'children': ['475', '478']}; {'id': '475', 'type': 'attribute', 'children': ['476', '477']}; {'id': '476', 'type': 'identifier', 'children': [], 'value': 'parameter'}; {'id': '477', 'type': 'identifier', 'children': [], 'value': 'pop'}; {'id': '478', 'type': 'argument_list', 'children': ['479']}; {'id': '479', 'type': 'string', 'children': [], 'value': "'IS_DIRECTORY'"}; {'id': '480', 'type': 'return_statement', 'children': ['481']}; {'id': '481', 'type': 'identifier', 'children': [], 'value': 'task_def'}
Retrieve the Task Information
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'convert'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '5', 'type': 'block', 'children': ['6', '21', '152', '183', '232', '277', '296', '347', '378', '393', '405']}; {'id': '6', 'type': 'if_statement', 'children': ['7', '14']}; {'id': '7', 'type': 'call', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '9', 'type': 'argument_list', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '11', 'type': 'attribute', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'Schema'}; {'id': '14', 'type': 'block', 'children': ['15']}; {'id': '15', 'type': 'expression_statement', 'children': ['16']}; {'id': '16', 'type': 'assignment', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '18', 'type': 'attribute', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '21', 'type': 'if_statement', 'children': ['22', '27']}; {'id': '22', 'type': 'call', 'children': ['23', '24']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '24', 'type': 'argument_list', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'Mapping'}; {'id': '27', 'type': 'block', 'children': ['28', '32', '150']}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '31', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '32', 'type': 'for_statement', 'children': ['33', '36', '41']}; {'id': '33', 'type': 'pattern_list', 'children': ['34', '35']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '36', 'type': 'call', 'children': ['37', '40']}; {'id': '37', 'type': 'attribute', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '40', 'type': 'argument_list', 'children': []}; {'id': '41', 'type': 'block', 'children': ['42', '46', '73', '80', '86', '97', '143']}; {'id': '42', 'type': 'expression_statement', 'children': ['43']}; {'id': '43', 'type': 'assignment', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '45', 'type': 'None', 'children': []}; {'id': '46', 'type': 'if_statement', 'children': ['47', '54', '67']}; {'id': '47', 'type': 'call', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '49', 'type': 'argument_list', 'children': ['50', '51']}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '51', 'type': 'attribute', 'children': ['52', '53']}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'Marker'}; {'id': '54', 'type': 'block', 'children': ['55', '61']}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'assignment', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'pkey'}; {'id': '58', 'type': 'attribute', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '64', 'type': 'attribute', 'children': ['65', '66']}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '67', 'type': 'else_clause', 'children': ['68']}; {'id': '68', 'type': 'block', 'children': ['69']}; {'id': '69', 'type': 'expression_statement', 'children': ['70']}; {'id': '70', 'type': 'assignment', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'pkey'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '73', 'type': 'expression_statement', 'children': ['74']}; {'id': '74', 'type': 'assignment', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '76', 'type': 'call', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'convert'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'value'}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '85']}; {'id': '82', 'type': 'subscript', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '84', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'pkey'}; {'id': '86', 'type': 'if_statement', 'children': ['87', '90']}; {'id': '87', 'type': 'comparison_operator', 'children': ['88', '89'], 'value': 'is'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '89', 'type': 'None', 'children': []}; {'id': '90', 'type': 'block', 'children': ['91']}; {'id': '91', 'type': 'expression_statement', 'children': ['92']}; {'id': '92', 'type': 'assignment', 'children': ['93', '96']}; {'id': '93', 'type': 'subscript', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '95', 'type': 'string', 'children': [], 'value': "'description'"}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '97', 'type': 'if_statement', 'children': ['98', '109']}; {'id': '98', 'type': 'call', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '100', 'type': 'argument_list', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '102', 'type': 'tuple', 'children': ['103', '106']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'Required'}; {'id': '106', 'type': 'attribute', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'Optional'}; {'id': '109', 'type': 'block', 'children': ['110', '124']}; {'id': '110', 'type': 'expression_statement', 'children': ['111']}; {'id': '111', 'type': 'assignment', 'children': ['112', '123']}; {'id': '112', 'type': 'subscript', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '114', 'type': 'call', 'children': ['115', '122']}; {'id': '115', 'type': 'attribute', 'children': ['116', '121']}; {'id': '116', 'type': 'attribute', 'children': ['117', '120']}; {'id': '117', 'type': 'attribute', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '119', 'type': 'identifier', 'children': [], 'value': '__class__'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': '__name__'}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '122', 'type': 'argument_list', 'children': []}; {'id': '123', 'type': 'True', 'children': []}; {'id': '124', 'type': 'if_statement', 'children': ['125', '132']}; {'id': '125', 'type': 'comparison_operator', 'children': ['126', '129'], 'value': 'is'}; {'id': '126', 'type': 'attribute', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'UNDEFINED'}; {'id': '132', 'type': 'block', 'children': ['133']}; {'id': '133', 'type': 'expression_statement', 'children': ['134']}; {'id': '134', 'type': 'assignment', 'children': ['135', '138']}; {'id': '135', 'type': 'subscript', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '137', 'type': 'string', 'children': [], 'value': "'default'"}; {'id': '138', 'type': 'call', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'key'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '142', 'type': 'argument_list', 'children': []}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'call', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'pval'}; {'id': '150', 'type': 'return_statement', 'children': ['151']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '152', 'type': 'if_statement', 'children': ['153', '160']}; {'id': '153', 'type': 'call', 'children': ['154', '155']}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '155', 'type': 'argument_list', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '157', 'type': 'attribute', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'All'}; {'id': '160', 'type': 'block', 'children': ['161', '165', '181']}; {'id': '161', 'type': 'expression_statement', 'children': ['162']}; {'id': '162', 'type': 'assignment', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '164', 'type': 'dictionary', 'children': []}; {'id': '165', 'type': 'for_statement', 'children': ['166', '167', '170']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'validator'}; {'id': '167', 'type': 'attribute', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'validators'}; {'id': '170', 'type': 'block', 'children': ['171']}; {'id': '171', 'type': 'expression_statement', 'children': ['172']}; {'id': '172', 'type': 'call', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '176', 'type': 'argument_list', 'children': ['177']}; {'id': '177', 'type': 'call', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'convert'}; {'id': '179', 'type': 'argument_list', 'children': ['180']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'validator'}; {'id': '181', 'type': 'return_statement', 'children': ['182']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '183', 'type': 'if_statement', 'children': ['184', '195']}; {'id': '184', 'type': 'call', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '186', 'type': 'argument_list', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '188', 'type': 'tuple', 'children': ['189', '192']}; {'id': '189', 'type': 'attribute', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'Clamp'}; {'id': '192', 'type': 'attribute', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'Range'}; {'id': '195', 'type': 'block', 'children': ['196', '200', '215', '230']}; {'id': '196', 'type': 'expression_statement', 'children': ['197']}; {'id': '197', 'type': 'assignment', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '199', 'type': 'dictionary', 'children': []}; {'id': '200', 'type': 'if_statement', 'children': ['201', '206']}; {'id': '201', 'type': 'comparison_operator', 'children': ['202', '205'], 'value': 'is'}; {'id': '202', 'type': 'attribute', 'children': ['203', '204']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '205', 'type': 'None', 'children': []}; {'id': '206', 'type': 'block', 'children': ['207']}; {'id': '207', 'type': 'expression_statement', 'children': ['208']}; {'id': '208', 'type': 'assignment', 'children': ['209', '212']}; {'id': '209', 'type': 'subscript', 'children': ['210', '211']}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '211', 'type': 'string', 'children': [], 'value': "'valueMin'"}; {'id': '212', 'type': 'attribute', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '215', 'type': 'if_statement', 'children': ['216', '221']}; {'id': '216', 'type': 'comparison_operator', 'children': ['217', '220'], 'value': 'is'}; {'id': '217', 'type': 'attribute', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '220', 'type': 'None', 'children': []}; {'id': '221', 'type': 'block', 'children': ['222']}; {'id': '222', 'type': 'expression_statement', 'children': ['223']}; {'id': '223', 'type': 'assignment', 'children': ['224', '227']}; {'id': '224', 'type': 'subscript', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '226', 'type': 'string', 'children': [], 'value': "'valueMax'"}; {'id': '227', 'type': 'attribute', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '230', 'type': 'return_statement', 'children': ['231']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '232', 'type': 'if_statement', 'children': ['233', '240']}; {'id': '233', 'type': 'call', 'children': ['234', '235']}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '235', 'type': 'argument_list', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'Length'}; {'id': '240', 'type': 'block', 'children': ['241', '245', '260', '275']}; {'id': '241', 'type': 'expression_statement', 'children': ['242']}; {'id': '242', 'type': 'assignment', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '244', 'type': 'dictionary', 'children': []}; {'id': '245', 'type': 'if_statement', 'children': ['246', '251']}; {'id': '246', 'type': 'comparison_operator', 'children': ['247', '250'], 'value': 'is'}; {'id': '247', 'type': 'attribute', 'children': ['248', '249']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '250', 'type': 'None', 'children': []}; {'id': '251', 'type': 'block', 'children': ['252']}; {'id': '252', 'type': 'expression_statement', 'children': ['253']}; {'id': '253', 'type': 'assignment', 'children': ['254', '257']}; {'id': '254', 'type': 'subscript', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '256', 'type': 'string', 'children': [], 'value': "'lengthMin'"}; {'id': '257', 'type': 'attribute', 'children': ['258', '259']}; {'id': '258', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'min'}; {'id': '260', 'type': 'if_statement', 'children': ['261', '266']}; {'id': '261', 'type': 'comparison_operator', 'children': ['262', '265'], 'value': 'is'}; {'id': '262', 'type': 'attribute', 'children': ['263', '264']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '265', 'type': 'None', 'children': []}; {'id': '266', 'type': 'block', 'children': ['267']}; {'id': '267', 'type': 'expression_statement', 'children': ['268']}; {'id': '268', 'type': 'assignment', 'children': ['269', '272']}; {'id': '269', 'type': 'subscript', 'children': ['270', '271']}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '271', 'type': 'string', 'children': [], 'value': "'lengthMax'"}; {'id': '272', 'type': 'attribute', 'children': ['273', '274']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'max'}; {'id': '275', 'type': 'return_statement', 'children': ['276']}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'val'}; {'id': '277', 'type': 'if_statement', 'children': ['278', '285']}; {'id': '278', 'type': 'call', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '280', 'type': 'argument_list', 'children': ['281', '282']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '282', 'type': 'attribute', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'Datetime'}; {'id': '285', 'type': 'block', 'children': ['286']}; {'id': '286', 'type': 'return_statement', 'children': ['287']}; {'id': '287', 'type': 'dictionary', 'children': ['288', '291']}; {'id': '288', 'type': 'pair', 'children': ['289', '290']}; {'id': '289', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '290', 'type': 'string', 'children': [], 'value': "'datetime'"}; {'id': '291', 'type': 'pair', 'children': ['292', '293']}; {'id': '292', 'type': 'string', 'children': [], 'value': "'format'"}; {'id': '293', 'type': 'attribute', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '296', 'type': 'if_statement', 'children': ['297', '304']}; {'id': '297', 'type': 'call', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '299', 'type': 'argument_list', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '301', 'type': 'attribute', 'children': ['302', '303']}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'In'}; {'id': '304', 'type': 'block', 'children': ['305', '331']}; {'id': '305', 'type': 'if_statement', 'children': ['306', '313']}; {'id': '306', 'type': 'call', 'children': ['307', '308']}; {'id': '307', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '308', 'type': 'argument_list', 'children': ['309', '312']}; {'id': '309', 'type': 'attribute', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'container'}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'Mapping'}; {'id': '313', 'type': 'block', 'children': ['314']}; {'id': '314', 'type': 'return_statement', 'children': ['315']}; {'id': '315', 'type': 'dictionary', 'children': ['316', '319']}; {'id': '316', 'type': 'pair', 'children': ['317', '318']}; {'id': '317', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '318', 'type': 'string', 'children': [], 'value': "'select'"}; {'id': '319', 'type': 'pair', 'children': ['320', '321']}; {'id': '320', 'type': 'string', 'children': [], 'value': "'options'"}; {'id': '321', 'type': 'call', 'children': ['322', '323']}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'list'}; {'id': '323', 'type': 'argument_list', 'children': ['324']}; {'id': '324', 'type': 'call', 'children': ['325', '330']}; {'id': '325', 'type': 'attribute', 'children': ['326', '329']}; {'id': '326', 'type': 'attribute', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'container'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '330', 'type': 'argument_list', 'children': []}; {'id': '331', 'type': 'return_statement', 'children': ['332']}; {'id': '332', 'type': 'dictionary', 'children': ['333', '336']}; {'id': '333', 'type': 'pair', 'children': ['334', '335']}; {'id': '334', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '335', 'type': 'string', 'children': [], 'value': "'select'"}; {'id': '336', 'type': 'pair', 'children': ['337', '338']}; {'id': '337', 'type': 'string', 'children': [], 'value': "'options'"}; {'id': '338', 'type': 'list_comprehension', 'children': ['339', '342']}; {'id': '339', 'type': 'tuple', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '342', 'type': 'for_in_clause', 'children': ['343', '344']}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '344', 'type': 'attribute', 'children': ['345', '346']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '346', 'type': 'identifier', 'children': [], 'value': 'container'}; {'id': '347', 'type': 'if_statement', 'children': ['348', '366']}; {'id': '348', 'type': 'comparison_operator', 'children': ['349', '350'], 'value': 'in'}; {'id': '349', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '350', 'type': 'tuple', 'children': ['351', '354', '357', '360', '363']}; {'id': '351', 'type': 'attribute', 'children': ['352', '353']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'Lower'}; {'id': '354', 'type': 'attribute', 'children': ['355', '356']}; {'id': '355', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'Upper'}; {'id': '357', 'type': 'attribute', 'children': ['358', '359']}; {'id': '358', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '359', 'type': 'identifier', 'children': [], 'value': 'Capitalize'}; {'id': '360', 'type': 'attribute', 'children': ['361', '362']}; {'id': '361', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '362', 'type': 'identifier', 'children': [], 'value': 'Title'}; {'id': '363', 'type': 'attribute', 'children': ['364', '365']}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '365', 'type': 'identifier', 'children': [], 'value': 'Strip'}; {'id': '366', 'type': 'block', 'children': ['367']}; {'id': '367', 'type': 'return_statement', 'children': ['368']}; {'id': '368', 'type': 'dictionary', 'children': ['369']}; {'id': '369', 'type': 'pair', 'children': ['370', '377']}; {'id': '370', 'type': 'call', 'children': ['371', '376']}; {'id': '371', 'type': 'attribute', 'children': ['372', '375']}; {'id': '372', 'type': 'attribute', 'children': ['373', '374']}; {'id': '373', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '374', 'type': 'identifier', 'children': [], 'value': '__name__'}; {'id': '375', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '376', 'type': 'argument_list', 'children': []}; {'id': '377', 'type': 'True', 'children': []}; {'id': '378', 'type': 'if_statement', 'children': ['379', '386']}; {'id': '379', 'type': 'call', 'children': ['380', '381']}; {'id': '380', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '381', 'type': 'argument_list', 'children': ['382', '383']}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '383', 'type': 'attribute', 'children': ['384', '385']}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'vol'}; {'id': '385', 'type': 'identifier', 'children': [], 'value': 'Coerce'}; {'id': '386', 'type': 'block', 'children': ['387']}; {'id': '387', 'type': 'expression_statement', 'children': ['388']}; {'id': '388', 'type': 'assignment', 'children': ['389', '390']}; {'id': '389', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '390', 'type': 'attribute', 'children': ['391', '392']}; {'id': '391', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '392', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '393', 'type': 'if_statement', 'children': ['394', '397']}; {'id': '394', 'type': 'comparison_operator', 'children': ['395', '396'], 'value': 'in'}; {'id': '395', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '396', 'type': 'identifier', 'children': [], 'value': 'TYPES_MAP'}; {'id': '397', 'type': 'block', 'children': ['398']}; {'id': '398', 'type': 'return_statement', 'children': ['399']}; {'id': '399', 'type': 'dictionary', 'children': ['400']}; {'id': '400', 'type': 'pair', 'children': ['401', '402']}; {'id': '401', 'type': 'string', 'children': [], 'value': "'type'"}; {'id': '402', 'type': 'subscript', 'children': ['403', '404']}; {'id': '403', 'type': 'identifier', 'children': [], 'value': 'TYPES_MAP'}; {'id': '404', 'type': 'identifier', 'children': [], 'value': 'schema'}; {'id': '405', 'type': 'raise_statement', 'children': ['406']}; {'id': '406', 'type': 'call', 'children': ['407', '408']}; {'id': '407', 'type': 'identifier', 'children': [], 'value': 'ValueError'}; {'id': '408', 'type': 'argument_list', 'children': ['409']}; {'id': '409', 'type': 'call', 'children': ['410', '413']}; {'id': '410', 'type': 'attribute', 'children': ['411', '412']}; {'id': '411', 'type': 'string', 'children': [], 'value': "'Unable to convert schema: {}'"}; {'id': '412', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '413', 'type': 'argument_list', 'children': ['414']}; {'id': '414', 'type': 'identifier', 'children': [], 'value': 'schema'}
Convert a voluptuous schema to a dictionary.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '9']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': '_proxy'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '6', 'type': 'default_parameter', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'urlparams'}; {'id': '8', 'type': 'None', 'children': []}; {'id': '9', 'type': 'block', 'children': ['10', '28', '35', '39', '59', '70', '114', '123', '131', '139', '143', '180', '188', '194']}; {'id': '10', 'type': 'for_statement', 'children': ['11', '14', '21']}; {'id': '11', 'type': 'pattern_list', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '14', 'type': 'call', 'children': ['15', '20']}; {'id': '15', 'type': 'attribute', 'children': ['16', '19']}; {'id': '16', 'type': 'attribute', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'params'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'iteritems'}; {'id': '20', 'type': 'argument_list', 'children': []}; {'id': '21', 'type': 'block', 'children': ['22']}; {'id': '22', 'type': 'expression_statement', 'children': ['23']}; {'id': '23', 'type': 'assignment', 'children': ['24', '27']}; {'id': '24', 'type': 'subscript', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'urlparams'}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'k'}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'v'}; {'id': '28', 'type': 'expression_statement', 'children': ['29']}; {'id': '29', 'type': 'assignment', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '31', 'type': 'call', 'children': ['32', '33']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'urlencode'}; {'id': '33', 'type': 'argument_list', 'children': ['34']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'urlparams'}; {'id': '35', 'type': 'expression_statement', 'children': ['36']}; {'id': '36', 'type': 'assignment', 'children': ['37', '38']}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'full_url'}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '39', 'type': 'if_statement', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '41', 'type': 'block', 'children': ['42', '55']}; {'id': '42', 'type': 'if_statement', 'children': ['43', '50']}; {'id': '43', 'type': 'not_operator', 'children': ['44']}; {'id': '44', 'type': 'call', 'children': ['45', '48']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'full_url'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'endswith'}; {'id': '48', 'type': 'argument_list', 'children': ['49']}; {'id': '49', 'type': 'string', 'children': [], 'value': '"?"'}; {'id': '50', 'type': 'block', 'children': ['51']}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'augmented_assignment', 'children': ['53', '54'], 'value': '+='}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'full_url'}; {'id': '54', 'type': 'string', 'children': [], 'value': '"?"'}; {'id': '55', 'type': 'expression_statement', 'children': ['56']}; {'id': '56', 'type': 'augmented_assignment', 'children': ['57', '58'], 'value': '+='}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'full_url'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'query'}; {'id': '59', 'type': 'expression_statement', 'children': ['60']}; {'id': '60', 'type': 'assignment', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '62', 'type': 'call', 'children': ['63', '66']}; {'id': '63', 'type': 'attribute', 'children': ['64', '65']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'urllib2'}; {'id': '65', 'type': 'identifier', 'children': [], 'value': 'Request'}; {'id': '66', 'type': 'argument_list', 'children': ['67']}; {'id': '67', 'type': 'keyword_argument', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'full_url'}; {'id': '70', 'type': 'for_statement', 'children': ['71', '72', '75']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'headers'}; {'id': '75', 'type': 'block', 'children': ['76']}; {'id': '76', 'type': 'if_statement', 'children': ['77', '84', '100']}; {'id': '77', 'type': 'comparison_operator', 'children': ['78', '83'], 'value': '=='}; {'id': '78', 'type': 'call', 'children': ['79', '82']}; {'id': '79', 'type': 'attribute', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '82', 'type': 'argument_list', 'children': []}; {'id': '83', 'type': 'string', 'children': [], 'value': '"host"'}; {'id': '84', 'type': 'block', 'children': ['85']}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'call', 'children': ['87', '90']}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'add_header'}; {'id': '90', 'type': 'argument_list', 'children': ['91', '92']}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '92', 'type': 'subscript', 'children': ['93', '99']}; {'id': '93', 'type': 'call', 'children': ['94', '97']}; {'id': '94', 'type': 'attribute', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'urlparse'}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'urlparse'}; {'id': '97', 'type': 'argument_list', 'children': ['98']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'url'}; {'id': '99', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '100', 'type': 'else_clause', 'children': ['101']}; {'id': '101', 'type': 'block', 'children': ['102']}; {'id': '102', 'type': 'expression_statement', 'children': ['103']}; {'id': '103', 'type': 'call', 'children': ['104', '107']}; {'id': '104', 'type': 'attribute', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'add_header'}; {'id': '107', 'type': 'argument_list', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '109', 'type': 'subscript', 'children': ['110', '113']}; {'id': '110', 'type': 'attribute', 'children': ['111', '112']}; {'id': '111', 'type': 'identifier', 'children': [], 'value': 'request'}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'headers'}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '117', 'type': 'call', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'urllib2'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'urlopen'}; {'id': '121', 'type': 'argument_list', 'children': ['122']}; {'id': '122', 'type': 'identifier', 'children': [], 'value': 'req'}; {'id': '123', 'type': 'expression_statement', 'children': ['124']}; {'id': '124', 'type': 'assignment', 'children': ['125', '126']}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '126', 'type': 'call', 'children': ['127', '130']}; {'id': '127', 'type': 'attribute', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '130', 'type': 'argument_list', 'children': []}; {'id': '131', 'type': 'expression_statement', 'children': ['132']}; {'id': '132', 'type': 'assignment', 'children': ['133', '136']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'response'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'status'}; {'id': '136', 'type': 'attribute', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'assignment', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'got_content_length'}; {'id': '142', 'type': 'False', 'children': []}; {'id': '143', 'type': 'for_statement', 'children': ['144', '145', '146']}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '146', 'type': 'block', 'children': ['147', '157', '170']}; {'id': '147', 'type': 'if_statement', 'children': ['148', '155']}; {'id': '148', 'type': 'comparison_operator', 'children': ['149', '154'], 'value': '=='}; {'id': '149', 'type': 'call', 'children': ['150', '153']}; {'id': '150', 'type': 'attribute', 'children': ['151', '152']}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '153', 'type': 'argument_list', 'children': []}; {'id': '154', 'type': 'string', 'children': [], 'value': '"transfer-encoding"'}; {'id': '155', 'type': 'block', 'children': ['156']}; {'id': '156', 'type': 'continue_statement', 'children': []}; {'id': '157', 'type': 'if_statement', 'children': ['158', '165']}; {'id': '158', 'type': 'comparison_operator', 'children': ['159', '164'], 'value': '=='}; {'id': '159', 'type': 'call', 'children': ['160', '163']}; {'id': '160', 'type': 'attribute', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '162', 'type': 'identifier', 'children': [], 'value': 'lower'}; {'id': '163', 'type': 'argument_list', 'children': []}; {'id': '164', 'type': 'string', 'children': [], 'value': '"content-length"'}; {'id': '165', 'type': 'block', 'children': ['166']}; {'id': '166', 'type': 'expression_statement', 'children': ['167']}; {'id': '167', 'type': 'assignment', 'children': ['168', '169']}; {'id': '168', 'type': 'identifier', 'children': [], 'value': 'got_content_length'}; {'id': '169', 'type': 'True', 'children': []}; {'id': '170', 'type': 'expression_statement', 'children': ['171']}; {'id': '171', 'type': 'assignment', 'children': ['172', '177']}; {'id': '172', 'type': 'subscript', 'children': ['173', '176']}; {'id': '173', 'type': 'attribute', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'response'}; {'id': '175', 'type': 'identifier', 'children': [], 'value': 'headers'}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '177', 'type': 'subscript', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'header'}; {'id': '180', 'type': 'expression_statement', 'children': ['181']}; {'id': '181', 'type': 'assignment', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'result'}; {'id': '183', 'type': 'call', 'children': ['184', '187']}; {'id': '184', 'type': 'attribute', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'read'}; {'id': '187', 'type': 'argument_list', 'children': []}; {'id': '188', 'type': 'expression_statement', 'children': ['189']}; {'id': '189', 'type': 'call', 'children': ['190', '193']}; {'id': '190', 'type': 'attribute', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'res'}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'close'}; {'id': '193', 'type': 'argument_list', 'children': []}; {'id': '194', 'type': 'return_statement', 'children': ['195']}; {'id': '195', 'type': 'identifier', 'children': [], 'value': 'result'}
Do the actual action of proxying the call.
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '16']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'apply'}; {'id': '3', 'type': 'parameters', 'children': ['4', '7', '10', '13']}; {'id': '4', 'type': 'default_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'config_override'}; {'id': '6', 'type': 'None', 'children': []}; {'id': '7', 'type': 'default_parameter', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'tag_override'}; {'id': '9', 'type': 'None', 'children': []}; {'id': '10', 'type': 'default_parameter', 'children': ['11', '12']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'rollback'}; {'id': '12', 'type': 'None', 'children': []}; {'id': '13', 'type': 'default_parameter', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'skip_missing'}; {'id': '15', 'type': 'None', 'children': []}; {'id': '16', 'type': 'block', 'children': ['17', '24', '30', '41', '252']}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '20', 'type': 'call', 'children': ['21', '22']}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'get_config'}; {'id': '22', 'type': 'argument_list', 'children': ['23']}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'config_override'}; {'id': '24', 'type': 'expression_statement', 'children': ['25']}; {'id': '25', 'type': 'assignment', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '27', 'type': 'subscript', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'config'}; {'id': '29', 'type': 'string', 'children': [], 'value': "'databases'"}; {'id': '30', 'type': 'if_statement', 'children': ['31', '35']}; {'id': '31', 'type': 'boolean_operator', 'children': ['32', '33'], 'value': 'and'}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'rollback'}; {'id': '33', 'type': 'not_operator', 'children': ['34']}; {'id': '34', 'type': 'identifier', 'children': [], 'value': 'tag_override'}; {'id': '35', 'type': 'block', 'children': ['36']}; {'id': '36', 'type': 'raise_statement', 'children': ['37']}; {'id': '37', 'type': 'call', 'children': ['38', '39']}; {'id': '38', 'type': 'identifier', 'children': [], 'value': 'RuntimeError'}; {'id': '39', 'type': 'argument_list', 'children': ['40']}; {'id': '40', 'type': 'string', 'children': [], 'value': "'To rollback a migration you need to specify the database tag with `--tag`'"}; {'id': '41', 'type': 'for_statement', 'children': ['42', '43', '47']}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '43', 'type': 'call', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '45', 'type': 'argument_list', 'children': ['46']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '47', 'type': 'block', 'children': ['48', '56', '68', '80', '92', '100', '108', '116', '127', '139', '151', '174', '192', '202', '242']}; {'id': '48', 'type': 'if_statement', 'children': ['49', '54']}; {'id': '49', 'type': 'boolean_operator', 'children': ['50', '51'], 'value': 'and'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'tag_override'}; {'id': '51', 'type': 'comparison_operator', 'children': ['52', '53'], 'value': '!='}; {'id': '52', 'type': 'identifier', 'children': [], 'value': 'tag_override'}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '54', 'type': 'block', 'children': ['55']}; {'id': '55', 'type': 'continue_statement', 'children': []}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '59']}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '59', 'type': 'call', 'children': ['60', '65']}; {'id': '60', 'type': 'attribute', 'children': ['61', '64']}; {'id': '61', 'type': 'subscript', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '65', 'type': 'argument_list', 'children': ['66', '67']}; {'id': '66', 'type': 'string', 'children': [], 'value': "'engine'"}; {'id': '67', 'type': 'string', 'children': [], 'value': "'mysql'"}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'assignment', 'children': ['70', '71']}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'host'}; {'id': '71', 'type': 'call', 'children': ['72', '77']}; {'id': '72', 'type': 'attribute', 'children': ['73', '76']}; {'id': '73', 'type': 'subscript', 'children': ['74', '75']}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '77', 'type': 'argument_list', 'children': ['78', '79']}; {'id': '78', 'type': 'string', 'children': [], 'value': "'host'"}; {'id': '79', 'type': 'string', 'children': [], 'value': "'localhost'"}; {'id': '80', 'type': 'expression_statement', 'children': ['81']}; {'id': '81', 'type': 'assignment', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'port'}; {'id': '83', 'type': 'call', 'children': ['84', '89']}; {'id': '84', 'type': 'attribute', 'children': ['85', '88']}; {'id': '85', 'type': 'subscript', 'children': ['86', '87']}; {'id': '86', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '89', 'type': 'argument_list', 'children': ['90', '91']}; {'id': '90', 'type': 'string', 'children': [], 'value': "'port'"}; {'id': '91', 'type': 'integer', 'children': [], 'value': '3306'}; {'id': '92', 'type': 'expression_statement', 'children': ['93']}; {'id': '93', 'type': 'assignment', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '95', 'type': 'subscript', 'children': ['96', '99']}; {'id': '96', 'type': 'subscript', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '99', 'type': 'string', 'children': [], 'value': "'user'"}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'assignment', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'password'}; {'id': '103', 'type': 'subscript', 'children': ['104', '107']}; {'id': '104', 'type': 'subscript', 'children': ['105', '106']}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '107', 'type': 'string', 'children': [], 'value': "'password'"}; {'id': '108', 'type': 'expression_statement', 'children': ['109']}; {'id': '109', 'type': 'assignment', 'children': ['110', '111']}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '111', 'type': 'subscript', 'children': ['112', '115']}; {'id': '112', 'type': 'subscript', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '115', 'type': 'string', 'children': [], 'value': "'db'"}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'assignment', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '119', 'type': 'call', 'children': ['120', '121']}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'add_slash'}; {'id': '121', 'type': 'argument_list', 'children': ['122']}; {'id': '122', 'type': 'subscript', 'children': ['123', '126']}; {'id': '123', 'type': 'subscript', 'children': ['124', '125']}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '125', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '126', 'type': 'string', 'children': [], 'value': "'path'"}; {'id': '127', 'type': 'expression_statement', 'children': ['128']}; {'id': '128', 'type': 'assignment', 'children': ['129', '130']}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'pre_migration'}; {'id': '130', 'type': 'call', 'children': ['131', '136']}; {'id': '131', 'type': 'attribute', 'children': ['132', '135']}; {'id': '132', 'type': 'subscript', 'children': ['133', '134']}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '136', 'type': 'argument_list', 'children': ['137', '138']}; {'id': '137', 'type': 'string', 'children': [], 'value': "'pre_migration'"}; {'id': '138', 'type': 'None', 'children': []}; {'id': '139', 'type': 'expression_statement', 'children': ['140']}; {'id': '140', 'type': 'assignment', 'children': ['141', '142']}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'post_migration'}; {'id': '142', 'type': 'call', 'children': ['143', '148']}; {'id': '143', 'type': 'attribute', 'children': ['144', '147']}; {'id': '144', 'type': 'subscript', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '148', 'type': 'argument_list', 'children': ['149', '150']}; {'id': '149', 'type': 'string', 'children': [], 'value': "'post_migration'"}; {'id': '150', 'type': 'None', 'children': []}; {'id': '151', 'type': 'if_statement', 'children': ['152', '153', '166']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'skip_missing'}; {'id': '153', 'type': 'block', 'children': ['154']}; {'id': '154', 'type': 'try_statement', 'children': ['155', '162']}; {'id': '155', 'type': 'block', 'children': ['156']}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'call', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'check_exists'}; {'id': '159', 'type': 'argument_list', 'children': ['160', '161']}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '161', 'type': 'string', 'children': [], 'value': "'dir'"}; {'id': '162', 'type': 'except_clause', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'RuntimeError'}; {'id': '164', 'type': 'block', 'children': ['165']}; {'id': '165', 'type': 'continue_statement', 'children': []}; {'id': '166', 'type': 'else_clause', 'children': ['167']}; {'id': '167', 'type': 'block', 'children': ['168']}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'call', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'check_exists'}; {'id': '171', 'type': 'argument_list', 'children': ['172', '173']}; {'id': '172', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '173', 'type': 'string', 'children': [], 'value': "'dir'"}; {'id': '174', 'type': 'expression_statement', 'children': ['175']}; {'id': '175', 'type': 'assignment', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'connection'}; {'id': '177', 'type': 'call', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'get_connection'}; {'id': '179', 'type': 'argument_list', 'children': ['180', '181', '182', '183', '184', '185', '186']}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '181', 'type': 'identifier', 'children': [], 'value': 'host'}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'port'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'password'}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '186', 'type': 'call', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'get_ssl'}; {'id': '188', 'type': 'argument_list', 'children': ['189']}; {'id': '189', 'type': 'subscript', 'children': ['190', '191']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'databases'}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '192', 'type': 'if_statement', 'children': ['193', '194']}; {'id': '193', 'type': 'identifier', 'children': [], 'value': 'pre_migration'}; {'id': '194', 'type': 'block', 'children': ['195']}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'call', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'run_migration'}; {'id': '198', 'type': 'argument_list', 'children': ['199', '200', '201']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'connection'}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'pre_migration'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '202', 'type': 'if_statement', 'children': ['203', '204', '223']}; {'id': '203', 'type': 'identifier', 'children': [], 'value': 'rollback'}; {'id': '204', 'type': 'block', 'children': ['205', '215']}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'call', 'children': ['207', '208']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '208', 'type': 'argument_list', 'children': ['209']}; {'id': '209', 'type': 'binary_operator', 'children': ['210', '211'], 'value': '%'}; {'id': '210', 'type': 'string', 'children': [], 'value': "' * Rolling back %s (`%s` on %s)'"}; {'id': '211', 'type': 'tuple', 'children': ['212', '213', '214']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '215', 'type': 'expression_statement', 'children': ['216']}; {'id': '216', 'type': 'call', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'rollback_migration'}; {'id': '218', 'type': 'argument_list', 'children': ['219', '220', '221', '222']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'connection'}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'rollback'}; {'id': '223', 'type': 'else_clause', 'children': ['224']}; {'id': '224', 'type': 'block', 'children': ['225', '235']}; {'id': '225', 'type': 'expression_statement', 'children': ['226']}; {'id': '226', 'type': 'call', 'children': ['227', '228']}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '228', 'type': 'argument_list', 'children': ['229']}; {'id': '229', 'type': 'binary_operator', 'children': ['230', '231'], 'value': '%'}; {'id': '230', 'type': 'string', 'children': [], 'value': "' * Applying migrations for %s (`%s` on %s)'"}; {'id': '231', 'type': 'tuple', 'children': ['232', '233', '234']}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'tag'}; {'id': '233', 'type': 'identifier', 'children': [], 'value': 'db'}; {'id': '234', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '235', 'type': 'expression_statement', 'children': ['236']}; {'id': '236', 'type': 'call', 'children': ['237', '238']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'apply_migrations'}; {'id': '238', 'type': 'argument_list', 'children': ['239', '240', '241']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'connection'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '242', 'type': 'if_statement', 'children': ['243', '244']}; {'id': '243', 'type': 'identifier', 'children': [], 'value': 'post_migration'}; {'id': '244', 'type': 'block', 'children': ['245']}; {'id': '245', 'type': 'expression_statement', 'children': ['246']}; {'id': '246', 'type': 'call', 'children': ['247', '248']}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'run_migration'}; {'id': '248', 'type': 'argument_list', 'children': ['249', '250', '251']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'connection'}; {'id': '250', 'type': 'identifier', 'children': [], 'value': 'post_migration'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'engine'}; {'id': '252', 'type': 'return_statement', 'children': ['253']}; {'id': '253', 'type': 'True', 'children': []}
Look thru migrations and apply them
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '5']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'processFiles'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '5', 'type': 'block', 'children': ['6', '10', '346']}; {'id': '6', 'type': 'expression_statement', 'children': ['7']}; {'id': '7', 'type': 'assignment', 'children': ['8', '9']}; {'id': '8', 'type': 'identifier', 'children': [], 'value': 'to_process'}; {'id': '9', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '10', 'type': 'for_statement', 'children': ['11', '12', '15']}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '12', 'type': 'subscript', 'children': ['13', '14']}; {'id': '13', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '14', 'type': 'string', 'children': [], 'value': "'filenames'"}; {'id': '15', 'type': 'block', 'children': ['16', '22', '56', '65', '90', '109', '128', '141', '147', '203', '222', '228', '333', '339']}; {'id': '16', 'type': 'expression_statement', 'children': ['17']}; {'id': '17', 'type': 'assignment', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '19', 'type': 'call', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'dict'}; {'id': '21', 'type': 'argument_list', 'children': []}; {'id': '22', 'type': 'if_statement', 'children': ['23', '26', '48']}; {'id': '23', 'type': 'subscript', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '25', 'type': 'string', 'children': [], 'value': "'include'"}; {'id': '26', 'type': 'block', 'children': ['27']}; {'id': '27', 'type': 'expression_statement', 'children': ['28']}; {'id': '28', 'type': 'assignment', 'children': ['29', '32']}; {'id': '29', 'type': 'subscript', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '31', 'type': 'string', 'children': [], 'value': "'include'"}; {'id': '32', 'type': 'binary_operator', 'children': ['33', '34'], 'value': '+'}; {'id': '33', 'type': 'identifier', 'children': [], 'value': 'INCLUDE_STRING'}; {'id': '34', 'type': 'call', 'children': ['35', '38']}; {'id': '35', 'type': 'attribute', 'children': ['36', '37']}; {'id': '36', 'type': 'string', 'children': [], 'value': "''"}; {'id': '37', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '38', 'type': 'argument_list', 'children': ['39']}; {'id': '39', 'type': 'list_comprehension', 'children': ['40', '43']}; {'id': '40', 'type': 'binary_operator', 'children': ['41', '42'], 'value': '+'}; {'id': '41', 'type': 'string', 'children': [], 'value': "'-I'"}; {'id': '42', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '43', 'type': 'for_in_clause', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'item'}; {'id': '45', 'type': 'subscript', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '47', 'type': 'string', 'children': [], 'value': "'include'"}; {'id': '48', 'type': 'else_clause', 'children': ['49']}; {'id': '49', 'type': 'block', 'children': ['50']}; {'id': '50', 'type': 'expression_statement', 'children': ['51']}; {'id': '51', 'type': 'assignment', 'children': ['52', '55']}; {'id': '52', 'type': 'subscript', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '54', 'type': 'string', 'children': [], 'value': "'include'"}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'INCLUDE_STRING'}; {'id': '56', 'type': 'expression_statement', 'children': ['57']}; {'id': '57', 'type': 'assignment', 'children': ['58', '61']}; {'id': '58', 'type': 'subscript', 'children': ['59', '60']}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '60', 'type': 'string', 'children': [], 'value': "'file_path'"}; {'id': '61', 'type': 'call', 'children': ['62', '63']}; {'id': '62', 'type': 'identifier', 'children': [], 'value': 'getPath'}; {'id': '63', 'type': 'argument_list', 'children': ['64']}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'filename'}; {'id': '65', 'type': 'expression_statement', 'children': ['66']}; {'id': '66', 'type': 'assignment', 'children': ['67', '70', '71']}; {'id': '67', 'type': 'subscript', 'children': ['68', '69']}; {'id': '68', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '69', 'type': 'string', 'children': [], 'value': "'file_base_name'"}; {'id': '70', 'type': 'line_continuation', 'children': [], 'value': '\\'}; {'id': '71', 'type': 'subscript', 'children': ['72', '89']}; {'id': '72', 'type': 'call', 'children': ['73', '78']}; {'id': '73', 'type': 'attribute', 'children': ['74', '77']}; {'id': '74', 'type': 'attribute', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'splitext'}; {'id': '78', 'type': 'argument_list', 'children': ['79']}; {'id': '79', 'type': 'call', 'children': ['80', '85']}; {'id': '80', 'type': 'attribute', 'children': ['81', '84']}; {'id': '81', 'type': 'attribute', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'basename'}; {'id': '85', 'type': 'argument_list', 'children': ['86']}; {'id': '86', 'type': 'subscript', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '88', 'type': 'string', 'children': [], 'value': "'file_path'"}; {'id': '89', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '90', 'type': 'expression_statement', 'children': ['91']}; {'id': '91', 'type': 'assignment', 'children': ['92', '99']}; {'id': '92', 'type': 'pattern_list', 'children': ['93', '96']}; {'id': '93', 'type': 'subscript', 'children': ['94', '95']}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '95', 'type': 'string', 'children': [], 'value': "'no_extension'"}; {'id': '96', 'type': 'subscript', 'children': ['97', '98']}; {'id': '97', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '98', 'type': 'string', 'children': [], 'value': "'extension'"}; {'id': '99', 'type': 'call', 'children': ['100', '105']}; {'id': '100', 'type': 'attribute', 'children': ['101', '104']}; {'id': '101', 'type': 'attribute', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'splitext'}; {'id': '105', 'type': 'argument_list', 'children': ['106']}; {'id': '106', 'type': 'subscript', 'children': ['107', '108']}; {'id': '107', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '108', 'type': 'string', 'children': [], 'value': "'file_path'"}; {'id': '109', 'type': 'if_statement', 'children': ['110', '115']}; {'id': '110', 'type': 'comparison_operator', 'children': ['111', '114'], 'value': 'not'}; {'id': '111', 'type': 'subscript', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '113', 'type': 'string', 'children': [], 'value': "'extension'"}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'CYTHONIZABLE_FILE_EXTS'}; {'id': '115', 'type': 'block', 'children': ['116']}; {'id': '116', 'type': 'raise_statement', 'children': ['117']}; {'id': '117', 'type': 'call', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'CytherError'}; {'id': '119', 'type': 'argument_list', 'children': ['120']}; {'id': '120', 'type': 'call', 'children': ['121', '124']}; {'id': '121', 'type': 'attribute', 'children': ['122', '123']}; {'id': '122', 'type': 'string', 'children': [], 'value': '"The file \'{}\' is not a designated cython file"'}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '124', 'type': 'argument_list', 'children': ['125']}; {'id': '125', 'type': 'subscript', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '127', 'type': 'string', 'children': [], 'value': "'file_path'"}; {'id': '128', 'type': 'expression_statement', 'children': ['129']}; {'id': '129', 'type': 'assignment', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'base_path'}; {'id': '131', 'type': 'call', 'children': ['132', '137']}; {'id': '132', 'type': 'attribute', 'children': ['133', '136']}; {'id': '133', 'type': 'attribute', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '135', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '137', 'type': 'argument_list', 'children': ['138']}; {'id': '138', 'type': 'subscript', 'children': ['139', '140']}; {'id': '139', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '140', 'type': 'string', 'children': [], 'value': "'file_path'"}; {'id': '141', 'type': 'expression_statement', 'children': ['142']}; {'id': '142', 'type': 'assignment', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'local_build'}; {'id': '144', 'type': 'subscript', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '146', 'type': 'string', 'children': [], 'value': "'local'"}; {'id': '147', 'type': 'if_statement', 'children': ['148', '150', '191']}; {'id': '148', 'type': 'not_operator', 'children': ['149']}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'local_build'}; {'id': '150', 'type': 'block', 'children': ['151', '163', '173']}; {'id': '151', 'type': 'expression_statement', 'children': ['152']}; {'id': '152', 'type': 'assignment', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'cache_name'}; {'id': '154', 'type': 'call', 'children': ['155', '160']}; {'id': '155', 'type': 'attribute', 'children': ['156', '159']}; {'id': '156', 'type': 'attribute', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '160', 'type': 'argument_list', 'children': ['161', '162']}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'base_path'}; {'id': '162', 'type': 'string', 'children': [], 'value': "'__cythercache__'"}; {'id': '163', 'type': 'expression_statement', 'children': ['164']}; {'id': '164', 'type': 'call', 'children': ['165', '168']}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'makedirs'}; {'id': '168', 'type': 'argument_list', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'cache_name'}; {'id': '170', 'type': 'keyword_argument', 'children': ['171', '172']}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'exist_ok'}; {'id': '172', 'type': 'True', 'children': []}; {'id': '173', 'type': 'expression_statement', 'children': ['174']}; {'id': '174', 'type': 'assignment', 'children': ['175', '178']}; {'id': '175', 'type': 'subscript', 'children': ['176', '177']}; {'id': '176', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '177', 'type': 'string', 'children': [], 'value': "'c_name'"}; {'id': '178', 'type': 'binary_operator', 'children': ['179', '190'], 'value': '+'}; {'id': '179', 'type': 'call', 'children': ['180', '185']}; {'id': '180', 'type': 'attribute', 'children': ['181', '184']}; {'id': '181', 'type': 'attribute', 'children': ['182', '183']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'join'}; {'id': '185', 'type': 'argument_list', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'cache_name'}; {'id': '187', 'type': 'subscript', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '189', 'type': 'string', 'children': [], 'value': "'file_base_name'"}; {'id': '190', 'type': 'string', 'children': [], 'value': "'.c'"}; {'id': '191', 'type': 'else_clause', 'children': ['192']}; {'id': '192', 'type': 'block', 'children': ['193']}; {'id': '193', 'type': 'expression_statement', 'children': ['194']}; {'id': '194', 'type': 'assignment', 'children': ['195', '198']}; {'id': '195', 'type': 'subscript', 'children': ['196', '197']}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '197', 'type': 'string', 'children': [], 'value': "'c_name'"}; {'id': '198', 'type': 'binary_operator', 'children': ['199', '202'], 'value': '+'}; {'id': '199', 'type': 'subscript', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '201', 'type': 'string', 'children': [], 'value': "'no_extension'"}; {'id': '202', 'type': 'string', 'children': [], 'value': "'.c'"}; {'id': '203', 'type': 'expression_statement', 'children': ['204']}; {'id': '204', 'type': 'assignment', 'children': ['205', '208']}; {'id': '205', 'type': 'subscript', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '207', 'type': 'string', 'children': [], 'value': "'object_file_name'"}; {'id': '208', 'type': 'binary_operator', 'children': ['209', '221'], 'value': '+'}; {'id': '209', 'type': 'subscript', 'children': ['210', '220']}; {'id': '210', 'type': 'call', 'children': ['211', '216']}; {'id': '211', 'type': 'attribute', 'children': ['212', '215']}; {'id': '212', 'type': 'attribute', 'children': ['213', '214']}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'splitext'}; {'id': '216', 'type': 'argument_list', 'children': ['217']}; {'id': '217', 'type': 'subscript', 'children': ['218', '219']}; {'id': '218', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '219', 'type': 'string', 'children': [], 'value': "'c_name'"}; {'id': '220', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '221', 'type': 'string', 'children': [], 'value': "'.o'"}; {'id': '222', 'type': 'expression_statement', 'children': ['223']}; {'id': '223', 'type': 'assignment', 'children': ['224', '225']}; {'id': '224', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '225', 'type': 'subscript', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '227', 'type': 'string', 'children': [], 'value': "'output_name'"}; {'id': '228', 'type': 'if_statement', 'children': ['229', '232', '243', '321']}; {'id': '229', 'type': 'subscript', 'children': ['230', '231']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '231', 'type': 'string', 'children': [], 'value': "'watch'"}; {'id': '232', 'type': 'block', 'children': ['233']}; {'id': '233', 'type': 'expression_statement', 'children': ['234']}; {'id': '234', 'type': 'assignment', 'children': ['235', '238']}; {'id': '235', 'type': 'subscript', 'children': ['236', '237']}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '237', 'type': 'string', 'children': [], 'value': "'output_name'"}; {'id': '238', 'type': 'binary_operator', 'children': ['239', '242'], 'value': '+'}; {'id': '239', 'type': 'subscript', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '241', 'type': 'string', 'children': [], 'value': "'no_extension'"}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'DEFAULT_OUTPUT_EXTENSION'}; {'id': '243', 'type': 'elif_clause', 'children': ['244', '245']}; {'id': '244', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '245', 'type': 'block', 'children': ['246']}; {'id': '246', 'type': 'if_statement', 'children': ['247', '264', '271']}; {'id': '247', 'type': 'boolean_operator', 'children': ['248', '256'], 'value': 'and'}; {'id': '248', 'type': 'call', 'children': ['249', '254']}; {'id': '249', 'type': 'attribute', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'exists'}; {'id': '254', 'type': 'argument_list', 'children': ['255']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '256', 'type': 'call', 'children': ['257', '262']}; {'id': '257', 'type': 'attribute', 'children': ['258', '261']}; {'id': '258', 'type': 'attribute', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'isfile'}; {'id': '262', 'type': 'argument_list', 'children': ['263']}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '264', 'type': 'block', 'children': ['265']}; {'id': '265', 'type': 'expression_statement', 'children': ['266']}; {'id': '266', 'type': 'assignment', 'children': ['267', '270']}; {'id': '267', 'type': 'subscript', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '269', 'type': 'string', 'children': [], 'value': "'output_name'"}; {'id': '270', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '271', 'type': 'else_clause', 'children': ['272']}; {'id': '272', 'type': 'block', 'children': ['273', '284', '296']}; {'id': '273', 'type': 'expression_statement', 'children': ['274']}; {'id': '274', 'type': 'assignment', 'children': ['275', '276']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '276', 'type': 'call', 'children': ['277', '282']}; {'id': '277', 'type': 'attribute', 'children': ['278', '281']}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '282', 'type': 'argument_list', 'children': ['283']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '284', 'type': 'if_statement', 'children': ['285', '287']}; {'id': '285', 'type': 'not_operator', 'children': ['286']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '287', 'type': 'block', 'children': ['288']}; {'id': '288', 'type': 'expression_statement', 'children': ['289']}; {'id': '289', 'type': 'assignment', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '291', 'type': 'call', 'children': ['292', '295']}; {'id': '292', 'type': 'attribute', 'children': ['293', '294']}; {'id': '293', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'getcwd'}; {'id': '295', 'type': 'argument_list', 'children': []}; {'id': '296', 'type': 'if_statement', 'children': ['297', '305', '312']}; {'id': '297', 'type': 'call', 'children': ['298', '303']}; {'id': '298', 'type': 'attribute', 'children': ['299', '302']}; {'id': '299', 'type': 'attribute', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'exists'}; {'id': '303', 'type': 'argument_list', 'children': ['304']}; {'id': '304', 'type': 'identifier', 'children': [], 'value': 'dirname'}; {'id': '305', 'type': 'block', 'children': ['306']}; {'id': '306', 'type': 'expression_statement', 'children': ['307']}; {'id': '307', 'type': 'assignment', 'children': ['308', '311']}; {'id': '308', 'type': 'subscript', 'children': ['309', '310']}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '310', 'type': 'string', 'children': [], 'value': "'output_name'"}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'output_name'}; {'id': '312', 'type': 'else_clause', 'children': ['313']}; {'id': '313', 'type': 'block', 'children': ['314']}; {'id': '314', 'type': 'raise_statement', 'children': ['315']}; {'id': '315', 'type': 'call', 'children': ['316', '317']}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'CytherError'}; {'id': '317', 'type': 'argument_list', 'children': ['318']}; {'id': '318', 'type': 'concatenated_string', 'children': ['319', '320']}; {'id': '319', 'type': 'string', 'children': [], 'value': "'The directory specified to write'"}; {'id': '320', 'type': 'string', 'children': [], 'value': "'the output file in does not exist'"}; {'id': '321', 'type': 'else_clause', 'children': ['322']}; {'id': '322', 'type': 'block', 'children': ['323']}; {'id': '323', 'type': 'expression_statement', 'children': ['324']}; {'id': '324', 'type': 'assignment', 'children': ['325', '328']}; {'id': '325', 'type': 'subscript', 'children': ['326', '327']}; {'id': '326', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '327', 'type': 'string', 'children': [], 'value': "'output_name'"}; {'id': '328', 'type': 'binary_operator', 'children': ['329', '332'], 'value': '+'}; {'id': '329', 'type': 'subscript', 'children': ['330', '331']}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '331', 'type': 'string', 'children': [], 'value': "'no_extension'"}; {'id': '332', 'type': 'identifier', 'children': [], 'value': 'DEFAULT_OUTPUT_EXTENSION'}; {'id': '333', 'type': 'expression_statement', 'children': ['334']}; {'id': '334', 'type': 'assignment', 'children': ['335', '338']}; {'id': '335', 'type': 'subscript', 'children': ['336', '337']}; {'id': '336', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '337', 'type': 'string', 'children': [], 'value': "'stamp_if_error'"}; {'id': '338', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '339', 'type': 'expression_statement', 'children': ['340']}; {'id': '340', 'type': 'call', 'children': ['341', '344']}; {'id': '341', 'type': 'attribute', 'children': ['342', '343']}; {'id': '342', 'type': 'identifier', 'children': [], 'value': 'to_process'}; {'id': '343', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '344', 'type': 'argument_list', 'children': ['345']}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '346', 'type': 'return_statement', 'children': ['347']}; {'id': '347', 'type': 'identifier', 'children': [], 'value': 'to_process'}
Generates and error checks each file's information before the compilation actually starts
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '4']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'main'}; {'id': '3', 'type': 'parameters', 'children': []}; {'id': '4', 'type': 'block', 'children': ['5', '19', '32', '46', '68', '95', '123', '145', '168', '176', '217', '233', '257', '270', '281', '303']}; {'id': '5', 'type': 'expression_statement', 'children': ['6']}; {'id': '6', 'type': 'assignment', 'children': ['7', '8']}; {'id': '7', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '8', 'type': 'call', 'children': ['9', '12']}; {'id': '9', 'type': 'attribute', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'argparse'}; {'id': '11', 'type': 'identifier', 'children': [], 'value': 'ArgumentParser'}; {'id': '12', 'type': 'argument_list', 'children': ['13', '16']}; {'id': '13', 'type': 'keyword_argument', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'description'}; {'id': '15', 'type': 'string', 'children': [], 'value': "'DistanceClassifier for classification based on distance measure in feature space.'"}; {'id': '16', 'type': 'keyword_argument', 'children': ['17', '18']}; {'id': '17', 'type': 'identifier', 'children': [], 'value': 'add_help'}; {'id': '18', 'type': 'False', 'children': []}; {'id': '19', 'type': 'expression_statement', 'children': ['20']}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '24', 'type': 'argument_list', 'children': ['25', '26', '29']}; {'id': '25', 'type': 'string', 'children': [], 'value': "'INPUT_FILE'"}; {'id': '26', 'type': 'keyword_argument', 'children': ['27', '28']}; {'id': '27', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '29', 'type': 'keyword_argument', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '31', 'type': 'string', 'children': [], 'value': '\'Data file to perform DistanceClassifier on; ensure that the class label column is labeled as "class".\''}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '37', 'type': 'argument_list', 'children': ['38', '39', '40', '43']}; {'id': '38', 'type': 'string', 'children': [], 'value': "'-h'"}; {'id': '39', 'type': 'string', 'children': [], 'value': "'--help'"}; {'id': '40', 'type': 'keyword_argument', 'children': ['41', '42']}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '42', 'type': 'string', 'children': [], 'value': "'help'"}; {'id': '43', 'type': 'keyword_argument', 'children': ['44', '45']}; {'id': '44', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '45', 'type': 'string', 'children': [], 'value': "'Show this help message and exit.'"}; {'id': '46', 'type': 'expression_statement', 'children': ['47']}; {'id': '47', 'type': 'call', 'children': ['48', '51']}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '51', 'type': 'argument_list', 'children': ['52', '53', '56', '59', '62', '65']}; {'id': '52', 'type': 'string', 'children': [], 'value': "'-is'"}; {'id': '53', 'type': 'keyword_argument', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '55', 'type': 'string', 'children': [], 'value': "'store'"}; {'id': '56', 'type': 'keyword_argument', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '58', 'type': 'string', 'children': [], 'value': "'INPUT_SEPARATOR'"}; {'id': '59', 'type': 'keyword_argument', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '61', 'type': 'string', 'children': [], 'value': "'\\t'"}; {'id': '62', 'type': 'keyword_argument', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '64', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '65', 'type': 'keyword_argument', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '67', 'type': 'string', 'children': [], 'value': "'Character used to separate columns in the input file.'"}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'call', 'children': ['70', '73']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '73', 'type': 'argument_list', 'children': ['74', '75', '78', '81', '84', '89', '92']}; {'id': '74', 'type': 'string', 'children': [], 'value': "'-d'"}; {'id': '75', 'type': 'keyword_argument', 'children': ['76', '77']}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '77', 'type': 'string', 'children': [], 'value': "'store'"}; {'id': '78', 'type': 'keyword_argument', 'children': ['79', '80']}; {'id': '79', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '80', 'type': 'string', 'children': [], 'value': "'D'"}; {'id': '81', 'type': 'keyword_argument', 'children': ['82', '83']}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '83', 'type': 'string', 'children': [], 'value': "'mahalanobis'"}; {'id': '84', 'type': 'keyword_argument', 'children': ['85', '86']}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'choices'}; {'id': '86', 'type': 'list', 'children': ['87', '88'], 'value': "['mahalanobis','euclidean']"}; {'id': '87', 'type': 'string', 'children': [], 'value': "'mahalanobis'"}; {'id': '88', 'type': 'string', 'children': [], 'value': "'euclidean'"}; {'id': '89', 'type': 'keyword_argument', 'children': ['90', '91']}; {'id': '90', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '92', 'type': 'keyword_argument', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '94', 'type': 'string', 'children': [], 'value': "'Distance metric to use.'"}; {'id': '95', 'type': 'expression_statement', 'children': ['96']}; {'id': '96', 'type': 'call', 'children': ['97', '100']}; {'id': '97', 'type': 'attribute', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '100', 'type': 'argument_list', 'children': ['101', '102', '105', '108', '111', '117', '120']}; {'id': '101', 'type': 'string', 'children': [], 'value': "'-v'"}; {'id': '102', 'type': 'keyword_argument', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '104', 'type': 'string', 'children': [], 'value': "'store'"}; {'id': '105', 'type': 'keyword_argument', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '107', 'type': 'string', 'children': [], 'value': "'VERBOSITY'"}; {'id': '108', 'type': 'keyword_argument', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '110', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '111', 'type': 'keyword_argument', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'choices'}; {'id': '113', 'type': 'list', 'children': ['114', '115', '116'], 'value': '[0, 1, 2]'}; {'id': '114', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '115', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '116', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '117', 'type': 'keyword_argument', 'children': ['118', '119']}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '120', 'type': 'keyword_argument', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '122', 'type': 'string', 'children': [], 'value': "'How much information DistanceClassifier communicates while it is running: 0 = none, 1 = minimal, 2 = all.'"}; {'id': '123', 'type': 'expression_statement', 'children': ['124']}; {'id': '124', 'type': 'call', 'children': ['125', '128']}; {'id': '125', 'type': 'attribute', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '128', 'type': 'argument_list', 'children': ['129', '130', '133', '136', '139', '142']}; {'id': '129', 'type': 'string', 'children': [], 'value': "'-s'"}; {'id': '130', 'type': 'keyword_argument', 'children': ['131', '132']}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '132', 'type': 'string', 'children': [], 'value': "'store'"}; {'id': '133', 'type': 'keyword_argument', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '135', 'type': 'string', 'children': [], 'value': "'RANDOM_STATE'"}; {'id': '136', 'type': 'keyword_argument', 'children': ['137', '138']}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '138', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '139', 'type': 'keyword_argument', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'type'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'int'}; {'id': '142', 'type': 'keyword_argument', 'children': ['143', '144']}; {'id': '143', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '144', 'type': 'string', 'children': [], 'value': "'Random state for train/test split.'"}; {'id': '145', 'type': 'expression_statement', 'children': ['146']}; {'id': '146', 'type': 'call', 'children': ['147', '150']}; {'id': '147', 'type': 'attribute', 'children': ['148', '149']}; {'id': '148', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '149', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '150', 'type': 'argument_list', 'children': ['151', '152', '155', '165']}; {'id': '151', 'type': 'string', 'children': [], 'value': "'--version'"}; {'id': '152', 'type': 'keyword_argument', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '154', 'type': 'string', 'children': [], 'value': "'version'"}; {'id': '155', 'type': 'keyword_argument', 'children': ['156', '157']}; {'id': '156', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '157', 'type': 'call', 'children': ['158', '161']}; {'id': '158', 'type': 'attribute', 'children': ['159', '160']}; {'id': '159', 'type': 'string', 'children': [], 'value': "'DistanceClassifier {version}'"}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '161', 'type': 'argument_list', 'children': ['162']}; {'id': '162', 'type': 'keyword_argument', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '164', 'type': 'identifier', 'children': [], 'value': '__version__'}; {'id': '165', 'type': 'keyword_argument', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '167', 'type': 'string', 'children': [], 'value': "'Show DistanceClassifier\\'s version number and exit.'"}; {'id': '168', 'type': 'expression_statement', 'children': ['169']}; {'id': '169', 'type': 'assignment', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '175', 'type': 'argument_list', 'children': []}; {'id': '176', 'type': 'if_statement', 'children': ['177', '182']}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '181'], 'value': '>='}; {'id': '178', 'type': 'attribute', 'children': ['179', '180']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'VERBOSITY'}; {'id': '181', 'type': 'integer', 'children': [], 'value': '2'}; {'id': '182', 'type': 'block', 'children': ['183', '188', '212']}; {'id': '183', 'type': 'expression_statement', 'children': ['184']}; {'id': '184', 'type': 'call', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '186', 'type': 'argument_list', 'children': ['187']}; {'id': '187', 'type': 'string', 'children': [], 'value': "'\\nDistanceClassifier settings:'"}; {'id': '188', 'type': 'for_statement', 'children': ['189', '190', '196']}; {'id': '189', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '190', 'type': 'call', 'children': ['191', '192']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'sorted'}; {'id': '192', 'type': 'argument_list', 'children': ['193']}; {'id': '193', 'type': 'attribute', 'children': ['194', '195']}; {'id': '194', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '195', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '196', 'type': 'block', 'children': ['197']}; {'id': '197', 'type': 'expression_statement', 'children': ['198']}; {'id': '198', 'type': 'call', 'children': ['199', '200']}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '200', 'type': 'argument_list', 'children': ['201']}; {'id': '201', 'type': 'call', 'children': ['202', '205']}; {'id': '202', 'type': 'attribute', 'children': ['203', '204']}; {'id': '203', 'type': 'string', 'children': [], 'value': "'{}\\t=\\t{}'"}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '205', 'type': 'argument_list', 'children': ['206', '207']}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '207', 'type': 'subscript', 'children': ['208', '211']}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': '__dict__'}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'arg'}; {'id': '212', 'type': 'expression_statement', 'children': ['213']}; {'id': '213', 'type': 'call', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '215', 'type': 'argument_list', 'children': ['216']}; {'id': '216', 'type': 'string', 'children': [], 'value': "''"}; {'id': '217', 'type': 'expression_statement', 'children': ['218']}; {'id': '218', 'type': 'assignment', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '220', 'type': 'call', 'children': ['221', '224']}; {'id': '221', 'type': 'attribute', 'children': ['222', '223']}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'pd'}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 'read_csv'}; {'id': '224', 'type': 'argument_list', 'children': ['225', '228']}; {'id': '225', 'type': 'attribute', 'children': ['226', '227']}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '227', 'type': 'identifier', 'children': [], 'value': 'INPUT_FILE'}; {'id': '228', 'type': 'keyword_argument', 'children': ['229', '230']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'sep'}; {'id': '230', 'type': 'attribute', 'children': ['231', '232']}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '232', 'type': 'identifier', 'children': [], 'value': 'INPUT_SEPARATOR'}; {'id': '233', 'type': 'if_statement', 'children': ['234', '241']}; {'id': '234', 'type': 'comparison_operator', 'children': ['235', '236'], 'value': 'in'}; {'id': '235', 'type': 'string', 'children': [], 'value': "'Class'"}; {'id': '236', 'type': 'attribute', 'children': ['237', '240']}; {'id': '237', 'type': 'attribute', 'children': ['238', '239']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'columns'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '241', 'type': 'block', 'children': ['242']}; {'id': '242', 'type': 'expression_statement', 'children': ['243']}; {'id': '243', 'type': 'call', 'children': ['244', '247']}; {'id': '244', 'type': 'attribute', 'children': ['245', '246']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'rename'}; {'id': '247', 'type': 'argument_list', 'children': ['248', '254']}; {'id': '248', 'type': 'keyword_argument', 'children': ['249', '250']}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'columns'}; {'id': '250', 'type': 'dictionary', 'children': ['251']}; {'id': '251', 'type': 'pair', 'children': ['252', '253']}; {'id': '252', 'type': 'string', 'children': [], 'value': "'Label'"}; {'id': '253', 'type': 'string', 'children': [], 'value': "'label'"}; {'id': '254', 'type': 'keyword_argument', 'children': ['255', '256']}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'inplace'}; {'id': '256', 'type': 'True', 'children': []}; {'id': '257', 'type': 'expression_statement', 'children': ['258']}; {'id': '258', 'type': 'assignment', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'RANDOM_STATE'}; {'id': '260', 'type': 'conditional_expression', 'children': ['261', '264', '269'], 'value': 'if'}; {'id': '261', 'type': 'attribute', 'children': ['262', '263']}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '263', 'type': 'identifier', 'children': [], 'value': 'RANDOM_STATE'}; {'id': '264', 'type': 'comparison_operator', 'children': ['265', '268'], 'value': '>'}; {'id': '265', 'type': 'attribute', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'RANDOM_STATE'}; {'id': '268', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '269', 'type': 'None', 'children': []}; {'id': '270', 'type': 'expression_statement', 'children': ['271']}; {'id': '271', 'type': 'assignment', 'children': ['272', '273']}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'dc'}; {'id': '273', 'type': 'call', 'children': ['274', '275']}; {'id': '274', 'type': 'identifier', 'children': [], 'value': 'DistanceClassifier'}; {'id': '275', 'type': 'argument_list', 'children': ['276']}; {'id': '276', 'type': 'keyword_argument', 'children': ['277', '278']}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'd'}; {'id': '278', 'type': 'attribute', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'args'}; {'id': '280', 'type': 'identifier', 'children': [], 'value': 'D'}; {'id': '281', 'type': 'expression_statement', 'children': ['282']}; {'id': '282', 'type': 'call', 'children': ['283', '286']}; {'id': '283', 'type': 'attribute', 'children': ['284', '285']}; {'id': '284', 'type': 'identifier', 'children': [], 'value': 'dc'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'fit'}; {'id': '286', 'type': 'argument_list', 'children': ['287', '298']}; {'id': '287', 'type': 'attribute', 'children': ['288', '297']}; {'id': '288', 'type': 'call', 'children': ['289', '292']}; {'id': '289', 'type': 'attribute', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'drop'}; {'id': '292', 'type': 'argument_list', 'children': ['293', '294']}; {'id': '293', 'type': 'string', 'children': [], 'value': "'label'"}; {'id': '294', 'type': 'keyword_argument', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'axis'}; {'id': '296', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '297', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '298', 'type': 'attribute', 'children': ['299', '302']}; {'id': '299', 'type': 'subscript', 'children': ['300', '301']}; {'id': '300', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '301', 'type': 'string', 'children': [], 'value': "'label'"}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '303', 'type': 'expression_statement', 'children': ['304']}; {'id': '304', 'type': 'call', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '306', 'type': 'argument_list', 'children': ['307']}; {'id': '307', 'type': 'call', 'children': ['308', '311']}; {'id': '308', 'type': 'attribute', 'children': ['309', '310']}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'dc'}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'score'}; {'id': '311', 'type': 'argument_list', 'children': ['312', '323']}; {'id': '312', 'type': 'attribute', 'children': ['313', '322']}; {'id': '313', 'type': 'call', 'children': ['314', '317']}; {'id': '314', 'type': 'attribute', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'drop'}; {'id': '317', 'type': 'argument_list', 'children': ['318', '319']}; {'id': '318', 'type': 'string', 'children': [], 'value': "'label'"}; {'id': '319', 'type': 'keyword_argument', 'children': ['320', '321']}; {'id': '320', 'type': 'identifier', 'children': [], 'value': 'axis'}; {'id': '321', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '323', 'type': 'attribute', 'children': ['324', '327']}; {'id': '324', 'type': 'subscript', 'children': ['325', '326']}; {'id': '325', 'type': 'identifier', 'children': [], 'value': 'input_data'}; {'id': '326', 'type': 'string', 'children': [], 'value': "'label'"}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'values'}
Main function that is called when DistanceClassifier is run on the command line
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'sync_ldap_user_membership'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '6']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'ldap_groups'}; {'id': '7', 'type': 'block', 'children': ['8', '12', '26', '33', '37', '41', '45', '51', '55', '244', '280', '312', '318', '324', '330']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'groupname_field'}; {'id': '11', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '12', 'type': 'expression_statement', 'children': ['13']}; {'id': '13', 'type': 'assignment', 'children': ['14', '15']}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'actualGroups'}; {'id': '15', 'type': 'call', 'children': ['16', '21']}; {'id': '16', 'type': 'attribute', 'children': ['17', '20']}; {'id': '17', 'type': 'attribute', 'children': ['18', '19']}; {'id': '18', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'groups'}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'values_list'}; {'id': '21', 'type': 'argument_list', 'children': ['22', '23']}; {'id': '22', 'type': 'string', 'children': [], 'value': "'name'"}; {'id': '23', 'type': 'keyword_argument', 'children': ['24', '25']}; {'id': '24', 'type': 'identifier', 'children': [], 'value': 'flat'}; {'id': '25', 'type': 'True', 'children': []}; {'id': '26', 'type': 'expression_statement', 'children': ['27']}; {'id': '27', 'type': 'assignment', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'user_Membership_total'}; {'id': '29', 'type': 'call', 'children': ['30', '31']}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '31', 'type': 'argument_list', 'children': ['32']}; {'id': '32', 'type': 'identifier', 'children': [], 'value': 'ldap_groups'}; {'id': '33', 'type': 'expression_statement', 'children': ['34']}; {'id': '34', 'type': 'assignment', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'user_Membership_added'}; {'id': '36', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '37', 'type': 'expression_statement', 'children': ['38']}; {'id': '38', 'type': 'assignment', 'children': ['39', '40']}; {'id': '39', 'type': 'identifier', 'children': [], 'value': 'user_Membership_deleted'}; {'id': '40', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '41', 'type': 'expression_statement', 'children': ['42']}; {'id': '42', 'type': 'assignment', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'user_Membership_errors'}; {'id': '44', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'augmented_assignment', 'children': ['47', '48'], 'value': '+='}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'ldap_groups'}; {'id': '48', 'type': 'attribute', 'children': ['49', '50']}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '50', 'type': 'identifier', 'children': [], 'value': 'conf_LDAP_SYNC_GROUP_MEMBERSHIP_ADD_DEFAULT'}; {'id': '51', 'type': 'expression_statement', 'children': ['52']}; {'id': '52', 'type': 'assignment', 'children': ['53', '54']}; {'id': '53', 'type': 'identifier', 'children': [], 'value': 'ldap_name_groups'}; {'id': '54', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '55', 'type': 'for_statement', 'children': ['56', '59', '60']}; {'id': '56', 'type': 'pattern_list', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'cname'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'ldap_attributes'}; {'id': '59', 'type': 'identifier', 'children': [], 'value': 'ldap_groups'}; {'id': '60', 'type': 'block', 'children': ['61', '65', '98', '130']}; {'id': '61', 'type': 'expression_statement', 'children': ['62']}; {'id': '62', 'type': 'assignment', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '64', 'type': 'dictionary', 'children': []}; {'id': '65', 'type': 'try_statement', 'children': ['66', '94']}; {'id': '66', 'type': 'block', 'children': ['67']}; {'id': '67', 'type': 'for_statement', 'children': ['68', '71', '76']}; {'id': '68', 'type': 'pattern_list', 'children': ['69', '70']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '70', 'type': 'identifier', 'children': [], 'value': 'attribute'}; {'id': '71', 'type': 'call', 'children': ['72', '75']}; {'id': '72', 'type': 'attribute', 'children': ['73', '74']}; {'id': '73', 'type': 'identifier', 'children': [], 'value': 'ldap_attributes'}; {'id': '74', 'type': 'identifier', 'children': [], 'value': 'items'}; {'id': '75', 'type': 'argument_list', 'children': []}; {'id': '76', 'type': 'block', 'children': ['77']}; {'id': '77', 'type': 'expression_statement', 'children': ['78']}; {'id': '78', 'type': 'assignment', 'children': ['79', '86']}; {'id': '79', 'type': 'subscript', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '81', 'type': 'subscript', 'children': ['82', '85']}; {'id': '82', 'type': 'attribute', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '84', 'type': 'identifier', 'children': [], 'value': 'conf_LDAP_SYNC_GROUP_ATTRIBUTES'}; {'id': '85', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '86', 'type': 'call', 'children': ['87', '92']}; {'id': '87', 'type': 'attribute', 'children': ['88', '91']}; {'id': '88', 'type': 'subscript', 'children': ['89', '90']}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'attribute'}; {'id': '90', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '91', 'type': 'identifier', 'children': [], 'value': 'decode'}; {'id': '92', 'type': 'argument_list', 'children': ['93']}; {'id': '93', 'type': 'string', 'children': [], 'value': "'utf-8'"}; {'id': '94', 'type': 'except_clause', 'children': ['95', '96']}; {'id': '95', 'type': 'identifier', 'children': [], 'value': 'AttributeError'}; {'id': '96', 'type': 'block', 'children': ['97']}; {'id': '97', 'type': 'continue_statement', 'children': []}; {'id': '98', 'type': 'try_statement', 'children': ['99', '113']}; {'id': '99', 'type': 'block', 'children': ['100', '106']}; {'id': '100', 'type': 'expression_statement', 'children': ['101']}; {'id': '101', 'type': 'assignment', 'children': ['102', '103']}; {'id': '102', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '103', 'type': 'subscript', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'groupname_field'}; {'id': '106', 'type': 'expression_statement', 'children': ['107']}; {'id': '107', 'type': 'call', 'children': ['108', '111']}; {'id': '108', 'type': 'attribute', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'ldap_name_groups'}; {'id': '110', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '111', 'type': 'argument_list', 'children': ['112']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '113', 'type': 'except_clause', 'children': ['114', '115']}; {'id': '114', 'type': 'identifier', 'children': [], 'value': 'KeyError'}; {'id': '115', 'type': 'block', 'children': ['116', '125', '129']}; {'id': '116', 'type': 'expression_statement', 'children': ['117']}; {'id': '117', 'type': 'call', 'children': ['118', '121']}; {'id': '118', 'type': 'attribute', 'children': ['119', '120']}; {'id': '119', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'warning'}; {'id': '121', 'type': 'argument_list', 'children': ['122']}; {'id': '122', 'type': 'binary_operator', 'children': ['123', '124'], 'value': '%'}; {'id': '123', 'type': 'string', 'children': [], 'value': '"Group is missing a required attribute \'%s\'"'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'groupname_field'}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'augmented_assignment', 'children': ['127', '128'], 'value': '+='}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'user_Membership_errors'}; {'id': '128', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '129', 'type': 'continue_statement', 'children': []}; {'id': '130', 'type': 'if_statement', 'children': ['131', '135']}; {'id': '131', 'type': '()', 'children': ['132']}; {'id': '132', 'type': 'comparison_operator', 'children': ['133', '134'], 'value': 'not'}; {'id': '133', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'actualGroups'}; {'id': '135', 'type': 'block', 'children': ['136', '148']}; {'id': '136', 'type': 'expression_statement', 'children': ['137']}; {'id': '137', 'type': 'assignment', 'children': ['138', '139']}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '139', 'type': 'dictionary', 'children': ['140', '145']}; {'id': '140', 'type': 'pair', 'children': ['141', '144']}; {'id': '141', 'type': 'binary_operator', 'children': ['142', '143'], 'value': '+'}; {'id': '142', 'type': 'identifier', 'children': [], 'value': 'groupname_field'}; {'id': '143', 'type': 'string', 'children': [], 'value': "'__iexact'"}; {'id': '144', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '145', 'type': 'pair', 'children': ['146', '147']}; {'id': '146', 'type': 'string', 'children': [], 'value': "'defaults'"}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'defaults'}; {'id': '148', 'type': 'try_statement', 'children': ['149', '189', '194', '217']}; {'id': '149', 'type': 'block', 'children': ['150']}; {'id': '150', 'type': 'if_statement', 'children': ['151', '155', '170']}; {'id': '151', 'type': '()', 'children': ['152']}; {'id': '152', 'type': 'attribute', 'children': ['153', '154']}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '154', 'type': 'identifier', 'children': [], 'value': 'conf_LDAP_SYNC_GROUP_MEMBERSHIP_CREATE_IF_NOT_EXISTS'}; {'id': '155', 'type': 'block', 'children': ['156']}; {'id': '156', 'type': 'expression_statement', 'children': ['157']}; {'id': '157', 'type': 'assignment', 'children': ['158', '161']}; {'id': '158', 'type': 'pattern_list', 'children': ['159', '160']}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'created'}; {'id': '161', 'type': 'call', 'children': ['162', '167']}; {'id': '162', 'type': 'attribute', 'children': ['163', '166']}; {'id': '163', 'type': 'attribute', 'children': ['164', '165']}; {'id': '164', 'type': 'identifier', 'children': [], 'value': 'Group'}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'objects'}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'get_or_create'}; {'id': '167', 'type': 'argument_list', 'children': ['168']}; {'id': '168', 'type': 'dictionary_splat', 'children': ['169']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'kwargs'}; {'id': '170', 'type': 'else_clause', 'children': ['171']}; {'id': '171', 'type': 'block', 'children': ['172', '185']}; {'id': '172', 'type': 'expression_statement', 'children': ['173']}; {'id': '173', 'type': 'assignment', 'children': ['174', '175']}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '175', 'type': 'call', 'children': ['176', '181']}; {'id': '176', 'type': 'attribute', 'children': ['177', '180']}; {'id': '177', 'type': 'attribute', 'children': ['178', '179']}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'Group'}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'objects'}; {'id': '180', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '181', 'type': 'argument_list', 'children': ['182']}; {'id': '182', 'type': 'keyword_argument', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '184', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '185', 'type': 'expression_statement', 'children': ['186']}; {'id': '186', 'type': 'assignment', 'children': ['187', '188']}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'created'}; {'id': '188', 'type': 'False', 'children': []}; {'id': '189', 'type': 'except_clause', 'children': ['190', '192']}; {'id': '190', 'type': '()', 'children': ['191']}; {'id': '191', 'type': 'identifier', 'children': [], 'value': 'ObjectDoesNotExist'}; {'id': '192', 'type': 'block', 'children': ['193']}; {'id': '193', 'type': 'continue_statement', 'children': []}; {'id': '194', 'type': 'except_clause', 'children': ['195', '201']}; {'id': '195', 'type': 'as_pattern', 'children': ['196', '199']}; {'id': '196', 'type': 'tuple', 'children': ['197', '198']}; {'id': '197', 'type': 'identifier', 'children': [], 'value': 'IntegrityError'}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'DataError'}; {'id': '199', 'type': 'as_pattern_target', 'children': ['200']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '201', 'type': 'block', 'children': ['202', '213']}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'call', 'children': ['204', '207']}; {'id': '204', 'type': 'attribute', 'children': ['205', '206']}; {'id': '205', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '206', 'type': 'identifier', 'children': [], 'value': 'error'}; {'id': '207', 'type': 'argument_list', 'children': ['208']}; {'id': '208', 'type': 'binary_operator', 'children': ['209', '210'], 'value': '%'}; {'id': '209', 'type': 'string', 'children': [], 'value': '"Error creating group %s: %s"'}; {'id': '210', 'type': 'tuple', 'children': ['211', '212']}; {'id': '211', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '213', 'type': 'expression_statement', 'children': ['214']}; {'id': '214', 'type': 'augmented_assignment', 'children': ['215', '216'], 'value': '+='}; {'id': '215', 'type': 'identifier', 'children': [], 'value': 'user_Membership_errors'}; {'id': '216', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '217', 'type': 'else_clause', 'children': ['218']}; {'id': '218', 'type': 'block', 'children': ['219', '231', '240']}; {'id': '219', 'type': 'if_statement', 'children': ['220', '221']}; {'id': '220', 'type': 'identifier', 'children': [], 'value': 'created'}; {'id': '221', 'type': 'block', 'children': ['222']}; {'id': '222', 'type': 'expression_statement', 'children': ['223']}; {'id': '223', 'type': 'call', 'children': ['224', '227']}; {'id': '224', 'type': 'attribute', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '227', 'type': 'argument_list', 'children': ['228']}; {'id': '228', 'type': 'binary_operator', 'children': ['229', '230'], 'value': '%'}; {'id': '229', 'type': 'string', 'children': [], 'value': '"Created group %s"'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'groupname'}; {'id': '231', 'type': 'expression_statement', 'children': ['232']}; {'id': '232', 'type': 'call', 'children': ['233', '238']}; {'id': '233', 'type': 'attribute', 'children': ['234', '237']}; {'id': '234', 'type': 'attribute', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '236', 'type': 'identifier', 'children': [], 'value': 'user_set'}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'add'}; {'id': '238', 'type': 'argument_list', 'children': ['239']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '240', 'type': 'expression_statement', 'children': ['241']}; {'id': '241', 'type': 'augmented_assignment', 'children': ['242', '243'], 'value': '+='}; {'id': '242', 'type': 'identifier', 'children': [], 'value': 'user_Membership_added'}; {'id': '243', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '244', 'type': 'for_statement', 'children': ['245', '246', '247']}; {'id': '245', 'type': 'identifier', 'children': [], 'value': 'check_group'}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'actualGroups'}; {'id': '247', 'type': 'block', 'children': ['248']}; {'id': '248', 'type': 'if_statement', 'children': ['249', '253']}; {'id': '249', 'type': '()', 'children': ['250']}; {'id': '250', 'type': 'comparison_operator', 'children': ['251', '252'], 'value': 'not'}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 'check_group'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'ldap_name_groups'}; {'id': '253', 'type': 'block', 'children': ['254', '267', '276']}; {'id': '254', 'type': 'expression_statement', 'children': ['255']}; {'id': '255', 'type': 'assignment', 'children': ['256', '257']}; {'id': '256', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '257', 'type': 'call', 'children': ['258', '263']}; {'id': '258', 'type': 'attribute', 'children': ['259', '262']}; {'id': '259', 'type': 'attribute', 'children': ['260', '261']}; {'id': '260', 'type': 'identifier', 'children': [], 'value': 'Group'}; {'id': '261', 'type': 'identifier', 'children': [], 'value': 'objects'}; {'id': '262', 'type': 'identifier', 'children': [], 'value': 'get'}; {'id': '263', 'type': 'argument_list', 'children': ['264']}; {'id': '264', 'type': 'keyword_argument', 'children': ['265', '266']}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'name'}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 'check_group'}; {'id': '267', 'type': 'expression_statement', 'children': ['268']}; {'id': '268', 'type': 'call', 'children': ['269', '274']}; {'id': '269', 'type': 'attribute', 'children': ['270', '273']}; {'id': '270', 'type': 'attribute', 'children': ['271', '272']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '272', 'type': 'identifier', 'children': [], 'value': 'user_set'}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'remove'}; {'id': '274', 'type': 'argument_list', 'children': ['275']}; {'id': '275', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '276', 'type': 'expression_statement', 'children': ['277']}; {'id': '277', 'type': 'augmented_assignment', 'children': ['278', '279'], 'value': '+='}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'user_Membership_deleted'}; {'id': '279', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '280', 'type': 'if_statement', 'children': ['281', '291']}; {'id': '281', 'type': '()', 'children': ['282']}; {'id': '282', 'type': 'boolean_operator', 'children': ['283', '287'], 'value': 'or'}; {'id': '283', 'type': '()', 'children': ['284']}; {'id': '284', 'type': 'comparison_operator', 'children': ['285', '286'], 'value': '>'}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'user_Membership_deleted'}; {'id': '286', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '287', 'type': '()', 'children': ['288']}; {'id': '288', 'type': 'comparison_operator', 'children': ['289', '290'], 'value': '>'}; {'id': '289', 'type': 'identifier', 'children': [], 'value': 'user_Membership_added'}; {'id': '290', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '291', 'type': 'block', 'children': ['292', '298']}; {'id': '292', 'type': 'expression_statement', 'children': ['293']}; {'id': '293', 'type': 'call', 'children': ['294', '297']}; {'id': '294', 'type': 'attribute', 'children': ['295', '296']}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'group'}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'save'}; {'id': '297', 'type': 'argument_list', 'children': []}; {'id': '298', 'type': 'expression_statement', 'children': ['299']}; {'id': '299', 'type': 'call', 'children': ['300', '303']}; {'id': '300', 'type': 'attribute', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'logger'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '303', 'type': 'argument_list', 'children': ['304']}; {'id': '304', 'type': 'binary_operator', 'children': ['305', '306'], 'value': '%'}; {'id': '305', 'type': 'string', 'children': [], 'value': '"Group membership for user %s synchronized: %d Added, %d Removed"'}; {'id': '306', 'type': 'tuple', 'children': ['307', '310', '311']}; {'id': '307', 'type': 'attribute', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'user'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'username'}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'user_Membership_added'}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'user_Membership_deleted'}; {'id': '312', 'type': 'expression_statement', 'children': ['313']}; {'id': '313', 'type': 'augmented_assignment', 'children': ['314', '317'], 'value': '+='}; {'id': '314', 'type': 'attribute', 'children': ['315', '316']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '316', 'type': 'identifier', 'children': [], 'value': 'stats_membership_total'}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'user_Membership_total'}; {'id': '318', 'type': 'expression_statement', 'children': ['319']}; {'id': '319', 'type': 'augmented_assignment', 'children': ['320', '323'], 'value': '+='}; {'id': '320', 'type': 'attribute', 'children': ['321', '322']}; {'id': '321', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '322', 'type': 'identifier', 'children': [], 'value': 'stats_membership_added'}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'user_Membership_added'}; {'id': '324', 'type': 'expression_statement', 'children': ['325']}; {'id': '325', 'type': 'augmented_assignment', 'children': ['326', '329'], 'value': '+='}; {'id': '326', 'type': 'attribute', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '328', 'type': 'identifier', 'children': [], 'value': 'stats_membership_deleted'}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'user_Membership_deleted'}; {'id': '330', 'type': 'expression_statement', 'children': ['331']}; {'id': '331', 'type': 'augmented_assignment', 'children': ['332', '335'], 'value': '+='}; {'id': '332', 'type': 'attribute', 'children': ['333', '334']}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'self'}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'stats_membership_errors'}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'user_Membership_errors'}
Synchronize LDAP membership to Django membership
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '11']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'encode'}; {'id': '3', 'type': 'parameters', 'children': ['4', '5', '8']}; {'id': '4', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '5', 'type': 'default_parameter', 'children': ['6', '7']}; {'id': '6', 'type': 'identifier', 'children': [], 'value': 'encoding'}; {'id': '7', 'type': 'string', 'children': [], 'value': "'utf8'"}; {'id': '8', 'type': 'default_parameter', 'children': ['9', '10']}; {'id': '9', 'type': 'identifier', 'children': [], 'value': 'verbosity'}; {'id': '10', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '11', 'type': 'block', 'children': ['12', '38', '304', '313']}; {'id': '12', 'type': 'if_statement', 'children': ['13', '16']}; {'id': '13', 'type': 'comparison_operator', 'children': ['14', '15'], 'value': '>'}; {'id': '14', 'type': 'identifier', 'children': [], 'value': 'verbosity'}; {'id': '15', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '16', 'type': 'block', 'children': ['17', '32']}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'assignment', 'children': ['19', '20']}; {'id': '19', 'type': 'identifier', 'children': [], 'value': 'pbar'}; {'id': '20', 'type': 'call', 'children': ['21', '24']}; {'id': '21', 'type': 'attribute', 'children': ['22', '23']}; {'id': '22', 'type': 'identifier', 'children': [], 'value': 'progressbar'}; {'id': '23', 'type': 'identifier', 'children': [], 'value': 'ProgressBar'}; {'id': '24', 'type': 'argument_list', 'children': ['25']}; {'id': '25', 'type': 'keyword_argument', 'children': ['26', '27']}; {'id': '26', 'type': 'identifier', 'children': [], 'value': 'maxval'}; {'id': '27', 'type': 'subscript', 'children': ['28', '31']}; {'id': '28', 'type': 'attribute', 'children': ['29', '30']}; {'id': '29', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '30', 'type': 'identifier', 'children': [], 'value': 'shape'}; {'id': '31', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'pbar'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'start'}; {'id': '37', 'type': 'argument_list', 'children': []}; {'id': '38', 'type': 'for_statement', 'children': ['39', '42', '48']}; {'id': '39', 'type': 'pattern_list', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'colnum'}; {'id': '41', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '42', 'type': 'call', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '44', 'type': 'argument_list', 'children': ['45']}; {'id': '45', 'type': 'attribute', 'children': ['46', '47']}; {'id': '46', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '47', 'type': 'identifier', 'children': [], 'value': 'columns'}; {'id': '48', 'type': 'block', 'children': ['49']}; {'id': '49', 'type': 'if_statement', 'children': ['50', '59']}; {'id': '50', 'type': 'call', 'children': ['51', '52']}; {'id': '51', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '52', 'type': 'argument_list', 'children': ['53', '56']}; {'id': '53', 'type': 'subscript', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '55', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '56', 'type': 'attribute', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'pd'}; {'id': '58', 'type': 'identifier', 'children': [], 'value': 'Series'}; {'id': '59', 'type': 'block', 'children': ['60', '70']}; {'id': '60', 'type': 'if_statement', 'children': ['61', '62']}; {'id': '61', 'type': 'identifier', 'children': [], 'value': 'verbosity'}; {'id': '62', 'type': 'block', 'children': ['63']}; {'id': '63', 'type': 'expression_statement', 'children': ['64']}; {'id': '64', 'type': 'call', 'children': ['65', '68']}; {'id': '65', 'type': 'attribute', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'pbar'}; {'id': '67', 'type': 'identifier', 'children': [], 'value': 'update'}; {'id': '68', 'type': 'argument_list', 'children': ['69']}; {'id': '69', 'type': 'identifier', 'children': [], 'value': 'colnum'}; {'id': '70', 'type': 'if_statement', 'children': ['71', '110']}; {'id': '71', 'type': 'boolean_operator', 'children': ['72', '97'], 'value': 'and'}; {'id': '72', 'type': 'comparison_operator', 'children': ['73', '78'], 'value': 'in'}; {'id': '73', 'type': 'attribute', 'children': ['74', '77']}; {'id': '74', 'type': 'subscript', 'children': ['75', '76']}; {'id': '75', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '76', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'dtype'}; {'id': '78', 'type': 'tuple', 'children': ['79', '85', '91']}; {'id': '79', 'type': 'call', 'children': ['80', '83']}; {'id': '80', 'type': 'attribute', 'children': ['81', '82']}; {'id': '81', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '82', 'type': 'identifier', 'children': [], 'value': 'dtype'}; {'id': '83', 'type': 'argument_list', 'children': ['84']}; {'id': '84', 'type': 'string', 'children': [], 'value': "'object'"}; {'id': '85', 'type': 'call', 'children': ['86', '89']}; {'id': '86', 'type': 'attribute', 'children': ['87', '88']}; {'id': '87', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'dtype'}; {'id': '89', 'type': 'argument_list', 'children': ['90']}; {'id': '90', 'type': 'string', 'children': [], 'value': "'U'"}; {'id': '91', 'type': 'call', 'children': ['92', '95']}; {'id': '92', 'type': 'attribute', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '94', 'type': 'identifier', 'children': [], 'value': 'dtype'}; {'id': '95', 'type': 'argument_list', 'children': ['96']}; {'id': '96', 'type': 'string', 'children': [], 'value': "'S'"}; {'id': '97', 'type': 'call', 'children': ['98', '99']}; {'id': '98', 'type': 'identifier', 'children': [], 'value': 'any'}; {'id': '99', 'type': 'generator_expression', 'children': ['100', '105']}; {'id': '100', 'type': 'call', 'children': ['101', '102']}; {'id': '101', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '102', 'type': 'argument_list', 'children': ['103', '104']}; {'id': '103', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'basestring'}; {'id': '105', 'type': 'for_in_clause', 'children': ['106', '107']}; {'id': '106', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '107', 'type': 'subscript', 'children': ['108', '109']}; {'id': '108', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '110', 'type': 'block', 'children': ['111', '130', '140', '298']}; {'id': '111', 'type': 'expression_statement', 'children': ['112']}; {'id': '112', 'type': 'assignment', 'children': ['113', '114']}; {'id': '113', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '114', 'type': 'call', 'children': ['115', '118']}; {'id': '115', 'type': 'attribute', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '117', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '118', 'type': 'argument_list', 'children': ['119']}; {'id': '119', 'type': 'list_comprehension', 'children': ['120', '125']}; {'id': '120', 'type': 'call', 'children': ['121', '122']}; {'id': '121', 'type': 'identifier', 'children': [], 'value': 'isinstance'}; {'id': '122', 'type': 'argument_list', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'basestring'}; {'id': '125', 'type': 'for_in_clause', 'children': ['126', '127']}; {'id': '126', 'type': 'identifier', 'children': [], 'value': 'obj'}; {'id': '127', 'type': 'subscript', 'children': ['128', '129']}; {'id': '128', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '129', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '130', 'type': 'expression_statement', 'children': ['131']}; {'id': '131', 'type': 'assignment', 'children': ['132', '133']}; {'id': '132', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '133', 'type': 'call', 'children': ['134', '139']}; {'id': '134', 'type': 'attribute', 'children': ['135', '138']}; {'id': '135', 'type': 'subscript', 'children': ['136', '137']}; {'id': '136', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '137', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '138', 'type': 'identifier', 'children': [], 'value': 'copy'}; {'id': '139', 'type': 'argument_list', 'children': []}; {'id': '140', 'type': 'try_statement', 'children': ['141', '164', '198']}; {'id': '141', 'type': 'block', 'children': ['142']}; {'id': '142', 'type': 'expression_statement', 'children': ['143']}; {'id': '143', 'type': 'assignment', 'children': ['144', '147']}; {'id': '144', 'type': 'subscript', 'children': ['145', '146']}; {'id': '145', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '147', 'type': 'call', 'children': ['148', '153']}; {'id': '148', 'type': 'attribute', 'children': ['149', '152']}; {'id': '149', 'type': 'attribute', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '151', 'type': 'identifier', 'children': [], 'value': 'char'}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '153', 'type': 'argument_list', 'children': ['154']}; {'id': '154', 'type': 'call', 'children': ['155', '162']}; {'id': '155', 'type': 'attribute', 'children': ['156', '161']}; {'id': '156', 'type': 'attribute', 'children': ['157', '160']}; {'id': '157', 'type': 'subscript', 'children': ['158', '159']}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '159', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '160', 'type': 'identifier', 'children': [], 'value': 'values'}; {'id': '161', 'type': 'identifier', 'children': [], 'value': 'astype'}; {'id': '162', 'type': 'argument_list', 'children': ['163']}; {'id': '163', 'type': 'string', 'children': [], 'value': "'U'"}; {'id': '164', 'type': 'except_clause', 'children': ['165', '166']}; {'id': '165', 'type': 'identifier', 'children': [], 'value': 'TypeError'}; {'id': '166', 'type': 'block', 'children': ['167', '197']}; {'id': '167', 'type': 'expression_statement', 'children': ['168']}; {'id': '168', 'type': 'call', 'children': ['169', '170']}; {'id': '169', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '170', 'type': 'argument_list', 'children': ['171']}; {'id': '171', 'type': 'call', 'children': ['172', '175']}; {'id': '172', 'type': 'attribute', 'children': ['173', '174']}; {'id': '173', 'type': 'string', 'children': [], 'value': '"Unable to convert {} elements starting at position {} in column {}"'}; {'id': '174', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '175', 'type': 'argument_list', 'children': ['176', '180', '196']}; {'id': '176', 'type': 'call', 'children': ['177', '178']}; {'id': '177', 'type': 'identifier', 'children': [], 'value': 'sum'}; {'id': '178', 'type': 'argument_list', 'children': ['179']}; {'id': '179', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '180', 'type': 'subscript', 'children': ['181', '193']}; {'id': '181', 'type': 'list_comprehension', 'children': ['182', '183', '191']}; {'id': '182', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '183', 'type': 'for_in_clause', 'children': ['184', '187']}; {'id': '184', 'type': 'pattern_list', 'children': ['185', '186']}; {'id': '185', 'type': 'identifier', 'children': [], 'value': 'i'}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '187', 'type': 'call', 'children': ['188', '189']}; {'id': '188', 'type': 'identifier', 'children': [], 'value': 'enumerate'}; {'id': '189', 'type': 'argument_list', 'children': ['190']}; {'id': '190', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '191', 'type': 'if_clause', 'children': ['192']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'b'}; {'id': '193', 'type': 'slice', 'children': ['194', '195']}; {'id': '194', 'type': 'colon', 'children': []}; {'id': '195', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '196', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '197', 'type': 'raise_statement', 'children': []}; {'id': '198', 'type': 'except_clause', 'children': ['199', '202']}; {'id': '199', 'type': 'tuple', 'children': ['200', '201']}; {'id': '200', 'type': 'identifier', 'children': [], 'value': 'UnicodeDecodeError'}; {'id': '201', 'type': 'identifier', 'children': [], 'value': 'UnicodeEncodeError'}; {'id': '202', 'type': 'block', 'children': ['203']}; {'id': '203', 'type': 'try_statement', 'children': ['204', '227']}; {'id': '204', 'type': 'block', 'children': ['205']}; {'id': '205', 'type': 'expression_statement', 'children': ['206']}; {'id': '206', 'type': 'assignment', 'children': ['207', '210']}; {'id': '207', 'type': 'subscript', 'children': ['208', '209']}; {'id': '208', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '210', 'type': 'call', 'children': ['211', '214']}; {'id': '211', 'type': 'attribute', 'children': ['212', '213']}; {'id': '212', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '213', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '214', 'type': 'argument_list', 'children': ['215']}; {'id': '215', 'type': 'list_comprehension', 'children': ['216', '222']}; {'id': '216', 'type': 'call', 'children': ['217', '218']}; {'id': '217', 'type': 'identifier', 'children': [], 'value': 'eval'}; {'id': '218', 'type': 'argument_list', 'children': ['219', '220', '221']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '220', 'type': 'dictionary', 'children': []}; {'id': '221', 'type': 'dictionary', 'children': []}; {'id': '222', 'type': 'for_in_clause', 'children': ['223', '224']}; {'id': '223', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '224', 'type': 'subscript', 'children': ['225', '226']}; {'id': '225', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '226', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '227', 'type': 'except_clause', 'children': ['228', '232']}; {'id': '228', 'type': 'tuple', 'children': ['229', '230', '231']}; {'id': '229', 'type': 'identifier', 'children': [], 'value': 'SyntaxError'}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'UnicodeDecodeError'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'UnicodeEncodeError'}; {'id': '232', 'type': 'block', 'children': ['233', '237', '282']}; {'id': '233', 'type': 'expression_statement', 'children': ['234']}; {'id': '234', 'type': 'assignment', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'newseries'}; {'id': '236', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '237', 'type': 'for_statement', 'children': ['238', '239', '242']}; {'id': '238', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '239', 'type': 'subscript', 'children': ['240', '241']}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '241', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '242', 'type': 'block', 'children': ['243']}; {'id': '243', 'type': 'try_statement', 'children': ['244', '255']}; {'id': '244', 'type': 'block', 'children': ['245']}; {'id': '245', 'type': 'expression_statement', 'children': ['246']}; {'id': '246', 'type': 'augmented_assignment', 'children': ['247', '248'], 'value': '+='}; {'id': '247', 'type': 'identifier', 'children': [], 'value': 'newseries'}; {'id': '248', 'type': 'list', 'children': ['249'], 'value': "[s.encode('utf8')]"}; {'id': '249', 'type': 'call', 'children': ['250', '253']}; {'id': '250', 'type': 'attribute', 'children': ['251', '252']}; {'id': '251', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '252', 'type': 'identifier', 'children': [], 'value': 'encode'}; {'id': '253', 'type': 'argument_list', 'children': ['254']}; {'id': '254', 'type': 'string', 'children': [], 'value': "'utf8'"}; {'id': '255', 'type': 'except_clause', 'children': ['256']}; {'id': '256', 'type': 'block', 'children': ['257', '274']}; {'id': '257', 'type': 'expression_statement', 'children': ['258']}; {'id': '258', 'type': 'call', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '260', 'type': 'argument_list', 'children': ['261']}; {'id': '261', 'type': 'call', 'children': ['262', '265']}; {'id': '262', 'type': 'attribute', 'children': ['263', '264']}; {'id': '263', 'type': 'string', 'children': [], 'value': "u'Had trouble encoding {} so used repr to turn it into {}'"}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'format'}; {'id': '265', 'type': 'argument_list', 'children': ['266', '267']}; {'id': '266', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '267', 'type': 'call', 'children': ['268', '269']}; {'id': '268', 'type': 'identifier', 'children': [], 'value': 'repr'}; {'id': '269', 'type': 'argument_list', 'children': ['270']}; {'id': '270', 'type': 'call', 'children': ['271', '272']}; {'id': '271', 'type': 'identifier', 'children': [], 'value': 'transcode_unicode'}; {'id': '272', 'type': 'argument_list', 'children': ['273']}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '274', 'type': 'expression_statement', 'children': ['275']}; {'id': '275', 'type': 'augmented_assignment', 'children': ['276', '277'], 'value': '+='}; {'id': '276', 'type': 'identifier', 'children': [], 'value': 'newseries'}; {'id': '277', 'type': 'list', 'children': ['278'], 'value': '[transcode_unicode(s)]'}; {'id': '278', 'type': 'call', 'children': ['279', '280']}; {'id': '279', 'type': 'identifier', 'children': [], 'value': 'transcode_unicode'}; {'id': '280', 'type': 'argument_list', 'children': ['281']}; {'id': '281', 'type': 'identifier', 'children': [], 'value': 's'}; {'id': '282', 'type': 'expression_statement', 'children': ['283']}; {'id': '283', 'type': 'assignment', 'children': ['284', '287']}; {'id': '284', 'type': 'subscript', 'children': ['285', '286']}; {'id': '285', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'strmask'}; {'id': '287', 'type': 'call', 'children': ['288', '296']}; {'id': '288', 'type': 'attribute', 'children': ['289', '295']}; {'id': '289', 'type': 'call', 'children': ['290', '293']}; {'id': '290', 'type': 'attribute', 'children': ['291', '292']}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'np'}; {'id': '292', 'type': 'identifier', 'children': [], 'value': 'array'}; {'id': '293', 'type': 'argument_list', 'children': ['294']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'newseries'}; {'id': '295', 'type': 'identifier', 'children': [], 'value': 'astype'}; {'id': '296', 'type': 'argument_list', 'children': ['297']}; {'id': '297', 'type': 'string', 'children': [], 'value': "'O'"}; {'id': '298', 'type': 'expression_statement', 'children': ['299']}; {'id': '299', 'type': 'assignment', 'children': ['300', '303']}; {'id': '300', 'type': 'subscript', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'df'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'col'}; {'id': '303', 'type': 'identifier', 'children': [], 'value': 'series'}; {'id': '304', 'type': 'if_statement', 'children': ['305', '306']}; {'id': '305', 'type': 'identifier', 'children': [], 'value': 'verbosity'}; {'id': '306', 'type': 'block', 'children': ['307']}; {'id': '307', 'type': 'expression_statement', 'children': ['308']}; {'id': '308', 'type': 'call', 'children': ['309', '312']}; {'id': '309', 'type': 'attribute', 'children': ['310', '311']}; {'id': '310', 'type': 'identifier', 'children': [], 'value': 'pbar'}; {'id': '311', 'type': 'identifier', 'children': [], 'value': 'finish'}; {'id': '312', 'type': 'argument_list', 'children': []}; {'id': '313', 'type': 'return_statement', 'children': ['314']}; {'id': '314', 'type': 'identifier', 'children': [], 'value': 'df'}
If you try to encode each element individually with python, this would take days!
{'id': '0', 'type': 'module', 'children': ['1']}; {'id': '1', 'type': 'function_definition', 'children': ['2', '3', '7']}; {'id': '2', 'type': 'function_name', 'children': [], 'value': 'main'}; {'id': '3', 'type': 'parameters', 'children': ['4']}; {'id': '4', 'type': 'default_parameter', 'children': ['5', '6']}; {'id': '5', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '6', 'type': 'None', 'children': []}; {'id': '7', 'type': 'block', 'children': ['8', '17', '32', '45', '68', '85', '101', '114', '125', '138', '161', '174', '202', '206', '314', '331']}; {'id': '8', 'type': 'expression_statement', 'children': ['9']}; {'id': '9', 'type': 'assignment', 'children': ['10', '11']}; {'id': '10', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '11', 'type': 'call', 'children': ['12', '13']}; {'id': '12', 'type': 'identifier', 'children': [], 'value': 'ArgumentParser'}; {'id': '13', 'type': 'argument_list', 'children': ['14']}; {'id': '14', 'type': 'keyword_argument', 'children': ['15', '16']}; {'id': '15', 'type': 'identifier', 'children': [], 'value': 'prog'}; {'id': '16', 'type': 'string', 'children': [], 'value': '"pygenstub"'}; {'id': '17', 'type': 'expression_statement', 'children': ['18']}; {'id': '18', 'type': 'call', 'children': ['19', '22']}; {'id': '19', 'type': 'attribute', 'children': ['20', '21']}; {'id': '20', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '21', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '22', 'type': 'argument_list', 'children': ['23', '24', '27']}; {'id': '23', 'type': 'string', 'children': [], 'value': '"--version"'}; {'id': '24', 'type': 'keyword_argument', 'children': ['25', '26']}; {'id': '25', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '26', 'type': 'string', 'children': [], 'value': '"version"'}; {'id': '27', 'type': 'keyword_argument', 'children': ['28', '29']}; {'id': '28', 'type': 'identifier', 'children': [], 'value': 'version'}; {'id': '29', 'type': 'binary_operator', 'children': ['30', '31'], 'value': '+'}; {'id': '30', 'type': 'string', 'children': [], 'value': '"%(prog)s "'}; {'id': '31', 'type': 'identifier', 'children': [], 'value': '__version__'}; {'id': '32', 'type': 'expression_statement', 'children': ['33']}; {'id': '33', 'type': 'call', 'children': ['34', '37']}; {'id': '34', 'type': 'attribute', 'children': ['35', '36']}; {'id': '35', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '36', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '37', 'type': 'argument_list', 'children': ['38', '39', '42']}; {'id': '38', 'type': 'string', 'children': [], 'value': '"files"'}; {'id': '39', 'type': 'keyword_argument', 'children': ['40', '41']}; {'id': '40', 'type': 'identifier', 'children': [], 'value': 'nargs'}; {'id': '41', 'type': 'string', 'children': [], 'value': '"*"'}; {'id': '42', 'type': 'keyword_argument', 'children': ['43', '44']}; {'id': '43', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '44', 'type': 'string', 'children': [], 'value': '"generate stubs for given files"'}; {'id': '45', 'type': 'expression_statement', 'children': ['46']}; {'id': '46', 'type': 'call', 'children': ['47', '50']}; {'id': '47', 'type': 'attribute', 'children': ['48', '49']}; {'id': '48', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '49', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '50', 'type': 'argument_list', 'children': ['51', '52', '53', '56', '59', '62', '65']}; {'id': '51', 'type': 'string', 'children': [], 'value': '"-m"'}; {'id': '52', 'type': 'string', 'children': [], 'value': '"--module"'}; {'id': '53', 'type': 'keyword_argument', 'children': ['54', '55']}; {'id': '54', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '55', 'type': 'string', 'children': [], 'value': '"append"'}; {'id': '56', 'type': 'keyword_argument', 'children': ['57', '58']}; {'id': '57', 'type': 'identifier', 'children': [], 'value': 'metavar'}; {'id': '58', 'type': 'string', 'children': [], 'value': '"MODULE"'}; {'id': '59', 'type': 'keyword_argument', 'children': ['60', '61']}; {'id': '60', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '61', 'type': 'string', 'children': [], 'value': '"modules"'}; {'id': '62', 'type': 'keyword_argument', 'children': ['63', '64']}; {'id': '63', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '64', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '65', 'type': 'keyword_argument', 'children': ['66', '67']}; {'id': '66', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '67', 'type': 'string', 'children': [], 'value': '"generate stubs for given modules"'}; {'id': '68', 'type': 'expression_statement', 'children': ['69']}; {'id': '69', 'type': 'call', 'children': ['70', '73']}; {'id': '70', 'type': 'attribute', 'children': ['71', '72']}; {'id': '71', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '72', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '73', 'type': 'argument_list', 'children': ['74', '75', '76', '79', '82']}; {'id': '74', 'type': 'string', 'children': [], 'value': '"-o"'}; {'id': '75', 'type': 'string', 'children': [], 'value': '"--output"'}; {'id': '76', 'type': 'keyword_argument', 'children': ['77', '78']}; {'id': '77', 'type': 'identifier', 'children': [], 'value': 'metavar'}; {'id': '78', 'type': 'string', 'children': [], 'value': '"PATH"'}; {'id': '79', 'type': 'keyword_argument', 'children': ['80', '81']}; {'id': '80', 'type': 'identifier', 'children': [], 'value': 'dest'}; {'id': '81', 'type': 'string', 'children': [], 'value': '"out_dir"'}; {'id': '82', 'type': 'keyword_argument', 'children': ['83', '84']}; {'id': '83', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '84', 'type': 'string', 'children': [], 'value': '"change the output directory"'}; {'id': '85', 'type': 'expression_statement', 'children': ['86']}; {'id': '86', 'type': 'call', 'children': ['87', '90']}; {'id': '87', 'type': 'attribute', 'children': ['88', '89']}; {'id': '88', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '89', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '90', 'type': 'argument_list', 'children': ['91', '92', '95', '98']}; {'id': '91', 'type': 'string', 'children': [], 'value': '"--generic"'}; {'id': '92', 'type': 'keyword_argument', 'children': ['93', '94']}; {'id': '93', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '94', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '95', 'type': 'keyword_argument', 'children': ['96', '97']}; {'id': '96', 'type': 'identifier', 'children': [], 'value': 'default'}; {'id': '97', 'type': 'False', 'children': []}; {'id': '98', 'type': 'keyword_argument', 'children': ['99', '100']}; {'id': '99', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '100', 'type': 'string', 'children': [], 'value': '"generate generic stubs"'}; {'id': '101', 'type': 'expression_statement', 'children': ['102']}; {'id': '102', 'type': 'call', 'children': ['103', '106']}; {'id': '103', 'type': 'attribute', 'children': ['104', '105']}; {'id': '104', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '105', 'type': 'identifier', 'children': [], 'value': 'add_argument'}; {'id': '106', 'type': 'argument_list', 'children': ['107', '108', '111']}; {'id': '107', 'type': 'string', 'children': [], 'value': '"--debug"'}; {'id': '108', 'type': 'keyword_argument', 'children': ['109', '110']}; {'id': '109', 'type': 'identifier', 'children': [], 'value': 'action'}; {'id': '110', 'type': 'string', 'children': [], 'value': '"store_true"'}; {'id': '111', 'type': 'keyword_argument', 'children': ['112', '113']}; {'id': '112', 'type': 'identifier', 'children': [], 'value': 'help'}; {'id': '113', 'type': 'string', 'children': [], 'value': '"enable debug messages"'}; {'id': '114', 'type': 'expression_statement', 'children': ['115']}; {'id': '115', 'type': 'assignment', 'children': ['116', '117']}; {'id': '116', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '117', 'type': 'conditional_expression', 'children': ['118', '119', '122'], 'value': 'if'}; {'id': '118', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '119', 'type': 'comparison_operator', 'children': ['120', '121'], 'value': 'is'}; {'id': '120', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '121', 'type': 'None', 'children': []}; {'id': '122', 'type': 'attribute', 'children': ['123', '124']}; {'id': '123', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '124', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '125', 'type': 'expression_statement', 'children': ['126']}; {'id': '126', 'type': 'assignment', 'children': ['127', '128']}; {'id': '127', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '128', 'type': 'call', 'children': ['129', '132']}; {'id': '129', 'type': 'attribute', 'children': ['130', '131']}; {'id': '130', 'type': 'identifier', 'children': [], 'value': 'parser'}; {'id': '131', 'type': 'identifier', 'children': [], 'value': 'parse_args'}; {'id': '132', 'type': 'argument_list', 'children': ['133']}; {'id': '133', 'type': 'subscript', 'children': ['134', '135']}; {'id': '134', 'type': 'identifier', 'children': [], 'value': 'argv'}; {'id': '135', 'type': 'slice', 'children': ['136', '137']}; {'id': '136', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '137', 'type': 'colon', 'children': []}; {'id': '138', 'type': 'if_statement', 'children': ['139', '142']}; {'id': '139', 'type': 'attribute', 'children': ['140', '141']}; {'id': '140', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '141', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '142', 'type': 'block', 'children': ['143', '154']}; {'id': '143', 'type': 'expression_statement', 'children': ['144']}; {'id': '144', 'type': 'call', 'children': ['145', '148']}; {'id': '145', 'type': 'attribute', 'children': ['146', '147']}; {'id': '146', 'type': 'identifier', 'children': [], 'value': 'logging'}; {'id': '147', 'type': 'identifier', 'children': [], 'value': 'basicConfig'}; {'id': '148', 'type': 'argument_list', 'children': ['149']}; {'id': '149', 'type': 'keyword_argument', 'children': ['150', '151']}; {'id': '150', 'type': 'identifier', 'children': [], 'value': 'level'}; {'id': '151', 'type': 'attribute', 'children': ['152', '153']}; {'id': '152', 'type': 'identifier', 'children': [], 'value': 'logging'}; {'id': '153', 'type': 'identifier', 'children': [], 'value': 'DEBUG'}; {'id': '154', 'type': 'expression_statement', 'children': ['155']}; {'id': '155', 'type': 'call', 'children': ['156', '159']}; {'id': '156', 'type': 'attribute', 'children': ['157', '158']}; {'id': '157', 'type': 'identifier', 'children': [], 'value': '_logger'}; {'id': '158', 'type': 'identifier', 'children': [], 'value': 'debug'}; {'id': '159', 'type': 'argument_list', 'children': ['160']}; {'id': '160', 'type': 'string', 'children': [], 'value': '"running in debug mode"'}; {'id': '161', 'type': 'expression_statement', 'children': ['162']}; {'id': '162', 'type': 'assignment', 'children': ['163', '164']}; {'id': '163', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '164', 'type': 'conditional_expression', 'children': ['165', '168', '173'], 'value': 'if'}; {'id': '165', 'type': 'attribute', 'children': ['166', '167']}; {'id': '166', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '167', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '168', 'type': 'comparison_operator', 'children': ['169', '172'], 'value': 'is'}; {'id': '169', 'type': 'attribute', 'children': ['170', '171']}; {'id': '170', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '171', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '172', 'type': 'None', 'children': []}; {'id': '173', 'type': 'string', 'children': [], 'value': '""'}; {'id': '174', 'type': 'if_statement', 'children': ['175', '189']}; {'id': '175', 'type': 'boolean_operator', 'children': ['176', '180'], 'value': 'and'}; {'id': '176', 'type': '()', 'children': ['177']}; {'id': '177', 'type': 'comparison_operator', 'children': ['178', '179'], 'value': '=='}; {'id': '178', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '179', 'type': 'string', 'children': [], 'value': '""'}; {'id': '180', 'type': '()', 'children': ['181']}; {'id': '181', 'type': 'comparison_operator', 'children': ['182', '188'], 'value': '>'}; {'id': '182', 'type': 'call', 'children': ['183', '184']}; {'id': '183', 'type': 'identifier', 'children': [], 'value': 'len'}; {'id': '184', 'type': 'argument_list', 'children': ['185']}; {'id': '185', 'type': 'attribute', 'children': ['186', '187']}; {'id': '186', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '187', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '188', 'type': 'integer', 'children': [], 'value': '0'}; {'id': '189', 'type': 'block', 'children': ['190', '195']}; {'id': '190', 'type': 'expression_statement', 'children': ['191']}; {'id': '191', 'type': 'call', 'children': ['192', '193']}; {'id': '192', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '193', 'type': 'argument_list', 'children': ['194']}; {'id': '194', 'type': 'string', 'children': [], 'value': '"Output directory must be given when generating stubs for modules."'}; {'id': '195', 'type': 'expression_statement', 'children': ['196']}; {'id': '196', 'type': 'call', 'children': ['197', '200']}; {'id': '197', 'type': 'attribute', 'children': ['198', '199']}; {'id': '198', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '199', 'type': 'identifier', 'children': [], 'value': 'exit'}; {'id': '200', 'type': 'argument_list', 'children': ['201']}; {'id': '201', 'type': 'integer', 'children': [], 'value': '1'}; {'id': '202', 'type': 'expression_statement', 'children': ['203']}; {'id': '203', 'type': 'assignment', 'children': ['204', '205']}; {'id': '204', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '205', 'type': 'list', 'children': [], 'value': '[]'}; {'id': '206', 'type': 'for_statement', 'children': ['207', '208', '211']}; {'id': '207', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '208', 'type': 'attribute', 'children': ['209', '210']}; {'id': '209', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '210', 'type': 'identifier', 'children': [], 'value': 'files'}; {'id': '211', 'type': 'block', 'children': ['212', '238']}; {'id': '212', 'type': 'expression_statement', 'children': ['213']}; {'id': '213', 'type': 'assignment', 'children': ['214', '215']}; {'id': '214', 'type': 'identifier', 'children': [], 'value': 'paths'}; {'id': '215', 'type': 'conditional_expression', 'children': ['216', '225', '233'], 'value': 'if'}; {'id': '216', 'type': 'call', 'children': ['217', '223']}; {'id': '217', 'type': 'attribute', 'children': ['218', '222']}; {'id': '218', 'type': 'call', 'children': ['219', '220']}; {'id': '219', 'type': 'identifier', 'children': [], 'value': 'Path'}; {'id': '220', 'type': 'argument_list', 'children': ['221']}; {'id': '221', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '222', 'type': 'identifier', 'children': [], 'value': 'glob'}; {'id': '223', 'type': 'argument_list', 'children': ['224']}; {'id': '224', 'type': 'string', 'children': [], 'value': '"**/*.py"'}; {'id': '225', 'type': 'call', 'children': ['226', '232']}; {'id': '226', 'type': 'attribute', 'children': ['227', '231']}; {'id': '227', 'type': 'call', 'children': ['228', '229']}; {'id': '228', 'type': 'identifier', 'children': [], 'value': 'Path'}; {'id': '229', 'type': 'argument_list', 'children': ['230']}; {'id': '230', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '231', 'type': 'identifier', 'children': [], 'value': 'is_dir'}; {'id': '232', 'type': 'argument_list', 'children': []}; {'id': '233', 'type': 'list', 'children': ['234'], 'value': '[Path(path)]'}; {'id': '234', 'type': 'call', 'children': ['235', '236']}; {'id': '235', 'type': 'identifier', 'children': [], 'value': 'Path'}; {'id': '236', 'type': 'argument_list', 'children': ['237']}; {'id': '237', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '238', 'type': 'for_statement', 'children': ['239', '240', '241']}; {'id': '239', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '240', 'type': 'identifier', 'children': [], 'value': 'paths'}; {'id': '241', 'type': 'block', 'children': ['242', '269', '292', '305']}; {'id': '242', 'type': 'if_statement', 'children': ['243', '256']}; {'id': '243', 'type': 'call', 'children': ['244', '250']}; {'id': '244', 'type': 'attribute', 'children': ['245', '249']}; {'id': '245', 'type': 'call', 'children': ['246', '247']}; {'id': '246', 'type': 'identifier', 'children': [], 'value': 'str'}; {'id': '247', 'type': 'argument_list', 'children': ['248']}; {'id': '248', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '249', 'type': 'identifier', 'children': [], 'value': 'startswith'}; {'id': '250', 'type': 'argument_list', 'children': ['251']}; {'id': '251', 'type': 'attribute', 'children': ['252', '255']}; {'id': '252', 'type': 'attribute', 'children': ['253', '254']}; {'id': '253', 'type': 'identifier', 'children': [], 'value': 'os'}; {'id': '254', 'type': 'identifier', 'children': [], 'value': 'path'}; {'id': '255', 'type': 'identifier', 'children': [], 'value': 'pardir'}; {'id': '256', 'type': 'block', 'children': ['257']}; {'id': '257', 'type': 'expression_statement', 'children': ['258']}; {'id': '258', 'type': 'assignment', 'children': ['259', '260']}; {'id': '259', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '260', 'type': 'call', 'children': ['261', '268']}; {'id': '261', 'type': 'attribute', 'children': ['262', '267']}; {'id': '262', 'type': 'call', 'children': ['263', '266']}; {'id': '263', 'type': 'attribute', 'children': ['264', '265']}; {'id': '264', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '265', 'type': 'identifier', 'children': [], 'value': 'absolute'}; {'id': '266', 'type': 'argument_list', 'children': []}; {'id': '267', 'type': 'identifier', 'children': [], 'value': 'resolve'}; {'id': '268', 'type': 'argument_list', 'children': []}; {'id': '269', 'type': 'if_statement', 'children': ['270', '280']}; {'id': '270', 'type': 'boolean_operator', 'children': ['271', '275'], 'value': 'and'}; {'id': '271', 'type': '()', 'children': ['272']}; {'id': '272', 'type': 'comparison_operator', 'children': ['273', '274'], 'value': '!='}; {'id': '273', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '274', 'type': 'string', 'children': [], 'value': '""'}; {'id': '275', 'type': 'call', 'children': ['276', '279']}; {'id': '276', 'type': 'attribute', 'children': ['277', '278']}; {'id': '277', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '278', 'type': 'identifier', 'children': [], 'value': 'is_absolute'}; {'id': '279', 'type': 'argument_list', 'children': []}; {'id': '280', 'type': 'block', 'children': ['281']}; {'id': '281', 'type': 'expression_statement', 'children': ['282']}; {'id': '282', 'type': 'assignment', 'children': ['283', '284']}; {'id': '283', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '284', 'type': 'call', 'children': ['285', '288']}; {'id': '285', 'type': 'attribute', 'children': ['286', '287']}; {'id': '286', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '287', 'type': 'identifier', 'children': [], 'value': 'relative_to'}; {'id': '288', 'type': 'argument_list', 'children': ['289']}; {'id': '289', 'type': 'attribute', 'children': ['290', '291']}; {'id': '290', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '291', 'type': 'identifier', 'children': [], 'value': 'root'}; {'id': '292', 'type': 'expression_statement', 'children': ['293']}; {'id': '293', 'type': 'assignment', 'children': ['294', '295']}; {'id': '294', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '295', 'type': 'call', 'children': ['296', '297']}; {'id': '296', 'type': 'identifier', 'children': [], 'value': 'Path'}; {'id': '297', 'type': 'argument_list', 'children': ['298', '299']}; {'id': '298', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '299', 'type': 'call', 'children': ['300', '303']}; {'id': '300', 'type': 'attribute', 'children': ['301', '302']}; {'id': '301', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '302', 'type': 'identifier', 'children': [], 'value': 'with_suffix'}; {'id': '303', 'type': 'argument_list', 'children': ['304']}; {'id': '304', 'type': 'string', 'children': [], 'value': '".pyi"'}; {'id': '305', 'type': 'expression_statement', 'children': ['306']}; {'id': '306', 'type': 'call', 'children': ['307', '310']}; {'id': '307', 'type': 'attribute', 'children': ['308', '309']}; {'id': '308', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '309', 'type': 'identifier', 'children': [], 'value': 'append'}; {'id': '310', 'type': 'argument_list', 'children': ['311']}; {'id': '311', 'type': 'tuple', 'children': ['312', '313']}; {'id': '312', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '313', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '314', 'type': 'for_statement', 'children': ['315', '316', '319']}; {'id': '315', 'type': 'identifier', 'children': [], 'value': 'mod_name'}; {'id': '316', 'type': 'attribute', 'children': ['317', '318']}; {'id': '317', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '318', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '319', 'type': 'block', 'children': ['320']}; {'id': '320', 'type': 'expression_statement', 'children': ['321']}; {'id': '321', 'type': 'call', 'children': ['322', '325']}; {'id': '322', 'type': 'attribute', 'children': ['323', '324']}; {'id': '323', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '324', 'type': 'identifier', 'children': [], 'value': 'extend'}; {'id': '325', 'type': 'argument_list', 'children': ['326']}; {'id': '326', 'type': 'call', 'children': ['327', '328']}; {'id': '327', 'type': 'identifier', 'children': [], 'value': 'get_pkg_paths'}; {'id': '328', 'type': 'argument_list', 'children': ['329', '330']}; {'id': '329', 'type': 'identifier', 'children': [], 'value': 'mod_name'}; {'id': '330', 'type': 'identifier', 'children': [], 'value': 'out_dir'}; {'id': '331', 'type': 'for_statement', 'children': ['332', '335', '336']}; {'id': '332', 'type': 'pattern_list', 'children': ['333', '334']}; {'id': '333', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '334', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '335', 'type': 'identifier', 'children': [], 'value': 'modules'}; {'id': '336', 'type': 'block', 'children': ['337', '346', '366', '399']}; {'id': '337', 'type': 'expression_statement', 'children': ['338']}; {'id': '338', 'type': 'call', 'children': ['339', '342']}; {'id': '339', 'type': 'attribute', 'children': ['340', '341']}; {'id': '340', 'type': 'identifier', 'children': [], 'value': '_logger'}; {'id': '341', 'type': 'identifier', 'children': [], 'value': 'info'}; {'id': '342', 'type': 'argument_list', 'children': ['343', '344', '345']}; {'id': '343', 'type': 'string', 'children': [], 'value': '"generating stub for %s to path %s"'}; {'id': '344', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '345', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '346', 'type': 'with_statement', 'children': ['347', '357']}; {'id': '347', 'type': 'with_clause', 'children': ['348']}; {'id': '348', 'type': 'with_item', 'children': ['349']}; {'id': '349', 'type': 'as_pattern', 'children': ['350', '355']}; {'id': '350', 'type': 'call', 'children': ['351', '354']}; {'id': '351', 'type': 'attribute', 'children': ['352', '353']}; {'id': '352', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '353', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '354', 'type': 'argument_list', 'children': []}; {'id': '355', 'type': 'as_pattern_target', 'children': ['356']}; {'id': '356', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '357', 'type': 'block', 'children': ['358']}; {'id': '358', 'type': 'expression_statement', 'children': ['359']}; {'id': '359', 'type': 'assignment', 'children': ['360', '361']}; {'id': '360', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '361', 'type': 'call', 'children': ['362', '365']}; {'id': '362', 'type': 'attribute', 'children': ['363', '364']}; {'id': '363', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '364', 'type': 'identifier', 'children': [], 'value': 'read'}; {'id': '365', 'type': 'argument_list', 'children': []}; {'id': '366', 'type': 'try_statement', 'children': ['367', '380']}; {'id': '367', 'type': 'block', 'children': ['368']}; {'id': '368', 'type': 'expression_statement', 'children': ['369']}; {'id': '369', 'type': 'assignment', 'children': ['370', '371']}; {'id': '370', 'type': 'identifier', 'children': [], 'value': 'stub'}; {'id': '371', 'type': 'call', 'children': ['372', '373']}; {'id': '372', 'type': 'identifier', 'children': [], 'value': 'get_stub'}; {'id': '373', 'type': 'argument_list', 'children': ['374', '375']}; {'id': '374', 'type': 'identifier', 'children': [], 'value': 'code'}; {'id': '375', 'type': 'keyword_argument', 'children': ['376', '377']}; {'id': '376', 'type': 'identifier', 'children': [], 'value': 'generic'}; {'id': '377', 'type': 'attribute', 'children': ['378', '379']}; {'id': '378', 'type': 'identifier', 'children': [], 'value': 'arguments'}; {'id': '379', 'type': 'identifier', 'children': [], 'value': 'generic'}; {'id': '380', 'type': 'except_clause', 'children': ['381', '385']}; {'id': '381', 'type': 'as_pattern', 'children': ['382', '383']}; {'id': '382', 'type': 'identifier', 'children': [], 'value': 'Exception'}; {'id': '383', 'type': 'as_pattern_target', 'children': ['384']}; {'id': '384', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '385', 'type': 'block', 'children': ['386', '398']}; {'id': '386', 'type': 'expression_statement', 'children': ['387']}; {'id': '387', 'type': 'call', 'children': ['388', '389']}; {'id': '388', 'type': 'identifier', 'children': [], 'value': 'print'}; {'id': '389', 'type': 'argument_list', 'children': ['390', '391', '392', '393']}; {'id': '390', 'type': 'identifier', 'children': [], 'value': 'source'}; {'id': '391', 'type': 'string', 'children': [], 'value': '"-"'}; {'id': '392', 'type': 'identifier', 'children': [], 'value': 'e'}; {'id': '393', 'type': 'keyword_argument', 'children': ['394', '395']}; {'id': '394', 'type': 'identifier', 'children': [], 'value': 'file'}; {'id': '395', 'type': 'attribute', 'children': ['396', '397']}; {'id': '396', 'type': 'identifier', 'children': [], 'value': 'sys'}; {'id': '397', 'type': 'identifier', 'children': [], 'value': 'stderr'}; {'id': '398', 'type': 'continue_statement', 'children': []}; {'id': '399', 'type': 'if_statement', 'children': ['400', '403']}; {'id': '400', 'type': 'comparison_operator', 'children': ['401', '402'], 'value': '!='}; {'id': '401', 'type': 'identifier', 'children': [], 'value': 'stub'}; {'id': '402', 'type': 'string', 'children': [], 'value': '""'}; {'id': '403', 'type': 'block', 'children': ['404', '425']}; {'id': '404', 'type': 'if_statement', 'children': ['405', '413']}; {'id': '405', 'type': 'not_operator', 'children': ['406']}; {'id': '406', 'type': 'call', 'children': ['407', '412']}; {'id': '407', 'type': 'attribute', 'children': ['408', '411']}; {'id': '408', 'type': 'attribute', 'children': ['409', '410']}; {'id': '409', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '410', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '411', 'type': 'identifier', 'children': [], 'value': 'exists'}; {'id': '412', 'type': 'argument_list', 'children': []}; {'id': '413', 'type': 'block', 'children': ['414']}; {'id': '414', 'type': 'expression_statement', 'children': ['415']}; {'id': '415', 'type': 'call', 'children': ['416', '421']}; {'id': '416', 'type': 'attribute', 'children': ['417', '420']}; {'id': '417', 'type': 'attribute', 'children': ['418', '419']}; {'id': '418', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '419', 'type': 'identifier', 'children': [], 'value': 'parent'}; {'id': '420', 'type': 'identifier', 'children': [], 'value': 'mkdir'}; {'id': '421', 'type': 'argument_list', 'children': ['422']}; {'id': '422', 'type': 'keyword_argument', 'children': ['423', '424']}; {'id': '423', 'type': 'identifier', 'children': [], 'value': 'parents'}; {'id': '424', 'type': 'True', 'children': []}; {'id': '425', 'type': 'with_statement', 'children': ['426', '437', '441']}; {'id': '426', 'type': 'with_clause', 'children': ['427']}; {'id': '427', 'type': 'with_item', 'children': ['428']}; {'id': '428', 'type': 'as_pattern', 'children': ['429', '435']}; {'id': '429', 'type': 'call', 'children': ['430', '433']}; {'id': '430', 'type': 'attribute', 'children': ['431', '432']}; {'id': '431', 'type': 'identifier', 'children': [], 'value': 'destination'}; {'id': '432', 'type': 'identifier', 'children': [], 'value': 'open'}; {'id': '433', 'type': 'argument_list', 'children': ['434']}; {'id': '434', 'type': 'string', 'children': [], 'value': '"w"'}; {'id': '435', 'type': 'as_pattern_target', 'children': ['436']}; {'id': '436', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '437', 'type': 'ERROR', 'children': ['438']}; {'id': '438', 'type': 'attribute', 'children': ['439', '440']}; {'id': '439', 'type': 'identifier', 'children': [], 'value': 'f'}; {'id': '440', 'type': 'identifier', 'children': [], 'value': 'write'}; {'id': '441', 'type': 'block', 'children': [], 'value': ''}
Start the command line interface.