Add logger, Exception

Hi JC, 
Sounds really good.
Thanks

Hi Pablo,
- I added a logger instread of stderr and stdout
- I added a custom Exception
- I modified /usr/bin/pyton ==> /usr/bin/env python