title: How to remove seconds from Python datetime object?
body: <p>I have a python datetime object that I want to display on a website, however the time shows in the format hh:mm:ss and I want to display it in the format hh:mm.</p>
  
  <p>I have tried using the replace method as per the following:</p>
  
  <pre><code>message.timestamp.replace(second='0', microsecond=0)
  </code></pre>
  
  <p>However this doesn't get red of the seconds it just replaces it with hh:mm:00</p>