{"record":{"id":"b5be445472e75d37","repo":"sipeed/picoclaw","slug":"no-media-store-available","errorCode":null,"errorMessage":"no media store available","messagePattern":"no media store available","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/channels/wecom/media.go","lineNumber":281,"sourceCode":"\tif ext == \"\" && contentType != \"\" {\n\t\tif exts, err := mime.ExtensionsByType(contentType); err == nil && len(exts) > 0 {\n\t\t\text = strings.ToLower(exts[0])\n\t\t}\n\t}\n\n\tif filepath.Ext(filename) == \"\" && ext != \"\" {\n\t\tfilename += ext\n\t}\n\treturn filename, contentType\n}\n\nfunc (c *WeComChannel) storeRemoteMedia(\n\tctx context.Context,\n\tscope, msgID, resourceURL, aesKey, fallbackExt string,\n) (string, error) {\n\tstore := c.GetMediaStore()\n\tif store == nil {\n\t\treturn \"\", fmt.Errorf(\"no media store available\")\n\t}\n\n\treq, err := http.NewRequestWithContext(ctx, http.MethodGet, resourceURL, nil)\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"create request: %w\", err)\n\t}\n\tresp, err := c.mediaClient.Do(req)\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"download media: %w\", err)\n\t}\n\tdefer resp.Body.Close()\n\tif resp.StatusCode != http.StatusOK {\n\t\treturn \"\", fmt.Errorf(\"download media returned HTTP %d\", resp.StatusCode)\n\t}\n\n\tdata, err := io.ReadAll(io.LimitReader(resp.Body, wecomOutboundMediaMaxBytes+1))\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"read media: %w\", err)","sourceCodeStart":263,"sourceCodeEnd":299,"githubUrl":"https://github.com/sipeed/picoclaw/blob/49183d7e8daed0dba89ddbb6fcb60089401d9680/pkg/channels/wecom/media.go#L263-L299","documentation":"Error \"no media store available\" thrown in sipeed/picoclaw.","triggerScenarios":"Thrown at pkg/channels/wecom/media.go:281 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":"49183d7e8daed0dba89ddbb6fcb60089401d9680","analyzedAt":"2026-08-15T21:55:41.315Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}