class ElasticAPM::Stacktrace

def build_frame(config, line, type)

rubocop:disable Metrics/AbcSize, Metrics/MethodLength
def build_frame(config, line, type)
  abs_path, lineno, function, _module_name = parse_line(line)
  library_frame = !(abs_path && abs_path.start_with?(config.root_path))
  frame = Frame.new
  frame.abs_path = abs_path
  frame.filename = strip_load_path(abs_path)
  frame.function = function
  frame.lineno = lineno.to_i
  frame.library_frame = library_frame
  line_count = context_lines_for(config, type, library_frame: library_frame)
  frame.build_context line_count
  frame
end