{"record":{"id":"01f56a0ea61c3a3f","repo":"lionsoul2014/ip2region","slug":"failed-to-create-v4-searcher-pool-w","errorCode":null,"errorMessage":"failed to create v4 searcher pool: %w","messagePattern":"failed to create v4 searcher pool: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"binding/golang/service/ip2region.go","lineNumber":58,"sourceCode":"\n\t// check and init the v4 pool or in-memory searcher\n\tvar v4Pool *SearcherPool\n\tvar v4InMemSearcher *xdb.Searcher\n\tif v4Config == nil {\n\t\t// with IPv4 disabled ?\n\t\tv4Pool = nil\n\t\tv4InMemSearcher = nil\n\t} else if v4Config.cachePolicy == BufferCache {\n\t\tv4Pool = nil\n\t\tv4InMemSearcher, err = xdb.NewWithBuffer(v4Config.ipVersion, v4Config.cBuffer)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to create v4 in-memory searcher: %w\", err)\n\t\t}\n\t} else {\n\t\tv4InMemSearcher = nil\n\t\tv4Pool, err = NewSearcherPool(v4Config)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to create v4 searcher pool: %w\", err)\n\t\t}\n\t}\n\n\t// check and init the v6 pool or in-memory searcher\n\tvar v6Pool *SearcherPool\n\tvar v6InMemSearcher *xdb.Searcher\n\tif v6Config == nil {\n\t\tv6Pool = nil\n\t\tv6InMemSearcher = nil\n\t} else if v6Config.cachePolicy == BufferCache {\n\t\tv6Pool = nil\n\t\tv6InMemSearcher, err = xdb.NewWithBuffer(v6Config.ipVersion, v6Config.cBuffer)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to create v6 in-memory searcher: %w\", err)\n\t\t}\n\t} else {\n\t\tv6InMemSearcher = nil\n\t\tv6Pool, err = NewSearcherPool(v6Config)","sourceCodeStart":40,"sourceCodeEnd":76,"githubUrl":"https://github.com/lionsoul2014/ip2region/blob/c1a1fc7d5941760db3f8431dc05c48cf7f0e30a1/binding/golang/service/ip2region.go#L40-L76","documentation":"Go service factory: NewSearcherPool failed while pre-creating the v4 searcher pool (each searcher open/verify fails individually); the wrapped error names the first searcher creation failure.","triggerScenarios":"Thrown at binding/golang/service/ip2region.go:58 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the v4 xdb path, permissions and integrity reported by the wrapped error","Reduce dependence on file access by using the content cache policy","Retry after the underlying file issue is fixed"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c1a1fc7d5941760db3f8431dc05c48cf7f0e30a1","analyzedAt":"2026-09-02T16:58:39.988Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-09T21:17:11.164Z"}