{"record":{"id":"5068299c75c7e6df","repo":"redis/go-redis","slug":"redis-expected-but-got-line-q","errorCode":null,"errorMessage":"redis: expected '*', but got line %q","messagePattern":"redis: expected '\\*', but got line %q","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"redis.go","lineNumber":2051,"sourceCode":"\t\t\t}\n\t\t}\n\t}\n\n\t// To be sure there are no buffered push notifications, we process them before reading the reply\n\tif err := c.processPendingPushNotificationWithReader(ctx, cn, rd); err != nil {\n\t\tinternal.Logger.Printf(ctx, \"push: error processing pending notifications before reading reply: %v\", err)\n\t}\n\t// Parse number of replies.\n\tline, err := rd.ReadLine()\n\tif err != nil {\n\t\tif err == Nil {\n\t\t\terr = TxFailedErr\n\t\t}\n\t\treturn err\n\t}\n\n\tif line[0] != proto.RespArray {\n\t\treturn fmt.Errorf(\"redis: expected '*', but got line %q\", line)\n\t}\n\n\treturn nil\n}\n\n//------------------------------------------------------------------------------\n\n// Client is a Redis client representing a pool of zero or more underlying connections.\n// It's safe for concurrent use by multiple goroutines.\n//\n// Client creates and frees connections automatically; it also maintains a free pool\n// of idle connections. You can control the pool size with Config.PoolSize option.\ntype Client struct {\n\t*baseClient\n\tcmdable\n\n\t// cscLifecycleOwner keeps the canonical Client wrapper (the one whose GC\n\t// cleanup owns the drainer) reachable while a WithTimeout clone can still","sourceCodeStart":2033,"sourceCodeEnd":2069,"githubUrl":"https://github.com/redis/go-redis/blob/c5cad058c72f58370553b48566302303cf8a2e89/redis.go#L2033-L2069","documentation":"Error \"redis: expected '*', but got line %q\" thrown in redis/go-redis.","triggerScenarios":"Thrown at redis.go:2051 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":"c5cad058c72f58370553b48566302303cf8a2e89","analyzedAt":"2026-09-01T06:50:53.388Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}