code: func genStacktrace(err error, skip int) errors.StackTrace {
  	var stack errors.StackTrace
  	errWithStack := errors.WithStack(err)
  	stack = errWithStack.(stackTracer).StackTrace()
  	skip++
  
  	// if it is recovering from a panic() call,
  	// reset the stack trace at that point
  	for index, frame := range stack {
  		file := fmt.Sprintf("%s", frame)
  		if file == "panic.go" {
  			skip = index + 1
  			break
  		}
  	}
  
  	return stack[skip:]
  }
docs: // It generates a brand new stack trace given an error and
  // the number of frames that should be skipped,
  // from innermost to outermost frames.