def simple_traceback(limit):
 stack_trace = traceback.extract_stack(limit=limit)[:(-2)]
 return '\n'.join(('-'.join((os.path.basename(filename), function_name, str(line_number))) for (filename, line_number, function_name, text) in stack_trace))

def simple_traceback ( limit ) : stack_trace = traceback . extract_stack ( limit = limit ) [ : ( - 2 ) ] return '\n' . join ( ( '-' . join ( ( os . path . basename ( filename ) , function_name , str ( line_number ) ) ) for ( filename , line_number , function_name , text ) in stack_trace ) )
generate a pared-down traceback thats human readable but small .