Module Import alias Import alias Import alias ImportFrom alias ImportFrom alias ImportFrom alias alias alias alias alias alias Import alias Import alias Import alias Assign NameStore Str Assign NameStore Call NameLoad NameLoad FunctionDef arguments args NameParam defaults body If CompareNotIn Str AttributeLoad NameLoad attr body Return Expr Call AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Str NameLoad keyword NameLoad decorator_list If UnaryOpNot AttributeLoad NameLoad attr body Import alias ImportFrom alias Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str Assign NameStore Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad Num NameLoad NameLoad body If CompareIsNot NameLoad NameLoad body Assign NameStore Call AttributeLoad Str attr Call NameLoad GeneratorExp Call AttributeLoad NameLoad attr comprehension NameStore NameLoad If BoolOpAnd CompareIsNot NameLoad NameLoad UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore Call AttributeLoad Str attr GeneratorExp Call AttributeLoad NameLoad attr comprehension NameStore NameLoad If UnaryOpNot Call NameLoad NameLoad NameLoad body Assign NameStore Call AttributeLoad Str attr NameLoad If Call NameLoad NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr FunctionDef arguments args defaults body If CompareIsNot NameLoad NameLoad body Return NameLoad Assign NameStore Call AttributeLoad NameLoad attr Return SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body FunctionDef arguments args defaults vararg kwarg body If BoolOpAnd NameLoad CompareEq AttributeLoad NameLoad attr Str body Assign NameStore Call AttributeLoad NameLoad attr orelse Assign NameStore Call NameLoad Call NameLoad NameLoad NameLoad If BoolOpAnd UnaryOpNot NameLoad CompareNotEq AttributeLoad NameLoad attr Str body Return NameLoad Assign NameStore AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str Call NameLoad Assign SubscriptStore NameLoad Index Str Call NameLoad NameLoad If CompareIsNot NameLoad NameLoad body Assign SubscriptStore NameLoad Index Str NameLoad Return NameLoad decorator_list Assign AttributeStore NameLoad attr NameLoad Return Call NameLoad NameLoad NameLoad decorator_list Return NameLoad decorator_list FunctionDef arguments args defaults body TryExcept body If BoolOpAnd CompareIs AttributeLoad NameLoad attr NameLoad CompareEq AttributeLoad NameLoad attr Str body Expr Call NameLoad Num Str orelse If CompareEq AttributeLoad NameLoad attr Str body Assign NameStore AttributeLoad NameLoad attr orelse Assign NameStore AttributeLoad NameLoad attr If CompareNotIn Str NameLoad body Expr Call NameLoad Num Str If CompareNotIn Str NameLoad body Expr Call NameLoad Num Str Assign NameStore Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr keyword Call NameLoad SubscriptLoad NameLoad Index Str keyword Call NameLoad SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr If CompareIs NameLoad NameLoad body Assign NameStore NameLoad orelse Assign NameStore Call AttributeLoad Call AttributeLoad SubscriptLoad NameLoad Index Num attr attr NameLoad Str Return Call NameLoad Dict Str NameLoad handlers ExceptHandler body Expr Call AttributeLoad NameLoad attr Raise decorator_list Call AttributeLoad NameLoad attr Str keyword ListLoad Str Str Str Call NameLoad keyword Str keyword ListLoad Str Str If CompareEq NameLoad Str body Expr Call NameLoad Str Expr Call AttributeLoad NameLoad attr keyword NameLoad orelse Expr Call NameLoad Str
N/A N/A functools N/A os N/A os.path datetime timedelta functools update_wrapper flask Flask abort current_app jsonify make_response request N/A psycopg2 N/A rollbar N/A dbcreds N/A QUERY_FORMAT 
SELECT elect_div FROM com20111216_elb_region WHERE
    ST_Contains(geom, ST_SetSRID(ST_Point({longitude:f}, {latitude:f}), 4283))
 N/A app N/A Flask __name__ setup_rollbar N/A N/A environment N/A N/A N/A N/A ROLLBAR_TOKEN N/A os environ N/A N/A N/A N/A N/A rollbar init N/A N/A os environ N/A ROLLBAR_TOKEN environment allow_logging_basic_config False N/A N/A N/A N/A app debug N/A N/A logging logging.handlers RotatingFileHandler N/A logfile N/A N/A N/A os path expanduser ~/logs/division.log N/A file_handler N/A RotatingFileHandler logfile N/A N/A N/A file_handler setLevel N/A logging INFO N/A N/A N/A N/A app logger addHandler file_handler crossdomain N/A N/A origin methods headers max_age attach_to_all automatic_options N/A None None None 21600 True True N/A N/A N/A methods None N/A N/A methods N/A N/A ,  join N/A sorted N/A N/A N/A x upper N/A x methods N/A N/A N/A headers None N/A N/A isinstance headers str N/A N/A headers N/A N/A ,  join N/A N/A N/A x upper N/A x headers N/A N/A N/A isinstance origin str N/A N/A origin N/A N/A ,  join origin N/A N/A isinstance max_age timedelta N/A N/A max_age N/A N/A max_age total_seconds get_methods N/A N/A N/A N/A N/A N/A methods None N/A N/A methods N/A options_resp N/A N/A current_app make_default_options_response N/A N/A N/A options_resp headers N/A allow N/A decorator N/A N/A f N/A N/A wrapped_function N/A N/A N/A args kwargs N/A N/A N/A automatic_options N/A N/A request method OPTIONS N/A N/A resp N/A N/A current_app make_default_options_response N/A N/A resp N/A make_response N/A f args kwargs N/A N/A N/A attach_to_all N/A N/A request method OPTIONS N/A N/A resp N/A h N/A resp headers N/A N/A h N/A Access-Control-Allow-Origin origin N/A N/A h N/A Access-Control-Allow-Methods N/A get_methods N/A N/A h N/A Access-Control-Max-Age N/A str max_age N/A N/A headers None N/A N/A N/A h N/A Access-Control-Allow-Headers headers N/A resp N/A N/A N/A f provide_automatic_options False N/A N/A update_wrapper wrapped_function f N/A N/A decorator N/A division_lookup N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A request json None N/A N/A request method POST N/A N/A N/A abort 400 Must provide JSON (did you set Content-type?) N/A N/A N/A N/A request method POST N/A N/A args N/A request json N/A N/A args N/A request args N/A N/A latitude args N/A N/A N/A abort 400 Most provide latitude and longitude N/A N/A longitude args N/A N/A N/A abort 400 Most provide latitude and longitude N/A conn N/A N/A psycopg2 connect host N/A dbcreds HOSTNAME database N/A dbcreds DATABASE user N/A dbcreds USERNAME password N/A dbcreds PASSWORD N/A cursor N/A N/A conn cursor N/A N/A N/A cursor execute N/A N/A QUERY_FORMAT format latitude N/A float N/A args N/A latitude longitude N/A float N/A args N/A longitude N/A result N/A N/A cursor fetchone N/A N/A result None N/A N/A name None N/A N/A name N/A N/A N/A N/A N/A result N/A 0 lower translate None  -' N/A N/A jsonify N/A division name N/A N/A N/A N/A N/A N/A rollbar report_exc_info N/A N/A N/A N/A app route /division methods N/A GET POST OPTIONS N/A crossdomain origin * headers N/A Content-Type X-Requested-With N/A N/A __name__ __main__ N/A N/A N/A setup_rollbar debug N/A N/A N/A app run debug True N/A N/A N/A setup_rollbar production