{"record":{"id":"2ff33ddc6c181a39","repo":"AlexxIT/go2rtc","slug":"reply","errorCode":null,"errorMessage":"${reply}","messagePattern":"\\$\\{reply\\}","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/roborock/client.go","lineNumber":377,"sourceCode":"}\n\nfunc (c *Client) EnableHomesecVoice(enable bool) error {\n\tif enable {\n\t\treturn c.Request(\"enable_homesec_voice\", `{\"enable\":true}`)\n\t} else {\n\t\treturn c.Request(\"enable_homesec_voice\", `{\"enable\":false}`)\n\t}\n}\n\nfunc (c *Client) Request(method string, args any) (err error) {\n\tvar reply string\n\n\tif err = c.iot.Call(method, args, &reply); err != nil {\n\t\treturn\n\t}\n\n\tif reply != `[\"ok\"]` {\n\t\treturn errors.New(reply)\n\t}\n\n\treturn\n}\n","sourceCodeStart":359,"sourceCodeEnd":382,"githubUrl":"https://github.com/AlexxIT/go2rtc/blob/c245815e75e2a5fd60b4290f12bfc04e55a984d3/pkg/roborock/client.go#L359-L382","documentation":"Roborock Request guard: the IoT RPC call succeeded transport-wise, but the device's reply string was not '[\"ok\"]' — the raw reply is returned as the error. Whatever the device answered (error text, 'ERROR', etc.) becomes the message, so the device explicitly rejected the request.","triggerScenarios":"Thrown at pkg/roborock/client.go:377 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Read the raw device reply in the error for the concrete reason","Verify device state — many commands fail when a stream is already active or the feature is unsupported","Retry after re-establishing the IoT session if the reply is garbled"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c245815e75e2a5fd60b4290f12bfc04e55a984d3","analyzedAt":"2026-09-07T11:47:02.965Z","contentChangedAt":"2026-09-07T11:47:02.965Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}