{"record":{"id":"95f535f5d8f7e322","repo":"go-delve/delve","slug":"interface-type-not-yet-supported-by-ebpf-tracing","errorCode":null,"errorMessage":"interface type not yet supported by ebpf tracing","messagePattern":"interface type not yet supported by ebpf tracing","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"pkg/proc/internal/ebpf/helpers.go","lineNumber":569,"sourceCode":"\t\tiparam.Kind = reflect.Uintptr\n\t\tiparam.RealType = &godwarf.UintType{BasicType: godwarf.BasicType{CommonType: godwarf.CommonType{ByteSize: 8, ReflectKind: reflect.Uintptr}}}\n\tcase reflect.String:\n\t\tif len(iparam.Data) >= 16 {\n\t\t\tiparam.Base = fakeAddressUnresolv + uint64(valSize)\n\t\t\tiparam.Len = int64(binary.LittleEndian.Uint64(iparam.Data[8:16]))\n\t\t}\n\t\tiparam.RealType = &godwarf.StringType{\n\t\t\tStructType: godwarf.StructType{\n\t\t\t\tCommonType: godwarf.CommonType{ByteSize: 16, ReflectKind: reflect.String},\n\t\t\t\tKind:       \"struct\",\n\t\t\t},\n\t\t}\n\tcase reflect.Map:\n\t\tiparam.Unreadable = fmt.Errorf(\"map type not yet supported by ebpf tracing\")\n\tcase reflect.Chan:\n\t\tiparam.Unreadable = fmt.Errorf(\"chan type not yet supported by ebpf tracing\")\n\tcase reflect.Interface:\n\t\tiparam.Unreadable = fmt.Errorf(\"interface type not yet supported by ebpf tracing\")\n\tcase reflect.Func:\n\t\tiparam.Unreadable = fmt.Errorf(\"func type not yet supported by ebpf tracing\")\n\tcase reflect.Struct:\n\t\tiparam.Unreadable = fmt.Errorf(\"struct type not yet supported by ebpf tracing without DWARF type\")\n\tcase reflect.Array:\n\t\tiparam.Unreadable = fmt.Errorf(\"array type not yet supported by ebpf tracing without DWARF type\")\n\tdefault:\n\t\tiparam.Unreadable = fmt.Errorf(\"unrecognized reflect.Kind %d from eBPF\", iparam.Kind)\n\t}\n}\n\nfunc createFunctionParameterList(entry uint64, goidOffset int64, args []UProbeArgMap, isret bool) function_parameter_list_t {\n\tvar params function_parameter_list_t\n\tparams.goid_offset = uint32(goidOffset)\n\tparams.fn_addr = entry\n\tparams.is_ret = isret\n\tparams.n_parameters = 0\n\tparams.n_ret_parameters = 0","sourceCodeStart":551,"sourceCodeEnd":587,"githubUrl":"https://github.com/go-delve/delve/blob/a23773e6c31361e43246bc43a424ee009679b174/pkg/proc/internal/ebpf/helpers.go#L551-L587","documentation":"When a traced argument resolves only to reflect.Interface via the eBPF UProbeArgMap and no DWARF type is available, synthesizeTypeFromKind marks the parameter Unreadable: an interface's dynamic type and value cannot be recovered from the raw register/stack bytes captured by the uprobe. The event still completes; this argument is just flagged unreadable.","triggerScenarios":"Tracing a function whose parameter is an interface type (e.g. error, io.Reader, any) through the eBPF backend when the DWARF type lookup failed or only the Kind was recorded, so handleParamEvent reaches 'case reflect.Interface'.","commonSituations":"'dlv trace --ebpf' on functions accepting io.Writer/error/any parameters; tracing interface-heavy APIs; running with binaries lacking complete DWARF info.","solutions":["Trace a concrete-typed wrapper function instead of the interface-typed entry point.","Ensure the binary keeps full DWARF debug info so the argument's concrete DWARF type can be resolved upstream of synthesizeTypeFromKind.","Handle Unreadable gracefully and display remaining arguments of the event.","Check delve's eBPF supported-type list (int/uint/bool/float/complex/string/pointer/slice) before choosing arguments to trace."],"exampleFix":"// before\ndlv trace --ebpf logger.Log   // Log(msg string, err error)\n// err param shows: interface type not yet supported by ebpf tracing\n// after\n// trace the concrete-typed variant:\nfunc (l *Logger) LogErrString(s string) { l.Log(s, errors.New(s)) }\ndlv trace --ebpf logger.LogErrString","handlingStrategy":"type-guard","validationCode":"// Detect interface-typed parameters before tracing:\nfunc hasInterfaceParam(types []godwarf.Type) bool {\n\tfor _, t := range types {\n\t\tif t != nil && t.Common().ReflectKind == reflect.Interface {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}","typeGuard":"func isInterfaceParam(p *RawUProbeParam) bool {\n\treturn p != nil && p.Kind == reflect.Interface\n}","tryCatchPattern":"if p.Unreadable != nil && strings.Contains(p.Unreadable.Error(), \"interface type not yet supported\") {\n\tfmt.Printf(\"param %s: <interface value unavailable via eBPF>\\n\", p.Name)\n\tcontinue\n}","preventionTips":["Trace concrete-typed functions rather than interface-parameter entry points.","Verify DWARF info is present so the argument resolves with a full type.","Always test Unreadable on trace-event parameters before use.","Consult the documented eBPF supported-type list when choosing trace targets."],"tags":["ebpf","tracing","unsupported-type","interface"],"backgroundTag":"ebpf-unsupported-arg-type","analyzedSha":"a23773e6c31361e43246bc43a424ee009679b174","analyzedAt":"2026-08-31T15:12:45.221Z","schemaVersion":2},"datasetVersion":"2026-08-31T19:17:28.585Z"}