{"record":{"id":"477806acea5e996f","repo":"gastownhall/beads","slug":"proxied-server-provider-t-does-not-offer-the-batc-477806","errorCode":null,"errorMessage":"proxied-server provider %T does not offer the batch-create surface","messagePattern":"proxied-server provider %T does not offer the batch-create surface","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cmd/bd/create_proxied_server.go","lineNumber":277,"sourceCode":"\tif err != nil {\n\t\treturn HandleError(\"%v\", err)\n\t}\n\tresult, err := creator.CreateBatch(ctx, request)\n\tif err != nil {\n\t\treturn HandleError(\"creating issues from markdown: %v\", err)\n\t}\n\treturn reportMarkdownBatch(result.Issues, in)\n}\n\n// proxiedBatchCreator reaches the batch-create role through the provider's own\n// capability accessor, which is where each decorator adds its layer.\nfunc proxiedBatchCreator() (issueops.BatchCreator, error) {\n\tif uowProvider == nil {\n\t\treturn nil, errors.New(\"proxied-server UOW provider not initialized\")\n\t}\n\tsrc, ok := uowProvider.(uow.BatchCreatorSource)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"proxied-server provider %T does not offer the batch-create surface\", uowProvider)\n\t}\n\treturn src.BatchCreator()\n}\n\nfunc runCreateProxiedGraph(_ *cobra.Command, ctx context.Context, in createInput) error {\n\tdata, err := os.ReadFile(in.graphFile) // #nosec G304 -- user-provided path is intentional\n\tif err != nil {\n\t\treturn HandleError(\"reading graph plan: %v\", err)\n\t}\n\tif unknown := detectUnknownGraphFields(data); len(unknown) > 0 {\n\t\twarnUnknownGraphFields(os.Stderr, unknown)\n\t}\n\n\tvar plan GraphApplyPlan\n\tif err := json.Unmarshal(data, &plan); err != nil {\n\t\treturn HandleError(\"parsing graph plan: %v\", err)\n\t}\n","sourceCodeStart":259,"sourceCodeEnd":295,"githubUrl":"https://github.com/gastownhall/beads/blob/71377f276968b452ee607177637970a4ff888584/cmd/bd/create_proxied_server.go#L259-L295","documentation":" proxiedBatchCreator checks that the proxied-server UOW provider implements uow.BatchCreatorSource; if the concrete provider type lacks BatchCreator(), creation fails fast with the provider's dynamic type in the message. This is a capability/wiring mismatch, not user input.","triggerScenarios":"runCreateProxiedMarkdown calls proxiedBatchCreator while uowProvider is wired to a provider type that does not implement uow.BatchCreatorSource (and uowProvider is non-nil, or the nil case surfaced earlier).","commonSituations":"Version skew between the bd client and server (older provider without batch-create); custom or mock provider injected in tests; build with mismatched internal interfaces.","solutions":["Update client and server to matching versions","Check which provider type is wired into uowProvider (shown in %T)","Use the non-batch proxied create path if the provider is older","Fix the provider implementation to expose BatchCreator()"],"exampleFix":"// before: provider missing the surface\nuowProvider = legacyProvider{} // no BatchCreator()\n// after: wire a provider implementing uow.BatchCreatorSource\nuowProvider = newBatchCapableProvider()","handlingStrategy":"type-guard","validationCode":null,"typeGuard":"src, ok := uowProvider.(uow.BatchCreatorSource)\nif !ok {\n    return fmt.Errorf(\"provider %T lacks batch-create; falling back\", uowProvider)\n}","tryCatchPattern":"bc, err := proxiedBatchCreator()\nif err != nil {\n    // fall back to per-issue proxied create instead of failing hard\n    return runProxiedCreateOneByOne(ctx, in)\n}","preventionTips":["Pin matching client/server versions","Assert provider capabilities at startup, not at first use","In tests, use provider doubles that implement all production interfaces"],"tags":["proxied-server","interface-mismatch","batch-create","capability"],"backgroundTag":"provider-does-not-implement-interface","analyzedSha":"71377f276968b452ee607177637970a4ff888584","analyzedAt":"2026-08-30T18:55:39.744Z","schemaVersion":2},"datasetVersion":"2026-08-30T23:17:21.991Z"}