Weekly Post 57

Posted on January 25, 2025

TWIL

Raising exceptions in the code are a great way to signal that something unexpected or wrong happened in the code. But in doing so there is also the possibility of masking the error with the message you pass in, depending on the level of detail it can be helpful or unhelpful. When the exception messages are unhelpful it is useful have the stack trace.

import traceback

traceback.print_exec()
  

The traceback.print_exec() will print the full trackback.

Books read

  • The leader without a title by Robin Sharma
  • Discover your destiny by Robin Sharma

Through the lens

ttl_week_57