pypackage: consistent logging + py3 support