import in try/except in examples is pointless and broken?
I don't understand this idiom:
try: import something except ImportError: import traceback traceback.print_exc() sys.exit(1)
Why not just do the import and let python print the exception and exit? I can't figure out any use-case where explicitly catching and printing the exception is preferable. In fact, it seems the only effect this has is to break various tools which rely on normal python exception handling, like "python --pdb ..." or ipython's prettified exception printing. I really can't figure out why all the examples use this pattern....