#NEWLINE# def main( ) : #NEWLINE# #INDENT# args = parser . parse_args ( ) #NEWLINE# request = Request . blank ( '/' ) #NEWLINE# env = paster . bootstrap ( args . config_uri , request = request ) #NEWLINE# request . root = env [ 'root' ] #NEWLINE# engine = db . make_engine ( request . registry . settings ) #NEWLINE# Session . configure ( bind = engine ) #NEWLINE# APIBase . query = Session . query_property ( ) #NEWLINE# if ( 'DEBUG_QUERY' in os . environ ) : #NEWLINE# #INDENT# logging . getLogger ( 'sqlalchemy.engine' ) . setLevel ( logging . INFO ) #NEWLINE# #UNINDENT# migrate_annotations ( request . legacy_es ) #NEWLINE# print ( '' ) #NEWLINE# delete_nonexisting_annotations ( request . legacy_es )