What’s the difference between __str__() and __repr__()?

The purpose of __str__() is to return a string that is human readable and can be printed.

The purpose of __repr__() is to return a string that is a valid Python expression i.e. if eval()-ed it wont return an error.