{"record":{"id":"592b5a652aaafd13","repo":"go-delve/delve","slug":"invalid-interface-q","errorCode":null,"errorMessage":"invalid interface %q","messagePattern":"invalid interface %q","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/proc/breakpoints.go","lineNumber":752,"sourceCode":"\t\treturn nil, fmt.Errorf(\"can not watch %q\", expr)\n\t}\n\tif xv.Unreadable != nil {\n\t\treturn nil, fmt.Errorf(\"expression %q is unreadable: %v\", expr, xv.Unreadable)\n\t}\n\tif xv.Kind == reflect.UnsafePointer || xv.Kind == reflect.Invalid {\n\t\treturn nil, fmt.Errorf(\"can not watch variable of type %s\", xv.Kind.String())\n\t}\n\n\t// Special handling for interface types\n\tif xv.Kind == reflect.Interface {\n\t\t// For interfaces, we want to watch the data they point to\n\t\t// Read the interface to get the data pointer\n\t\t_, data, _ := xv.readInterface()\n\t\tif xv.Unreadable != nil {\n\t\t\treturn nil, fmt.Errorf(\"error reading interface %q: %v\", expr, xv.Unreadable)\n\t\t}\n\t\tif data == nil {\n\t\t\treturn nil, fmt.Errorf(\"invalid interface %q\", expr)\n\t\t}\n\n\t\t// Use the data field as our watch target\n\t\txv = data\n\t\texpr = expr + \" (interface data)\"\n\t}\n\n\tsz := xv.DwarfType.Size()\n\tif sz <= 0 || sz > int64(t.BinInfo().Arch.PtrSize()) {\n\t\t//TODO(aarzilli): it is reasonable to expect to be able to watch string\n\t\t//variables and we could support it by watching certain member fields here.\n\t\treturn nil, fmt.Errorf(\"can not watch variable of type %s\", xv.DwarfType.String())\n\t}\n\n\tstackWatch := scope.g != nil && !scope.g.SystemStack && xv.Addr >= scope.g.stack.lo && xv.Addr < scope.g.stack.hi\n\n\tif stackWatch && wtype&WatchRead != 0 {\n\t\t// In theory this would work except for the fact that the runtime will","sourceCodeStart":734,"sourceCodeEnd":770,"githubUrl":"https://github.com/go-delve/delve/blob/a23773e6c31361e43246bc43a424ee009679b174/pkg/proc/breakpoints.go#L734-L770","documentation":"Error \"invalid interface %q\" thrown in go-delve/delve.","triggerScenarios":"Thrown at pkg/proc/breakpoints.go:752 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a23773e6c31361e43246bc43a424ee009679b174","analyzedAt":"2026-08-31T15:12:45.221Z","schemaVersion":2},"datasetVersion":"2026-08-31T19:17:28.585Z"}