Logger Setup In Python A Function