title: Python and logging: best practice with .exe
body: <p>I have a software in Python and I compiled it with pyinstaller.</p>
  
  <p>I would like, if any error occurs, to save the logs. Which do you think is the best practice to do so in an exe by keeping the software fast, portable and smart?</p>