#NEWLINE# def main( dry_run = True ) : #NEWLINE# #INDENT# for user in find_inactive_users_with_no_inactivity_email_sent_or_queued ( ) : #NEWLINE# #INDENT# if dry_run : #NEWLINE# #INDENT# logger . warn ( 'Dry run mode' ) #NEWLINE# #UNINDENT# logger . warn ( 'Email of type no_login queued to {0}' . format ( user . username ) ) #NEWLINE# if ( not dry_run ) : #NEWLINE# #INDENT# with TokuTransaction ( ) : #NEWLINE# #INDENT# mails . queue_mail ( to_addr = user . username , mail = mails . NO_LOGIN , send_at = datetime . utcnow ( ) , user = user , fullname = user . fullname )