from . import imap def on_email(content): print('on_email:', content) def main(): imap.main(on_email)