{"record":{"id":"65cd71440e183f83","repo":"inancgumus/learngo","slug":"wrong-input-v-line-d-65cd71","errorCode":null,"errorMessage":"wrong input: %v (line #%d)","messagePattern":"wrong input: (.+?) \\(line #(.+?)\\)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"26-pointers/05-log-parser-pointers-vs-values/parser.go","lineNumber":48,"sourceCode":"\tp.lines++\n\n\tfields := strings.Fields(line)\n\tif len(fields) != 2 {\n\t\tp.lerr = fmt.Errorf(\"wrong input: %v (line #%d)\", fields, p.lines)\n\t\treturn\n\t}\n\n\tvar err error\n\n\tr.domain = fields[0]","sourceCodeStart":30,"sourceCodeEnd":66,"githubUrl":"https://github.com/inancgumus/learngo/blob/3c475a78e54336c6255e925ff66b8ef4da6a2ae7/26-pointers/05-log-parser-pointers-vs-values/parser.go#L30-L66","documentation":"Pointer-based parse() returning *parser from newParser(): rejects lines whose field count is not exactly two; the error is recorded in p.lerr, freezing the parser so later lines are ignored. The line counter p.lines reflects the current (offending) line.","triggerScenarios":"Thrown at 26-pointers/05-log-parser-pointers-vs-values/parser.go:48 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect p.lerr after the parse loop and report the bad line.","Pre-filter the log to remove lines lacking exactly two columns.","Fix the offending line in the input file."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3c475a78e54336c6255e925ff66b8ef4da6a2ae7","analyzedAt":"2026-09-02T10:14:38.492Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-09T16:17:10.729Z"}