{"record":{"id":"2c7a787d8b30fbc0","repo":"AlexxIT/go2rtc","slug":"wyze-probe-w","errorCode":null,"errorMessage":"wyze: probe: %w","messagePattern":"wyze: probe: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/wyze/producer.go","lineNumber":179,"sourceCode":"\t\t}\n\t}\n}\n\nfunc probe(client *Client, quality byte) ([]*core.Media, error) {\n\tclient.SetResolution(quality)\n\tclient.SetDeadline(time.Now().Add(core.ProbeTimeout))\n\n\tvar vcodec, acodec *core.Codec\n\tvar tutkAudioCodec byte\n\n\tfor {\n\t\tif client.verbose {\n\t\t\tfmt.Println(\"[Wyze] Probing for codecs...\")\n\t\t}\n\n\t\tpkt, err := client.ReadPacket()\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"wyze: probe: %w\", err)\n\t\t}\n\t\tif pkt == nil || len(pkt.Payload) < 5 {\n\t\t\tcontinue\n\t\t}\n\n\t\tswitch pkt.Codec {\n\t\tcase tutk.CodecH264:\n\t\t\tif vcodec == nil {\n\t\t\t\tbuf := annexb.EncodeToAVCC(pkt.Payload)\n\t\t\t\tif len(buf) >= 5 && h264.NALUType(buf) == h264.NALUTypeSPS {\n\t\t\t\t\tvcodec = h264.AVCCToCodec(buf)\n\t\t\t\t}\n\t\t\t}\n\t\tcase tutk.CodecH265:\n\t\t\tif vcodec == nil {\n\t\t\t\tbuf := annexb.EncodeToAVCC(pkt.Payload)\n\t\t\t\tif len(buf) >= 5 && h265.NALUType(buf) == h265.NALUTypeVPS {\n\t\t\t\t\tvcodec = h265.AVCCToCodec(buf)","sourceCodeStart":161,"sourceCodeEnd":197,"githubUrl":"https://github.com/AlexxIT/go2rtc/blob/c245815e75e2a5fd60b4290f12bfc04e55a984d3/pkg/wyze/producer.go#L161-L197","documentation":"During producer probing, client.ReadPacket failed (network error, auth problem, or stream ended) before all codecs could be discovered. Wraps the read error; NewProducer therefore cannot be created. Note that nil/short payloads are skipped, only hard read errors raise this.","triggerScenarios":"Thrown at pkg/wyze/producer.go:179 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the camera is online and reachable for P2P","Retry NewProducer; transient P2P setup failures are common","Check credentials used for the P2P session"],"exampleFix":null,"handlingStrategy":"retry","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"}