{"record":{"id":"7293f21c7ae28deb","repo":"github/github-mcp-server","slug":"after-cursor-is-invalid","errorCode":null,"errorMessage":"after cursor is invalid","messagePattern":"after cursor is invalid","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/github/repositories.go","lineNumber":2363,"sourceCode":"}\n\n// maxBlameRanges caps the number of matching blame ranges considered for one response.\nconst maxBlameRanges = 1000\n\nconst blameCursorPrefix = \"blame-range:\"\n\nfunc encodeBlameCursor(offset int) string {\n\treturn base64.RawURLEncoding.EncodeToString(fmt.Appendf(nil, \"%s%d\", blameCursorPrefix, offset))\n}\n\nfunc decodeBlameCursor(cursor string) (int, error) {\n\tif cursor == \"\" {\n\t\treturn 0, nil\n\t}\n\n\tdecoded, err := base64.RawURLEncoding.DecodeString(cursor)\n\tif err != nil {\n\t\treturn 0, fmt.Errorf(\"after cursor is invalid\")\n\t}\n\n\tvalue := string(decoded)\n\tif !strings.HasPrefix(value, blameCursorPrefix) {\n\t\treturn 0, fmt.Errorf(\"after cursor is invalid\")\n\t}\n\n\toffset, err := strconv.Atoi(strings.TrimPrefix(value, blameCursorPrefix))\n\tif err != nil || offset < 0 {\n\t\treturn 0, fmt.Errorf(\"after cursor is invalid\")\n\t}\n\n\treturn offset, nil\n}\n\n// BlameAuthor describes the author of a commit referenced by a BlameRange.\ntype BlameAuthor struct {\n\tName  string  `json:\"name\"`","sourceCodeStart":2345,"sourceCodeEnd":2381,"githubUrl":"https://github.com/github/github-mcp-server/blob/0ea1f775a7c73eff1bd2e25904d01136756bbfe2/pkg/github/repositories.go#L2345-L2381","documentation":"Error \"after cursor is invalid\" thrown in github/github-mcp-server.","triggerScenarios":"Thrown at pkg/github/repositories.go:2363 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":"0ea1f775a7c73eff1bd2e25904d01136756bbfe2","analyzedAt":"2026-08-15T18:10:19.804Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}