1 2 3 4 5 6 7
import logging try: function() except Exception as e: logging.error('Error occurred: %s', type(e), e) # [logging-too-many-args] raise