use python logging module for messages instead of print()

Ah ha! This impacts my previous remark. Let me think on this...