{"record":{"id":"003e47e51aaaf052","repo":"thanos-io/thanos","slug":"verify-s","errorCode":null,"errorMessage":"verify %s","messagePattern":"verify (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/verifier/verify.go","lineNumber":146,"sourceCode":"\t}\n}\n\n// Verify verifies matching blocks using registered list of Verifier and VerifierRepairer.\n// TODO(blotka): Wrap bucket with WrapWithMetrics and print metrics after each issue (e.g how many blocks where touched).\nfunc (m *Manager) Verify(ctx context.Context, idMatcher func(ulid.ULID) bool) error {\n\tif len(m.vs.Verifiers)+len(m.vs.VerifierRepairers) == 0 {\n\t\treturn errors.New(\"nothing to verify. No verifiers and verifierRepairers registered\")\n\t}\n\n\tlogger := log.With(m.Logger, \"verifiers\", strings.Join(append(m.vs.VerifiersIDs(), m.vs.VerifierRepairersIDs()...), \",\"))\n\tlevel.Info(logger).Log(\"msg\", \"Starting verify task\")\n\n\tfor _, v := range m.vs.Verifiers {\n\t\tvCtx := m.Context\n\t\tvCtx.Logger = log.With(logger, \"verifier\", v.IssueID())\n\t\tvCtx.Context = ctx\n\t\tif err := v.Verify(vCtx, idMatcher); err != nil {\n\t\t\treturn errors.Wrapf(err, \"verify %s\", v.IssueID())\n\t\t}\n\t}\n\tfor _, vr := range m.vs.VerifierRepairers {\n\t\tvCtx := m.Context\n\t\tvCtx.Context = ctx\n\t\tvCtx.Logger = log.With(logger, \"verifier\", vr.IssueID())\n\t\tif err := vr.VerifyRepair(vCtx, idMatcher, false); err != nil {\n\t\t\treturn errors.Wrapf(err, \"verify %s\", vr.IssueID())\n\t\t}\n\t}\n\n\tlevel.Info(logger).Log(\"msg\", \"verify task completed\")\n\treturn nil\n}\n\n// VerifyAndRepair verifies and repairs matching blocks using registered list of VerifierRepairer.\n// TODO(blotka): Wrap bucket with WrapWithMetrics and print metrics after each issue (e.g how many blocks where touched).\nfunc (m *Manager) VerifyAndRepair(ctx context.Context, idMatcher func(ulid.ULID) bool) error {","sourceCodeStart":128,"sourceCodeEnd":164,"githubUrl":"https://github.com/thanos-io/thanos/blob/35b8b991177def87ed52dcf10f9b6d87f07282c8/pkg/verifier/verify.go#L128-L164","documentation":"Manager.Verify runs each registered Verifier's Verify method and, on failure, wraps the error with \"verify <issueID>\" so the operator knows which issue's verifier failed. It surfaces the underlying verifier error attributed to its issue ID.","triggerScenarios":"Any registered Verifier returns an error from its Verify method (e.g. bucket fetch failures, corrupted index verification failures, internal errors) during thanos verify.","commonSituations":"Object store access problems during verification; blocks with corrupted index failing the index verifier; context cancellation/timeout during a long verify run.","solutions":["Read the wrapped cause to identify which underlying operation failed","Re-run verification; many object store errors are transient","Isolate the failing block ID from verifier logs and inspect/repair it specifically","Increase timeout or ensure stable bucket connectivity for large buckets"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"for _, v := range verifiers {\n\tif err := v.Verify(vCtx, matcher); err != nil {\n\t\tlog.Printf(\"verifier %s failed: %v\", v.IssueID(), err) // inspect wrapped cause\n\t}\n}","preventionTips":["Ensure stable object store connectivity before long verify runs","Use generous timeouts for large buckets","Log per-issue errors and continue instead of aborting on first failure"],"tags":["verification","thanos","error-wrapping"],"backgroundTag":"api-error-response","analyzedSha":"35b8b991177def87ed52dcf10f9b6d87f07282c8","analyzedAt":"2026-09-07T01:49:59.689Z","contentChangedAt":"2026-09-07T01:49:59.689Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}