Using something like,
for name, mod in sys.modules.iteritems()
if hasattr(mod, '__file__'))
we can map files to modules, and use that to match lines in tracebacks against a 'blacklist' of module globs to hide. Use internally for traceback cleaning and maybe expose publicly if it seems useful.