Skip to content

Instantly share code, notes, and snippets.

@marioidival
Created July 22, 2013 18:13
Show Gist options
  • Save marioidival/6056154 to your computer and use it in GitHub Desktop.
Save marioidival/6056154 to your computer and use it in GitHub Desktop.
def dict_except(func, excp, dici, key):
try:
rv = func()
return rv
except excp as e:
if key in dici:
dici[n] += "-- %s" % str(e)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment