{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"id":"D21","name":"Naming Consistency","shortDescription":{"text":"Naming Consistency"},"helpUri":"https://codehealth.canine.dev/dimensions/D21"},{"id":"D28","name":"Secrets (history)","shortDescription":{"text":"Secrets (history)"},"helpUri":"https://codehealth.canine.dev/dimensions/D28","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"]}},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"]}},{"id":"D31","name":"IaC \u0026 Container Security","shortDescription":{"text":"IaC \u0026 Container Security"},"helpUri":"https://codehealth.canine.dev/dimensions/D31","relationships":[{"target":{"id":"CWE-1032","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-732","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-16","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1032","CWE-732","CWE-16"]}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D36","name":"Supply-chain Provenance \u0026 Signing","shortDescription":{"text":"Supply-chain Provenance \u0026 Signing"},"helpUri":"https://codehealth.canine.dev/dimensions/D36","relationships":[{"target":{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1357","CWE-494"]}},{"id":"D38","name":"OSV Dependency Vulnerabilities","shortDescription":{"text":"OSV Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D38","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"]}}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertClaudeRequestToAntigravity (cyclomatic 195): claude.ConvertClaudeRequestToAntigravity has cyclomatic complexity 195 (threshold 15). Of this number, 194 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc4f0a07163907018d647ca6867513f2f25bf3c3d1f23fc71bd53662123ccbd8"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertGeminiResponseToOpenAIResponses (cyclomatic 165): responses.ConvertGeminiResponseToOpenAIResponses has cyclomatic complexity 165 (threshold 15). Of this number, 74 points are the body\u0027s own statements and 91 belong to 7 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"80fab917ae5ae03e0e3395ed0496a5bdc419a7975774314f144df72faf67b92c"}},{"ruleId":"D1","level":"warning","message":{"text":"main.main (cyclomatic 137): main.main has cyclomatic complexity 137 (threshold 15). Of this number, 125 points are the body\u0027s own statements and 12 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/server/main.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"edb5369aa10e570b88a98c6ef0374be1d59362a5e8c15fdacdc89750a5e9d951"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToAntigravity (cyclomatic 126): chat_completions.ConvertOpenAIRequestToAntigravity has cyclomatic complexity 126 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ddd4f3243e1d584e2b5e0ca338eb24079c939ade101120398093c7a34ef4446"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToGemini (cyclomatic 126): chat_completions.ConvertOpenAIRequestToGemini has cyclomatic complexity 126 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d8c6b0c8edcb17fb935fc3ac2804f3a58ac6ad0092d5f6c04b104a9f21b2e69"}},{"ruleId":"D1","level":"warning","message":{"text":"diff.BuildConfigChangeDetails (cyclomatic 125): diff.BuildConfigChangeDetails has cyclomatic complexity 125 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/config_diff.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"adbcf5e1e4146f195d31e01cbb330b34ae254f6ffc59f149f2daa5d9b59f6cfe"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToClaude (cyclomatic 113): responses.ConvertOpenAIResponsesRequestToClaude has cyclomatic complexity 113 (threshold 15). Of this number, 47 points are the body\u0027s own statements and 66 belong to 7 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf85d5df1fe2ad88b03a7a6ed27e140472c8af609098623c82a39ebcd316a471"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIWebsocketsExecutor.ExecuteStream (cyclomatic 107): XAIWebsocketsExecutor.ExecuteStream has cyclomatic complexity 107 (threshold 15). Of this number, 50 points are the body\u0027s own statements and 57 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"303adc1615c5169a55092510e9c9f01173c73719eb8eed5d44eacd3d14e7460a"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToCodex (cyclomatic 107): chat_completions.ConvertOpenAIRequestToCodex has cyclomatic complexity 107 (threshold 15). Of this number, 104 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce5b14bc31f502a8c6fe87f4f4d05d92d3cd6b299dc8a60cf836c864a9df65cc"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIResponsesAPIHandler.ResponsesWebsocket (cyclomatic 106): OpenAIResponsesAPIHandler.ResponsesWebsocket has cyclomatic complexity 106 (threshold 15). Of this number, 76 points are the body\u0027s own statements and 30 belong to 8 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"36208508fad3ab3e3fcfca008b65250e53bbdb38190c465684ccf549b81f3030"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToGemini (cyclomatic 105): responses.ConvertOpenAIResponsesRequestToGemini has cyclomatic complexity 105 (threshold 15). Of this number, 75 points are the body\u0027s own statements and 30 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b8c052040e103c72817118cd7d5e3da3b3b275625a18063f82dd1da40259a83"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertGeminiResponseToOpenAIResponsesNonStream (cyclomatic 93): responses.ConvertGeminiResponseToOpenAIResponsesNonStream has cyclomatic complexity 93 (threshold 15). Of this number, 54 points are the body\u0027s own statements and 39 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":842}}}],"partialFingerprints":{"codehealthFindingId/v1":"dce5f9dbb4c92f52387974fe236d0380babf66ff5f5d942fd2a1d5f175c3027f"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertClaudeResponseToOpenAIResponses (cyclomatic 91): responses.ConvertClaudeResponseToOpenAIResponses has cyclomatic complexity 91 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1e5e86da8204fc7dc8fc6605ed77a946b6a346695fc152fa78189870cb5f0b6"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponses (cyclomatic 83): responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponses has cyclomatic complexity 83 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 57 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf5d540e128a94430df6077dbcb8e6fae2b2cdbf6d4f18a89885203b2ded2a7"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.registerModelsForAuthWithCache (cyclomatic 83): Service.registerModelsForAuthWithCache has cyclomatic complexity 83 (threshold 15). Of this number, 78 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e30f03563d836406ec32173380d4959318ae005098ff29efc4dd9220d2981c"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexWebsocketsExecutor.ExecuteStream (cyclomatic 81): CodexWebsocketsExecutor.ExecuteStream has cyclomatic complexity 81 (threshold 15). Of this number, 42 points are the body\u0027s own statements and 39 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_stream.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed82d61a5c8b2b514fbf66c310fcd3a1eeb6de887f196c910bcb2f90bdc93136"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToClaude (cyclomatic 81): gemini.ConvertGeminiRequestToClaude has cyclomatic complexity 81 (threshold 15). Of this number, 46 points are the body\u0027s own statements and 35 belong to 6 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d303dd1b02009c598a641685e8de2feb1b60bfab76a4757af88feffb7d42081"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertClaudeResponseToOpenAIResponsesNonStream (cyclomatic 79): responses.ConvertClaudeResponseToOpenAIResponsesNonStream has cyclomatic complexity 79 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"797e2da91bb3d32367dae6287454af603d27cf4083f38af54495694107273f4d"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertClaudeRequestToCodex (cyclomatic 78): claude.ConvertClaudeRequestToCodex has cyclomatic complexity 78 (threshold 15). Of this number, 70 points are the body\u0027s own statements and 8 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"448b1042fa7209794cf77059591766640cb02db007150a99db821c3e715bb992"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.executeStreamWithAuthManagerFormats (cyclomatic 77): BaseAPIHandler.executeStreamWithAuthManagerFormats has cyclomatic complexity 77 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 52 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_stream.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"f83b681965fe39e27b91bb96559458afe9c3dd173e4c361af05c78f37192f269"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.ExecuteStream (cyclomatic 74): AntigravityExecutor.ExecuteStream has cyclomatic complexity 74 (threshold 15). Of this number, 59 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_stream.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fcfc6bbbcb9544dc10a886756e013ebc9a13e6ecb522586e0fe43d012ea1b8a"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToClaude (cyclomatic 74): chat_completions.ConvertOpenAIRequestToClaude has cyclomatic complexity 74 (threshold 15). Of this number, 39 points are the body\u0027s own statements and 35 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_request.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"27ea12565ee56cd30e4aaa053b6c60edcfa6aaf903e1a14c3287253e85d94119"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertClaudeRequestToGemini (cyclomatic 74): claude.ConvertClaudeRequestToGemini has cyclomatic complexity 74 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 37 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_request.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"2838808384c197b27ff2653f80e51ceb0c512c4e4b191346465b84550c228504"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertClaudeRequestToOpenAI (cyclomatic 74): claude.ConvertClaudeRequestToOpenAI has cyclomatic complexity 74 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 36 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_request.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"a66e5c08d4fe249f0ac239d80f2edfe3d73a1a3d4ee0c9b20466a47c2a1733ca"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertAntigravityResponseToClaude (cyclomatic 73): claude.ConvertAntigravityResponseToClaude has cyclomatic complexity 73 (threshold 15). Of this number, 64 points are the body\u0027s own statements and 9 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"44d9ac728f0f58268eeaed134db58655312e5afaed50d3146b41dd83dbca582f"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToOpenAI (cyclomatic 72): gemini.ConvertGeminiRequestToOpenAI has cyclomatic complexity 72 (threshold 15). Of this number, 42 points are the body\u0027s own statements and 30 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_request.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"11e8b54177542af60a3d62fa53d135ffa3db2c15cc4626eb949358114a3ae982"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToOpenAIChatCompletions (cyclomatic 70): responses.ConvertOpenAIResponsesRequestToOpenAIChatCompletions has cyclomatic complexity 70 (threshold 15). Of this number, 52 points are the body\u0027s own statements and 18 belong to 8 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"218e816a42a3bd6d2d72e4051b06a61d0c558ebac653cf59731559d0d88d5e0c"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.executeClaudeNonStream (cyclomatic 68): AntigravityExecutor.executeClaudeNonStream has cyclomatic complexity 68 (threshold 15). Of this number, 61 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f34bcd7b58a09f15326752d088bcf819e0e62fcf3ba2a42e591da515f684ad3"}},{"ruleId":"D1","level":"warning","message":{"text":"GitTokenStore.ensureRepositoryLocked (cyclomatic 67): GitTokenStore.ensureRepositoryLocked has cyclomatic complexity 67 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"2811244cf96579afb2f58ef6e3aaa417b8dc2a82190f3a1f3f03a2147748e2ce"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.UpdateClientsContext (cyclomatic 66): Server.UpdateClientsContext has cyclomatic complexity 66 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_reload.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"735f25903b506398ff39ca12e3b7eb6ca8d43a635e5db0a2cb639bc20f2b2535"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertCodexResponseToOpenAI (cyclomatic 66): chat_completions.ConvertCodexResponseToOpenAI has cyclomatic complexity 66 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4cd6ccfd6572192b78f75bd94fb05b0ddf89c0c0ae6f6e118f83853dcd49057"}},{"ruleId":"D1","level":"warning","message":{"text":"antigravityReasoningReplayAccumulator.observeResponsePayload (cyclomatic 63): antigravityReasoningReplayAccumulator.observeResponsePayload has cyclomatic complexity 63 (threshold 15). Most of this is not in the body itself: 3 of the 63 points are its own statements and the rest belongs to one function literal inside it that branches (line 1697). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1689}}}],"partialFingerprints":{"codehealthFindingId/v1":"20f41282a79ca65a27988fb0cd9835e1f1d7498231c981ed9e36ea1c6f32c9d6"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToCodex (cyclomatic 62): gemini.ConvertGeminiRequestToCodex has cyclomatic complexity 62 (threshold 15). Of this number, 57 points are the body\u0027s own statements and 5 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c3c3d411b6b1543b6a9893805d2003cacc3073a54f88f54ad0ecf90ffa3c94e"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeExecutor.ExecuteStream (cyclomatic 59): ClaudeExecutor.ExecuteStream has cyclomatic complexity 59 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 28 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_stream.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"77d57b0071b56d22c7db9d7cde9ed70d6f3230f20d7ab5f8ec001d4acca9e471"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.Handle (cyclomatic 58): Handler.Handle has cyclomatic complexity 58 (threshold 15). Of this number, 52 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/live.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad7b6e82d79071f7a161ba0de9c2f095ad733f7da99460cf874b776c5dfe3c70"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.Execute (cyclomatic 58): AntigravityExecutor.Execute has cyclomatic complexity 58 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"11ed3afc44d0a93012503fc4d103ed2cb9d5e4e5f34462a0aa154f9d6788fac8"}},{"ruleId":"D1","level":"warning","message":{"text":"thinking.ValidateConfig (cyclomatic 58): thinking.ValidateConfig has cyclomatic complexity 58 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/validate.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7b5d1fe77829ae9fda643c6a9d7ac6274a32c571747de8aa3ff5a4306679f07"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.remapOAuthToolNamesWithBatchedEdits (cyclomatic 57): executor.remapOAuthToolNamesWithBatchedEdits has cyclomatic complexity 57 (threshold 15). Most of this is not in the body itself: 15 of the 57 points are its own statements and the rest belongs to 8 function literals inside it that branch (lines 1120, 1064, 992, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":960}}}],"partialFingerprints":{"codehealthFindingId/v1":"6051b6f0a312e66ac8dbd6934d17198b82a6e82440d3bd354866baa0cfcd2978"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.extractMessageHashIDs (cyclomatic 57): auth.extractMessageHashIDs has cyclomatic complexity 57 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 36 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"04b40dad410372c24cb2193bfbbe323458b397b72fd078ca9865d976f34e8437"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.pickHomeDispatchSelection (cyclomatic 57): Manager.pickHomeDispatchSelection has cyclomatic complexity 57 (threshold 15). Of this number, 56 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"158f87a1ccfda467743f061b58cbe0df6867c1856a7bc4afa35a3d389c20c54d"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexWebsocketsExecutor.Execute (cyclomatic 56): CodexWebsocketsExecutor.Execute has cyclomatic complexity 56 (threshold 15). Of this number, 52 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_execute.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3e70bc0b5638e6a4cd19fd0f0c98216758b5b8a8d6351faab98b2c4a9f68cf3"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertAntigravityResponseToClaudeNonStream (cyclomatic 55): claude.ConvertAntigravityResponseToClaudeNonStream has cyclomatic complexity 55 (threshold 15). Of this number, 49 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"5da2deb18d0b5994ef9bce9ef25abe407c2f1bfbbccb7aec6a22e2d419084a3b"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertClaudeResponseToGemini (cyclomatic 55): gemini.ConvertClaudeResponseToGemini has cyclomatic complexity 55 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c84fc3499df282126ee925bf8bcdbdbf4a7105034b6a362b478614dd12b1078"}},{"ruleId":"D1","level":"warning","message":{"text":"ModelRegistry.RegisterClient (cyclomatic 54): ModelRegistry.RegisterClient has cyclomatic complexity 54 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"572713fb10a2f754058378e8d04f627011929a2daa597b615e70b80695fe0de6"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.ApplyPayloadConfigWithRequestTracked (cyclomatic 53): helps.ApplyPayloadConfigWithRequestTracked has cyclomatic complexity 53 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5496499eb9fe7d78af581cb59b55c278b4443a09b32156e13d221b3da8aa81b"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.handleRedisConnection (cyclomatic 52): Server.handleRedisConnection has cyclomatic complexity 52 (threshold 15). Of this number, 50 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/redis_queue_protocol.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d9225aaf37acc180ed7dbe073c90427e8f20a194c976accf57360c5a80c2274"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.executeStreamMixedOnce (cyclomatic 51): Manager.executeStreamMixedOnce has cyclomatic complexity 51 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8e3d5be7acd5ad8fb5496359fccf3fc56f25aca263ef3feef05d5e97a458864"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertClaudeResponseToGeminiNonStream (cyclomatic 50): gemini.ConvertClaudeResponseToGeminiNonStream has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eae107b2914a3e7d92c59b8346c84ecfcd85ce2e5e6311f05997c2ebf21d741"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.convertStreamToNonStream (cyclomatic 49): AntigravityExecutor.convertStreamToNonStream has cyclomatic complexity 49 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 11 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2f802a569a3dc00b692ea875765b673188c80cb9c98ebb5673e38cb32870215"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.executeStreamWithModelPool (cyclomatic 49): Manager.executeStreamWithModelPool has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"63fd335dcae380660a8528c7eec3d9bad355e7e4017992c856302e002305c201"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.applyClaudeHeaders (cyclomatic 48): executor.applyClaudeHeaders has cyclomatic complexity 48 (threshold 15). Of this number, 42 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c30669e319c90984f522a4cd68b7cae3a617b5705a42808ab82539bf9948aea"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.convertOpenAIStreamingChunkToAnthropic (cyclomatic 48): claude.convertOpenAIStreamingChunkToAnthropic has cyclomatic complexity 48 (threshold 15). Of this number, 33 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"01bc5228cd06b551b67073b23e07bc34663d24a4616c615280bc280d2654b4fe"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponsesNonStream (cyclomatic 48): responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponsesNonStream has cyclomatic complexity 48 (threshold 15). Of this number, 41 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":711}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b9317c6ff43a127a8581d24e0cd1be8e1d193190cea29834081984adca02247"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.codexAlphaSearch (cyclomatic 47): Server.codexAlphaSearch has cyclomatic complexity 47 (threshold 15). Of this number, 40 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4620e68a781882058f0ce7a7e49c05e4bb6567c7106211fe72888dfb2f9bdca"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertGeminiResponseToOpenAI (cyclomatic 47): chat_completions.ConvertGeminiResponseToOpenAI has cyclomatic complexity 47 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 27 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"09b033029ace9ec61545309182d56e03e69453b838cd78a6afda695e8d94b09e"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.tolerantParseJSONObjectRaw (cyclomatic 47): gemini.tolerantParseJSONObjectRaw has cyclomatic complexity 47 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"d557a62a784423c2c1d2e69275ba22170e5d2905a28b17d6862ed469805e455f"}},{"ruleId":"D1","level":"warning","message":{"text":"App.Update (cyclomatic 47): App.Update has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/app.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"cefd26f8ead7053d127c8ed4afc23deba2d7c7c214f3dd7e616a5e6db2136d71"}},{"ruleId":"D1","level":"warning","message":{"text":"authScheduler.pickMixedWithStrategy (cyclomatic 47): authScheduler.pickMixedWithStrategy has cyclomatic complexity 47 (threshold 15). Of this number, 43 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"1234bf14b6c9eaf129fda45ba8870b8f8512150a0cd07f663cd17291172e0aa6"}},{"ruleId":"D1","level":"warning","message":{"text":"AIStudioExecutor.ExecuteStream (cyclomatic 46): AIStudioExecutor.ExecuteStream has cyclomatic complexity 46 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 27 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa561d1cdf3da7d5e08dd007fc5b100f7c152e2fd727f1987284bf210933eb5d"}},{"ruleId":"D1","level":"warning","message":{"text":"ModelRegistry.GetAvailableModelsByProvider (cyclomatic 44): ModelRegistry.GetAvailableModelsByProvider has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b55c92c594973200ee55795e68278e5c734fa9425f982cafd71ee8ff037b5a9"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.remapOAuthToolNamesWithOptionsLegacy (cyclomatic 44): executor.remapOAuthToolNamesWithOptionsLegacy has cyclomatic complexity 44 (threshold 15). Most of this is not in the body itself: 10 of the 44 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 1350, 1301, 1246, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1218}}}],"partialFingerprints":{"codehealthFindingId/v1":"38c3c533dac661a5fae560e457c79af1aee4d18dc66fade44dd05ce50fc32ef5"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertCodexResponseToOpenAINonStream (cyclomatic 44): chat_completions.ConvertCodexResponseToOpenAINonStream has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3dd4362530cae96c5c0a37136aeff82976c67e15e3f0e701479b48d7058817"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.executeHome (cyclomatic 44): Manager.executeHome has cyclomatic complexity 44 (threshold 15). Of this number, 40 points are the body\u0027s own statements and 4 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home_execution.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"b655ac24d05cba23fabc8f28d902005ab2b1cf04273bee3134f00218794d0ecf"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.normalizeKimiToolMessageLinks (cyclomatic 43): executor.normalizeKimiToolMessageLinks has cyclomatic complexity 43 (threshold 15). Of this number, 41 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"43e9c3ab383fd39bd4502066128db06bb219f5ee83f9fdcf4c4e15fc7b8550d3"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertCodexResponseToClaude (cyclomatic 43): claude.ConvertCodexResponseToClaude has cyclomatic complexity 43 (threshold 15). Of this number, 41 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b945c3efc82ff598175b0a3da405ccbb3009177ef4c3ec09cae00861b56b54b"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertGeminiResponseToClaude (cyclomatic 43): claude.ConvertGeminiResponseToClaude has cyclomatic complexity 43 (threshold 15). Of this number, 41 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"4810bca69bbe7199724b0f140364a4a925ecd5e55b3fbe23438db979d4c82887"}},{"ruleId":"D1","level":"warning","message":{"text":"synthesizer.synthesizeFileAuths (cyclomatic 43): synthesizer.synthesizeFileAuths has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/file.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ec762bdac3b15eb97f9c4a2cfbefe430eb12e9d155a2161886d2b820ca51078"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.HandleSideband (cyclomatic 42): Handler.HandleSideband has cyclomatic complexity 42 (threshold 15). Of this number, 39 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/sideband.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fdcf2647b70ffaa164e0f38c5f54763923848fe7d0354d4ab6647c03c029ee0"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.pairOpenAIResponsesReasoningWithFunctionCalls (cyclomatic 42): responses.pairOpenAIResponsesReasoningWithFunctionCalls has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"4051113df89f2a4fb91e705157589e834963f13a9f0a33bca9279398ce56668c"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.MarkResult (cyclomatic 42): Manager.MarkResult has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2018e2073ef04cb2af6ebd0b8734ab4bad2bd9aad105ff4607a3c1824b88eb"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Run (cyclomatic 42): Service.Run has cyclomatic complexity 42 (threshold 15). Of this number, 35 points are the body\u0027s own statements and 7 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_lifecycle.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f079d331fb0e13af95ea389168b5b501fb8656ed3207f708811beb36903b04"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.GetContextWithCancel (cyclomatic 41): BaseAPIHandler.GetContextWithCancel has cyclomatic complexity 41 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 22 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4d7a432b3eced4a7bd014aa3fdece403afa075dbcc5d06441bc76adc72049b6"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.buildAuthFileEntryLocked (cyclomatic 40): Handler.buildAuthFileEntryLocked has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0e574d96c0447948e673ea4d247963fe7590fb76df11a8e5bab761daa9bde25"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.InspectClaudeCAISSignature (cyclomatic 40): signature.InspectClaudeCAISSignature has cyclomatic complexity 40 (threshold 15). Most of this is not in the body itself: 15 of the 40 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 688, 640, 669). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce8c2747848a18cee7207c8d2145e90667107abe48a3c140f93a3eadad6f332f"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAICompatExecutor.ExecuteStream (cyclomatic 39): OpenAICompatExecutor.ExecuteStream has cyclomatic complexity 39 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 23 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"fde2620464d219440f7050ccb79ad49021bc862bd4ea86f002966a892092da6f"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertAntigravityResponseToOpenAI (cyclomatic 39): chat_completions.ConvertAntigravityResponseToOpenAI has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"726e9a294de81db9476e167f76d2ec9fde530dddf45a250347befaa8d5f38623"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeAuthenticator.Login (cyclomatic 39): ClaudeAuthenticator.Login has cyclomatic complexity 39 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/claude.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a2b016e352069f79b35ca2929754bd6c6c7c81fb12a6d4e0c47779c610107e"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.ExecuteStream (cyclomatic 38): CodexExecutor.ExecuteStream has cyclomatic complexity 38 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 21 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_stream.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfa13babdf2488d9271757a6e41f16f034b8584f407dddfe40736b7e61bfccb3"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.applyClaudeToolPrefix (cyclomatic 37): executor.applyClaudeToolPrefix has cyclomatic complexity 37 (threshold 15). Most of this is not in the body itself: 11 of the 37 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1536, 1509). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1499}}}],"partialFingerprints":{"codehealthFindingId/v1":"81e58f4ac7dfaf6099f31514c88248bbceed7c45f01807e9dcaefd84755fb57e"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeExecutor.Execute (cyclomatic 37): ClaudeExecutor.Execute has cyclomatic complexity 37 (threshold 15). Of this number, 36 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_execute.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"1420fb6deab500fb774707986d0e44fdd3fd1acc6aee0debb16ceb45665bebb2"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIExecutor.ExecuteStream (cyclomatic 37): XAIExecutor.ExecuteStream has cyclomatic complexity 37 (threshold 15). Most of this is not in the body itself: 10 of the 37 points are its own statements and the rest belongs to one function literal inside it that branches (line 70). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_stream.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0842190b0a84a196b5a4f134a2ce79536e248602b5e3931d84c85d1aab0cb67"}},{"ruleId":"D1","level":"warning","message":{"text":"cache.ReplaceAntigravityReasoningReplayItemsIfUnchanged (cyclomatic 36): cache.ReplaceAntigravityReasoningReplayItemsIfUnchanged has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2d45eb28da684e4b3d6292c367fc401202ded2f65c33bf5c03b1329f46fda63"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.enforceCacheControlLimit (cyclomatic 36): executor.enforceCacheControlLimit has cyclomatic complexity 36 (threshold 15). Most of this is not in the body itself: 15 of the 36 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 1107, 1043, 1079, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"525b44c02da9bd8cac75c61c9c33c90fc9381f473685481b245670a55f2b4f65"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertClaudeResponseToOpenAI (cyclomatic 36): chat_completions.ConvertClaudeResponseToOpenAI has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecf34d68b2a397a1f321d088a64b9749015e79cf958c9d4d36861db6963ada1e"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertClaudeResponseToOpenAINonStream (cyclomatic 36): chat_completions.ConvertClaudeResponseToOpenAINonStream has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e47f1eefa14f96143e31e694c0582d87042f26eeae3b67edd24652014839576"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertCodexResponseToGemini (cyclomatic 36): gemini.ConvertCodexResponseToGemini has cyclomatic complexity 36 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"4073beb5484e646bdb2e934cebe3ecd2f2b8fede3307f874d47a1cbee0b0d4de"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.reorderOpenAIResponsesDetachedReasoning (cyclomatic 36): responses.reorderOpenAIResponsesDetachedReasoning has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a2ae104c8c32fe67aa7ebfb59676bd52e52ce678df4efc7bdda39cd9ffc172f"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.buildResponsesCompletedEvent (cyclomatic 36): responses.buildResponsesCompletedEvent has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"635c049ab6a5be855d14723e92b8ad5b324efa5ef5bea4be94e7ff59861efb92"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.registerExecutorForAuth (cyclomatic 36): Service.registerExecutorForAuth has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb7e69c62a1e3c41e98876facd381eeee88f8ec1c6951d86ad8c082d7f0e66c6"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiExecutor.executeInteractionsStream (cyclomatic 35): GeminiExecutor.executeInteractionsStream has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 10 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 525). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d8dc26bfca539bc87362698a2179dc5991fa86926f5b77da605d04a0f202c17"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.streamWithPluginExecutor (cyclomatic 35): BaseAPIHandler.streamWithPluginExecutor has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 14 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 119). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_stream.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"5402934826767f71305a653189f2947580712c9b95835bf88362bfe59a83021e"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityAuthenticator.Login (cyclomatic 35): AntigravityAuthenticator.Login has cyclomatic complexity 35 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/antigravity.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"741bc9f5778dd51b533e4278df2b575182de96f6e3a61d411a1cce0e103e0d7a"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.ApplyConfig (cyclomatic 34): Host.ApplyConfig has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"439634a490e1a1937645aed98982fe0ac24ccbfa7d4a4aad01d1bf8423782930"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertOpenAIResponseToGemini (cyclomatic 34): gemini.ConvertOpenAIResponseToGemini has cyclomatic complexity 34 (threshold 15). Most of this is not in the body itself: 10 of the 34 points are its own statements and the rest belongs to one function literal inside it that branches (line 95). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"56f1c9ffd6088c0b8fb5b5f8fc10e5093a7779754d5b0bf9b0f7c8165c31a9b9"}},{"ruleId":"D1","level":"warning","message":{"text":"oauthTabModel.Update (cyclomatic 34): oauthTabModel.Update has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/oauth_tab.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"1018a2a84762115fac37cd52b45b758556f910bda7fa4059e63fc89e7750d9bc"}},{"ruleId":"D1","level":"warning","message":{"text":"ResponseWriterWrapper.Finalize (cyclomatic 33): ResponseWriterWrapper.Finalize has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/middleware/response_writer.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d2a167d580c431b7d54d0b253d3ef00cbe089be261e39b076d6b3d07618b7d5"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.CountTokens (cyclomatic 33): AntigravityExecutor.CountTokens has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_tokens.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e65aa3db72c9944ef58743501a6e4fb669f8a4602009cf8c9d84f3d35d9f574"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.inspectClaudeChannelBlock (cyclomatic 33): signature.inspectClaudeChannelBlock has cyclomatic complexity 33 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 13 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"605088b7fd500e792cc01d9c065c693269ae6f53f6eb1356c6d0868c3dfa6cf7"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertOpenAIResponseToClaudeNonStream (cyclomatic 33): claude.ConvertOpenAIResponseToClaudeNonStream has cyclomatic complexity 33 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 8 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5afc2b136f01bd3741baa35566f91202abea3242b070b17b2da45f2732d67f1"}},{"ruleId":"D1","level":"warning","message":{"text":"keysTabModel.Update (cyclomatic 33): keysTabModel.Update has cyclomatic complexity 33 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 3 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/keys_tab.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9199cfba8011d9032370eb788e91a85083281a29de088f9365708f6dec4ee93"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.forwardImagesStream (cyclomatic 33): OpenAIAPIHandler.forwardImagesStream has cyclomatic complexity 33 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 17 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1821}}}],"partialFingerprints":{"codehealthFindingId/v1":"3427f9290303e8c6649a9918b731fdc314985d8a68bb5c036e407b29326a99b2"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexAuthenticator.Login (cyclomatic 33): CodexAuthenticator.Login has cyclomatic complexity 33 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/codex.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d35c7f39f35b100703737e7b81352d0aee3c842c98d95c60085e9590d785cae"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.buildHostAuthFileEntry (cyclomatic 32): Host.buildHostAuthFileEntry has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"749aacc4c30b72de812824047ae9fe15274a0ac06bf8795215a9be944120d692"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.mergeAntigravityFunctionCallPartReplayWithSchemas (cyclomatic 32): executor.mergeAntigravityFunctionCallPartReplayWithSchemas has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1397}}}],"partialFingerprints":{"codehealthFindingId/v1":"80d7c03219fde87c94edfd563184990c004a053dfbc1e06de828643e17e78c48"}},{"ruleId":"D1","level":"warning","message":{"text":"StreamRewriter.RewriteChunk (cyclomatic 32): StreamRewriter.RewriteChunk has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/response_model_rewriter.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"659f846587f61ede87e9e7c1645998acd3c35f8027d2e90328f520cdf060c54f"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.tryRegisterPluginModelsForAuth (cyclomatic 32): Service.tryRegisterPluginModelsForAuth has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"df22107d88a7ff90ef2e10dc73e08e3c3cc75062b0f92cf807d55f07e1011f8e"}},{"ruleId":"D1","level":"warning","message":{"text":"pionMediaRelay.NewSession (cyclomatic 31): pionMediaRelay.NewSession has cyclomatic complexity 31 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 4 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"59bc7c4386a826405acfe53ac53823914aa2773c997fedf3bb9fcd29134f804d"}},{"ruleId":"D1","level":"warning","message":{"text":"Client.RunConfigSubscriberLifetime (cyclomatic 31): Client.RunConfigSubscriberLifetime has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1782}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f50dc5bf0c74be6e10271b5d34bd6d5141f9deaa3e58beee751238ce326b7e5"}},{"ruleId":"D1","level":"warning","message":{"text":"GitTokenStore.commitAndPushWithOptionsLocked (cyclomatic 31): GitTokenStore.commitAndPushWithOptionsLocked has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1519}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc37d9d6430dec9b2d8885d18abfb927c577ba912cbf6e13c38310d0e5c34d4"}},{"ruleId":"D1","level":"warning","message":{"text":"Applier.Apply (cyclomatic 31): Applier.Apply has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"564abaab60934d8e3761d2c57b5d8b1f204a1780e63c33cfc274fcfe30805751"}},{"ruleId":"D1","level":"warning","message":{"text":"FileTokenStore.readAuthFiles (cyclomatic 31): FileTokenStore.readAuthFiles has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"dabfbe5f9ec36fee779e97c52369ad7d75793abba72501a933b05960638cee1c"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.executeCountMixedOnce (cyclomatic 31): Manager.executeCountMixedOnce has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d5e538654eb88c26f018c7bdd920601a21d63dc82dc22ffa330235f282de79f"}},{"ruleId":"D1","level":"warning","message":{"text":"ModelRegistry.convertModelToMap (cyclomatic 30): ModelRegistry.convertModelToMap has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"858cfc419aa52602f63445f7d73983e8a5dc165c9ae390ae176a88cde165296e"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.antigravityFunctionCallPartLocationForReplayWithSchemas (cyclomatic 30): executor.antigravityFunctionCallPartLocationForReplayWithSchemas has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d9508087aebddcdd67bbd42db2d6a6435ed42c9785ed849234b6d2d0494e830"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.countCodexInputTokens (cyclomatic 30): executor.countCodexInputTokens has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_tokens.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"56bbe7d71e2303f3b80226ed6d293d988e726c8d0b77fd9b50352ded3cc76266"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.Execute (cyclomatic 30): CodexExecutor.Execute has cyclomatic complexity 30 (threshold 15). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_execute.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9ecf824c269697d02863a16534c16144353b4ee9bf01b869e168202c550eb27"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.executeOpenAIImageStream (cyclomatic 30): CodexExecutor.executeOpenAIImageStream has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 11 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 242). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"db95ac1de3c92a7143dbe883523b71df6f3b4d599dfa8ee7fb6c6877c626f798"}},{"ruleId":"D1","level":"warning","message":{"text":"thinking.applyThinking (cyclomatic 30): thinking.applyThinking has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"c714f910b93656023df03676df1b2f7fec9edad6824d4504793bf93ac4ac8ef8"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertCodexResponseToClaudeNonStream (cyclomatic 30): claude.ConvertCodexResponseToClaudeNonStream has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 7 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 375). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9aa35434d41ec182bfd63088d616e2171de9fad9edf16312b3b1e3db974020d"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.imagesEditsFromMultipart (cyclomatic 30): OpenAIAPIHandler.imagesEditsFromMultipart has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2780757aa68dd357dd6ff6c1f994e0abe4b6af60f95f96d54cc4c82ee81bf89"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.executeMixedOnce (cyclomatic 30): Manager.executeMixedOnce has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"9049f4867e69a9be4b4ca534be506ad267bbbfb964ec390bbb18138aa2f9698e"}},{"ruleId":"D1","level":"warning","message":{"text":"config.pruneMappingToGeneratedKeys (cyclomatic 29): config.pruneMappingToGeneratedKeys has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":644}}}],"partialFingerprints":{"codehealthFindingId/v1":"78917346ce6581f28ec3b4bca7f40f2ced9112b70e6a8636ff1e437583833285"}},{"ruleId":"D1","level":"warning","message":{"text":"executorAdapter.Refresh (cyclomatic 29): executorAdapter.Refresh has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":688}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd9b3d665fd6302114626e2c7f8cec2ad1606246ffc650e8a37340be99e9ebfd"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.antigravityThoughtSignatureReplayPartPath (cyclomatic 29): executor.antigravityThoughtSignatureReplayPartPath has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1135}}}],"partialFingerprints":{"codehealthFindingId/v1":"ede5bbb8fd81690e8dc55d7930508906e4d5ce0a8251d9a429327e3a9e6adf19"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.decodeResponseBody (cyclomatic 29): executor.decodeResponseBody has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd5972021057420c33f76bc2c5077cc9be0c9dd8697bb8cc0ca611a7683f5875"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeExecutor.countTokensUpstream (cyclomatic 29): ClaudeExecutor.countTokensUpstream has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_tokens.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c47d896d882b499a381f2b7719070a9064500275a733efab44472aca378cab5"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIResponsesAPIHandler.forwardResponsesWebsocket (cyclomatic 29): OpenAIResponsesAPIHandler.forwardResponsesWebsocket has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_forward.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"22fc36c797851c8ac6ced4c3f67fccb37df9ed5dec1d793ad8773e08f6a4ac29"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.pickNextMixedLegacy (cyclomatic 29): Manager.pickNextMixedLegacy has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1267}}}],"partialFingerprints":{"codehealthFindingId/v1":"77ef79679d92537448e7c67fee6319811e3c36231137fff45d610475261fe1dc"}},{"ruleId":"D1","level":"warning","message":{"text":"management.locateLogCursorFile (cyclomatic 28): management.locateLogCursorFile has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"654c7d15d77289c91867a6a245823130773522720b576744e8e96d68b2024af0"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.listAuthFilesFromDisk (cyclomatic 28): Handler.listAuthFilesFromDisk has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"12d8c437e1a5d1390db59c35e5e4a8c904e885620f068fff7ed69e3c6dfca4a2"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.normalizeAntigravityGeminiFunctionResponseRoles (cyclomatic 28): executor.normalizeAntigravityGeminiFunctionResponseRoles has cyclomatic complexity 28 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ff739b8d3f2ba72d2d9298b4da0642e8afad2dd281a0a0328ce83ff260a9bf1"}},{"ruleId":"D1","level":"warning","message":{"text":"KimiExecutor.ExecuteStream (cyclomatic 28): KimiExecutor.ExecuteStream has cyclomatic complexity 28 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 11 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2e40f4d3d73b844c72aa6ba40140e474ae3ba06b451b9624e541b53c6e26ac4"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.StripInvalidGeminiSignatureThinkingBlocks (cyclomatic 28): claude.StripInvalidGeminiSignatureThinkingBlocks has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/signature_validation.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bdcb18f084cb9fd42f7e9c705a1a3c3ee827f71eb47e8ebbe7eaa1d334ffcce"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.ConvertGeminiResponseToOpenAINonStream (cyclomatic 28): chat_completions.ConvertGeminiResponseToOpenAINonStream has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 11 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 337). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"6071457d01b277e65ed57c8c9f6ac40a938f616bae5ff53ec77d31cb0b29008d"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.runHomeSubscriber (cyclomatic 28): Service.runHomeSubscriber has cyclomatic complexity 28 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 8 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"03348f3765a92e7da4a27898dc55d5557140f1afeb4d7ad7e3dd5733da2110dd"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginhost.cloneInterceptorMetadataReflectValue (cyclomatic 27): pluginhost.cloneInterceptorMetadataReflectValue has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_interceptors.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a219cfd19bf866e20a883f7f719546a2cf6919c5a0920bc336484b80ab26a3"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.normalizeXAITool (cyclomatic 27): executor.normalizeXAITool has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":924}}}],"partialFingerprints":{"codehealthFindingId/v1":"36de6ffa752c7ad0247b70e107705ca737c97e83101f0be2a0d58c1cb603308e"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.maybeRefreshAntigravityCreditsHint (cyclomatic 27): AntigravityExecutor.maybeRefreshAntigravityCreditsHint has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d9820636be22368a45387784a80e9411e46249befc73ad1a54d2a2f7c784b3a"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiVertexExecutor.executeStreamWithServiceAccount (cyclomatic 27): GeminiVertexExecutor.executeStreamWithServiceAccount has cyclomatic complexity 27 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 12 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"d80d5872c531d45f3562ff08f01dba2173c2ea9775200a23ccb42a120910bf09"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.SanitizeClaudeMessagesSignaturesForTarget (cyclomatic 27): signature.SanitizeClaudeMessagesSignaturesForTarget has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_messages_sanitize.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e28bc2e4f6002e3d9a3c01fcb67c859e27a9484cf4ec699bd0c41258f172b95"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.SanitizeGeminiRequestThoughtSignatures (cyclomatic 27): signature.SanitizeGeminiRequestThoughtSignatures has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 6 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 44). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_sanitize.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e6080226ba40d2ee0dc501818a705655d7fa76d22327dfea0a34451b7be5bfe"}},{"ruleId":"D1","level":"warning","message":{"text":"handlers.BuildOpenAIResponsesStreamErrorChunk (cyclomatic 27): handlers.BuildOpenAIResponsesStreamErrorChunk has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai_responses_stream_error.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"33fcf12efce1db01a95f63398a48d9bddb3488ed282dae8ae242e7350ca3a66a"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.WriteErrorResponse (cyclomatic 27): BaseAPIHandler.WriteErrorResponse has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_errors.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae90bfb71c21dc94322f2f86e75f44b69191a48438b6aa28c563de5a09a63c53"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.normalizeResponseSubsequentRequest (cyclomatic 27): openai.normalizeResponseSubsequentRequest has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"5359a122d79203c3ad743d7d8aa83c8eecaed34c75373dd02cb2d709b0c9d65f"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.repairResponsesToolCallsArray (cyclomatic 27): openai.repairResponsesToolCallsArray has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d424d5e3eaef0c5d4bcfb9d071119b1a85c4fc1d0b0908b970cab03abe6498d"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.pickNextMixed (cyclomatic 27): Manager.pickNextMixed has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1371}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e536307248a8c8d073a09f9aa07af08fb515d060538cb973888d205d901a1cb"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.runHomeConfigWorkerWithSupervisor (cyclomatic 27): Service.runHomeConfigWorkerWithSupervisor has cyclomatic complexity 27 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"92ea9dde35a1c16ad7f3c23428f38115e2cad7d2b3dd6a081863e8abada44b36"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Shutdown (cyclomatic 27): Service.Shutdown has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 2 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 232). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_lifecycle.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae6b5047a2537c86f5b04b568a68dcfd6ff2464447ad75da0bd80f460e92e30"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchAuthFileFields (cyclomatic 26): Handler.PatchAuthFileFields has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_fields.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"a470cb796dde571324e37ae048f2bbac05b4987470a44511a7c49e251b281e2c"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.RequestAntigravityToken (cyclomatic 26): Handler.RequestAntigravityToken has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 5 of the 26 points are its own statements and the rest belongs to one function literal inside it that branches (line 381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2b61d108b9506440861362662bed0f6c570416acee4d4a2b0804bbf6b022dda"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.Start (cyclomatic 26): Server.Start has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a439803911c32ce372a84d65aa81dccb75191392497e5acec2aa1e49fc3b788"}},{"ruleId":"D1","level":"warning","message":{"text":"config.LoadConfigOptional (cyclomatic 26): config.LoadConfigOptional has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_load.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2489551877cbcc4944ad205a5c6668b25e288dc7d39226beed17e165b40887d"}},{"ruleId":"D1","level":"warning","message":{"text":"logging.writeRequestInfoWithBody (cyclomatic 26): logging.writeRequestInfoWithBody has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"98773235abe7b4d6766268382c9f7ac6304e2378bd5beb59fb096a88fc1cc298"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.RegisterExecutors (cyclomatic 26): Host.RegisterExecutors has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"937dcd354fb3c2feb1e93cd506c76f9dbc3af9d2551d73e70f43cf878447bcc9"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.sanitizeOpenAIResponsesReasoningEncryptedContent (cyclomatic 26): executor.sanitizeOpenAIResponsesReasoningEncryptedContent has cyclomatic complexity 26 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_responses_signature.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bacc652a60d955acc7d4a9e76c4a20f6ab344e37eebab9cd489116dc0ab185d"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.filterXAIReasoningReplayItemsForInput (cyclomatic 26): executor.filterXAIReasoningReplayItemsForInput has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_reasoning_replay.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5a7392626ef56c04e2c76062a5c4047fb241bf3beecf8bff0009692212ae78c"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.buildRequest (cyclomatic 26): AntigravityExecutor.buildRequest has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_request.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c95b3f69869fdade1ee8f76b8462ce17ba5e862c93c7ca6b89fa1a16245dde7"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiExecutor.ExecuteStream (cyclomatic 26): GeminiExecutor.ExecuteStream has cyclomatic complexity 26 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 13 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9326a6a0adeb0a6bbd4607842cde2d5bbcea3962b6022a2e0e66e9dbc450556"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiVertexExecutor.executeStreamWithAPIKey (cyclomatic 26): GeminiVertexExecutor.executeStreamWithAPIKey has cyclomatic complexity 26 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 12 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"b26ff8bf4fbabc95b56223a2684f714711b7842d0bef049315d13a263b341a9d"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.CachedUserIDRequired (cyclomatic 26): helps.CachedUserIDRequired has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/user_id_cache.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"f47f13aee46d393ac96cdc896dc5b5d658e7e8185897b1307768f3436f6c9e30"}},{"ruleId":"D1","level":"warning","message":{"text":"util.FixJSON (cyclomatic 26): util.FixJSON has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/translator.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a25ae70583456496f25b8cbe753835487a0236eea2f07493ff719152ba89261"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.imagesEditsFromJSON (cyclomatic 26): OpenAIAPIHandler.imagesEditsFromJSON has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"71afdae3c57a638c479358bcc63bc5aedca8ab3037fd5efa738e92164a9929da"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.nextRefreshCheckAt (cyclomatic 26): auth.nextRefreshCheckAt has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/auto_refresh_loop.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecca6939931fcc3dce89cd16c9d43a09d98ff10331da32d2965ba23e10ff6026"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.resolveAPIKeyConfig (cyclomatic 26): auth.resolveAPIKeyConfig has cyclomatic complexity 26 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fa24c7ca4972972105a2a9404e2593e11e6c41d783606dc39829be70d3864d0"}},{"ruleId":"D1","level":"warning","message":{"text":"Auth.indexSeed (cyclomatic 26): Auth.indexSeed has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/types.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"844fe3e44c43012d9cc05e89b2e20ae82f037efdc738effc7a8fe11e7b3ed7a7"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginhost.registerRPCPlugin (cyclomatic 25): pluginhost.registerRPCPlugin has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/rpc_client.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"756a442ddb03a35002d81e9a90c4013ba5aa390be4270196b3155078c6d03576"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.ModelsForAuth (cyclomatic 25): Host.ModelsForAuth has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"64b29fb80f46d3c61313fc818bcf4213c79ebef66aa7e8c97a8abbb8183446af"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.ValidateGeminiFunctionCallPairing (cyclomatic 25): signature.ValidateGeminiFunctionCallPairing has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_validation.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"83c7cc78c8c8c9c202489b3b7d0a76072eb9dd8fe73b00cedfb413c756f823bd"}},{"ruleId":"D1","level":"warning","message":{"text":"GitTokenStore.Save (cyclomatic 25): GitTokenStore.Save has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5d2ebdb25c2a2f4c3a64bbf3484a375a56d543d65f40322ac000a08e293e60c"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.rewriteGeminiFunctionNames (cyclomatic 25): gemini.rewriteGeminiFunctionNames has cyclomatic complexity 25 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 9 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc8df0d24c64b8cd70bfb644b67c02eb0a1f971c157df77e11d37f36f5a0eb2"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertCodexResponseToGeminiNonStream (cyclomatic 25): gemini.ConvertCodexResponseToGeminiNonStream has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 10 of the 25 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 304, 291). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"aebba614810e73db2a849f8b17d289ae0d76b7ed246a206a7770dc17a4459872"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.reloadClients (cyclomatic 25): Watcher.reloadClients has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ccc31b275ba6e29989f1dbd273fa34fdfa0b3932a9bb0c9a3c63ff989542bb3"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.parseDurationValue (cyclomatic 25): auth.parseDurationValue has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"61ec305518b986c93c506d3b25bb0b7548b641a7dc6ce32684cdb12388981b62"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.rebuildAPIKeyModelAliasLocked (cyclomatic 25): Manager.rebuildAPIKeyModelAliasLocked has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"068e9bd28d96eca5be2f8fc19f216af79ba013b7296460f3e08f70bd56cdfaf8"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.refreshAuthForRequest (cyclomatic 25): Manager.refreshAuthForRequest has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"e52d363a7cd34dbedabb27bccaecacd24171888ac4e6e599f09e7df654696714"}},{"ruleId":"D1","level":"warning","message":{"text":"management.tokenValueFromMetadata (cyclomatic 24): management.tokenValueFromMetadata has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"485c04ff90b2463914bf53bca076a3ea16eb9ab262d03a67ea5eabf161c2bdfe"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.RequestAnthropicToken (cyclomatic 24): Handler.RequestAnthropicToken has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 88). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"990f10e62a8f0899acdff578a451dfafe09efd071059620e4eacf58d7d8ed990"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchXAIKey (cyclomatic 24): Handler.PatchXAIKey has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1406}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddf1935016c8fe526343a226b3d587aa9fdebb971ba78556c5089d74faa71e0f"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.handleOAuthCallback (cyclomatic 24): Handler.handleOAuthCallback has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/oauth_callback.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"f63a71e31205e0525cc900a1988abd3b4b1442d6cd59f65d943a7c26dfb76b59"}},{"ruleId":"D1","level":"warning","message":{"text":"credentialweight.ParseValue (cyclomatic 24): credentialweight.ParseValue has cyclomatic complexity 24 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/credentialweight/weight.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"438267705d88b22e0fe1ab49af300675142fd2f1e729b93288f10f02680472c0"}},{"ruleId":"D1","level":"warning","message":{"text":"GitTokenStore.recoverRepositoryLocked (cyclomatic 24): GitTokenStore.recoverRepositoryLocked has cyclomatic complexity 24 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"f65029d460f86cf55b73425bf4f5b76f1f8cfe2ee47920ccaf8079a5efdc55ca"}},{"ruleId":"D1","level":"warning","message":{"text":"PostgresStore.Save (cyclomatic 24): PostgresStore.Save has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgresstore.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e0e0026d91320429c04e8f4a01ebb1e46adddcc97177ee0f974cae96685d4e0"}},{"ruleId":"D1","level":"warning","message":{"text":"thinking.ExtractSummaryConfig (cyclomatic 24): thinking.ExtractSummaryConfig has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/summary.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"82a6b88f0322ed0e82dd9a72aa8e0013e05bc2eb0e265e309f67b263b0ad5f1d"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.rewriteInteractionsFunctionNames (cyclomatic 24): interactions.rewriteInteractionsFunctionNames has cyclomatic complexity 24 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 9 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"475029b885211ce383f7f30a7060a6343a3b933668af6af0520a7d21541085ca"}},{"ruleId":"D1","level":"warning","message":{"text":"logsTabModel.Update (cyclomatic 24): logsTabModel.Update has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/logs_tab.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"3453e9f4c2e9e6c5832745a2b7a2956846e37eefdce82c40e811796c02f6a5f6"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.NonStream (cyclomatic 24): Manager.NonStream has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdeef419ba0973f59debd307c3ec21806e7773235f0e8b6643b2f7c4138d5281"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.ForwardStream (cyclomatic 24): BaseAPIHandler.ForwardStream has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/stream_forwarder.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"9be93a5a8da4f9e88e76494de38acf8ed5fe522bea61e19cd97b28f4850e4984"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.convertChatCompletionsStreamChunkToCompletions (cyclomatic 24): openai.convertChatCompletionsStreamChunkToCompletions has cyclomatic complexity 24 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5a4c10319b20f5a7c97127b5b9213c070cc23b4c73128b7eeb33f3f08e80f11"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.collectImagesFromResponsesStream (cyclomatic 24): openai.collectImagesFromResponsesStream has cyclomatic complexity 24 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1569}}}],"partialFingerprints":{"codehealthFindingId/v1":"27c4f72d8293c354a1fa819d660a8c36bf9d99ff0f962498461c2d705f86d3fe"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.ImagesGenerations (cyclomatic 24): OpenAIAPIHandler.ImagesGenerations has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"259ba82ec9cf794a9da8833f2b692cf364827bde4d81fa870d6b41bf69ccee2c"}},{"ruleId":"D1","level":"warning","message":{"text":"cliproxy.applyOAuthModelAliasEntries (cyclomatic 24): cliproxy.applyOAuthModelAliasEntries has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":934}}}],"partialFingerprints":{"codehealthFindingId/v1":"33dd6f17260c1bcc6452b1beed120d201ac686e7abdd0ac778fd534d045fee61"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.pickNextLegacy (cyclomatic 24): Manager.pickNextLegacy has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"516187ba60e99b18cf18cfa7ef06dd11873fa578e689b219253239ca2a0d209f"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.wrapStreamResult (cyclomatic 24): Manager.wrapStreamResult has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to one function literal inside it that branches (line 118). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4963b1dfa5269f7e908309dc32201ffe0eb21edb3717b9e52b128f359076068"}},{"ruleId":"D1","level":"warning","message":{"text":"main.main (cyclomatic 23): main.main has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_antigravity_models/main.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"45a136c8ed1b49ce272258135867b6ddd73505734e31081905fb005b4b4110be"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.APICall (cyclomatic 23): Handler.APICall has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"1afcdd2ccf90db615f2f01a457a4ca9d1c1fe958f69f7968969909439b0196ee"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchOpenAICompat (cyclomatic 23): Handler.PatchOpenAICompat has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"473e72921e03f1378859183794dde3a3aadee27205770f759dc9ade8f5437ca1"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchVertexCompatKey (cyclomatic 23): Handler.PatchVertexCompatKey has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"73210f5514229af32b3de1283496e3ccc83c0e3c8d69ec1e8ea40310333c2b17"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.GetLogs (cyclomatic 23): Handler.GetLogs has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fd0266456ff09826f7c1d87d9ff5962d1fb9354ed96e23737d8c6f18f2c814a"}},{"ruleId":"D1","level":"warning","message":{"text":"api.NewServer (cyclomatic 23): api.NewServer has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6232ea4ade919170892223977fe0cc3f527ed4e130e76df5de2b542ea038f94"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.codexReasoningReplayTurnAnchorIndex (cyclomatic 23): executor.codexReasoningReplayTurnAnchorIndex has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"83764a7a4e580311a00200c433ddc34cf67d243843a0e8c24b3a7648ecc03344"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.EnsureClaudeCredentialDevicePoolRequired (cyclomatic 23): helps.EnsureClaudeCredentialDevicePoolRequired has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"e903a54d74faccf57b4d9d8fe9175e85ada33e1ff7a49bef1d351b15e959f563"}},{"ruleId":"D1","level":"warning","message":{"text":"ObjectTokenStore.Save (cyclomatic 23): ObjectTokenStore.Save has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b3c393ffffd7e2bff3d043f4bc54933a796a5ce44e92c015bfbc35ca3790bcb"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToAntigravity (cyclomatic 23): gemini.ConvertGeminiRequestToAntigravity has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 9 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 95, 69). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"d88eda98dba01ade58a0cef6cb1c710e99233bbfcfcb265b023de7ddd011e529"}},{"ruleId":"D1","level":"warning","message":{"text":"FileTokenStore.Save (cyclomatic 23): FileTokenStore.Save has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb6dd0b5a36fe1550f9270ba860ba0bb7b9eb78f7a1c9321a6469d4dcc675bb2"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.encodeHomeInFlightFreeze (cyclomatic 23): auth.encodeHomeInFlightFreeze has cyclomatic complexity 23 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38240562ead2ab612206de6aad57151a51f32c03106d2350d131ba2a8748a39"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.ResetQuota (cyclomatic 23): Manager.ResetQuota has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b022dab3d96a7c0d9e86d524d1213604a9602e46153756ec43bc1187555aacb"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.applyConfigRuntime (cyclomatic 23): Service.applyConfigRuntime has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_config.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f865efdd3c8d945714d89c4301ac25b7a7f8d563afb20d032731578eac24e1"}},{"ruleId":"D1","level":"warning","message":{"text":"main.fetchModels (cyclomatic 22): main.fetchModels has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_antigravity_models/main.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"832770b6e297fe7f690a1ccf88d033446384e9be6e86e02bc5c8e06010a17792"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchCodexKey (cyclomatic 22): Handler.PatchCodexKey has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1224}}}],"partialFingerprints":{"codehealthFindingId/v1":"45872d9cbdf584f0198312629f20f05d265d676d1b6442a332be4cc9bf948c17"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.AuthenticateManagementKey (cyclomatic 22): Handler.AuthenticateManagementKey has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/handler.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9dc3bf7e1668a55ed9cc49b4660e571b715a891de0b6527b5d23fa769a0ec96"}},{"ruleId":"D1","level":"warning","message":{"text":"cache.GetAntigravityReasoningReplayItemsWithSnapshotRequired (cyclomatic 22): cache.GetAntigravityReasoningReplayItemsWithSnapshotRequired has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"adac6e2ef60c89a5fb64be04511d466ff5fcd812cf6c354109ac60d49228f769"}},{"ruleId":"D1","level":"warning","message":{"text":"live.prepareProxiedUpstreamAnswer (cyclomatic 22): live.prepareProxiedUpstreamAnswer has cyclomatic complexity 22 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/tcp_proxy.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fe90e0bde93df9bd5d1b5f523cb76e11e290188c18969b0fc475c490672edf7"}},{"ruleId":"D1","level":"warning","message":{"text":"config.mergeNodePreserve (cyclomatic 22): config.mergeNodePreserve has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0ec731c389b703a14f919b2ba8740923d5cf40e8ff3c63f592205713c0f7abe"}},{"ruleId":"D1","level":"warning","message":{"text":"managementasset.EnsureLatestManagementHTML (cyclomatic 22): managementasset.EnsureLatestManagementHTML has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 3 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 203). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/managementasset/updater.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"1848da5694d20f1ea444077b7028f1822fc6a74a3d25fa9b83fecc3517072569"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.codexStatusErrorClassification (cyclomatic 22): executor.codexStatusErrorClassification has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"6203a26f28b9194f90be92ea5ef84dceaefb5c06d56915c84a4ddfdb8b9595ed"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.rewriteOpenAICompatImagesMultipartPayload (cyclomatic 22): executor.rewriteOpenAICompatImagesMultipartPayload has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":699}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf70027a2afc500cccf76d9b72bf9d4b78f93d7c248c99698709f3633a10042"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAICompatExecutor.executeImagesStream (cyclomatic 22): OpenAICompatExecutor.executeImagesStream has cyclomatic complexity 22 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa33dd8674f8c75c0c686e170d4ab6722099297be7cf02b58960f9769c9a6df5"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.fixCLIToolResponse (cyclomatic 22): gemini.fixCLIToolResponse has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 7 of the 22 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 606, 589, 567). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"247a281a5a3ce9a02911b7beafdf19fd627129302ec935e1541df2430ca582b8"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.applyAuthFailureState (cyclomatic 22): auth.applyAuthFailureState has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1578}}}],"partialFingerprints":{"codehealthFindingId/v1":"122af79f718e39e57aeb7f6f966f125b4ecdd7e26ec8c5c44bc0f6b5884e2489"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.extractSessionIDs (cyclomatic 22): auth.extractSessionIDs has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3e1b9ae11f39a81a104d2f95772d3fc6fbd18018f6ab367cdf2c65d2f6a62db"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.shouldRefresh (cyclomatic 22): Manager.shouldRefresh has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"76b00f76deaa2f1764f6fe1eb835c21be3049b7a8b76be89406ca97bf9fa6ec3"}},{"ruleId":"D1","level":"warning","message":{"text":"main.main (cyclomatic 21): main.main has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_codex_models/main.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"a38ce21a1cf06f07cb4456f3963c196aac951b6cf334d588f424d6f0dbb91419"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.refreshAntigravityOAuthAccessToken (cyclomatic 21): Handler.refreshAntigravityOAuthAccessToken has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"88ac68887b7f54c50a24d7470ff5a083e3506aa66c8d91dc0754daa67614727d"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchGeminiKey (cyclomatic 21): Handler.PatchGeminiKey has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"531c5c147c5d04feea7161762a952f53ce494f67c0dce7c947d509438942b666"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchInteractionsKey (cyclomatic 21): Handler.PatchInteractionsKey has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"f419aa2142542dffef5840318497db8bd58ec429ea3063e827d28c9d9a7ab601"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchClaudeKey (cyclomatic 21): Handler.PatchClaudeKey has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"d02748e23f101d34e956f2cfcd6f2386e72022ddd4046ce24282edfca094af59"}},{"ruleId":"D1","level":"warning","message":{"text":"multiagentv2.restoreCodexCollaborationValue (cyclomatic 21): multiagentv2.restoreCodexCollaborationValue has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"747a1f5a82c1d180dfb93651f0b7f227282560de53566b418b872be9a25d916b"}},{"ruleId":"D1","level":"warning","message":{"text":"FileRequestLogger.logRequestWithSources (cyclomatic 21): FileRequestLogger.logRequestWithSources has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_writer.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"3801b698d16297bfb41c770c2298efdbf0ee40e08e866ebcf88fc257923ea09e"}},{"ruleId":"D1","level":"warning","message":{"text":"misc.ParseOAuthCallback (cyclomatic 21): misc.ParseOAuthCallback has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/misc/oauth.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae6b6859917da9e6644eba8675fbf4c0451b1d3e92a8e56f29a59a6acb370d4"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginstore.ValidateResolvedAuthConfig (cyclomatic 21): pluginstore.ValidateResolvedAuthConfig has cyclomatic complexity 21 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/auth.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"e015b6eb94596ef55c2fd15f4d1626487f88e427b665ce453dfd4c336ec50b92"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiVertexExecutor.executeWithServiceAccount (cyclomatic 21): GeminiVertexExecutor.executeWithServiceAccount has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"326e017ac9c65f5d18a1d2f72d6ff20d6e551f32a33c9e98dbbe56055e78c2c5"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.RefreshAuthViaHome (cyclomatic 21): helps.RefreshAuthViaHome has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/home_refresh.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf863295f137e916e3161f5be96d3c482140f0da386cf5f9d6879b6e2ff5dc15"}},{"ruleId":"D1","level":"warning","message":{"text":"thinking.applySummaryConfigForProvider (cyclomatic 21): thinking.applySummaryConfigForProvider has cyclomatic complexity 21 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/summary.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e00c1eaf2ecd628b82b42ee4b590d579229a26e268adbde71b19bcdf366890a"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.SanitizeAntigravityClaudeGeminiRequestSignatures (cyclomatic 21): gemini.SanitizeAntigravityClaudeGeminiRequestSignatures has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"08609c4f9c69d10c2f0ee61cdb717323b507f740c870d6d88389e42e99456cd3"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.addOrUpdateClientLocked (cyclomatic 21): Watcher.addOrUpdateClientLocked has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"969abd7965f80b8efc72021da9a49d575e1a57745e3d482239a197793da51a46"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.writeResponsesWebsocketError (cyclomatic 21): openai.writeResponsesWebsocketError has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_forward.go"},"region":{"startLine":481}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aaa310a4d3edd5513cb162ba8093c399bba03147a709df80e44a86092059cb8"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.pickNext (cyclomatic 21): Manager.pickNext has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1211}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9ca41fb5f678d628ebc6591fbc2f2e16ed4a0897ee7d9b4d95b67a23eac18b1"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.DeleteAuthFile (cyclomatic 20): Handler.DeleteAuthFile has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c80034a41458b5be144a211bcbf4a87094293682ff7a6a5cdd2094f54e16096"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.buildAuthFromFileData (cyclomatic 20): Handler.buildAuthFromFileData has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"29bb8d5ee27dff6355f53df13fe670b73652ab5f5557ae2f06b2717f57620ec6"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.RequestCodexToken (cyclomatic 20): Handler.RequestCodexToken has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 7 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 248). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"0002e4c0be4b45a2d25b075d7192dfa40727f884f7bf19073df48b711b67555e"}},{"ruleId":"D1","level":"warning","message":{"text":"config.matchSequenceElement (cyclomatic 20): config.matchSequenceElement has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe326514ca75003f759367b4e0d35b3c5d9f3c93ec7e5fc2c2e653fa0d2c483f"}},{"ruleId":"D1","level":"warning","message":{"text":"chunkedRequestTracker.consume (cyclomatic 20): chunkedRequestTracker.consume has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/httpwire/ordered_conn.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"52f521f42885ce66a5f6be9f053d85ff1b889b8cec14d6a62929471991d22078"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.restoreAntigravityNativeFunctionCallReplay (cyclomatic 20): executor.restoreAntigravityNativeFunctionCallReplay has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1337}}}],"partialFingerprints":{"codehealthFindingId/v1":"06fbb5219d8f538c9ac3f126dc9778b8e91ba4a2078c8bdd40b6ada20b4617ec"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.applyCodexWebsocketHeaders (cyclomatic 20): executor.applyCodexWebsocketHeaders has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_request.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"a93955a4a94bcea8f1382bb4aca65c7a60e8639d09aaa89eb3f8c2f38e2c0831"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.executeDirectOpenAIImageStream (cyclomatic 20): CodexExecutor.executeDirectOpenAIImageStream has cyclomatic complexity 20 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc7e5d982252017a4722b0affff763e3455a9011ccce00dbc91c13082c32fccb"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.CachedSessionIDRequired (cyclomatic 20): helps.CachedSessionIDRequired has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/session_id_cache.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"b94dbae750f2c965d7cd6d318944c12afee9cb07df856d809fa7f75461ee5561"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAICompatExecutor.Execute (cyclomatic 20): OpenAICompatExecutor.Execute has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea0a7377c32b829e89527e98bf51f0b64a26a52d29e1938a2d5db23700be5f3c"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.ValidateGeminiThoughtSignatures (cyclomatic 20): signature.ValidateGeminiThoughtSignatures has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_validation.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6beb39f4877ba565af46ebf8acd3af0281e41ab25c0f28be09c4f2ab8f17a6d"}},{"ruleId":"D1","level":"warning","message":{"text":"store.reconcileRemoteWorktree (cyclomatic 20): store.reconcileRemoteWorktree has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"40d2b0e003cb07dc828bafa273ccd67f6f999c8969685da5c9990e62b6dfddbe"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.applyCompatibleClaude (cyclomatic 20): claude.applyCompatibleClaude has cyclomatic complexity 20 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"71307055652ccf9168dada2d755562657fe515b8cd94333b1795cf9274dcb96f"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.appendInteractionsContentToAntigravityPart (cyclomatic 20): interactions.appendInteractionsContentToAntigravityPart has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2ae7e88a4c06919a627614fa6debe7e79566b8cf46416ffa5ebda871ef7fd73"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.interactionsContentPartToGeminiPart (cyclomatic 20): interactions.interactionsContentPartToGeminiPart has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"05bd346f6d2d896905d4b889e6adaf52195d7935107e776b658d865e9c4e0bd5"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.convertClaudeToolResultContent (cyclomatic 20): claude.convertClaudeToolResultContent has cyclomatic complexity 20 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_request.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"83bb7a1bf744924beff69fc07baf03c62484bbb93ff681df1e9f5eba8cbad5b2"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeCodeAPIHandler.WriteErrorResponse (cyclomatic 20): ClaudeCodeAPIHandler.WriteErrorResponse has cyclomatic complexity 20 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"199b57e413eb688307c1fa5fb260b22a15d21d0390bc9886d35fbf3c50863784"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.buildOpenAICompatImagesMultipartRequest (cyclomatic 20): openai.buildOpenAICompatImagesMultipartRequest has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"08ef8fc5dd59b718589bff124549ab6a02a5ca3bfbc175612b5e4c4e2500b57b"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.responsesWebsocketAuthAvailableForModel (cyclomatic 20): openai.responsesWebsocketAuthAvailableForModel has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_session.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b1c03a2bcf4d106f5f27ffc666b7795635199a417a2453842c00d94678a63c"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.updateAggregatedAvailability (cyclomatic 20): auth.updateAggregatedAvailability has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":974}}}],"partialFingerprints":{"codehealthFindingId/v1":"83b2af7c57926fae5dd7504705878cb19d1a38bd366c088a5302feda1fd74cfe"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.containsStructuredModelNotFound (cyclomatic 20): auth.containsStructuredModelNotFound has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1383}}}],"partialFingerprints":{"codehealthFindingId/v1":"443e892d32b8eb4c9ba542953d3cd4f03a7c152ebfb50d124517179caa87f913"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.packHomeInFlightFrames (cyclomatic 20): auth.packHomeInFlightFrames has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"19c9aa4a25244b49f1a8bd07a4c636f7749b507f554818854332053233fb3f00"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.pickSmoothWeightedScheduled (cyclomatic 20): auth.pickSmoothWeightedScheduled has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":1068}}}],"partialFingerprints":{"codehealthFindingId/v1":"9185616189760535b6ef63934234602cbf2ecc2356711c53493f0c51021b7d9d"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.Update (cyclomatic 20): Manager.Update has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_lifecycle.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"890ecf4fc1e5b4ac8418dc5a569e047269342cf23fd295ae2df4ea9ebb70acf5"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.ReconcileRegistryModelStates (cyclomatic 20): Manager.ReconcileRegistryModelStates has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d52aa4103881f657f41986b84f1941c69afe31397c1a899f9e37eb6ec6d0713"}},{"ruleId":"D1","level":"warning","message":{"text":"Builder.Build (cyclomatic 20): Builder.Build has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/builder.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"0568ec7863c52de2f6446c76b3bcf150aed69c601aa9601df5592a35dd58dd68"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.resolveConfigClaudeKey (cyclomatic 20): Service.resolveConfigClaudeKey has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"d87a814f189775ed31d17e63945d4a31f957330fdecc7b5950cdbc795e7111c8"}},{"ruleId":"D1","level":"warning","message":{"text":"httpConnectDialer.DialContext (cyclomatic 20): httpConnectDialer.DialContext has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/proxyutil/proxy.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"334545423e2303df8194882ac8e68572feb856be2c20f96caeeddd1908cc3fc1"}},{"ruleId":"D1","level":"warning","message":{"text":"management.resolveAPIKeyConfig (cyclomatic 19): management.resolveAPIKeyConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf85ee0b0346b53eb4da99002ff970fd59b5e30cdc75fab6f6bf6be9d6c3ad6e"}},{"ruleId":"D1","level":"warning","message":{"text":"management.readCompleteLogLines (cyclomatic 19): management.readCompleteLogLines has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":1081}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecbd5b8ac11ae40285391895319756fe5d74dadd8ec4e7209eedc1f53970588b"}},{"ruleId":"D1","level":"warning","message":{"text":"cache.normalizeAntigravityFunctionCallPartReplayItem (cyclomatic 19): cache.normalizeAntigravityFunctionCallPartReplayItem has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"f599cf1cdd83ededa47c3d8532ed419a0d9d401a442374120fbb512203204e31"}},{"ruleId":"D1","level":"warning","message":{"text":"config.ValidateCredentialConcurrency (cyclomatic 19): config.ValidateCredentialConcurrency has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/credential_concurrency.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"b79f4d50038a92e2b4659d07e920171bc9babd66fcf363dfece9ff0551141058"}},{"ruleId":"D1","level":"warning","message":{"text":"CredentialConcurrencyConfig.WithDefaults (cyclomatic 19): CredentialConcurrencyConfig.WithDefaults has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/credential_concurrency.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"f01ca6d2b1ca28df2d96ee16e53b8b45d1738c7fe417a6cb9a2a9b18c4040420"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.commitExecutorState (cyclomatic 19): Host.commitExecutorState has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1e344bbc11f328585c16fda6ae9b8c33327446a5b1f1f517adf863f26d936f9"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.RefreshAuth (cyclomatic 19): Host.RefreshAuth has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_provider.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b5c2934d2e9edb938f017b3b6017a7ec6519814563b821750ad980fca72513f"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.filterCodexReasoningReplayItemsForInput (cyclomatic 19): executor.filterCodexReasoningReplayItemsForInput has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"7747763bc5afc4fb58f711f92b5386069df7f65ce7c043e6fcfa99b50ef37583"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.codexRewriteOpenAIImageEditMultipartToJSON (cyclomatic 19): executor.codexRewriteOpenAIImageEditMultipartToJSON has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"38262240d2d8f3a75f3959847192a1ab212de326604f7ab26063ae84e7d34667"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.sanitizeXAIInputEncryptedContent (cyclomatic 19): executor.sanitizeXAIInputEncryptedContent has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d3e361506c970e4e1ff6545c1a952c18d0e6940797ac94b76980a411010a8d1"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.resolveCodexConfig (cyclomatic 19): CodexExecutor.resolveCodexConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_auth.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"e34c416fdfc0b417a68b7a08c4252f5c33697fa84daaec8446b9b03af17c1a3f"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.executeOpenAIImage (cyclomatic 19): CodexExecutor.executeOpenAIImage has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b00eb23b419aac4f3855a04ae89a65633ed39c047ad8438ec6e705115a4c429"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiExecutor.resolveGeminiConfig (cyclomatic 19): GeminiExecutor.resolveGeminiConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d18ff1441ed45b6ca2e455b85f79a1a4a01a8c1b2748a019e337a806ba5b02c"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiVertexExecutor.resolveVertexConfig (cyclomatic 19): GeminiVertexExecutor.resolveVertexConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":1113}}}],"partialFingerprints":{"codehealthFindingId/v1":"22030880ae0af50182611e4d2a84eaa9f096cae3d86f413dd9fd9f7398c55cec"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeInputTokenState.applyChunk (cyclomatic 19): ClaudeInputTokenState.applyChunk has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_input_tokens.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"362b299f7cc2faced8ac273fe062bb0eeb3fc524b5b5ef5580d4994cfd216a30"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAICompatExecutor.resolveCompatConfig (cyclomatic 19): OpenAICompatExecutor.resolveCompatConfig has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fc3d2deb10c8957eea00a0b8db1400ff4cf4b8a707c2eefcb9f1c23d893eb1c"}},{"ruleId":"D1","level":"warning","message":{"text":"store.deepEqualJSON (cyclomatic 19): store.deepEqualJSON has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1842}}}],"partialFingerprints":{"codehealthFindingId/v1":"74a27af8ebaa366daf9a377b9b54111c36862863f3326dd915644fda18785ece"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.ConvertGeminiResponseToClaudeNonStream (cyclomatic 19): claude.ConvertGeminiResponseToClaudeNonStream has cyclomatic complexity 19 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"126e8896938d8afae5e4453699ab12f545d59996261690f47f129fa256a5c73d"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToGemini (cyclomatic 19): gemini.ConvertGeminiRequestToGemini has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 8 of the 19 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 36, 78, 90, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f218ad226660cd64d4486c263f8f4d827556ed01b76b32a8273a3607196cb5c"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.dedupeInputItemsByID (cyclomatic 19): openai.dedupeInputItemsByID has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"16c1c6b72d2178c752032e0eff64f94a95672803d8863d51475efd008b47970c"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.streamImagesWithModel (cyclomatic 19): OpenAIAPIHandler.streamImagesWithModel has cyclomatic complexity 19 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1434}}}],"partialFingerprints":{"codehealthFindingId/v1":"824582fd89dec5c7a825da827e41585d98ae33bd94dbc944979cdb3104490f18"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.deepEqualJSON (cyclomatic 19): auth.deepEqualJSON has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"399c5b21e7dba2812f907fa2f52d70ea3ecabbb5c563ee732ed532d246ed0645"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.configuredModelAliasEntries (cyclomatic 19): auth.configuredModelAliasEntries has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"a67c916a41f89af3b2cac6e9711dda88fc8390d58d623b945e596cc05967c3e4"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.closestCooldownWait (cyclomatic 19): Manager.closestCooldownWait has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":651}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3f3d3d4ecbdc972afe48f1970e7a7fb521d69d81be5cf292a91e5d23ea16850"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.GetAuthStatus (cyclomatic 18): Handler.GetAuthStatus has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"750f53c82e5c41ccb11c70fd9316cdcd6cbfd6f3ea96716ef94eefc741f89a85"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.GetRequestLogByID (cyclomatic 18): Handler.GetRequestLogByID has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"55ab8598bb7617911d7f7df36ca103ba3ef3dc071479f07f6e93dddf65b7d0f3"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.ListPlugins (cyclomatic 18): Handler.ListPlugins has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba044a988dad28e846490b7730472939caf20cbccd448cadf75de30ee8c94550"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.DeletePlugin (cyclomatic 18): Handler.DeletePlugin has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3e28954f1652a263e8ec210c61ee10157c32a78c505ded013db914a213dc71a"}},{"ruleId":"D1","level":"warning","message":{"text":"multiagentv2.codexSpawnAgentModelsFromSources (cyclomatic 18): multiagentv2.codexSpawnAgentModelsFromSources has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"28f04fa5a9c461eecf3c766d0559d1135ae48e4e1c3bce76fd29419202101285"}},{"ruleId":"D1","level":"warning","message":{"text":"config.cloneRuntimeValue (cyclomatic 18): config.cloneRuntimeValue has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/clone.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"0edbdb2ac19b8ffc3ee919436e91be65a918e04be5e2c3a35f3e5e82669c0483"}},{"ruleId":"D1","level":"warning","message":{"text":"config.ParseConfigBytes (cyclomatic 18): config.ParseConfigBytes has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/parse.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"83540319a99ed8af5723ff5f9fc69782fc973cc68988cdb6117c24458629e3b6"}},{"ruleId":"D1","level":"warning","message":{"text":"homeplugins.deletePluginArtifact (cyclomatic 18): homeplugins.deletePluginArtifact has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"13fa060261584d6c7ccaa7922e9d4d4606375b7596aed14987e8f01723018f3c"}},{"ruleId":"D1","level":"warning","message":{"text":"homeplugins.pluginFileInfos (cyclomatic 18): homeplugins.pluginFileInfos has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"378bea298fce9a8987d299c63237f094ca54276ab624616cd2927af1e580d220"}},{"ruleId":"D1","level":"warning","message":{"text":"FileRequestLogger.formatLogContent (cyclomatic 18): FileRequestLogger.formatLogContent has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":448}}}],"partialFingerprints":{"codehealthFindingId/v1":"78e4fdabeb18079337d8c6a7f73b186978cf5cee18e65049e25214d8350a82d2"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.validateClaudeStreamingResponse (cyclomatic 18): executor.validateClaudeStreamingResponse has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_stream.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"c90029b79f9429b95c0347bb47d7f99ad0c7d5c75844bbf3c7c949de7b21ff5e"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.codexExtractImageResults (cyclomatic 18): executor.codexExtractImageResults has cyclomatic complexity 18 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"509a998aa25aa4df2f9c8cf93725b16a1a5a454c05a29fee81bb69986c1ecc63"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityExecutor.updateAntigravityCreditsBalance (cyclomatic 18): AntigravityExecutor.updateAntigravityCreditsBalance has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"02742ce379f75994d1f7d9507bd7df716aacea0a756a9d00b74f57da988cc4de"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexExecutor.cacheHelper (cyclomatic 18): CodexExecutor.cacheHelper has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_request.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"72bcbcfc29fbea3c22cb9a12f6051f5b302a8fad91866548955e6a9d8afa8e28"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIExecutor.Execute (cyclomatic 18): XAIExecutor.Execute has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_execute.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"af35b6582bc92892b7cd391feda0712ca00d315798c8513e8ce08874d309058b"}},{"ruleId":"D1","level":"warning","message":{"text":"signature.DetectSignatureProviderForBlock (cyclomatic 18): signature.DetectSignatureProviderForBlock has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/provider_compatibility.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cd8a0eee0c0a677d5d5c95e7aebbd9109e580be37e45123ed2c07b9051ab01f"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.copyInteractionsToolChoiceToAntigravity (cyclomatic 18): interactions.copyInteractionsToolChoiceToAntigravity has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8d295e01bc8b4501b003b02eeb29625ae54dd5cb1ecae2522d981f88d159970"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.rewriteOpenAIResponsesReasoningForAntigravityClaude (cyclomatic 18): responses.rewriteOpenAIResponsesReasoningForAntigravityClaude has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/responses/antigravity_openai-responses_request.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd8a7c54de6cfbf259b0469e382bb40c82e7afff6f24859b445e5d22e83f4f16"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.responsesToolDescriptors (cyclomatic 18): responses.responsesToolDescriptors has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 2 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 840, 816, 801). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e968e34b051d9a1a1351eef373a572666048a4d9d8468558142377f6c64a30e"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.toolOutputContentPart (cyclomatic 18): chat_completions.toolOutputContentPart has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"544bf9feb3fa91e73265cd8ab806942f852e571815db1ce20c27c23f4f8bdb1d"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.copyInteractionsToolChoice (cyclomatic 18): interactions.copyInteractionsToolChoice has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c23f0cd5671c3c0b18df68d4e2d495c00c1b9ec539bde29a77f74f86efaaae0"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.compileAPIKeyModelCapabilitiesForAuth (cyclomatic 18): auth.compileAPIKeyModelCapabilitiesForAuth has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/api_key_model_capabilities.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b9ebd67e1ea5a84c32195135e206c9cb2fac4f2b11575a15b1d0016e4caa747"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.resolveModelAliasPoolFromConfigModels (cyclomatic 18): auth.resolveModelAliasPoolFromConfigModels has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"f04524eff53f4dadf2986f0ffe6bf68925ea021b3402e3be14dc34bb8dff48f9"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.hasNativeOpenAICompatExecutorConfig (cyclomatic 18): Service.hasNativeOpenAICompatExecutorConfig has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"0db2a7faedde3b60ae4b325a50c84bec387e47ac1bb36dbae95af9800ba4c622"}},{"ruleId":"D1","level":"warning","message":{"text":"session.appendCanonicalParts (cyclomatic 18): session.appendCanonicalParts has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"946e344fe0210cb6472d2ca08589f6ce4193aa1b2e785d25a5f495d4556eaa45"}},{"ruleId":"D1","level":"warning","message":{"text":"management.proxyURLFromAPIKeyConfig (cyclomatic 17): management.proxyURLFromAPIKeyConfig has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"080861538e78fd848555a195f0f10f2bcec88e39a2dcc7e9f2f186362b7091fc"}},{"ruleId":"D1","level":"warning","message":{"text":"management.toggleConfigAPIKeyExcludedAll (cyclomatic 17): management.toggleConfigAPIKeyExcludedAll has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_apikey_disable.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"9789913bd55744220d0baf6abd6e8525a945c1b2eaa027de9fcb6c204f5f107c"}},{"ruleId":"D1","level":"warning","message":{"text":"management.readLogFilesFromCursor (cyclomatic 17): management.readLogFilesFromCursor has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"accedf6ec1cf087aa1ba6a831bc3f043bb6bee69987fcec02c59b248af8162c1"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.UploadAuthFile (cyclomatic 17): Handler.UploadAuthFile has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ee6621638b84d0bb6b4a5b8bdd3f4d120d05d2b230990037acc9dff02ff6859"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.PatchAuthFileStatus (cyclomatic 17): Handler.PatchAuthFileStatus has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_fields.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"73f77a7e52d550b80eede4071d5aa1c48dead9bab2b00caf28dfb7193d908820"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.installPluginFromStore (cyclomatic 17): Handler.installPluginFromStore has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"00260a0e9471e43743e4893b9a338b2c5ea51dc5d3f11fae2197b42d130f2776"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.routeMuxConnection (cyclomatic 17): Server.routeMuxConnection has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/protocol_multiplexer.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bf80dcf0260c19442b349ece749da648fc5369af73ed3cf9c7b12fdd6a6a80f"}},{"ruleId":"D1","level":"warning","message":{"text":"pionMediaSession.AcceptUpstreamAnswer (cyclomatic 17): pionMediaSession.AcceptUpstreamAnswer has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"930dd21a6780dc68467cefb7ccbc8ebce2c2b5dd158be5667971e718d0f3f47c"}},{"ruleId":"D1","level":"warning","message":{"text":"config.isKnownDefaultValue (cyclomatic 17): config.isKnownDefaultValue has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b69591a5682a70d7d9e2de7e69f461f0f2d34a44cbfccf907fcabb1378b3fe1"}},{"ruleId":"D1","level":"warning","message":{"text":"Config.ValidateCredentialWeights (cyclomatic 17): Config.ValidateCredentialWeights has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/weight.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"81647584c6dbf229be3517f7df1df0cf3d3362f593c16829b9062c32b8f504e4"}},{"ruleId":"D1","level":"warning","message":{"text":"Client.rPopAuth (cyclomatic 17): Client.rPopAuth has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"f69261ed386f246be8ebf0729c9b0cb96b8a8af4d8200997bc471f6b26383c13"}},{"ruleId":"D1","level":"warning","message":{"text":"logging.enforceLogDirSizeLimit (cyclomatic 17): logging.enforceLogDirSizeLimit has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/log_dir_cleaner.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"32f9c22954377b1f9d2cdf6ee2fb34e4f1e7da325b7f8c7022a87f4192a04b1c"}},{"ruleId":"D1","level":"warning","message":{"text":"logging.writeResponseSection (cyclomatic 17): logging.writeResponseSection has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"1063538c8053bc642e66e484ffc16b7ab1cd6a0407c72cd3c7fed37fbe89cb99"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginhost.normalizeCommandLineFlagValue (cyclomatic 17): pluginhost.normalizeCommandLineFlagValue has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/command_line.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"20f04f5ab3d2b476f2bbc15233a450ddb702681ca845dfbff8992238cfb87bfb"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginstore.InstallArchive (cyclomatic 17): pluginstore.InstallArchive has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"64d5321eadaf49364c67918552bb211eeefece2bf2a13ada897aa689d71b10ad"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginstore.writeFileAtomic (cyclomatic 17): pluginstore.writeFileAtomic has cyclomatic complexity 17 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7b9747d2473a2039473f3adce1f7c8706421705e9f4f118baf3f646d42a9459"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.filterAntigravityReasoningReplayItemsForRequestWithSchemas (cyclomatic 17): executor.filterAntigravityReasoningReplayItemsForRequestWithSchemas has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a48f3a1683db2f07c47758c2f8dab65768e56f1344f991022df2f9d0af1c22f"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.prependClaudeSystemRemindersToFirstUserMessage (cyclomatic 17): executor.prependClaudeSystemRemindersToFirstUserMessage has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"649cdc60320bcdb34e42a98428af16a19344e6a0451c6a696276ba3c97e1d56d"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.filterCodexReasoningReplayTurnItems (cyclomatic 17): executor.filterCodexReasoningReplayTurnItems has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"3320eefa2f989f9283f30032945fdc266b3a5bd4777643afd93086aa4d172a44"}},{"ruleId":"D1","level":"warning","message":{"text":"claudeCCHJSONScanner.parseObject (cyclomatic 17): claudeCCHJSONScanner.parseObject has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_signing.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a4cf9bbd57cd3d6fe603022143364b19584a221bf91bb4ac848c0a1597630b7"}},{"ruleId":"D1","level":"warning","message":{"text":"CodexWebsocketsExecutor.readUpstreamLoop (cyclomatic 17): CodexWebsocketsExecutor.readUpstreamLoop has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"88cdbf3ea082fc1095ca557dc02c2a07dc2af5ad6de51ab7ab6b0eeaa254dd87"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiExecutor.Execute (cyclomatic 17): GeminiExecutor.Execute has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e43b4074b42e1e146ad4a8907fc51d9f1bead229988076b5e99d3abed64adf3"}},{"ruleId":"D1","level":"warning","message":{"text":"GeminiVertexExecutor.executeWithAPIKey (cyclomatic 17): GeminiVertexExecutor.executeWithAPIKey has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee85679fd8340a0c0a355a94ea2f97d69573880ca1de48f9342f50dda87108cc"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.resolveClaudeDeviceProfileLocal (cyclomatic 17): helps.resolveClaudeDeviceProfileLocal has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_device_profile.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"acd49f5233890ab3475a45718e2e640fc5a9e93168c84297652d7bc6c3d6b43e"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.SanitizeCodexInputItemIDs (cyclomatic 17): helps.SanitizeCodexInputItemIDs has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/codex_input_ids.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"209934c2a0f3dd0ede4e5ed8a52297a12602d5650aea079f200de5df676bc01c"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.ParseRetryDelay (cyclomatic 17): helps.ParseRetryDelay has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/json_retry_helpers.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7efda369833f2459454e8cdc0664354fcd69de72ee31472d28ef4663291f2a4"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.setPayloadValueIfDifferentTracked (cyclomatic 17): helps.setPayloadValueIfDifferentTracked has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc7028dc19a0865b049671235dc07529d4139866bd35167dbdc467d449d1cac6"}},{"ruleId":"D1","level":"warning","message":{"text":"KimiExecutor.Execute (cyclomatic 17): KimiExecutor.Execute has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3f52dde83330e34e1cc5dc157a494646a344ce822f036e1dbe942a0ab59db21"}},{"ruleId":"D1","level":"warning","message":{"text":"kimiThinkingReplayStreamAccumulator.content (cyclomatic 17): kimiThinkingReplayStreamAccumulator.content has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_thinking_replay.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"38e994de0bcaf4aa6777731c8c4c4cbb7d4efb1941f510d7c412380d48d04df3"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIExecutor.Refresh (cyclomatic 17): XAIExecutor.Refresh has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_auth.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ad88387e157561adf7bb6b73f5134cace9f751fc55a623d3087aad734d38f2f"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIWebsocketsExecutor.readUpstreamLoop (cyclomatic 17): XAIWebsocketsExecutor.readUpstreamLoop has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1215}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d7d419486cd5785a7979412ddfdfeab0ecbba8a8abd0ccaa71717635c0c6d7a"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.backfillEmptyFunctionResponseNames (cyclomatic 17): gemini.backfillEmptyFunctionResponseNames has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 167, 143). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0528e9f5304fa7a2f5866e79b191e1a6157c47e8ddc20cb0c5aa7b26911d30a"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.normalizeGeminiResponsesCarriers (cyclomatic 17): responses.normalizeGeminiResponsesCarriers has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/signature_carrier.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b7eaee9c82b3c22768778a80bbbb1ce806d4e1e945a127e8832e4f80bd04cd8"}},{"ruleId":"D1","level":"warning","message":{"text":"gemini.ConvertOpenAIResponseToGeminiNonStream (cyclomatic 17): gemini.ConvertOpenAIResponseToGeminiNonStream has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 5 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 543). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a9236d07897afd069de31ca5739df36e5acb32bb3ee92be6f820b556deb553"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.convertOpenAIChatStreamToInteractions (cyclomatic 17): chat_completions.convertOpenAIChatStreamToInteractions has cyclomatic complexity 17 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"65192e7a8b59582cf93332e387f4c8175484ce286e9620ef9cb25a129feab5ae"}},{"ruleId":"D1","level":"warning","message":{"text":"authTabModel.handleNormalInput (cyclomatic 17): authTabModel.handleNormalInput has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/auth_tab.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"857fd3b063f91e5ad104bd41e7bbfa24e1527c83440d456b6435cbfe8ba1e3d1"}},{"ruleId":"D1","level":"warning","message":{"text":"util.flattenTypeArrays (cyclomatic 17): util.flattenTypeArrays has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3387c4f298cdbf599d0ba08d8c4fee9635d623ad5d8d2e902e839dc73fa9ff5"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.triggerServerUpdate (cyclomatic 17): Watcher.triggerServerUpdate has cyclomatic complexity 17 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"c073d9b53b80ec0eaa97a01e392f076d50f7e210dc6abcb8e1150164abde8291"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.reloadConfig (cyclomatic 17): Watcher.reloadConfig has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/config_reload.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"03c03bc7f50c71b0229f9c609ba96407497144617a2ee78945c88535f280095a"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.prepareAuthUpdatesLocked (cyclomatic 17): Watcher.prepareAuthUpdatesLocked has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/dispatcher.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d586c3437e2951a85960ade2e591f66aa27ef4cb2af0838c9d585a492c99428"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.Stream (cyclomatic 17): Manager.Stream has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 125). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5d80ee5329086e2a3fdb9690787bf24a93232a788a65e33dedcb93073984058"}},{"ruleId":"D1","level":"warning","message":{"text":"handlers.requestExecutionMetadata (cyclomatic 17): handlers.requestExecutionMetadata has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"42424a15b5fe4672cf06dfd8407d43ce617b9a0597db5c44780aa41711b7b1db"}},{"ruleId":"D1","level":"warning","message":{"text":"OpenAIAPIHandler.handleCompletionsStreamingResponse (cyclomatic 17): OpenAIAPIHandler.handleCompletionsStreamingResponse has cyclomatic complexity 17 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"f995f1cea02b3dee7534df2c40b93acfee3e2448e10269b15f480018c6583508"}},{"ruleId":"D1","level":"warning","message":{"text":"XAIAuthenticator.Login (cyclomatic 17): XAIAuthenticator.Login has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/xai.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"542dd2a480a2b2d3c0c9420cb53ab3fde8e31ee1576b1db3775f69b28d060478"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.resolveUpstreamModelFromAliasTable (cyclomatic 17): auth.resolveUpstreamModelFromAliasTable has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"8051355c41205d5e9994decb4b4913df5056fbe25f4eb653701eefd7f378e7b0"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.findAllAntigravityCreditsCandidateAuths (cyclomatic 17): Manager.findAllAntigravityCreditsCandidateAuths has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":972}}}],"partialFingerprints":{"codehealthFindingId/v1":"36cfcb14763c165d205ecdf7f71b1450d36ea83c24f22437c25aaffbd6625750"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.availableAuthsForRouteModel (cyclomatic 17): Manager.availableAuthsForRouteModel has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e7cf47bc7c387c0ba8ad16cb3d4b40f95e804ef35638c9adaad042adf558d63"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.startHomeUsageForwarder (cyclomatic 17): Service.startHomeUsageForwarder has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 334, 320). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"fecb4717759e18554bda3f9bd78e3afd921f249e580187d4a9bdffa1381a4c61"}},{"ruleId":"D1","level":"warning","message":{"text":"usage.tokenBreakdownForSemantics (cyclomatic 17): usage.tokenBreakdownForSemantics has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/usage/accounting.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"93a7091a0e67f7e8b7f547dd92d4d08783cab87368313254c6771a115cba9e11"}},{"ruleId":"D1","level":"warning","message":{"text":"TokenBreakdown.Valid (cyclomatic 17): TokenBreakdown.Valid has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/usage/accounting.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"efe21d24f9b5a95fc0b18c18ddb656e05ae238da2936c15ac20cf9795424a81c"}},{"ruleId":"D1","level":"warning","message":{"text":"management.parseLastRefreshValue (cyclomatic 16): management.parseLastRefreshValue has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"e07c98a05fe5b29193d4d92a7107b6247474c9485b585681e70ba6865cb5c5e3"}},{"ruleId":"D1","level":"warning","message":{"text":"management.ValidateOAuthState (cyclomatic 16): management.ValidateOAuthState has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/oauth_sessions.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"d44410490ed218d58f09cdc6df8619d270787bb6595e641139aed8317747d4ca"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.DeleteGeminiKey (cyclomatic 16): Handler.DeleteGeminiKey has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1cd1c505db6f59528432d69f9d3497cc79ac958eeb37321d3ce470649145079"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.DeleteInteractionsKey (cyclomatic 16): Handler.DeleteInteractionsKey has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"97f1af61c4fd5a732c2e82f331ca73f4c28d177a1c5ab63d14b02b534170938d"}},{"ruleId":"D1","level":"warning","message":{"text":"AntigravityAuth.OnboardUser (cyclomatic 16): AntigravityAuth.OnboardUser has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/antigravity/auth.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"52f5d617520052e031f3439b43f2036bdf327db5a0cbd64a491d89faffb1be90"}},{"ruleId":"D1","level":"warning","message":{"text":"ClaudeAuth.ExchangeCodeForTokens (cyclomatic 16): ClaudeAuth.ExchangeCodeForTokens has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/anthropic_auth.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff0c1432dbc13c27bcc0da31075185d15939da7675c244a8c7ebd92a9904eac9"}},{"ruleId":"D1","level":"warning","message":{"text":"vertex.stripANSIEscape (cyclomatic 16): vertex.stripANSIEscape has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/vertex/keyutil.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"d203efde6bef6187ef284cc2c39aad70daf7894d9544d743a178dd0c11371160"}},{"ruleId":"D1","level":"warning","message":{"text":"cache.AppendCodexReasoningReplayItemsBestEffort (cyclomatic 16): cache.AppendCodexReasoningReplayItemsBestEffort has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/codex_reasoning_replay_cache.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"409e2485d230f74bf8c64e903bc64f2aefd54cf59e60fa7b4f6a982b0df2c174"}},{"ruleId":"D1","level":"warning","message":{"text":"config.SaveConfigPreserveComments (cyclomatic 16): config.SaveConfigPreserveComments has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"183da6bb5c9f7ae432dfb17b3c7d7608dde5bb76d856bcfc1f96c606cbce36ba"}},{"ruleId":"D1","level":"warning","message":{"text":"config.isZeroValueNode (cyclomatic 16): config.isZeroValueNode has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8512b75ca281b43e3600b15af73f23f93d7c8505cba3f4b6bff650077ab70fd"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginhost.authDataWithDefaults (cyclomatic 16): pluginhost.authDataWithDefaults has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c8d387fc7571801cc67fb951a6d72a8864183df10b8b47a1406f40fac21c11c"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginhost.selectPluginFilesWithCandidates (cyclomatic 16): pluginhost.selectPluginFilesWithCandidates has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/platform.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc6c246b79c85324a12c7dec9565c0d49ed22bab383592eb4c606ec80cab4972"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.RegisterModels (cyclomatic 16): Host.RegisterModels has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8544e0f2751858fa33241b78c8ab9bba286bebeab1b9f24069b22aa56f6b136"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.listAuthFilesFromDisk (cyclomatic 16): Host.listAuthFilesFromDisk has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"6511d163e58245b7df1bdf371b9589502d6f5cb4b9d848c1d454f4386dc11c55"}},{"ruleId":"D1","level":"warning","message":{"text":"Host.ServeManagementHTTP (cyclomatic 16): Host.ServeManagementHTTP has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/management.go"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8056a34442af2844e8a418dd8c4d1df40531c3bea9522a59be7352a2775bb48"}},{"ruleId":"D1","level":"warning","message":{"text":"pluginstore.readTargetLibrary (cyclomatic 16): pluginstore.readTargetLibrary has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecf79dde9e1e0c6f32ca147005258c5bd8cfc61528f7e30b3891e55e38cb93f7"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.decideAntigravity429 (cyclomatic 16): executor.decideAntigravity429 has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b7ad629df0c99af759a1d115834ba445b4462de3a5e95c52e9ba92f8c8e768d"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.antigravityReplayToolSchemasFromRequests (cyclomatic 16): executor.antigravityReplayToolSchemasFromRequests has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"31b1c6f085d677a01c93339ae9b9c7c8c87410547ac4cf9b61255944bf09df9d"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.claudeCodeCLIBetas (cyclomatic 16): executor.claudeCodeCLIBetas has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"11c0de6bdbc73b767a15ed1ce8fd502751586c4ccd8620d85d5230b0e5ac94b9"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.codexReasoningReplayInsertIndex (cyclomatic 16): executor.codexReasoningReplayInsertIndex has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"611f175295b9164e7ee467001fcd1c2652bd380a3e521367223d91322a0fbcee"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.patchCodexCompletedOutput (cyclomatic 16): executor.patchCodexCompletedOutput has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef6d8a7450987dffe8f3928e2a10c24e7e7a12fe5204292bc9662ebf26a82c6e"}},{"ruleId":"D1","level":"warning","message":{"text":"executor.collectXAIClientDeclaredToolKeys (cyclomatic 16): executor.collectXAIClientDeclaredToolKeys has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 57). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"8baa134634b8440ff0977f082663fc29cc97a0c3b795739ebff047b020825500"}},{"ruleId":"D1","level":"warning","message":{"text":"codexWebsocketSession.bindExecutionLifecycle (cyclomatic 16): codexWebsocketSession.bindExecutionLifecycle has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3ca924b986ba257a25900cbfe39280c7e5421bf94f1817a5fa8c0d7044a7f91"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.uniqueClaudeJSONObjectMember (cyclomatic 16): helps.uniqueClaudeJSONObjectMember has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff513be784891cb66a146f15e07237aaba5b10f77aac5dd1c8522fc2805ff618"}},{"ruleId":"D1","level":"warning","message":{"text":"helps.FilterSSEUsageMetadata (cyclomatic 16): helps.FilterSSEUsageMetadata has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb510b3a107fa71f1bf3349a3d49a897a93ccfe546470fac5b574f813586c84e"}},{"ruleId":"D1","level":"warning","message":{"text":"postgresCooldownStateStore.Save (cyclomatic 16): postgresCooldownStateStore.Save has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres_cooldown_store.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"f83985e6f425657b042a6de9a7867aa7c0923b53be1323ee9aebb41bf6ca2d4d"}},{"ruleId":"D1","level":"warning","message":{"text":"Applier.Apply (cyclomatic 16): Applier.Apply has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/codex/apply.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"d66c633be2e4e2f94b8721175c9c3132aeaa3f9f01446ce6664cf3ae2ef792b9"}},{"ruleId":"D1","level":"warning","message":{"text":"Applier.Apply (cyclomatic 16): Applier.Apply has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/openai/apply.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac222bfcdada3fd3647fc0f861edc445ea16b7aeacfc13094267dd34b92f00a6"}},{"ruleId":"D1","level":"warning","message":{"text":"interactions.appendInteractionsStepToAntigravity (cyclomatic 16): interactions.appendInteractionsStepToAntigravity has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d0fe366c2eb8d3e1f24f334e245a5311a17261dbc161503a5f134548e4fa17e"}},{"ruleId":"D1","level":"warning","message":{"text":"chat_completions.normalizeAntigravityOpenAIThinkingConfig (cyclomatic 16): chat_completions.normalizeAntigravityOpenAIThinkingConfig has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"898c33b9e1225bc450d49f2d51bfb015e58f12ae37b1f0b0a55531907fa999c8"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.convertOpenAINonStreamingToAnthropic (cyclomatic 16): claude.convertOpenAINonStreamingToAnthropic has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"18e4c1384f9b4554518b2dff08be7af10feee868de65fe7c9a25d06f38c68f5a"}},{"ruleId":"D1","level":"warning","message":{"text":"responses.ConvertInteractionsRequestToOpenAIResponses (cyclomatic 16): responses.ConvertInteractionsRequestToOpenAIResponses has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/responses/interactions_openai_responses_request.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"da63db1f6a485650379a44aa92e4eac9897ffccb30b5a8f6979ac75588dec282"}},{"ruleId":"D1","level":"warning","message":{"text":"Client.GetLogs (cyclomatic 16): Client.GetLogs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/client.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"e454ce9c4a7ff4754c9e206b1312b53cadbf7cd5d2a9abd714f0c08ba86b010e"}},{"ruleId":"D1","level":"warning","message":{"text":"util.removePlaceholderFields (cyclomatic 16): util.removePlaceholderFields has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"496c4c3553b6f2a97c10c9ceab0809ae686eae24eab2a1807be7870d2cd63bdf"}},{"ruleId":"D1","level":"warning","message":{"text":"Watcher.handleEvent (cyclomatic 16): Watcher.handleEvent has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/events.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"42eaf6d8c3debb5191edfda68469e4d0896a57b6192d5e88fc1dab7f1eb7fd05"}},{"ruleId":"D1","level":"warning","message":{"text":"claude.claudeErrorDetailFromText (cyclomatic 16): claude.claudeErrorDetailFromText has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff61b52bf35235937816dff58f0648e3f2db4ce734fdb6b276de47a09686e8ae"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseAPIHandler.getRequestDetailsWithOptions (cyclomatic 16): BaseAPIHandler.getRequestDetailsWithOptions has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_routing.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"59c7f7a5fbdc91e5e5a557d837afe4bbd78369e93c0aa43af342864dc7c0b56e"}},{"ruleId":"D1","level":"warning","message":{"text":"openai.inputHasCodexLocalCompactionSummary (cyclomatic 16): openai.inputHasCodexLocalCompactionSummary has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"32e32d6c42d15afc59154e2777ebe789419d1031fd8846bd13b4084e04dfe98d"}},{"ruleId":"D1","level":"warning","message":{"text":"auth.isExplicitModelNotFoundMessage (cyclomatic 16): auth.isExplicitModelNotFoundMessage has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1456}}}],"partialFingerprints":{"codehealthFindingId/v1":"1159c9d5e96ee35509604ceb98264618df961d599a7f77b458c550e45916794d"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.ExecuteStream (cyclomatic 16): Manager.ExecuteStream has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"37d2c3ece3b6011af10641704242f77d844d33ef693a5358ee096df43b28bab3"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.prepareRequestAuth (cyclomatic 16): Manager.prepareRequestAuth has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":868}}}],"partialFingerprints":{"codehealthFindingId/v1":"4af1ce191a7d3d771ae9f293c34683f709e548430ef5cb0377dd2121a1ef60f1"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.retainedHomeSessionSelection (cyclomatic 16): Manager.retainedHomeSessionSelection has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"09e20077f31150dc77285eda8efb2bc76ef7ba540c6d54a7ce94ac7f12f4b91f"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.tryRefreshExecutionAuthAfterUnauthorized (cyclomatic 16): Manager.tryRefreshExecutionAuthAfterUnauthorized has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"80212000c59362073350da8ed6f95e59f28d9a2202e38ef8127cc0da2f8c99f5"}},{"ruleId":"D1","level":"warning","message":{"text":"modelScheduler.rebuildIndexesLocked (cyclomatic 16): modelScheduler.rebuildIndexesLocked has cyclomatic complexity 16 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":929}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5f6c66e9a691812b2784a825bdc075b5afc76b29698b5ad8f5334541b027d6b"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionAffinitySelector.Pick (cyclomatic 16): SessionAffinitySelector.Pick has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6a233a2af62b43d3b2b309b4448fa12dbdc1b9db588d1b68a415fbccbe6f64f"}},{"ruleId":"D1","level":"warning","message":{"text":"pprofServer.ApplyContext (cyclomatic 16): pprofServer.ApplyContext has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/pprof_server.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cbbaacc4fafb0d3d91acc8a2d02c30a0196e2a531585f7f8a0d13d7e146ec87"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.resolveConfigVertexCompatKey (cyclomatic 16): Service.resolveConfigVertexCompatKey has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"1271a2979eb5da078a0e77649fff529df15047572ad201b43c80a00a725ac0a9"}},{"ruleId":"D1","level":"warning","message":{"text":"session.interactionsRoot (cyclomatic 16): session.interactionsRoot has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"cea8e0eb1c924c3da8f5557d7264664beacf7ea74e6200dfdd74f5ac48325037"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertClaudeRequestToAntigravity (cognitive 579): claude.ConvertClaudeRequestToAntigravity has cognitive complexity 579 (threshold 15). Drivers by points: if/else 469, boolean chains 52, loops 33, match/switch 25 (nesting depth added 396). Of this number, 576 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"488804db70f4972938eddc499eba1a4a50a4b89e11ff146f9ea87794b536749b"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToAntigravity (cognitive 383): chat_completions.ConvertOpenAIRequestToAntigravity has cognitive complexity 383 (threshold 15). Drivers by points: if/else 299, loops 43, boolean chains 24, match/switch 17 (nesting depth added 259). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"051e0d682af3551248d4fb17f8dc465b19fb7f1dfccc739a8bef54fa13b7508c"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToCodex (cognitive 379): chat_completions.ConvertOpenAIRequestToCodex has cognitive complexity 379 (threshold 15). Drivers by points: if/else 300, loops 43, match/switch 24, boolean chains 12 (nesting depth added 277). Of this number, 376 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"832b7a0604ada40aeb8b340dcfa432833303fde17c7a6f808a44b41885e4e436"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToGemini (cognitive 377): chat_completions.ConvertOpenAIRequestToGemini has cognitive complexity 377 (threshold 15). Drivers by points: if/else 295, loops 40, boolean chains 27, match/switch 15 (nesting depth added 256). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"d703e343c50049efd8754439b7d66d44a5ff2c48e8a6a900e725dada083778dd"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertGeminiResponseToOpenAIResponses (cognitive 338): responses.ConvertGeminiResponseToOpenAIResponses has cognitive complexity 338 (threshold 15). Drivers by points: if/else 274, boolean chains 34, loops 16, match/switch 14 (nesting depth added 182). Of this number, 168 points are the body\u0027s own statements and 170 belong to 7 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"7165417f9643fb6f7bb02359ab3b3735a7b011c50ecb137211eb6e7581046801"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToGemini (cognitive 308): responses.ConvertOpenAIResponsesRequestToGemini has cognitive complexity 308 (threshold 15). Drivers by points: if/else 255, boolean chains 21, match/switch 20, loops 12 (nesting depth added 211). Of this number, 153 points are the body\u0027s own statements and 155 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"09b2fef3d1089cd18c5015aef6d72d7ad20795e708b7ff3afec98ed1eea050a6"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToClaude (cognitive 290): responses.ConvertOpenAIResponsesRequestToClaude has cognitive complexity 290 (threshold 15). Drivers by points: if/else 247, match/switch 27, boolean chains 12, loops 4 (nesting depth added 187). Of this number, 95 points are the body\u0027s own statements and 195 belong to 7 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"2952c493688d6440135d2107a0d33fb8500dabc1b394d34cc229091b55ad40d8"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertClaudeRequestToCodex (cognitive 270): claude.ConvertClaudeRequestToCodex has cognitive complexity 270 (threshold 15). Drivers by points: if/else 234, loops 21, boolean chains 8, match/switch 7 (nesting depth added 195). Of this number, 247 points are the body\u0027s own statements and 23 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"0243eaea93e0aa3512a85ee879bfa83e40d9a5b79945fd219c9d84d01b10cb4b"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 250): main.main has cognitive complexity 250 (threshold 15). Drivers by points: if/else 227, boolean chains 11, match/switch 7, loops 5 (nesting depth added 106). Of this number, 231 points are the body\u0027s own statements and 19 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/server/main.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"650b65cf841102568539e9eed4673166f46afa16e7e974ee91cf75c78e4d1f70"}},{"ruleId":"D2","level":"warning","message":{"text":"diff.BuildConfigChangeDetails (cognitive 244): diff.BuildConfigChangeDetails has cognitive complexity 244 (threshold 15). Drivers by points: if/else 224, loops 14, boolean chains 4, match/switch 2 (nesting depth added 115). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/config_diff.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"399f811dc236f031161b773397408e55f3f97fd287708ec1433d9341a9d63077"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.ExecuteStream (cognitive 231): AntigravityExecutor.ExecuteStream has cognitive complexity 231 (threshold 15). Drivers by points: if/else 184, match/switch 20, loops 13, boolean chains 10, jumps 4 (nesting depth added 159). Of this number, 185 points are the body\u0027s own statements and 46 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_stream.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"25012d66144f0ccd3f7ff60483a710282fa8e5a251da9dda77ab089f37fdb892"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.executeClaudeNonStream (cognitive 221): AntigravityExecutor.executeClaudeNonStream has cognitive complexity 221 (threshold 15). Drivers by points: if/else 191, boolean chains 10, loops 9, match/switch 7, jumps 4 (nesting depth added 152). Of this number, 195 points are the body\u0027s own statements and 26 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"c58b806b2fd995254308e5a82405e65dca8a2a2ccafaea002c9d2c89ae687fa0"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertClaudeResponseToOpenAIResponses (cognitive 221): responses.ConvertClaudeResponseToOpenAIResponses has cognitive complexity 221 (threshold 15). Drivers by points: if/else 194, loops 19, boolean chains 7, match/switch 1 (nesting depth added 133). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"082eb3fdc1a7bf41e312e6cfac3ee2be42b8ebc55439813b3717cd66b5a56321"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIWebsocketsExecutor.ExecuteStream (cognitive 207): XAIWebsocketsExecutor.ExecuteStream has cognitive complexity 207 (threshold 15). Drivers by points: if/else 177, boolean chains 16, loops 10, match/switch 4 (nesting depth added 110). Of this number, 85 points are the body\u0027s own statements and 122 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"8062f712315ecee61383b41df36e4b2d5c524f96cfa50f13c18fecf714b19f4d"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToClaude (cognitive 196): gemini.ConvertGeminiRequestToClaude has cognitive complexity 196 (threshold 15). Drivers by points: if/else 160, match/switch 22, boolean chains 12, loops 2 (nesting depth added 117). Of this number, 111 points are the body\u0027s own statements and 85 belong to 6 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"c07a792822ceb090a7ad3f07762f44ca4c28bd87d67f8e54e159681d63ee8c2a"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIResponsesAPIHandler.ResponsesWebsocket (cognitive 187): OpenAIResponsesAPIHandler.ResponsesWebsocket has cognitive complexity 187 (threshold 15). Drivers by points: if/else 144, boolean chains 30, loops 8, match/switch 5 (nesting depth added 84). Of this number, 153 points are the body\u0027s own statements and 34 belong to 8 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"1187a114f56a2da6999d301924d5012eebdf2af72be63aecc3ac1c8c5da84de2"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.ApplyPayloadConfigWithRequestTracked (cognitive 186): helps.ApplyPayloadConfigWithRequestTracked has cognitive complexity 186 (threshold 15). Drivers by points: if/else 118, loops 60, boolean chains 8 (nesting depth added 137). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"a05ab1bee3619e8aa34679764ba1a5daa8985c5309e60aa45f2eb6ce307867ef"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponses (cognitive 181): responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponses has cognitive complexity 181 (threshold 15). Drivers by points: if/else 143, boolean chains 22, loops 16 (nesting depth added 99). Of this number, 33 points are the body\u0027s own statements and 148 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"664f4f67509567e3236f17d0a74461d4300daf4ae733fb476c2438f2caed718d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.registerModelsForAuthWithCache (cognitive 177): Service.registerModelsForAuthWithCache has cognitive complexity 177 (threshold 15). Drivers by points: if/else 162, boolean chains 9, loops 3, match/switch 3 (nesting depth added 101). Of this number, 161 points are the body\u0027s own statements and 16 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"daa8c0bfefe72c5580dadeb0c4f126792c3533b287d025ba6fce9804dedc651f"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.ensureRepositoryLocked (cognitive 174): GitTokenStore.ensureRepositoryLocked has cognitive complexity 174 (threshold 15). Drivers by points: if/else 168, boolean chains 3, match/switch 3 (nesting depth added 109). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ce36a0ae99bf4f5e05b5bd4992cf41064ad39a2cc7373f19e4993973ecff068"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToCodex (cognitive 171): gemini.ConvertGeminiRequestToCodex has cognitive complexity 171 (threshold 15). Drivers by points: if/else 150, loops 20, boolean chains 1 (nesting depth added 106). Of this number, 165 points are the body\u0027s own statements and 6 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"4496ff8746b3e41da59c25b1d453c5ec8b0869cfe706a07672763de9a0570530"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertAntigravityResponseToClaude (cognitive 169): claude.ConvertAntigravityResponseToClaude has cognitive complexity 169 (threshold 15). Drivers by points: if/else 150, boolean chains 17, loops 2 (nesting depth added 99). Of this number, 160 points are the body\u0027s own statements and 9 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"feac4043bc1ca774ae3294fc0dafa4b10186bf42ee7b36345b51980caad405da"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertGeminiResponseToOpenAIResponsesNonStream (cognitive 166): responses.ConvertGeminiResponseToOpenAIResponsesNonStream has cognitive complexity 166 (threshold 15). Drivers by points: if/else 140, boolean chains 16, match/switch 6, loops 4 (nesting depth added 78). Of this number, 96 points are the body\u0027s own statements and 70 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":842}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dde2fce690b7255954b371055916c1be1aa95044091f9ad62e2b3c37ab23ab6"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertOpenAIResponsesRequestToOpenAIChatCompletions (cognitive 165): responses.ConvertOpenAIResponsesRequestToOpenAIChatCompletions has cognitive complexity 165 (threshold 15). Drivers by points: if/else 136, loops 11, boolean chains 10, match/switch 8 (nesting depth added 100). Of this number, 123 points are the body\u0027s own statements and 42 belong to 8 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_request.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"7221ceb30d95988e9e352c7e2dab8f22ac170357367835c6c43091d5852d1a31"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.Execute (cognitive 161): AntigravityExecutor.Execute has cognitive complexity 161 (threshold 15). Drivers by points: if/else 138, boolean chains 10, match/switch 6, jumps 4, loops 3 (nesting depth added 104). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"fee9087dd630eec80cd8e2191fde13048a05406a64546302a45ddf8fcdc95fda"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertOpenAIRequestToClaude (cognitive 159): chat_completions.ConvertOpenAIRequestToClaude has cognitive complexity 159 (threshold 15). Drivers by points: if/else 130, match/switch 16, boolean chains 12, loops 1 (nesting depth added 90). Of this number, 68 points are the body\u0027s own statements and 91 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_request.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"c52bb485162487e22263418db9a0cba89fe29bfd188f4ceec4c9fb5cad276130"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToOpenAI (cognitive 158): gemini.ConvertGeminiRequestToOpenAI has cognitive complexity 158 (threshold 15). Drivers by points: if/else 139, boolean chains 12, match/switch 6, loops 1 (nesting depth added 85). Of this number, 79 points are the body\u0027s own statements and 79 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_request.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c0fa37cfa51f0bb3b85368fe4b45404394cbd5b58be2c3167e71a2a9fdb7ea8"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertClaudeRequestToOpenAI (cognitive 157): claude.ConvertClaudeRequestToOpenAI has cognitive complexity 157 (threshold 15). Drivers by points: if/else 137, boolean chains 12, match/switch 8 (nesting depth added 86). Of this number, 67 points are the body\u0027s own statements and 90 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_request.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc3a9304ef86537cc7128dab8172e33dc755a6b590d2ba0dfc3f4b3685984926"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertClaudeRequestToGemini (cognitive 156): claude.ConvertClaudeRequestToGemini has cognitive complexity 156 (threshold 15). Drivers by points: if/else 129, boolean chains 13, loops 7, match/switch 7 (nesting depth added 87). Of this number, 59 points are the body\u0027s own statements and 97 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_request.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"d56f70cfb5fdcd20114e2f614b119c89923215b16d9a02a1891e4c601dee0b11"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertClaudeResponseToOpenAIResponsesNonStream (cognitive 154): responses.ConvertClaudeResponseToOpenAIResponsesNonStream has cognitive complexity 154 (threshold 15). Drivers by points: if/else 133, match/switch 10, boolean chains 7, loops 4 (nesting depth added 86). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1178c5e202a9f00544918d1d44cf2ec151e3689712bc3682ee666d2e7a0addf"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexWebsocketsExecutor.ExecuteStream (cognitive 145): CodexWebsocketsExecutor.ExecuteStream has cognitive complexity 145 (threshold 15). Drivers by points: if/else 129, boolean chains 12, loops 3, match/switch 1 (nesting depth added 66). Of this number, 74 points are the body\u0027s own statements and 71 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_stream.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"911fa994b5e2d9a2ac0fb4fa32db87d4ee90db8e0251149bde4d06d60e16af87"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleRedisConnection (cognitive 139): Server.handleRedisConnection has cognitive complexity 139 (threshold 15). Drivers by points: if/else 131, boolean chains 5, match/switch 2, loops 1 (nesting depth added 88). Of this number, 137 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/redis_queue_protocol.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1f9519acd26812f5725add8cb26fc337c7a2ff23938c2c2753badce8a95a802"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertClaudeResponseToGeminiNonStream (cognitive 136): gemini.ConvertClaudeResponseToGeminiNonStream has cognitive complexity 136 (threshold 15). Drivers by points: if/else 122, match/switch 6, boolean chains 4, loops 4 (nesting depth added 93). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"a38c0e242bdbf6b6820c4160b3c3a43e58ad1c83df5e3430e7b235c9b5ff78d5"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.MarkResult (cognitive 124): Manager.MarkResult has cognitive complexity 124 (threshold 15). Drivers by points: if/else 112, boolean chains 6, match/switch 6 (nesting depth added 78). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ea391c746b148ea8d5996a252b35c015787fdddaedd766c6f6f17301939d2f2"}},{"ruleId":"D2","level":"warning","message":{"text":"antigravityReasoningReplayAccumulator.observeResponsePayload (cognitive 116): antigravityReasoningReplayAccumulator.observeResponsePayload has cognitive complexity 116 (threshold 15). Drivers by points: if/else 82, boolean chains 18, loops 14, match/switch 2 (nesting depth added 55). Most of this is not in the body itself: 2 of the 116 points are its own statements and the rest belongs to one function literal inside it that branches (line 1697). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1689}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbb682d03187f64a6e04fd758168c31c6b616eb5f2bf53b5ed1731cb4e1c7432"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executeStreamMixedOnce (cognitive 115): Manager.executeStreamMixedOnce has cognitive complexity 115 (threshold 15). Drivers by points: if/else 108, boolean chains 6, loops 1 (nesting depth added 65). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7223310fcc04c81cc9b07616d490d4a74c6dd1d359a9a6103f9fb83a4e214d6"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertGeminiResponseToClaude (cognitive 114): claude.ConvertGeminiResponseToClaude has cognitive complexity 114 (threshold 15). Drivers by points: if/else 104, boolean chains 8, loops 2 (nesting depth added 71). Of this number, 112 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"e48a0f7d19a9404f98f598233c3204d6f234dd437e51fcd6968362a125b85238"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.executeStreamWithAuthManagerFormats (cognitive 113): BaseAPIHandler.executeStreamWithAuthManagerFormats has cognitive complexity 113 (threshold 15). Drivers by points: if/else 95, boolean chains 9, match/switch 6, loops 3 (nesting depth added 41). Of this number, 31 points are the body\u0027s own statements and 82 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_stream.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"5615bb326d0d20c0ffa04e82e8e000ceb04ee7f1aaefcac369b8fae3d4f28010"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executeStreamWithModelPool (cognitive 113): Manager.executeStreamWithModelPool has cognitive complexity 113 (threshold 15). Drivers by points: if/else 108, boolean chains 4, loops 1 (nesting depth added 70). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"d434b94f71f92c70ba3f7b00c07d8e2155c871bc183117cb84e7e42b48c59334"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.RegisterClient (cognitive 112): ModelRegistry.RegisterClient has cognitive complexity 112 (threshold 15). Drivers by points: if/else 84, loops 22, boolean chains 6 (nesting depth added 57). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d07276b21dbc88b8ec7d2909b6afbec0edd06df2428cea5294877fc2038b373"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertCodexResponseToOpenAI (cognitive 111): chat_completions.ConvertCodexResponseToOpenAI has cognitive complexity 111 (threshold 15). Drivers by points: if/else 98, boolean chains 10, match/switch 3 (nesting depth added 48). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"c501e464e98a9cc2ee9129d0cb04dcb3610c7f9e8a1d7530c01acf7bc0bba538"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertCodexResponseToOpenAINonStream (cognitive 111): chat_completions.ConvertCodexResponseToOpenAINonStream has cognitive complexity 111 (threshold 15). Drivers by points: if/else 84, loops 18, match/switch 8, boolean chains 1 (nesting depth added 72). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9751f8d576e4391a7a0b8d27cbc5eb2a8f7fefb52347fc99cdb60e9444f6bac"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertClaudeResponseToGemini (cognitive 110): gemini.ConvertClaudeResponseToGemini has cognitive complexity 110 (threshold 15). Drivers by points: if/else 98, match/switch 8, boolean chains 4 (nesting depth added 67). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9609bef50b5a72407bec66deff06804e710b7343103ac2bf59009ce86ebdad8"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.convertOpenAIStreamingChunkToAnthropic (cognitive 109): claude.convertOpenAIStreamingChunkToAnthropic has cognitive complexity 109 (threshold 15). Drivers by points: if/else 93, boolean chains 8, loops 6, match/switch 2 (nesting depth added 66). Of this number, 72 points are the body\u0027s own statements and 37 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbd419d427083d33a289a660bbbd6ba2c60e98081b5b84b56517d7d3940aa6e6"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertOpenAIResponseToClaudeNonStream (cognitive 109): claude.ConvertOpenAIResponseToClaudeNonStream has cognitive complexity 109 (threshold 15). Drivers by points: if/else 90, loops 9, match/switch 6, boolean chains 4 (nesting depth added 75). Of this number, 67 points are the body\u0027s own statements and 42 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d19cfb1cccf77e65dae2755ba38f5af2383f75f10695fba66528bda9ddbfcf7"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertAntigravityResponseToClaudeNonStream (cognitive 107): claude.ConvertAntigravityResponseToClaudeNonStream has cognitive complexity 107 (threshold 15). Drivers by points: if/else 91, boolean chains 11, match/switch 3, loops 2 (nesting depth added 55). Of this number, 101 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"59407bea83d3ff3242151a8684904719495f9f128565296a663a33bd9f847fc0"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.extractMessageHashIDs (cognitive 107): auth.extractMessageHashIDs has cognitive complexity 107 (threshold 15). Drivers by points: if/else 85, boolean chains 14, match/switch 8 (nesting depth added 56). Of this number, 27 points are the body\u0027s own statements and 80 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a8769fc74b7559f63be93dce420c208a799eb52faaeaad5cdf554072f9d8fdd"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.GetAvailableModelsByProvider (cognitive 105): ModelRegistry.GetAvailableModelsByProvider has cognitive complexity 105 (threshold 15). Drivers by points: if/else 83, loops 12, boolean chains 10 (nesting depth added 65). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"af2bf35d66883193a177f2bc430902432e5de2f7c98ddf271c9779222a350154"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertGeminiResponseToOpenAI (cognitive 105): chat_completions.ConvertGeminiResponseToOpenAI has cognitive complexity 105 (threshold 15). Drivers by points: if/else 95, boolean chains 7, loops 3 (nesting depth added 55). Of this number, 28 points are the body\u0027s own statements and 77 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"9846adf118a4fc60e43bb4a12045c29301dc51bee525a1014b129a5a0f4161da"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexWebsocketsExecutor.Execute (cognitive 104): CodexWebsocketsExecutor.Execute has cognitive complexity 104 (threshold 15). Drivers by points: if/else 94, boolean chains 7, match/switch 2, loops 1 (nesting depth added 46). Of this number, 98 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_execute.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"c68dcb61ff61df69c398bebd7de4e32804525f36812074fd368fa7da9c44de2a"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executeHome (cognitive 104): Manager.executeHome has cognitive complexity 104 (threshold 15). Drivers by points: if/else 96, boolean chains 5, loops 3 (nesting depth added 62). Of this number, 94 points are the body\u0027s own statements and 10 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home_execution.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ab9c0cf16612c8f75574b631217a86dc3bb3d2fb9d76d43a5550efdf7eb0034"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.remapOAuthToolNamesWithBatchedEdits (cognitive 98): executor.remapOAuthToolNamesWithBatchedEdits has cognitive complexity 98 (threshold 15). Drivers by points: if/else 85, boolean chains 9, loops 2, match/switch 2 (nesting depth added 48). Of this number, 18 points are the body\u0027s own statements and 80 belong to 8 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":960}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ddd915fe7f039ca8eb0c3a69615837ceb3ec91e4fc4357ad5d47f7c48f1fd5"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.Handle (cognitive 96): Handler.Handle has cognitive complexity 96 (threshold 15). Drivers by points: if/else 88, boolean chains 8 (nesting depth added 39). Of this number, 86 points are the body\u0027s own statements and 10 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/live.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"762518e53acafd0399a90698b69f9a88df8256e90522100e9df486f4d16eaaca"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeKimiToolMessageLinks (cognitive 93): executor.normalizeKimiToolMessageLinks has cognitive complexity 93 (threshold 15). Drivers by points: if/else 71, loops 12, boolean chains 8, match/switch 2 (nesting depth added 51). Of this number, 90 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f62df40011c9f9c78503724ded7a3ceb8c1ed58bc100140958e3cce8002eb68"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponsesNonStream (cognitive 88): responses.ConvertOpenAIChatCompletionsResponseToOpenAIResponsesNonStream has cognitive complexity 88 (threshold 15). Drivers by points: if/else 83, boolean chains 5 (nesting depth added 40). Of this number, 70 points are the body\u0027s own statements and 18 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":711}}}],"partialFingerprints":{"codehealthFindingId/v1":"0923bd88a716641532cf3126bfe5791051dff004a668d5292d6361cb1ca583a3"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.convertStreamToNonStream (cognitive 85): AntigravityExecutor.convertStreamToNonStream has cognitive complexity 85 (threshold 15). Drivers by points: if/else 69, boolean chains 11, loops 4, match/switch 1 (nesting depth added 37). Of this number, 72 points are the body\u0027s own statements and 13 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"953a3b373d5b80ee606cdad3ba0b7e7fb508816a2446342b1e11d6164b94c086"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertCodexResponseToClaudeNonStream (cognitive 85): claude.ConvertCodexResponseToClaudeNonStream has cognitive complexity 85 (threshold 15). Drivers by points: if/else 79, boolean chains 4, match/switch 2 (nesting depth added 54). Most of this is not in the body itself: 6 of the 85 points are its own statements and the rest belongs to one function literal inside it that branches (line 375). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b291dcdb188656820b45e32335de6e7a81fa5c2820ec21da8741855f13b4c1d"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executeCountMixedOnce (cognitive 84): Manager.executeCountMixedOnce has cognitive complexity 84 (threshold 15). Drivers by points: if/else 80, loops 3, boolean chains 1 (nesting depth added 54). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"2050d642000de0a4449d49aa7bf2cbb668a9568648915f6e1b3b815ecb1db474"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIResponsesAPIHandler.forwardResponsesWebsocket (cognitive 82): OpenAIResponsesAPIHandler.forwardResponsesWebsocket has cognitive complexity 82 (threshold 15). Drivers by points: if/else 73, loops 4, boolean chains 3, match/switch 2 (nesting depth added 54). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_forward.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"9046eb06c9cf5cc6f4a4455395533e653b64e5c5393d8770a3dcc1e78ec7a6f4"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.UpdateClientsContext (cognitive 81): Server.UpdateClientsContext has cognitive complexity 81 (threshold 15). Drivers by points: if/else 57, boolean chains 21, match/switch 2, loops 1 (nesting depth added 15). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_reload.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d680a1349b9ddc35e2054b9291a37436c4b7ab8bf9ad7b4b3afcca5a5173cbc"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeExecutor.ExecuteStream (cognitive 80): ClaudeExecutor.ExecuteStream has cognitive complexity 80 (threshold 15). Drivers by points: if/else 58, match/switch 11, boolean chains 6, loops 5 (nesting depth added 26). Of this number, 38 points are the body\u0027s own statements and 42 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_stream.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"3afda86ee459e48b2991a2563428d83440e685f38edb2c0b163b826539a0b8cd"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.listAuthFilesFromDisk (cognitive 79): Handler.listAuthFilesFromDisk has cognitive complexity 79 (threshold 15). Drivers by points: if/else 61, match/switch 15, boolean chains 2, loops 1 (nesting depth added 56). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"d68454cdb1a6a8fb2d2fcb816d359059908b3a3fc24261e19b15088ce28241d8"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertClaudeResponseToOpenAINonStream (cognitive 79): chat_completions.ConvertClaudeResponseToOpenAINonStream has cognitive complexity 79 (threshold 15). Drivers by points: if/else 67, loops 6, match/switch 6 (nesting depth added 50). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee2ca5c8cafdef13b3e3eaa0f9de90066e386b92859da7a42553c9129db9c7c2"}},{"ruleId":"D2","level":"warning","message":{"text":"synthesizer.synthesizeFileAuths (cognitive 79): synthesizer.synthesizeFileAuths has cognitive complexity 79 (threshold 15). Drivers by points: if/else 67, boolean chains 7, loops 3, match/switch 2 (nesting depth added 38). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/file.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d19f46397cdef0ae02c87b97796f810c398391b0a622984fc9cf5a33ad3e135"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executeMixedOnce (cognitive 79): Manager.executeMixedOnce has cognitive complexity 79 (threshold 15). Drivers by points: if/else 75, loops 3, boolean chains 1 (nesting depth added 51). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"a933ee1a66f68ef64867d0e046eef2bc9fa55960aeae8def648596e6b70c453c"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertAntigravityResponseToOpenAI (cognitive 78): chat_completions.ConvertAntigravityResponseToOpenAI has cognitive complexity 78 (threshold 15). Drivers by points: if/else 70, boolean chains 6, loops 2 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"94a6bf60711de6cfbd4cb0b49d010b6c0e85dbc98f8e90bd554304a543d2fe26"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertGeminiResponseToOpenAINonStream (cognitive 77): chat_completions.ConvertGeminiResponseToOpenAINonStream has cognitive complexity 77 (threshold 15). Drivers by points: if/else 72, loops 3, boolean chains 2 (nesting depth added 48). Of this number, 17 points are the body\u0027s own statements and 60 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdd615fc242922e4f32d35127dd3f2b09a028507064ca05d1110889ccff40639"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.reloadClients (cognitive 77): Watcher.reloadClients has cognitive complexity 77 (threshold 15). Drivers by points: if/else 68, loops 7, boolean chains 2 (nesting depth added 50). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4cc402bfec326526653904578986f330b3680c0292e13423a983761a1310b56"}},{"ruleId":"D2","level":"warning","message":{"text":"authScheduler.pickMixedWithStrategy (cognitive 77): authScheduler.pickMixedWithStrategy has cognitive complexity 77 (threshold 15). Drivers by points: if/else 64, loops 8, boolean chains 5 (nesting depth added 31). Of this number, 71 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"f943090073c5ed0946c67f15efee9ca9c2729403301ad2f4b67f660dfeb4b03f"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.remapOAuthToolNamesWithOptionsLegacy (cognitive 76): executor.remapOAuthToolNamesWithOptionsLegacy has cognitive complexity 76 (threshold 15). Drivers by points: if/else 64, boolean chains 8, loops 2, match/switch 2 (nesting depth added 36). Most of this is not in the body itself: 10 of the 76 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 1350, 1301, 1246, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1218}}}],"partialFingerprints":{"codehealthFindingId/v1":"63ac8d4108b5bd157628298d0daa88f2c82938cf6ad53ed8a86907b5fef30785"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIExecutor.ExecuteStream (cognitive 75): XAIExecutor.ExecuteStream has cognitive complexity 75 (threshold 15). Drivers by points: if/else 59, match/switch 8, loops 5, boolean chains 3 (nesting depth added 42). Most of this is not in the body itself: 11 of the 75 points are its own statements and the rest belongs to one function literal inside it that branches (line 70). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_stream.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"7924a74fed1197bb65c51360539001e0b8a472e2d6a1cfd9355f73992485c6db"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertOpenAIResponseToGemini (cognitive 75): gemini.ConvertOpenAIResponseToGemini has cognitive complexity 75 (threshold 15). Drivers by points: if/else 63, loops 7, boolean chains 5 (nesting depth added 42). Most of this is not in the body itself: 15 of the 75 points are its own statements and the rest belongs to one function literal inside it that branches (line 95). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c61dff6adde2b0dc4010501432880265a02963c90d70bfe5d1fa43a221cf566"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.ValidateConfig (cognitive 74): thinking.ValidateConfig has cognitive complexity 74 (threshold 15). Drivers by points: if/else 50, boolean chains 21, match/switch 3 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/validate.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecc0ec6a1da789dafb04eace43277bd3f6c8fe0047e7050704b6f6d7b6875ba4"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.countCodexInputTokens (cognitive 73): executor.countCodexInputTokens has cognitive complexity 73 (threshold 15). Drivers by points: if/else 61, loops 9, match/switch 3 (nesting depth added 46). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_tokens.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"64049971d81a9ceefcfca8f49e3e30f867cc8d6319aebcfdef02261563cc846b"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.pickHomeDispatchSelection (cognitive 71): Manager.pickHomeDispatchSelection has cognitive complexity 71 (threshold 15). Drivers by points: if/else 65, boolean chains 6 (nesting depth added 15). Of this number, 70 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e43d219f3a331e49ecaee8375b10da835024fcdc718c0ef5eb0a74e2530c82f"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.codexAlphaSearch (cognitive 70): Server.codexAlphaSearch has cognitive complexity 70 (threshold 15). Drivers by points: if/else 61, boolean chains 6, loops 3 (nesting depth added 23). Of this number, 61 points are the body\u0027s own statements and 9 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dc89ad3f04a37a4c77715818711be044d7d3ff4a8e868c7d8aa4de6b28281d8"}},{"ruleId":"D2","level":"warning","message":{"text":"FileTokenStore.readAuthFiles (cognitive 70): FileTokenStore.readAuthFiles has cognitive complexity 70 (threshold 15). Drivers by points: if/else 64, boolean chains 3, loops 3 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1b98784d58315a6b32022980083f23e60a1147b151ca9bda4af2dc10bc9b14a"}},{"ruleId":"D2","level":"warning","message":{"text":"AIStudioExecutor.ExecuteStream (cognitive 69): AIStudioExecutor.ExecuteStream has cognitive complexity 69 (threshold 15). Drivers by points: if/else 45, match/switch 12, loops 8, boolean chains 4 (nesting depth added 32). Of this number, 33 points are the body\u0027s own statements and 36 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"442ee0e30c8270d3237fc2e14909c25aaf97ffcac08af38434e3a2cee5bf4367"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.ConvertClaudeResponseToOpenAI (cognitive 69): chat_completions.ConvertClaudeResponseToOpenAI has cognitive complexity 69 (threshold 15). Drivers by points: if/else 65, match/switch 4 (nesting depth added 42). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4663499faa29c16a65688841cc6ce117fba5ae0004cf65f8e1cd9d02a5b4313"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.pairOpenAIResponsesReasoningWithFunctionCalls (cognitive 68): responses.pairOpenAIResponsesReasoningWithFunctionCalls has cognitive complexity 68 (threshold 15). Drivers by points: if/else 36, loops 17, boolean chains 15 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"45e07d2982152d58cd329eceef93572f2403b2206ae2817534fc5e39f180009e"}},{"ruleId":"D2","level":"warning","message":{"text":"App.Update (cognitive 68): App.Update has cognitive complexity 68 (threshold 15). Drivers by points: if/else 53, match/switch 9, boolean chains 6 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/app.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"b80068b2a2024a3304bfcce8a8a62dfeb285ffede0519359c86b14b90280742d"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertCodexResponseToGemini (cognitive 67): gemini.ConvertCodexResponseToGemini has cognitive complexity 67 (threshold 15). Drivers by points: if/else 62, boolean chains 5 (nesting depth added 31). Of this number, 63 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"27dd610493941888c70fafeba25b7ac034c2941f74f5b4c7c527ca2bc98e0f37"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.enforceCacheControlLimit (cognitive 66): executor.enforceCacheControlLimit has cognitive complexity 66 (threshold 15). Drivers by points: if/else 65, boolean chains 1 (nesting depth added 31). Of this number, 16 points are the body\u0027s own statements and 50 belong to 7 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"a48b03d9d2920a15d3952fb7b6e99902615857cf96dce91bdf6a545fe898893a"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.buildResponsesCompletedEvent (cognitive 66): responses.buildResponsesCompletedEvent has cognitive complexity 66 (threshold 15). Drivers by points: if/else 59, loops 7 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4d48b7c4e1417d54481f514849b3b8f0255ab869bfbdb60a91f0d62021a8936"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.GetContextWithCancel (cognitive 66): BaseAPIHandler.GetContextWithCancel has cognitive complexity 66 (threshold 15). Drivers by points: if/else 47, boolean chains 11, match/switch 8 (nesting depth added 28). Of this number, 24 points are the body\u0027s own statements and 42 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffd58671cd3ad9215136c30d16327ccf7053e1a9d7902eb7da43d4f51eb90c47"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.forwardImagesStream (cognitive 66): OpenAIAPIHandler.forwardImagesStream has cognitive complexity 66 (threshold 15). Drivers by points: if/else 45, loops 13, boolean chains 4, match/switch 4 (nesting depth added 37). Of this number, 30 points are the body\u0027s own statements and 36 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1821}}}],"partialFingerprints":{"codehealthFindingId/v1":"58d5beacdfcc465e010947c4e79177592aaa4809c437d1c6203c63246006d368"}},{"ruleId":"D2","level":"warning","message":{"text":"keysTabModel.Update (cognitive 64): keysTabModel.Update has cognitive complexity 64 (threshold 15). Drivers by points: if/else 54, match/switch 9, boolean chains 1 (nesting depth added 40). Of this number, 51 points are the body\u0027s own statements and 13 belong to 3 function literals inside it that branch. The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/keys_tab.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ffc7e5078f2ffb60257171dc97dc56b782201c6eaad741e7f48a6af70cdfbc3"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.tolerantParseJSONObjectRaw (cognitive 63): gemini.tolerantParseJSONObjectRaw has cognitive complexity 63 (threshold 15). Drivers by points: if/else 33, loops 15, boolean chains 13, match/switch 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"e708342922a16eee42b7af93fde367c0e36698fad165b875b5aeaf4d50763c23"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.streamWithPluginExecutor (cognitive 63): BaseAPIHandler.streamWithPluginExecutor has cognitive complexity 63 (threshold 15). Drivers by points: if/else 50, match/switch 9, boolean chains 3, loops 1 (nesting depth added 31). Most of this is not in the body itself: 13 of the 63 points are its own statements and the rest belongs to one function literal inside it that branches (line 119). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_stream.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca809eaa4a28d48fc7f93a15ea3e567fd8888f2ab3dcfce94d212ad020bbe328"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.ApplyConfig (cognitive 61): Host.ApplyConfig has cognitive complexity 61 (threshold 15). Drivers by points: if/else 55, boolean chains 4, loops 2 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"035f95a108c35fb37ae56092d83cd068fb076ed20a024ec51a59c56dd151452c"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeAntigravityGeminiFunctionResponseRoles (cognitive 61): executor.normalizeAntigravityGeminiFunctionResponseRoles has cognitive complexity 61 (threshold 15). Drivers by points: if/else 45, loops 8, boolean chains 6, match/switch 2 (nesting depth added 36). Of this number, 59 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dad0ed315af63ffd71c1fb3ef57e894ae6c75801dae37043ade06384dc85a77"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.applyClaudeHeaders (cognitive 61): executor.applyClaudeHeaders has cognitive complexity 61 (threshold 15). Drivers by points: if/else 45, boolean chains 10, loops 6 (nesting depth added 12). Of this number, 55 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"e90ad2619120377449b9b4734a34e6b21283fe7f6a7142f5091772346b9542cc"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.ExecuteStream (cognitive 61): CodexExecutor.ExecuteStream has cognitive complexity 61 (threshold 15). Drivers by points: if/else 40, match/switch 16, loops 3, boolean chains 2 (nesting depth added 29). Of this number, 19 points are the body\u0027s own statements and 42 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_stream.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3ba480e2cd52eb641d06ebe933cdb92730ef3bc75edd6bbf948da9c7b18f7ef"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.StripInvalidGeminiSignatureThinkingBlocks (cognitive 60): claude.StripInvalidGeminiSignatureThinkingBlocks has cognitive complexity 60 (threshold 15). Drivers by points: if/else 45, boolean chains 7, match/switch 5, loops 3 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/signature_validation.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"beb9b3fe16a737ef3c35d9649f31699e0ac59f87b66e610c604db335a5b412b7"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertCodexResponseToGeminiNonStream (cognitive 58): gemini.ConvertCodexResponseToGeminiNonStream has cognitive complexity 58 (threshold 15). Drivers by points: if/else 50, boolean chains 3, match/switch 3, loops 2 (nesting depth added 37). Most of this is not in the body itself: 14 of the 58 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 304, 291). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a9cc22971bfe7ce9c27d4e13bd8bb019e7be826654277107e42dc2bcdeb0500"}},{"ruleId":"D2","level":"warning","message":{"text":"ResponseWriterWrapper.Finalize (cognitive 57): ResponseWriterWrapper.Finalize has cognitive complexity 57 (threshold 15). Drivers by points: if/else 49, boolean chains 8 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/middleware/response_writer.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"558987dfcf96ab9812624f029fe630c49b8339d0e36e7e76e111312be486ad63"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.mergeAntigravityFunctionCallPartReplayWithSchemas (cognitive 57): executor.mergeAntigravityFunctionCallPartReplayWithSchemas has cognitive complexity 57 (threshold 15). Drivers by points: if/else 51, boolean chains 6 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1397}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cef0da6e65854ab1ee8da433f653dc58dd642dc8c586dee67541209b0fab093"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.repairResponsesToolCallsArray (cognitive 57): openai.repairResponsesToolCallsArray has cognitive complexity 57 (threshold 15). Drivers by points: if/else 52, loops 2, match/switch 2, boolean chains 1 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"09a9971f866c6299905a594fbfe3765629d2c8089bd48647f41db59d83d6c9f3"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.Run (cognitive 57): Service.Run has cognitive complexity 57 (threshold 15). Drivers by points: if/else 49, boolean chains 7, match/switch 1 (nesting depth added 16). Of this number, 45 points are the body\u0027s own statements and 12 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_lifecycle.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"26220a13a4f3ddd18bd6378d82baa9b2898286aef43c0df70fd96637a4631b78"}},{"ruleId":"D2","level":"warning","message":{"text":"oauthTabModel.Update (cognitive 56): oauthTabModel.Update has cognitive complexity 56 (threshold 15). Drivers by points: if/else 44, match/switch 9, boolean chains 3 (nesting depth added 30). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/oauth_tab.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"db726df9e41184fc8cd91824336420b08d672d88265a462b466175b20d11c9e5"}},{"ruleId":"D2","level":"warning","message":{"text":"handlers.BuildOpenAIResponsesStreamErrorChunk (cognitive 56): handlers.BuildOpenAIResponsesStreamErrorChunk has cognitive complexity 56 (threshold 15). Drivers by points: if/else 47, boolean chains 9 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai_responses_stream_error.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"612f6ee4f94ca1fe59da58f704ed28ad3040e575cbddb43cb5ebeb204aa994ae"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.SanitizeClaudeMessagesSignaturesForTarget (cognitive 55): signature.SanitizeClaudeMessagesSignaturesForTarget has cognitive complexity 55 (threshold 15). Drivers by points: if/else 36, match/switch 8, loops 7, boolean chains 4 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_messages_sanitize.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"30f40aee4db4cc013000e1219b9309c6bb940df3270c04b05a6cd6cb53060486"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.rewriteGeminiFunctionNames (cognitive 55): gemini.rewriteGeminiFunctionNames has cognitive complexity 55 (threshold 15). Drivers by points: if/else 35, loops 15, boolean chains 5 (nesting depth added 30). Of this number, 40 points are the body\u0027s own statements and 15 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"da9bb8edbd48d374a460b12c2e58ce7cb8853eb5148e9a4bd62dcf342b7be607"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.convertModelToMap (cognitive 54): ModelRegistry.convertModelToMap has cognitive complexity 54 (threshold 15). Drivers by points: if/else 53, match/switch 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eda25050fbf4b1a5196cf303d2d30d6a295976b7e2e9128cbe2819c0f6a3f68"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.ForwardStream (cognitive 54): BaseAPIHandler.ForwardStream has cognitive complexity 54 (threshold 15). Drivers by points: if/else 45, match/switch 7, boolean chains 1, loops 1 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/stream_forwarder.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"99195e7b69f50f215b274225fb1838f7cd0ce4b237d4a917bdbd95aeb8d006bb"}},{"ruleId":"D2","level":"warning","message":{"text":"management.locateLogCursorFile (cognitive 53): management.locateLogCursorFile has cognitive complexity 53 (threshold 15). Drivers by points: if/else 45, boolean chains 4, loops 4 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f727459be076b4f6d9948b9732b3245d6a93bd52766b1d61c824a839170c02e"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.RunConfigSubscriberLifetime (cognitive 53): Client.RunConfigSubscriberLifetime has cognitive complexity 53 (threshold 15). Drivers by points: if/else 49, match/switch 2, boolean chains 1, loops 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1782}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcdcf99e2feb0fb54051447a0ba7d87dabf6534db9b8d73215feba7dfb3e518c"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.ValidateGeminiFunctionCallPairing (cognitive 53): signature.ValidateGeminiFunctionCallPairing has cognitive complexity 53 (threshold 15). Drivers by points: if/else 44, loops 5, boolean chains 4 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_validation.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f5810283fcc345a721eb4b60bf1b6ea1ee60077677bb2c618ec4468e22eb230"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeAuthenticator.Login (cognitive 53): ClaudeAuthenticator.Login has cognitive complexity 53 (threshold 15). Drivers by points: if/else 43, match/switch 5, jumps 3, boolean chains 1, loops 1 (nesting depth added 16). Of this number, 51 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/claude.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"f423fb3f82023e9761c979d3f662c671b75d20b29463116b393f29d0519a1fe3"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.runHomeConfigWorkerWithSupervisor (cognitive 53): Service.runHomeConfigWorkerWithSupervisor has cognitive complexity 53 (threshold 15). Drivers by points: if/else 47, loops 3, boolean chains 2, match/switch 1 (nesting depth added 29). Of this number, 43 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8fb6b2f47514299cea6f822c0461077d3a71d3d1ece56afbdf3f58ce5431bef"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.buildAuthFileEntryLocked (cognitive 52): Handler.buildAuthFileEntryLocked has cognitive complexity 52 (threshold 15). Drivers by points: if/else 43, boolean chains 6, match/switch 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"6568460358d5df077edca86e7dc642e1f0988173bf344f8b3ed7e97813da292c"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.HandleSideband (cognitive 52): Handler.HandleSideband has cognitive complexity 52 (threshold 15). Drivers by points: if/else 46, boolean chains 5, match/switch 1 (nesting depth added 13). Of this number, 49 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/sideband.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"6146cdcf5f5a9441ed5837c00ce5d401fb18c3cff46805b75217e145d439509d"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertCodexResponseToClaude (cognitive 52): claude.ConvertCodexResponseToClaude has cognitive complexity 52 (threshold 15). Drivers by points: if/else 45, match/switch 5, boolean chains 2 (nesting depth added 26). Of this number, 46 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"765a012090f83846ec6b920a60e2ddfc67a8d61527f9697978ebf57b2780b4b6"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.NonStream (cognitive 52): Manager.NonStream has cognitive complexity 52 (threshold 15). Drivers by points: if/else 45, match/switch 5, boolean chains 1, loops 1 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfd2b580d0a99e52ac07db76827d707c153951dc0cac29ef4eba08ae9e7e8a7e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.registerExecutorForAuth (cognitive 52): Service.registerExecutorForAuth has cognitive complexity 52 (threshold 15). Drivers by points: if/else 46, boolean chains 5, match/switch 1 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"94035b5d05bdfe76ab3ff704e39e3b97a00c3fd8c88aac11c32b0c96147c55d0"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.ModelsForAuth (cognitive 51): Host.ModelsForAuth has cognitive complexity 51 (threshold 15). Drivers by points: if/else 43, boolean chains 5, loops 3 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"a60a06b592858b9bd8c058e48d10e1e47894af2eae8ff2ea92c82fa4e4c44536"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.CountTokens (cognitive 51): AntigravityExecutor.CountTokens has cognitive complexity 51 (threshold 15). Drivers by points: if/else 44, boolean chains 5, loops 1, match/switch 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_tokens.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"70a96b25affcec058ecf02a471f257fabf6e85236ee322a916d08d9cd8e13d0d"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAICompatExecutor.ExecuteStream (cognitive 51): OpenAICompatExecutor.ExecuteStream has cognitive complexity 51 (threshold 15). Drivers by points: if/else 31, match/switch 12, loops 5, boolean chains 3 (nesting depth added 19). Of this number, 17 points are the body\u0027s own statements and 34 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"0296fbb3cefd8d19bd8aa19ada4b417aa8f38e4690c2fbf6c423904f94342d7e"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.commitAndPushWithOptionsLocked (cognitive 50): GitTokenStore.commitAndPushWithOptionsLocked has cognitive complexity 50 (threshold 15). Drivers by points: if/else 47, boolean chains 2, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1519}}}],"partialFingerprints":{"codehealthFindingId/v1":"28c99e84ffbe7cf167095c6958266f925378e4a681df66912dadeba4f63edb67"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.rewriteInteractionsFunctionNames (cognitive 50): interactions.rewriteInteractionsFunctionNames has cognitive complexity 50 (threshold 15). Drivers by points: if/else 32, loops 13, boolean chains 5 (nesting depth added 26). Of this number, 35 points are the body\u0027s own statements and 15 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f8f4192e24db84110f6ebe6b3cebe7724d142c122b400e5828b854998e98100"}},{"ruleId":"D2","level":"warning","message":{"text":"util.FixJSON (cognitive 50): util.FixJSON has cognitive complexity 50 (threshold 15). Drivers by points: if/else 35, loops 6, boolean chains 5, match/switch 4 (nesting depth added 28). Of this number, 49 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/translator.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"87ea6227233bc5fdf197946fae02fdad3e127a7173042462a92477f6058102ba"}},{"ruleId":"D2","level":"warning","message":{"text":"cliproxy.applyOAuthModelAliasEntries (cognitive 50): cliproxy.applyOAuthModelAliasEntries has cognitive complexity 50 (threshold 15). Drivers by points: if/else 42, loops 6, boolean chains 2 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":934}}}],"partialFingerprints":{"codehealthFindingId/v1":"beb88beb8dfda1314b7aea95360b6d186d6c21f8b58e64907665e5c309f54bd1"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityReplayToolSchemasFromRequests (cognitive 49): executor.antigravityReplayToolSchemasFromRequests has cognitive complexity 49 (threshold 15). Drivers by points: if/else 34, loops 14, boolean chains 1 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"e40ffb6b0de13212e02bb470d9e1b5153d3a8994d0f044dfef0c38b46622b7c1"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeExecutor.Execute (cognitive 49): ClaudeExecutor.Execute has cognitive complexity 49 (threshold 15). Drivers by points: if/else 42, boolean chains 5, loops 2 (nesting depth added 12). Of this number, 48 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_execute.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"9965648b41528ee51ad716d32c362c494dd55173b9c0c526d0ea86624249141e"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.SanitizeAntigravityClaudeGeminiRequestSignatures (cognitive 49): gemini.SanitizeAntigravityClaudeGeminiRequestSignatures has cognitive complexity 49 (threshold 15). Drivers by points: if/else 46, loops 3 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"441e64045afea0f35584ed64affefdb432b0fc7e5f7fc3d8db2573a58defc202"}},{"ruleId":"D2","level":"warning","message":{"text":"StreamRewriter.RewriteChunk (cognitive 49): StreamRewriter.RewriteChunk has cognitive complexity 49 (threshold 15). Drivers by points: if/else 42, boolean chains 6, loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/response_model_rewriter.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c82e468ec76a1a465eea7c0b62c027c48d8c1896922a25a98554121eec62c78"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.runHomeSubscriber (cognitive 49): Service.runHomeSubscriber has cognitive complexity 49 (threshold 15). Drivers by points: if/else 44, boolean chains 4, loops 1 (nesting depth added 24). Of this number, 39 points are the body\u0027s own statements and 10 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"64a75c6c7535a130b077736957e9261ff50b06f1128d0defd3ec3e163ee22eef"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.filterXAIReasoningReplayItemsForInput (cognitive 48): executor.filterXAIReasoningReplayItemsForInput has cognitive complexity 48 (threshold 15). Drivers by points: if/else 27, loops 15, boolean chains 4, match/switch 2 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_reasoning_replay.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"081bac914214e1ae919f3519437d9fd1d7810d45aef99ae297f3d93bd6aaecc7"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.normalizeResponseSubsequentRequest (cognitive 48): openai.normalizeResponseSubsequentRequest has cognitive complexity 48 (threshold 15). Drivers by points: if/else 46, boolean chains 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ead539c61fc8c7dd2ed20400fa6531b5e55215a40cde61aad6a62584f5bd2ac"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToAntigravity (cognitive 47): gemini.ConvertGeminiRequestToAntigravity has cognitive complexity 47 (threshold 15). Drivers by points: if/else 41, boolean chains 4, loops 2 (nesting depth added 22). Most of this is not in the body itself: 11 of the 47 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 95, 69). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"e324fe871bf4f1b08aa668e3780bb24bad876fe10f28f4aa8242b06d04840935"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.reorderOpenAIResponsesDetachedReasoning (cognitive 47): responses.reorderOpenAIResponsesDetachedReasoning has cognitive complexity 47 (threshold 15). Drivers by points: if/else 28, boolean chains 18, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dee1a98f53715836a20064e3360611cae482aadf93741ee870655d40e7b8c74"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexAuthenticator.Login (cognitive 47): CodexAuthenticator.Login has cognitive complexity 47 (threshold 15). Drivers by points: if/else 38, match/switch 5, jumps 3, loops 1 (nesting depth added 16). Of this number, 45 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/codex.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"714618fad41bd2c1c8739665cef8741805bea946662dd57a031b8b04be3c25fe"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.collectImagesFromResponsesStream (cognitive 46): openai.collectImagesFromResponsesStream has cognitive complexity 46 (threshold 15). Drivers by points: if/else 33, loops 9, boolean chains 2, match/switch 2 (nesting depth added 25). Of this number, 28 points are the body\u0027s own statements and 18 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1569}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d460981ada651475231fe8dd1bce71a0b8505cbe52ed206a0bf82ecc8a5c428"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityAuthenticator.Login (cognitive 46): AntigravityAuthenticator.Login has cognitive complexity 46 (threshold 15). Drivers by points: if/else 37, match/switch 5, jumps 3, loops 1 (nesting depth added 11). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/antigravity.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"7caa1a5a57aa5b2c569e1b696747483dd29f245b06c84316701d066462f9a63a"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.applyClaudeToolPrefix (cognitive 45): executor.applyClaudeToolPrefix has cognitive complexity 45 (threshold 15). Drivers by points: if/else 33, boolean chains 10, match/switch 2 (nesting depth added 20). Most of this is not in the body itself: 9 of the 45 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1536, 1509). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1499}}}],"partialFingerprints":{"codehealthFindingId/v1":"51748d50ada516400863734d8bc0fb70d51d13610816d8f611d2abca434bd920"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.Start (cognitive 44): Server.Start has cognitive complexity 44 (threshold 15). Drivers by points: if/else 38, boolean chains 5, match/switch 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a48344ac8432d98e988c9e00a2984b2fae663900f105f2692f581239bea0ccd"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.ReplaceAntigravityReasoningReplayItemsIfUnchanged (cognitive 44): cache.ReplaceAntigravityReasoningReplayItemsIfUnchanged has cognitive complexity 44 (threshold 15). Drivers by points: if/else 29, boolean chains 13, loops 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"374461f5c874302801aef200fc3c96b0eaeb39971f717db000a59afe05b4ec77"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.cloneInterceptorMetadataReflectValue (cognitive 44): pluginhost.cloneInterceptorMetadataReflectValue has cognitive complexity 44 (threshold 15). Drivers by points: if/else 35, loops 8, match/switch 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_interceptors.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"aedca19cc29c1b40971fa817e361f14de0bab70c03d27e531404ecd874ba78c3"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RegisterExecutors (cognitive 44): Host.RegisterExecutors has cognitive complexity 44 (threshold 15). Drivers by points: if/else 34, boolean chains 5, loops 5 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"f553e36b31a43104a726e384f312506c797c509dfe8db5c1b06775a15569c9ab"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityFunctionCallPartLocationForReplayWithSchemas (cognitive 44): executor.antigravityFunctionCallPartLocationForReplayWithSchemas has cognitive complexity 44 (threshold 15). Drivers by points: if/else 31, boolean chains 7, loops 6 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba9cc3628aa81174c9c64d23e52df8eb14ef9aa8f32765980bc195412b6d5f71"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.Execute (cognitive 44): CodexExecutor.Execute has cognitive complexity 44 (threshold 15). Drivers by points: if/else 39, boolean chains 4, loops 1 (nesting depth added 14). Of this number, 43 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_execute.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"837d412462a3e0d1f150d87229aa2e763610be6c0cc480fa24eaa5c534b47acc"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.containsStructuredModelNotFound (cognitive 44): auth.containsStructuredModelNotFound has cognitive complexity 44 (threshold 15). Drivers by points: if/else 28, match/switch 8, boolean chains 4, loops 4 (nesting depth added 28). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1383}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ec4b7a471c824a07f6d315b7d3e2725fd6035421e3c2b6fba2f8e877f0b8b5f"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.rebuildAPIKeyModelAliasLocked (cognitive 44): Manager.rebuildAPIKeyModelAliasLocked has cognitive complexity 44 (threshold 15). Drivers by points: if/else 40, match/switch 2, boolean chains 1, loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"282efd9c38ff0dd02b9fa990fd7e20dffbd537efaf9804fce577eb6127077bfe"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchAuthFileFields (cognitive 43): Handler.PatchAuthFileFields has cognitive complexity 43 (threshold 15). Drivers by points: if/else 40, loops 3 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_fields.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"7337a4d0031028c112be04df38455dbd015cde13297e696698da29c7807f4095"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.listAuthFilesFromDisk (cognitive 43): Host.listAuthFilesFromDisk has cognitive complexity 43 (threshold 15). Drivers by points: if/else 42, loops 1 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b1d598c2b962d483214db0ae5010f4c697ffaf6a3897d0ef6708597111f8933"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityThoughtSignatureReplayPartPath (cognitive 43): executor.antigravityThoughtSignatureReplayPartPath has cognitive complexity 43 (threshold 15). Drivers by points: if/else 28, boolean chains 9, loops 6 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1135}}}],"partialFingerprints":{"codehealthFindingId/v1":"26738020f8eeebcd2ff55a839530daa0a666edcb6dc5e10613ed318f6e9b4ab2"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.rewriteOpenAICompatImagesMultipartPayload (cognitive 43): executor.rewriteOpenAICompatImagesMultipartPayload has cognitive complexity 43 (threshold 15). Drivers by points: if/else 36, loops 6, boolean chains 1 (nesting depth added 22). Of this number, 42 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":699}}}],"partialFingerprints":{"codehealthFindingId/v1":"1abb703a60e42fdcc0d6414d0f1afba88f68dde6671d837e41cdc5ca0404309e"}},{"ruleId":"D2","level":"warning","message":{"text":"main.fetchModels (cognitive 42): main.fetchModels has cognitive complexity 42 (threshold 15). Drivers by points: if/else 32, boolean chains 4, loops 3, match/switch 3 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_antigravity_models/main.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae6f1daf8af3882b53d0ba8d74d9afbb7a40acf73de32fc514982ea890c23cf"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.filterCodexReasoningReplayItemsForInput (cognitive 42): executor.filterCodexReasoningReplayItemsForInput has cognitive complexity 42 (threshold 15). Drivers by points: if/else 23, loops 15, boolean chains 2, match/switch 2 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3b159579d2f01f9fc44055a5e90b9331841ac3ffc01e7b5461da129b872ea6d"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeExecutor.countTokensUpstream (cognitive 42): ClaudeExecutor.countTokensUpstream has cognitive complexity 42 (threshold 15). Drivers by points: if/else 39, boolean chains 3 (nesting depth added 13). Of this number, 41 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_tokens.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"e69ea9212ea56bebfd50a638e76b96608a5ccf3fceca7dc6365e1a2933c42e1c"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.executeOpenAIImageStream (cognitive 42): CodexExecutor.executeOpenAIImageStream has cognitive complexity 42 (threshold 15). Drivers by points: if/else 31, loops 4, match/switch 4, boolean chains 3 (nesting depth added 17). Most of this is not in the body itself: 12 of the 42 points are its own statements and the rest belongs to one function literal inside it that branches (line 242). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9382691b5fae77757db40ce285009afd85923999a974264126c7845df983f02"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.InspectClaudeCAISSignature (cognitive 42): signature.InspectClaudeCAISSignature has cognitive complexity 42 (threshold 15). Drivers by points: if/else 39, match/switch 3 (nesting depth added 13). Most of this is not in the body itself: 12 of the 42 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 688, 640, 669). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb8cfd1f2041c0f31cf525f0750e7c5be51793e3425018e79427f874a697a2d3"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.sanitizeOpenAIResponsesReasoningEncryptedContent (cognitive 41): executor.sanitizeOpenAIResponsesReasoningEncryptedContent has cognitive complexity 41 (threshold 15). Drivers by points: if/else 34, boolean chains 3, loops 2, match/switch 2 (nesting depth added 16). Of this number, 37 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_responses_signature.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f2f09895aea5602544dd8e47153dad7eab50762f232f68b38ee887f9cdcae1c"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.EnsureClaudeCredentialDevicePoolRequired (cognitive 41): helps.EnsureClaudeCredentialDevicePoolRequired has cognitive complexity 41 (threshold 15). Drivers by points: if/else 41 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fce95736e1d1ff1ff9b5911454dcb357b73c9cc38656b224bf286c7fd29700a"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.resolveUsageSource (cognitive 41): helps.resolveUsageSource has cognitive complexity 41 (threshold 15). Drivers by points: if/else 41 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"f59429d697c49ecee83cfca13ec69f9260478b7a234a11c60fd70ca38770913f"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeInputTokenState.applyChunk (cognitive 41): ClaudeInputTokenState.applyChunk has cognitive complexity 41 (threshold 15). Drivers by points: if/else 28, loops 7, boolean chains 6 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_input_tokens.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"d090985002cab630f733f121dc905a5d47cc72072fa255868387a6bad9b9cb34"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.pickNextMixed (cognitive 41): Manager.pickNextMixed has cognitive complexity 41 (threshold 15). Drivers by points: if/else 32, loops 5, boolean chains 4 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1371}}}],"partialFingerprints":{"codehealthFindingId/v1":"88bb18d6f28f667b27f1590961d8d219ad4ab3a429edd9bda71b3fcd3bcc7108"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.SanitizeCodexInputItemIDs (cognitive 40): helps.SanitizeCodexInputItemIDs has cognitive complexity 40 (threshold 15). Drivers by points: if/else 33, loops 7 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/codex_input_ids.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"26c3a4c4845e4df8772a477f7210b15ea18d0f05aa1817be69198b7e6d66d333"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.ValidateGeminiThoughtSignatures (cognitive 40): signature.ValidateGeminiThoughtSignatures has cognitive complexity 40 (threshold 15). Drivers by points: if/else 32, boolean chains 5, loops 3 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_validation.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"900a08d887276e288b2886fe6d5715b6565140ff0ab7d311c92555a2c8de498c"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.buildOpenAICompatImagesMultipartRequest (cognitive 40): openai.buildOpenAICompatImagesMultipartRequest has cognitive complexity 40 (threshold 15). Drivers by points: if/else 33, loops 6, boolean chains 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"9000f83441696dd8ef76c0f4169993a0c0ba62cc26f3a19a1563a9f19721f75c"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.streamImagesWithModel (cognitive 40): OpenAIAPIHandler.streamImagesWithModel has cognitive complexity 40 (threshold 15). Drivers by points: if/else 32, loops 4, boolean chains 2, match/switch 2 (nesting depth added 20). Of this number, 34 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1434}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfc3458bee2de2fdcdcbdd8e91bb38c57768beaee42977724502e8f097c91989"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.pickNextMixedLegacy (cognitive 40): Manager.pickNextMixedLegacy has cognitive complexity 40 (threshold 15). Drivers by points: if/else 34, boolean chains 4, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1267}}}],"partialFingerprints":{"codehealthFindingId/v1":"c28ad59ae2fd2e6e20c9de21108a00ae643424154ab4f43cbb01c1258819acf2"}},{"ruleId":"D2","level":"warning","message":{"text":"management.readCompleteLogLines (cognitive 39): management.readCompleteLogLines has cognitive complexity 39 (threshold 15). Drivers by points: if/else 33, loops 4, boolean chains 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":1081}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ce06f3e43cfd6ec1051c835fba2f0e2d5079c7b7337d0324dbe90fa764cf5a1"}},{"ruleId":"D2","level":"warning","message":{"text":"config.pruneMappingToGeneratedKeys (cognitive 39): config.pruneMappingToGeneratedKeys has cognitive complexity 39 (threshold 15). Drivers by points: if/else 28, boolean chains 9, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":644}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8d32c3174f100005b3dcf10d8e3104eafa7b8acc41295e9c3c6ddc6cb27b7cb"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiExecutor.executeInteractionsStream (cognitive 39): GeminiExecutor.executeInteractionsStream has cognitive complexity 39 (threshold 15). Drivers by points: if/else 27, match/switch 6, boolean chains 4, loops 2 (nesting depth added 9). Most of this is not in the body itself: 10 of the 39 points are its own statements and the rest belongs to one function literal inside it that branches (line 525). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"77b00e1dc95ea1e849f95369c542efa20d8acb213a922406c73038b0c999ddf6"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.handleCompletionsStreamingResponse (cognitive 39): OpenAIAPIHandler.handleCompletionsStreamingResponse has cognitive complexity 39 (threshold 15). Drivers by points: if/else 24, match/switch 11, loops 4 (nesting depth added 26). Of this number, 17 points are the body\u0027s own statements and 22 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"b82e873155af9a54d62882f68daffd9c4c407f56000784eeaad5cdf9618dd9ca"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.RequestAntigravityToken (cognitive 38): Handler.RequestAntigravityToken has cognitive complexity 38 (threshold 15). Drivers by points: if/else 36, boolean chains 1, loops 1 (nesting depth added 12). Most of this is not in the body itself: 6 of the 38 points are its own statements and the rest belongs to one function literal inside it that branches (line 381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"76ec36f41e02dcd3eba3a6270ac55c07aab949d9f5899a2c3e5d13d0d5993134"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.buildHostAuthFileEntry (cognitive 38): Host.buildHostAuthFileEntry has cognitive complexity 38 (threshold 15). Drivers by points: if/else 32, boolean chains 6 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"eac52a09f1b0a754c99c01a6609ac9615a7d783966d5efb7cd71e0c3a3d43cf7"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexReasoningReplayTurnAnchorIndex (cognitive 38): executor.codexReasoningReplayTurnAnchorIndex has cognitive complexity 38 (threshold 15). Drivers by points: if/else 21, loops 12, boolean chains 5 (nesting depth added 18). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e09813b3e41a601de66ff409f8c5ff92e5d1576cf02215a200c750a1e8f806"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.tryRegisterPluginModelsForAuth (cognitive 38): Service.tryRegisterPluginModelsForAuth has cognitive complexity 38 (threshold 15). Drivers by points: if/else 27, boolean chains 9, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"a82e0dc41c66d473dd6f9ddbe7c0972869b4f5c86165adfe769873fd3b413313"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.Shutdown (cognitive 38): Service.Shutdown has cognitive complexity 38 (threshold 15). Drivers by points: if/else 38 (nesting depth added 12). Most of this is not in the body itself: 1 of the 38 points is its own statement and the rest belongs to one function literal inside it that branches (line 232). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_lifecycle.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"88e8e7a3dd8aad9b94406134991f8f26d5f641b21f642958f577c64b090bf38c"}},{"ruleId":"D2","level":"warning","message":{"text":"chunkedRequestTracker.consume (cognitive 37): chunkedRequestTracker.consume has cognitive complexity 37 (threshold 15). Drivers by points: if/else 30, boolean chains 4, match/switch 2, loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/httpwire/ordered_conn.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"2abe62df7f5b23c30d03dab8ffce265564cdf3c76dec97437c078d71d253ac47"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAITool (cognitive 37): executor.normalizeXAITool has cognitive complexity 37 (threshold 15). Drivers by points: if/else 29, boolean chains 8 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":924}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c2bb046a90fc6038cd7c1f2273977a69012af21ae5fa26727e7fd45dd9a0c20"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexWebsocketsExecutor.readUpstreamLoop (cognitive 37): CodexWebsocketsExecutor.readUpstreamLoop has cognitive complexity 37 (threshold 15). Drivers by points: if/else 33, match/switch 2, boolean chains 1, loops 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc3587e4b6d8a0d5377ddc5e056e48fcf8414370fe81f1722acea4f212c5a7bd"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIWebsocketsExecutor.readUpstreamLoop (cognitive 37): XAIWebsocketsExecutor.readUpstreamLoop has cognitive complexity 37 (threshold 15). Drivers by points: if/else 33, match/switch 2, boolean chains 1, loops 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1215}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e4218dcfc6fa4191df46f63638d3d2c1f23632bc3f08d237f613aed1b05c3e0"}},{"ruleId":"D2","level":"warning","message":{"text":"util.removePlaceholderFields (cognitive 37): util.removePlaceholderFields has cognitive complexity 37 (threshold 15). Drivers by points: if/else 28, loops 8, boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2acbeec24a801501273f72abd9e84df2e1295c6162ebbc431135778a79f3994"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.nextRefreshCheckAt (cognitive 37): auth.nextRefreshCheckAt has cognitive complexity 37 (threshold 15). Drivers by points: if/else 30, boolean chains 5, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/auto_refresh_loop.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a59151663043a45358bd5ecb27efeef100186f63e2d89eeb1d919e0ff3befc"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteAuthFile (cognitive 36): Handler.DeleteAuthFile has cognitive complexity 36 (threshold 15). Drivers by points: if/else 32, loops 3, boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"cda2d0b6a46ae6a353c2d701e4a13f5ecf0d5fe84f55a115c9df6bdb3b4c529d"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.GetAntigravityReasoningReplayItemsWithSnapshotRequired (cognitive 36): cache.GetAntigravityReasoningReplayItemsWithSnapshotRequired has cognitive complexity 36 (threshold 15). Drivers by points: if/else 31, boolean chains 3, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"1429d1f61d1f4c634b9b808792f1cf0345b355f6865bd2ef141a33c14d55ad10"}},{"ruleId":"D2","level":"warning","message":{"text":"live.prepareProxiedUpstreamAnswer (cognitive 36): live.prepareProxiedUpstreamAnswer has cognitive complexity 36 (threshold 15). Drivers by points: if/else 30, loops 5, boolean chains 1 (nesting depth added 15). Of this number, 33 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/tcp_proxy.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eebb89ffaca67e21104c655ea87b22738a7388914489e030e71a01cad079547"}},{"ruleId":"D2","level":"warning","message":{"text":"config.matchSequenceElement (cognitive 36): config.matchSequenceElement has cognitive complexity 36 (threshold 15). Drivers by points: if/else 25, loops 7, boolean chains 3, match/switch 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b37db1f9bdefbd317ecf2716058a98de6f83185fe1f7dcb0c7fe36f927295cc"}},{"ruleId":"D2","level":"warning","message":{"text":"FileRequestLogger.formatLogContent (cognitive 36): FileRequestLogger.formatLogContent has cognitive complexity 36 (threshold 15). Drivers by points: if/else 30, loops 6 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":448}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee28d09a9d4d5ab0b8f1fa027e1c50f4e23391b11639c279cb3652440900ec79"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.buildRequest (cognitive 36): AntigravityExecutor.buildRequest has cognitive complexity 36 (threshold 15). Drivers by points: if/else 31, boolean chains 5 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_request.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"15daf71acd131a0f4e9e94197a378b041f6c7087f62fa1c43e20bc81abb007bb"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.ParseRetryDelay (cognitive 36): helps.ParseRetryDelay has cognitive complexity 36 (threshold 15). Drivers by points: if/else 30, loops 4, boolean chains 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/json_retry_helpers.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"51504ed44940bb09bd3d489871499838380a41b25147f2ff1b43227f86444a25"}},{"ruleId":"D2","level":"warning","message":{"text":"ConfigSynthesizer.synthesizeOpenAICompat (cognitive 36): ConfigSynthesizer.synthesizeOpenAICompat has cognitive complexity 36 (threshold 15). Drivers by points: if/else 33, loops 3 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a4278fd442cbd1ec98ca745468ed341104cd48b7fa507679dac3d5fbbab1b9a"}},{"ruleId":"D2","level":"warning","message":{"text":"FileTokenStore.Save (cognitive 36): FileTokenStore.Save has cognitive complexity 36 (threshold 15). Drivers by points: if/else 35, match/switch 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9d23127d83ffad3c393b215d5325e89e62120faa5815a28813d6bb1e749e0bf"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.routeMuxConnection (cognitive 35): Server.routeMuxConnection has cognitive complexity 35 (threshold 15). Drivers by points: if/else 34, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/protocol_multiplexer.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e46a34ff384539c52057847f3a040614c642c56972e6d826a0461e232bb870c"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.decodeResponseBody (cognitive 35): executor.decodeResponseBody has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22, boolean chains 5, match/switch 5, loops 3 (nesting depth added 16). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"83ac83407b7f6292dde7b039589aaefe0484a0e1bb78b25d780a3f9e022ad6d1"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.writeResponsesWebsocketError (cognitive 35): openai.writeResponsesWebsocketError has cognitive complexity 35 (threshold 15). Drivers by points: if/else 30, boolean chains 3, loops 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_forward.go"},"region":{"startLine":481}}}],"partialFingerprints":{"codehealthFindingId/v1":"753234b961c2a1c3790267da1b27cdfcab0b7220cd463ddf3fe48b396f8dddb8"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.updateAggregatedAvailability (cognitive 35): auth.updateAggregatedAvailability has cognitive complexity 35 (threshold 15). Drivers by points: if/else 31, boolean chains 3, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":974}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4ee3640e330ed8364b5c994feaf63af0355b84a802714596fe870858bfecb6f"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.ReconcileRegistryModelStates (cognitive 35): Manager.ReconcileRegistryModelStates has cognitive complexity 35 (threshold 15). Drivers by points: if/else 29, boolean chains 3, loops 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f5bcdd59d1ea417109c5d5f5f4672e306819c746ed4a9b5dbaddaaf026ca00f"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.GetLogs (cognitive 34): Handler.GetLogs has cognitive complexity 34 (threshold 15). Drivers by points: if/else 30, boolean chains 3, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"a18a901965d4768540ee219cfe3903f9bfe0db6070365638425ee1f69173c88c"}},{"ruleId":"D2","level":"warning","message":{"text":"logging.writeRequestInfoWithBody (cognitive 34): logging.writeRequestInfoWithBody has cognitive complexity 34 (threshold 15). Drivers by points: if/else 31, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"b08f9be39aedebf5d4188c755327f8dfd1c45bd7c36819d233081cc9d8758932"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.filterCodexReasoningReplayTurnItems (cognitive 34): executor.filterCodexReasoningReplayTurnItems has cognitive complexity 34 (threshold 15). Drivers by points: if/else 16, loops 13, match/switch 4, boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"86d43eac057fce5907f93e0be0e1669417fdbf974aea2ba8d4fbe5026e9eccc1"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.maybeRefreshAntigravityCreditsHint (cognitive 34): AntigravityExecutor.maybeRefreshAntigravityCreditsHint has cognitive complexity 34 (threshold 15). Drivers by points: if/else 27, boolean chains 7 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"4230d4ee16db6c77c204e7a72f1c3c7e8e004e99bc84266804d46462de150350"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.Save (cognitive 34): GitTokenStore.Save has cognitive complexity 34 (threshold 15). Drivers by points: if/else 33, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"4599fc206d6071463a8f9742836e97d811deb2215d210607a5892dcd57f664d2"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.ExtractSummaryConfig (cognitive 34): thinking.ExtractSummaryConfig has cognitive complexity 34 (threshold 15). Drivers by points: if/else 30, loops 2, boolean chains 1, match/switch 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/summary.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"886f8a84276a493fc5580bc794c96f42c0bc6f28f8344f9981c032f896311e7f"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.WriteErrorResponse (cognitive 34): BaseAPIHandler.WriteErrorResponse has cognitive complexity 34 (threshold 15). Drivers by points: if/else 17, boolean chains 10, loops 7 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_errors.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8d492527861cf2490e9a0b214bb656ed01688b61e87be859a079b6c8b9adc36"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.handleOAuthCallback (cognitive 33): Handler.handleOAuthCallback has cognitive complexity 33 (threshold 15). Drivers by points: if/else 30, boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/oauth_callback.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"4856249f520ae35f56d594f6f28b6d8b9e0e83266b120f1ef7f1dd76bda0470f"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityAuth.OnboardUser (cognitive 33): AntigravityAuth.OnboardUser has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 1, loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/antigravity/auth.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"34c15af9509b16bb5a5a5724b1cbbbd34d16688406977bd391729608a7cea770"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.unregisterClientInternal (cognitive 33): ModelRegistry.unregisterClientInternal has cognitive complexity 33 (threshold 15). Drivers by points: if/else 31, boolean chains 1, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"64e33ddd95c5b19c0ff5545542b09b7ffed1294a3b930ca5943ebdbf90860a15"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.filterAntigravityReasoningReplayItemsForRequestWithSchemas (cognitive 33): executor.filterAntigravityReasoningReplayItemsForRequestWithSchemas has cognitive complexity 33 (threshold 15). Drivers by points: if/else 25, boolean chains 5, match/switch 2, loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f63f74a1738c81a2f24cdbe07416bbaafd21c6c33481301b837676c255b3b58"}},{"ruleId":"D2","level":"warning","message":{"text":"KimiExecutor.ExecuteStream (cognitive 33): KimiExecutor.ExecuteStream has cognitive complexity 33 (threshold 15). Drivers by points: if/else 20, match/switch 7, loops 4, boolean chains 2 (nesting depth added 9). Of this number, 20 points are the body\u0027s own statements and 13 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e2f270ecc1ff0c28ba2f909f3533d6eb405f93329d81380a4d899f1cf493bb"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.inspectClaudeChannelBlock (cognitive 33): signature.inspectClaudeChannelBlock has cognitive complexity 33 (threshold 15). Drivers by points: if/else 23, match/switch 7, boolean chains 3 (nesting depth added 11). Most of this is not in the body itself: 14 of the 33 points are its own statements and the rest belongs to one function literal inside it that branches (line 422). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"52e57235afc894f5c18a440b072081b3e309770eacbb5c3e615c13ec7adacaf1"}},{"ruleId":"D2","level":"warning","message":{"text":"Applier.Apply (cognitive 33): Applier.Apply has cognitive complexity 33 (threshold 15). Drivers by points: if/else 24, boolean chains 8, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce966111635acf319ef6bfbe7a99b165355fa0d21d7dd2e81e19aedf7b27fe0a"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertOpenAIResponseToGeminiNonStream (cognitive 33): gemini.ConvertOpenAIResponseToGeminiNonStream has cognitive complexity 33 (threshold 15). Drivers by points: if/else 27, boolean chains 3, loops 3 (nesting depth added 17). Most of this is not in the body itself: 4 of the 33 points are its own statements and the rest belongs to one function literal inside it that branches (line 543). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"80bacc5f765f6e7693a1d7a16ed4ae5c9224712a6c81128ec89e2939106031ca"}},{"ruleId":"D2","level":"warning","message":{"text":"logsTabModel.Update (cognitive 33): logsTabModel.Update has cognitive complexity 33 (threshold 15). Drivers by points: if/else 29, match/switch 3, boolean chains 1 (nesting depth added 18). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/logs_tab.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"405986d8b7b057dfe3c653aee75a6231a7624606cd161968c3362db8d9a423f8"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.convertChatCompletionsStreamChunkToCompletions (cognitive 33): openai.convertChatCompletionsStreamChunkToCompletions has cognitive complexity 33 (threshold 15). Drivers by points: if/else 26, boolean chains 7 (nesting depth added 9). Most of this is not in the body itself: 11 of the 33 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 383, 342). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"47303512fb39bb1090790a0a05b30cf428be7e4531b41f7ccc4004dd06602d41"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.imagesEditsFromMultipart (cognitive 33): OpenAIAPIHandler.imagesEditsFromMultipart has cognitive complexity 33 (threshold 15). Drivers by points: if/else 30, boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"42d02fc176ebd67fa25f73c90db870f5af6bbc2438da5c229f0ca7a8e294f6cf"}},{"ruleId":"D2","level":"warning","message":{"text":"management.tokenValueFromMetadata (cognitive 32): management.tokenValueFromMetadata has cognitive complexity 32 (threshold 15). Drivers by points: if/else 22, boolean chains 8, match/switch 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4990459356cb7c129d809eb8cd2fa51f4a9722edaca0f7b77832087606e012a"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteGeminiKey (cognitive 32): Handler.DeleteGeminiKey has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25, loops 5, boolean chains 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"bad73dab063feb0d457c75b1dfc11e93ad879fe6007b7500d89dd234ce6c0f5a"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteInteractionsKey (cognitive 32): Handler.DeleteInteractionsKey has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25, loops 5, boolean chains 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"90d58dfd706a95edfb29cbcf8bf1275a59dc3892de3296de6671915bf0f67b7f"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.AppendCodexReasoningReplayItemsBestEffort (cognitive 32): cache.AppendCodexReasoningReplayItemsBestEffort has cognitive complexity 32 (threshold 15). Drivers by points: if/else 30, loops 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/codex_reasoning_replay_cache.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"af17a3d37a8e3dec3e0e4e8d098fa9299e744e5f7e669c9432c4515028d122e1"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiVertexExecutor.executeStreamWithServiceAccount (cognitive 32): GeminiVertexExecutor.executeStreamWithServiceAccount has cognitive complexity 32 (threshold 15). Drivers by points: if/else 19, match/switch 7, loops 4, boolean chains 2 (nesting depth added 8). Of this number, 17 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"098148439544f4a185bdd8db2e3202c93cdae9b772edf7a052672f83782460f0"}},{"ruleId":"D2","level":"warning","message":{"text":"ObjectTokenStore.syncConfigFromBucket (cognitive 32): ObjectTokenStore.syncConfigFromBucket has cognitive complexity 32 (threshold 15). Drivers by points: if/else 31, match/switch 1 (nesting depth added 19). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"28be685754243ed8a7e5ee642ab1c9b26b80ec0025bd84c68c88572a51a8795c"}},{"ruleId":"D2","level":"warning","message":{"text":"PostgresStore.Save (cognitive 32): PostgresStore.Save has cognitive complexity 32 (threshold 15). Drivers by points: if/else 30, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgresstore.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab3284f05a5f1c752e75cdf36fcfe47b2a8f1ada11fc8e41ccd885fad6b54547"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.fixCLIToolResponse (cognitive 32): gemini.fixCLIToolResponse has cognitive complexity 32 (threshold 15). Drivers by points: if/else 26, loops 4, boolean chains 2 (nesting depth added 10). Most of this is not in the body itself: 6 of the 32 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 606, 589, 567). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"61b63e7ea572dbdd5013f76383082751ae68887c2977486848f42b43988a1793"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.imagesEditsFromJSON (cognitive 32): OpenAIAPIHandler.imagesEditsFromJSON has cognitive complexity 32 (threshold 15). Drivers by points: if/else 26, loops 4, boolean chains 2 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"5be3e8b19bed7d98c484cec28f992a0003e9cae9153a3bf91f3fbd170c451265"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.extractSessionIDs (cognitive 32): auth.extractSessionIDs has cognitive complexity 32 (threshold 15). Drivers by points: if/else 30, loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bd0b3e98a1160fe7d14eb00f47085bda982951de3a6baa4c78f50a8bf8808f0"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.refreshAuthForRequest (cognitive 32): Manager.refreshAuthForRequest has cognitive complexity 32 (threshold 15). Drivers by points: if/else 28, boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"db55c64e73035e1ca5e63df0435e5ada4db329a5296ce895bb03f713ca22b1a9"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.GetAuthStatus (cognitive 31): Handler.GetAuthStatus has cognitive complexity 31 (threshold 15). Drivers by points: if/else 27, match/switch 3, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"d93dce254ddd099d0ebae8dce0fbf62372fac514828fbf9163dc4c893e7a7e3c"}},{"ruleId":"D2","level":"warning","message":{"text":"multiagentv2.restoreCodexCollaborationValue (cognitive 31): multiagentv2.restoreCodexCollaborationValue has cognitive complexity 31 (threshold 15). Drivers by points: if/else 16, boolean chains 7, loops 4, match/switch 4 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3f9af0a4e1c4532b8c35699483973bde2b21a8c04de145b5694908af628cdd1"}},{"ruleId":"D2","level":"warning","message":{"text":"config.LoadConfigOptional (cognitive 31): config.LoadConfigOptional has cognitive complexity 31 (threshold 15). Drivers by points: if/else 27, boolean chains 4 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_load.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"71b872320ecc9590c0d040e4abcccdb2579e935f5839a78961cb9dbd5f9bb283"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.selectPluginFilesWithCandidates (cognitive 31): pluginhost.selectPluginFilesWithCandidates has cognitive complexity 31 (threshold 15). Drivers by points: if/else 23, loops 6, boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/platform.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fdb128c130a585fab894dfffe11b5ad31ee860bec22e0dee3f8060cc87b4c84"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.fixGeminiImageAspectRatio (cognitive 31): executor.fixGeminiImageAspectRatio has cognitive complexity 31 (threshold 15). Drivers by points: if/else 16, loops 14, jumps 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":919}}}],"partialFingerprints":{"codehealthFindingId/v1":"a07d7844c472aeaf4dc1b0101ac6378d0dfbf8a78b6b51742ef1d5ad2c300a93"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiExecutor.ExecuteStream (cognitive 31): GeminiExecutor.ExecuteStream has cognitive complexity 31 (threshold 15). Drivers by points: if/else 19, match/switch 7, loops 4, boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 14 of the 31 points are its own statements and the rest belongs to one function literal inside it that branches (line 333). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"39befe91d430d29f6a10d3ac46bca2bd7ab35307d318754745614b31704f0eb9"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiVertexExecutor.executeStreamWithAPIKey (cognitive 31): GeminiVertexExecutor.executeStreamWithAPIKey has cognitive complexity 31 (threshold 15). Drivers by points: if/else 19, match/switch 7, loops 4, boolean chains 1 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 15 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"d819b52a7c98fdece64870c62e3150daaf03a4a462bc133ac3171b15fef8c86d"}},{"ruleId":"D2","level":"warning","message":{"text":"ObjectTokenStore.Save (cognitive 31): ObjectTokenStore.Save has cognitive complexity 31 (threshold 15). Drivers by points: if/else 29, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c00b406ee73bab944c5af850be8a00e782059ff388f3260140c765f80a937f2"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.rewriteOpenAIResponsesReasoningForAntigravityClaude (cognitive 31): responses.rewriteOpenAIResponsesReasoningForAntigravityClaude has cognitive complexity 31 (threshold 15). Drivers by points: if/else 27, loops 3, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/responses/antigravity_openai-responses_request.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d3e90e9ac93369d9bfc57849d638a2345a80d19e430195e480523b15e8ecb6f"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertGeminiRequestToGemini (cognitive 31): gemini.ConvertGeminiRequestToGemini has cognitive complexity 31 (threshold 15). Drivers by points: if/else 26, boolean chains 5 (nesting depth added 12). Most of this is not in the body itself: 10 of the 31 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 36, 78, 90, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1d871b6a88181422397fd7e13740b198231ad7a347f89170b085b63bf512338"}},{"ruleId":"D2","level":"warning","message":{"text":"util.flattenTypeArrays (cognitive 31): util.flattenTypeArrays has cognitive complexity 31 (threshold 15). Drivers by points: if/else 23, loops 6, boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"a65e72659baad629030496f5fe93d237a4e53eebe46923085032d5a43923a1c8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.startHomeUsageForwarder (cognitive 31): Service.startHomeUsageForwarder has cognitive complexity 31 (threshold 15). Drivers by points: if/else 20, loops 7, match/switch 3, boolean chains 1 (nesting depth added 16). Most of this is not in the body itself: 3 of the 31 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 334, 320). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"58165282653a9e3431a55a40a3b50d5b552cb087967ef2133952e26e8b23015c"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchVertexCompatKey (cognitive 30): Handler.PatchVertexCompatKey has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, boolean chains 3, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"d089df535d936e64854d6279e80a11c4a4983da9ada703a410334dfbdbdec7b9"}},{"ruleId":"D2","level":"warning","message":{"text":"multiagentv2.codexSpawnAgentModelsFromSources (cognitive 30): multiagentv2.codexSpawnAgentModelsFromSources has cognitive complexity 30 (threshold 15). Drivers by points: if/else 27, loops 2, boolean chains 1 (nesting depth added 13). Of this number, 28 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"22abb71cf9891b11b7f68b4e4bcfd5962efc869848083c53270b33b2f0af817d"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.pluginFileInfos (cognitive 30): homeplugins.pluginFileInfos has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21, loops 7, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4d30949158f524e816d5983f6e45120cbc1f311e9653e467522ea65ee5e2e02"}},{"ruleId":"D2","level":"warning","message":{"text":"misc.ParseOAuthCallback (cognitive 30): misc.ParseOAuthCallback has cognitive complexity 30 (threshold 15). Drivers by points: if/else 26, boolean chains 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/misc/oauth.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a729af75170eb4ba01f15365fc00d970a0d1ab467834bc10feccac70e1e6906"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RegisterManagementRoutes (cognitive 30): Host.RegisterManagementRoutes has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, loops 5, boolean chains 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/management.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"a185e5383cb42cc8e93d21cd8a490c4daed721714fa252792d7d7535fdd80095"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.collectXAIClientDeclaredToolKeys (cognitive 30): executor.collectXAIClientDeclaredToolKeys has cognitive complexity 30 (threshold 15). Drivers by points: if/else 19, loops 6, boolean chains 3, match/switch 2 (nesting depth added 16). Most of this is not in the body itself: 7 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 57). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a9f6037506251f18d92ea60ae187d11da35d5ca7248786b99445a7c56ce0356"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.executeDirectOpenAIImageStream (cognitive 30): CodexExecutor.executeDirectOpenAIImageStream has cognitive complexity 30 (threshold 15). Drivers by points: if/else 18, match/switch 7, loops 4, boolean chains 1 (nesting depth added 13). Most of this is not in the body itself: 11 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 433). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbf867e087e0a7c9dfa7cb1df6bd5225cb2b54854916ffd5e877858db53fddfd"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.CachedUserIDRequired (cognitive 30): helps.CachedUserIDRequired has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, boolean chains 5 (nesting depth added 10). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/user_id_cache.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"d18ced6d40093cd5f02fd6237614245167c5074ee82c862d217b42efc96c3b58"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAICompatExecutor.executeImagesStream (cognitive 30): OpenAICompatExecutor.executeImagesStream has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21, match/switch 7, boolean chains 1, loops 1 (nesting depth added 11). Most of this is not in the body itself: 14 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 576). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"797f765dd5107b0dc5b376f9830cea7dff9194a7a1f271723406c7634f8269d1"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.applyThinking (cognitive 30): thinking.applyThinking has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, boolean chains 5 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"b49df374e8b150f881dabdd87bf8e16d6a66b75b7a883b03ff2cf68d753686c9"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.convertResponsesContentPartToClaude (cognitive 30): responses.convertResponsesContentPartToClaude has cognitive complexity 30 (threshold 15). Drivers by points: if/else 29, match/switch 1 (nesting depth added 18). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"72e6bc461f6ec49ae75f5b1e884f5c2603427811480d44e5c6ebf561284a52d1"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.ConvertGeminiResponseToClaudeNonStream (cognitive 30): claude.ConvertGeminiResponseToClaudeNonStream has cognitive complexity 30 (threshold 15). Drivers by points: if/else 22, boolean chains 3, match/switch 3, loops 2 (nesting depth added 14). Of this number, 28 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f628bce85801b94bfa47617b0674d7d5e6dcbe8335fcef3fa1f088936177766"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.claudeErrorDetailFromText (cognitive 30): claude.claudeErrorDetailFromText has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, boolean chains 5 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"368f70708eb933f10790d9f82189046882481c44423646a40f4a377187ff97f1"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.applyAuthFailureState (cognitive 30): auth.applyAuthFailureState has cognitive complexity 30 (threshold 15). Drivers by points: if/else 28, boolean chains 1, match/switch 1 (nesting depth added 9). Of this number, 28 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1578}}}],"partialFingerprints":{"codehealthFindingId/v1":"edf86bf914a46ad5f87a055f833d1a26df16c3e2aec8b409e9e912b06a6e6a3a"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.pickNextLegacy (cognitive 30): Manager.pickNextLegacy has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, boolean chains 4, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8d322a778c4665314ed812eabad82e4f7cfd745ec050e6e480b20505771ea5b"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.UploadAuthFile (cognitive 29): Handler.UploadAuthFile has cognitive complexity 29 (threshold 15). Drivers by points: if/else 27, loops 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"645aef69abc958204bed4adf4d0c912f5d4850e128913bc76d598548a40fd2f3"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.RequestAnthropicToken (cognitive 29): Handler.RequestAnthropicToken has cognitive complexity 29 (threshold 15). Drivers by points: if/else 28, loops 1 (nesting depth added 6). Most of this is not in the body itself: 8 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 88). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1540af0599d9806cf92985583e2d252e90ce61c8a4ca0329a024ac9e6a3d3c"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.RequestCodexToken (cognitive 29): Handler.RequestCodexToken has cognitive complexity 29 (threshold 15). Drivers by points: if/else 28, loops 1 (nesting depth added 10). Most of this is not in the body itself: 8 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 248). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cc38e4a3643a5feede8f057f627b26374fd0329c75b1caa338352c0b88f9597"}},{"ruleId":"D2","level":"warning","message":{"text":"vertex.stripANSIEscape (cognitive 29): vertex.stripANSIEscape has cognitive complexity 29 (threshold 15). Drivers by points: if/else 16, loops 7, boolean chains 4, match/switch 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/vertex/keyutil.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"537a1c3952a126c9736f8c571afa2dd755ebf301a0da05d49d07597f6f017f88"}},{"ruleId":"D2","level":"warning","message":{"text":"pionMediaRelay.NewSession (cognitive 29): pionMediaRelay.NewSession has cognitive complexity 29 (threshold 15). Drivers by points: if/else 26, boolean chains 2, match/switch 1 (nesting depth added 3). Of this number, 24 points are the body\u0027s own statements and 5 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdae17007d1dad6433aa28ef8cf030893a49766a646947a7da51e929cbd9e322"}},{"ruleId":"D2","level":"warning","message":{"text":"orderedRequestConn.Write (cognitive 29): orderedRequestConn.Write has cognitive complexity 29 (threshold 15). Drivers by points: if/else 28, loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/httpwire/ordered_conn.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"b29e88b19cb46ad123b06f63f7ba1a14030e6093cc2371c93ca9c45888476e09"}},{"ruleId":"D2","level":"warning","message":{"text":"managementasset.EnsureLatestManagementHTML (cognitive 29): managementasset.EnsureLatestManagementHTML has cognitive complexity 29 (threshold 15). Drivers by points: if/else 26, boolean chains 3 (nesting depth added 8). Most of this is not in the body itself: 2 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 203). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/managementasset/updater.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"40d86c91c2b2a7f65bd584659fb3abb79c6d2212c448bc7b698135fda0cd3ce5"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.get (cognitive 29): Client.get has cognitive complexity 29 (threshold 15). Drivers by points: if/else 24, loops 4, boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/github.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"841dfa5658cf11a7aae22a2bd9580699523cc3bb85a79e7af96ce0de9d4cdba2"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.prependClaudeSystemRemindersToFirstUserMessage (cognitive 29): executor.prependClaudeSystemRemindersToFirstUserMessage has cognitive complexity 29 (threshold 15). Drivers by points: if/else 16, loops 11, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d754a5fc26677e0629afe1656691aa87cb8329397e02983f51639d2dfb10237"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAICompatExecutor.resolveCompatConfig (cognitive 29): OpenAICompatExecutor.resolveCompatConfig has cognitive complexity 29 (threshold 15). Drivers by points: if/else 22, boolean chains 4, loops 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a14640160e6c154c623d354c0ac0ee00a2c4102e28c145ad2c838b19fdcf6c6"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.recoverRepositoryLocked (cognitive 29): GitTokenStore.recoverRepositoryLocked has cognitive complexity 29 (threshold 15). Drivers by points: if/else 29 (nesting depth added 5). Of this number, 24 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fdb64684d5e976e65e5075703e254e498f385903fedbb526cc80f69a7b992ba"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeCodeAPIHandler.WriteErrorResponse (cognitive 29): ClaudeCodeAPIHandler.WriteErrorResponse has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13, loops 10, boolean chains 6 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f86d0554c40b9a3294041a43ac42650c5362ad8eda19040acc8544da029cca7"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.dedupeInputItemsByID (cognitive 29): openai.dedupeInputItemsByID has cognitive complexity 29 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 2, match/switch 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cf081d2f5bb5d71b4f2914790628cc0ff819c6dabc11c4343592ee2a904053b"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.packHomeInFlightFrames (cognitive 29): auth.packHomeInFlightFrames has cognitive complexity 29 (threshold 15). Drivers by points: if/else 23, boolean chains 3, loops 3 (nesting depth added 11). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c74d367644cdb500e0152aa4ee7b24dcf63d9a53d0832e2195e4036701fee82"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.shouldRefresh (cognitive 29): Manager.shouldRefresh has cognitive complexity 29 (threshold 15). Drivers by points: if/else 24, boolean chains 5 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb2b958d45899f405675b030d5e36543e45a5f3e6fae8c84de4a18a9cb3085ef"}},{"ruleId":"D2","level":"warning","message":{"text":"Auth.indexSeed (cognitive 29): Auth.indexSeed has cognitive complexity 29 (threshold 15). Drivers by points: if/else 24, boolean chains 3, match/switch 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/types.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b905583df4e3907a51281d5dcc3fd0fe5ff36607eb85a4f0a4cc7a9d98d34dd"}},{"ruleId":"D2","level":"warning","message":{"text":"management.readLogFilesFromCursor (cognitive 28): management.readLogFilesFromCursor has cognitive complexity 28 (threshold 15). Drivers by points: if/else 27, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"101f841a194e02791060638e862af2f02423aed277f94be5e72dfa256946393e"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.APICall (cognitive 28): Handler.APICall has cognitive complexity 28 (threshold 15). Drivers by points: if/else 24, boolean chains 2, loops 2 (nesting depth added 7). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"db04e4a9f71c3b00db902cb3edea7953a535a40aff45ee6e9730eb74b9d76efb"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteClaudeKey (cognitive 28): Handler.DeleteClaudeKey has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e1211b8a6c94ba0eee8d5ee62eb6967144415b8b12b4811469c281f1d1908de"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchOpenAICompat (cognitive 28): Handler.PatchOpenAICompat has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 3 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"75089acc6d94dcc8fd82c954c00609a487882729c6c426ccf85351cb7d2ec0ec"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteVertexCompatKey (cognitive 28): Handler.DeleteVertexCompatKey has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":949}}}],"partialFingerprints":{"codehealthFindingId/v1":"29aadce76e630110de36abcaa3ff3413f96f8c927cf1a9a9c8bcb8f2f62df508"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteCodexKey (cognitive 28): Handler.DeleteCodexKey has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1312}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc509c10be8179df2aa1ec57c97e586bb1dc1f455a7ce6791ce90c00fd68f30b"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteXAIKey (cognitive 28): Handler.DeleteXAIKey has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 5, boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1502}}}],"partialFingerprints":{"codehealthFindingId/v1":"d23bf06a55603e170b5870653003d47c071a319510ca01bc8fba0a63d727eff9"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexRewriteOpenAIImageEditMultipartToJSON (cognitive 28): executor.codexRewriteOpenAIImageEditMultipartToJSON has cognitive complexity 28 (threshold 15). Drivers by points: if/else 18, loops 7, boolean chains 3 (nesting depth added 10). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"8edde65de561106e4b0928f6eac4f5fae6eff0028ca36ccf52ffffebc793c10e"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.sanitizeXAIInputEncryptedContent (cognitive 28): executor.sanitizeXAIInputEncryptedContent has cognitive complexity 28 (threshold 15). Drivers by points: if/else 23, boolean chains 2, match/switch 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"2875af73288911d0b48f5fdeaec2ef1697a11d3b800283361eefd76a5ad086d5"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.RecordAPIRequest (cognitive 28): helps.RecordAPIRequest has cognitive complexity 28 (threshold 15). Drivers by points: if/else 27, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/logging_helpers.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2d765d36c9f7b944b053e846a287823856e8d62272a525d23a98bb496708449"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.resolvePayloadRulePaths (cognitive 28): helps.resolvePayloadRulePaths has cognitive complexity 28 (threshold 15). Drivers by points: if/else 18, loops 9, boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe713719fe741f274659ddacdfa4ecb93096eaafa3f174fd08afe577e462b191"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.SanitizeGeminiRequestThoughtSignatures (cognitive 28): signature.SanitizeGeminiRequestThoughtSignatures has cognitive complexity 28 (threshold 15). Drivers by points: if/else 23, boolean chains 4, match/switch 1 (nesting depth added 4). Most of this is not in the body itself: 5 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 44). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_sanitize.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e187133b92a0bfa08f1952defee4d88c78bb7961d78823c010ef2fc2bc28743"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.appendInteractionsContentToAntigravityPart (cognitive 28): interactions.appendInteractionsContentToAntigravityPart has cognitive complexity 28 (threshold 15). Drivers by points: if/else 25, boolean chains 2, match/switch 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"98da0b0ea4ccd5e1f571b980e01934db8a9adf8df9f8ff8f99839e8f99ecf162"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.interactionsContentPartToGeminiPart (cognitive 28): interactions.interactionsContentPartToGeminiPart has cognitive complexity 28 (threshold 15). Drivers by points: if/else 25, boolean chains 2, match/switch 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"6143433a327df0e6bbc8e7abe42e6c5f373c1ac3692c06b9cd3137ff7fda1e1f"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.convertOpenAINonStreamingToAnthropic (cognitive 28): claude.convertOpenAINonStreamingToAnthropic has cognitive complexity 28 (threshold 15). Drivers by points: if/else 22, boolean chains 4, loops 2 (nesting depth added 12). Of this number, 18 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b63bdb9f9e1657b51ba8ea98880c4bdb68456b4e5ef9eb1101da63eb51b7166"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.resolveAPIKeyConfig (cognitive 28): auth.resolveAPIKeyConfig has cognitive complexity 28 (threshold 15). Drivers by points: if/else 15, boolean chains 9, loops 4 (nesting depth added 6). Of this number, 21 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"db9dab183b0f86967d1aa0bfc3890c1c04ed5f266ac3114457bc05147fc9bad7"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.resolveModelAliasPoolFromConfigModels (cognitive 28): auth.resolveModelAliasPoolFromConfigModels has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20, loops 6, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38c64b6ad033a3fb187fadee73a61287906cf4693a88f08fc71bb573b9d7233"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.pickNext (cognitive 28): Manager.pickNext has cognitive complexity 28 (threshold 15). Drivers by points: if/else 22, boolean chains 4, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1211}}}],"partialFingerprints":{"codehealthFindingId/v1":"1621aa3f9b7c4f72d9e574919bf7de5199dea60a4fb26a18f23155cac32ca32a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resolveConfigClaudeKey (cognitive 28): Service.resolveConfigClaudeKey has cognitive complexity 28 (threshold 15). Drivers by points: if/else 19, boolean chains 6, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"f876bfa9665b6d2dbf90454c54e70b8bdaf9fbdd3ed278decbf254d45eb5a9a8"}},{"ruleId":"D2","level":"warning","message":{"text":"main.runOrderedExecutionPlans (cognitive 27): main.runOrderedExecutionPlans has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 3, match/switch 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/execution_fallback.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"96e9dc5c874b02510d0a8206440bb2140edca685d6386875d00de63d75819c66"}},{"ruleId":"D2","level":"warning","message":{"text":"management.resolveAPIKeyConfig (cognitive 27): management.resolveAPIKeyConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, boolean chains 6, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"1eb38e50cefe83fb4afa62ec2169b2b8b07508b356c6129a71fcb698e5ef4cab"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchGeminiKey (cognitive 27): Handler.PatchGeminiKey has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, boolean chains 3, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"0520ac1715b2df1f771718a34671f318b0a083057f347d81420f022bd68b75db"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchInteractionsKey (cognitive 27): Handler.PatchInteractionsKey has cognitive complexity 27 (threshold 15). Drivers by points: if/else 21, boolean chains 3, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cb52573efd2d504363779a834d84c6b67e8873cc89af3a156806bffab521040"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchXAIKey (cognitive 27): Handler.PatchXAIKey has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1406}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa96247fdb35756bc27a32830f47731f6bfff94feeb2bbd67d187f34a8023315"}},{"ruleId":"D2","level":"warning","message":{"text":"logging.writeResponseSection (cognitive 27): logging.writeResponseSection has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f2f41d44ff1dfdec632fa639544724230f77d75600fac797d1b0c7f4e0fa430"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.ensureColonSpacedJSON (cognitive 27): executor.ensureColonSpacedJSON has cognitive complexity 27 (threshold 15). Drivers by points: if/else 20, loops 4, boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"17aae3409bdbcad96095b847f0054a082e7d4c78a795f279cb2023cf5750114e"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAIToolArray (cognitive 27): executor.normalizeXAIToolArray has cognitive complexity 27 (threshold 15). Drivers by points: if/else 20, loops 5, boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":807}}}],"partialFingerprints":{"codehealthFindingId/v1":"27e3190ae8abdb5595a871ecb65df27e5d5c9a56f596a9526ec6206611de78e4"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.resolveCodexConfig (cognitive 27): CodexExecutor.resolveCodexConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, boolean chains 6, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_auth.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"189a2def2b54ef1c9d41267606ac2244a99dbf4e3a0fd576fe447388a5560f0f"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.executeOpenAIImage (cognitive 27): CodexExecutor.executeOpenAIImage has cognitive complexity 27 (threshold 15). Drivers by points: if/else 23, match/switch 2, boolean chains 1, loops 1 (nesting depth added 10). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"8575952885dc05e6f3b57b32fdd4dddbd30511f34414cb234fbae85cd94ff1a7"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiExecutor.resolveGeminiConfig (cognitive 27): GeminiExecutor.resolveGeminiConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, boolean chains 6, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f035cc32a1d1c3a0fe4d56e4c252b0e24883e208d9840a0d930ef04320a8970"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiVertexExecutor.resolveVertexConfig (cognitive 27): GeminiVertexExecutor.resolveVertexConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, boolean chains 6, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":1113}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7569d060b9a6819dc93e085d93c41f77881a137546f0f09340b94a329987381"}},{"ruleId":"D2","level":"warning","message":{"text":"store.applyRecoveryLocalChanges (cognitive 27): store.applyRecoveryLocalChanges has cognitive complexity 27 (threshold 15). Drivers by points: if/else 23, loops 2, match/switch 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1250}}}],"partialFingerprints":{"codehealthFindingId/v1":"600d1ce8caa6cbd7956bb5b963a663087509355f630ff109875a7197a5449aa8"}},{"ruleId":"D2","level":"warning","message":{"text":"PostgresStore.syncConfigFromDatabase (cognitive 27): PostgresStore.syncConfigFromDatabase has cognitive complexity 27 (threshold 15). Drivers by points: if/else 26, match/switch 1 (nesting depth added 16). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgresstore.go"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"33bbf72ffbfc09b80133a2abb56f790251442b509f95435944f68bbcfd448189"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.normalizeAntigravityOpenAIThinkingConfig (cognitive 27): chat_completions.normalizeAntigravityOpenAIThinkingConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 3, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"71475c6746ac7c7d21637b1e7a85cc4ff1d3fc0c1709211536db0a81eacb40d1"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.backfillEmptyFunctionResponseNames (cognitive 27): gemini.backfillEmptyFunctionResponseNames has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, loops 2, boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 8 of the 27 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 167, 143). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"b19ba4d5a7b17fc16dc7d24d63a5d152c7208dce865fab451d3c33eb7edfccde"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeCodeAPIHandler.handleStreamingResponse (cognitive 27): ClaudeCodeAPIHandler.handleStreamingResponse has cognitive complexity 27 (threshold 15). Drivers by points: if/else 24, match/switch 2, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7a8f0adc8b4591a27bbcda9ef158e216f17fe22adb08d096bd7e7a19bc49d2c"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.parseDurationValue (cognitive 27): auth.parseDurationValue has cognitive complexity 27 (threshold 15). Drivers by points: if/else 25, boolean chains 1, match/switch 1 (nesting depth added 13). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_refresh.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f94c9b22f861b28b6b1218fc234c10f7f0f899bf221665d94653386ede23847"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.encodeHomeInFlightFreeze (cognitive 27): auth.encodeHomeInFlightFreeze has cognitive complexity 27 (threshold 15). Drivers by points: if/else 20, loops 4, boolean chains 3 (nesting depth added 6). Of this number, 21 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff76f14b14f0659c7f0b13e152cb692a9232b0e26895bbf1f7ac0baf4489da38"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.closestCooldownWait (cognitive 27): Manager.closestCooldownWait has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, boolean chains 3, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":651}}}],"partialFingerprints":{"codehealthFindingId/v1":"f68024cb52de5c6cbba146d04b6692f607bb8d358a941eb6d70d166fd9152fa8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.runModelRegistrationTaskPhase (cognitive 27): Service.runModelRegistrationTaskPhase has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11, loops 9, match/switch 7 (nesting depth added 14). Of this number, 15 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_plugins.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5a5efe293e4510293ceeb7d334b0048fbcc12a3cb591a7d4f4f98b38dcc6bca"}},{"ruleId":"D2","level":"warning","message":{"text":"httpConnectDialer.DialContext (cognitive 27): httpConnectDialer.DialContext has cognitive complexity 27 (threshold 15). Drivers by points: if/else 26, boolean chains 1 (nesting depth added 8). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/proxyutil/proxy.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"baf4e018cc11e7f1a9a77d03b557753de6fd388a2ee2e685d97f188bc6e67f28"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.normalizeAntigravityFunctionCallPartReplayItem (cognitive 26): cache.normalizeAntigravityFunctionCallPartReplayItem has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, boolean chains 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc21fc2955f17447bdf7437cdd0d25ef737969fb1977e920ed07e41ab74271c7"}},{"ruleId":"D2","level":"warning","message":{"text":"multiagentv2.formatCodexSpawnAgentModels (cognitive 26): multiagentv2.formatCodexSpawnAgentModels has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, loops 4 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"10da68a8d6700a518ee4c54b2a0243b25abae14a4b749e2354c0084380f2475c"}},{"ruleId":"D2","level":"warning","message":{"text":"config.mergeNodePreserve (cognitive 26): config.mergeNodePreserve has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18, loops 4, boolean chains 3, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e5de0976e2be8dfa15ced40bc7a82f082d8a48c1928c9a3249ed3ec57893db"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.deletePluginArtifact (cognitive 26): homeplugins.deletePluginArtifact has cognitive complexity 26 (threshold 15). Drivers by points: if/else 23, boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"1faef538508f7e0ff61fce88719be23f7fc1c9513cd1928c61f0ef053b4b440a"}},{"ruleId":"D2","level":"warning","message":{"text":"executorAdapter.Refresh (cognitive 26): executorAdapter.Refresh has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17, boolean chains 9. Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":688}}}],"partialFingerprints":{"codehealthFindingId/v1":"73db267ced47d8bc1599ffc69db20cefc5c65100552710d34b92dba8835751d6"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RegisterModels (cognitive 26): Host.RegisterModels has cognitive complexity 26 (threshold 15). Drivers by points: if/else 19, boolean chains 4, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"e163903d5b9d17f55d6ef3bd550e3fde61a7686140a9ad85d2aac85d76622988"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.ExecuteCommandLine (cognitive 26): Host.ExecuteCommandLine has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, boolean chains 3, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/command_line.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b92b69b8e301a62775febcdc39668a923b62f4616f961c062206bac23d688a8"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexExecutor.cacheHelper (cognitive 26): CodexExecutor.cacheHelper has cognitive complexity 26 (threshold 15). Drivers by points: if/else 26 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_request.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"7780e5ef9978442e8c87fb3c223e10974b85b702817d82925c21c02fbb1fc233"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.CachedSessionIDRequired (cognitive 26): helps.CachedSessionIDRequired has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21, boolean chains 5 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/session_id_cache.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef43034fcbca5b47f727d2e4aaf7ae3f52ebf6b87e04d63be8f8ed828c230d1e"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.FilterSSEUsageMetadata (cognitive 26): helps.FilterSSEUsageMetadata has cognitive complexity 26 (threshold 15). Drivers by points: if/else 22, boolean chains 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"262b8e717cfc85eea3336fb48d7b32c7d873d5293c6c29e5eeb04a5874bb5433"}},{"ruleId":"D2","level":"warning","message":{"text":"store.resolveRemoteDefaultBranch (cognitive 26): store.resolveRemoteDefaultBranch has cognitive complexity 26 (threshold 15). Drivers by points: if/else 24, loops 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f902d27d7ea8ce43d48b57210150d8ec94609db36ab19650da09e37b80e3159"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.convertOpenAIChatStreamToInteractions (cognitive 26): chat_completions.convertOpenAIChatStreamToInteractions has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, boolean chains 3, loops 3 (nesting depth added 10). Of this number, 13 points are the body\u0027s own statements and 13 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e5298248b03ec6e4105581e76a507cd04bea18769ffb7c03bbca6f4e1740d5b"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.addOrUpdateClientLocked (cognitive 26): Watcher.addOrUpdateClientLocked has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, loops 4, boolean chains 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"8036e40cebde025a4ebd911251db5c3920af2548258c343031cfcc90c2bdef9e"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.availableAuthsForRouteModel (cognitive 26): Manager.availableAuthsForRouteModel has cognitive complexity 26 (threshold 15). Drivers by points: if/else 20, boolean chains 4, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"baee60e5a5f3b9e0ed03a628c341800f63c5c72f7dcfa5c5a61cbe136b0cd015"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.wrapStreamResult (cognitive 26): Manager.wrapStreamResult has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17, boolean chains 4, match/switch 3, loops 2 (nesting depth added 5). Most of this is not in the body itself: 0 of the 26 points are its own statements and the rest belongs to one function literal inside it that branches (line 118). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0589cdbad3424696dca3cc64e7235d8458bdeaecf9a85f905e6eed8b6a71dd9"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 25): main.main has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, boolean chains 2, loops 1 (nesting depth added 2). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_antigravity_models/main.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"9800f5ab2fdd47045c3570d2a7b6f7a0bd1d09e8c7df56b81c1db0b5228189e6"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.buildAuthFromFileData (cognitive 25): Handler.buildAuthFromFileData has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, boolean chains 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbe91f39054f587489dd5cbf3e6d61c5d43dfbda5803156ecbbfff51b601d6c0"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchCodexKey (cognitive 25): Handler.PatchCodexKey has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1224}}}],"partialFingerprints":{"codehealthFindingId/v1":"1221a01a0f4ff052d13778bcac4047c1d95e9b37f2a7af15bebe3607a0f4e990"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.AuthenticateManagementKey (cognitive 25): Handler.AuthenticateManagementKey has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, boolean chains 5 (nesting depth added 4). Of this number, 22 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/handler.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"32024ac7edb746a107c1cfdf134554c79513b49d228d94a5e752de10ecab45aa"}},{"ruleId":"D2","level":"warning","message":{"text":"api.NewServer (cognitive 25): api.NewServer has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, boolean chains 4, loops 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"22d2b00849e4043a5742f5bea1a01d2c4094faec31dcd6acb70e7dfbedac219f"}},{"ruleId":"D2","level":"warning","message":{"text":"Config.ValidateCredentialWeights (cognitive 25): Config.ValidateCredentialWeights has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, loops 9 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/weight.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0f5585762657e71a2e48191cb93f200750e0602d5ec2581019e39aa61cab9c1"}},{"ruleId":"D2","level":"warning","message":{"text":"LogFormatter.Format (cognitive 25): LogFormatter.Format has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 5, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/global_logger.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b2600d14ecd16d5169a0530975fc39193f858517ad3b44e24abe7fa63761079"}},{"ruleId":"D2","level":"warning","message":{"text":"FileRequestLogger.logRequestWithSources (cognitive 25): FileRequestLogger.logRequestWithSources has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, boolean chains 4 (nesting depth added 5). Of this number, 23 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_writer.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c48af93ca38da3019275e75d11617c4ce7f7747d9bac447f09c94369b6f180"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.decideAntigravity429 (cognitive 25): executor.decideAntigravity429 has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13, match/switch 7, loops 3, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c092342c513bdfef2db7608b00091b169f493829d21942d5cc0158275224e94"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.validateClaudeStreamingResponse (cognitive 25): executor.validateClaudeStreamingResponse has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, boolean chains 3, match/switch 2, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_stream.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a15a4e3ffb7a60e444d98d36e62ed15c865995bd960ae3c932d6e83b257c348"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.applyCodexWebsocketHeaders (cognitive 25): executor.applyCodexWebsocketHeaders has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, boolean chains 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_request.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"3935bfe26a32c63530c796c9107bb55003da3be4b4d2fc875703bb0613a0df67"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiVertexExecutor.executeWithServiceAccount (cognitive 25): GeminiVertexExecutor.executeWithServiceAccount has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, boolean chains 3 (nesting depth added 4). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef3ef9b90b33fa2950cd2fb1136eefc701de84546b66b5c48be366a35ccbecfa"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.codexReasoningText (cognitive 25): interactions.codexReasoningText has cognitive complexity 25 (threshold 15). Drivers by points: if/else 25 (nesting depth added 14). Most of this is not in the body itself: 10 of the 25 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 429, 452). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/interactions/interactions_codex_response.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77dff63db3b13de7b7bdbe0152aa6d6dfd19712eee3763081a4d8ea8d40d946"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.toolOutputContentPart (cognitive 25): chat_completions.toolOutputContentPart has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, boolean chains 2, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba39dea5353e40edb6fffac36828adb12710378393e8443f21acdfc7efb3986"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.normalizeGeminiResponsesCarriers (cognitive 25): responses.normalizeGeminiResponsesCarriers has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, boolean chains 8, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/signature_carrier.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e26f2ea65aa65031926b6efce44f9f66cdc4da19ae71a4b10e24d1e92023aba"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.convertClaudeToolResultContent (cognitive 25): claude.convertClaudeToolResultContent has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, boolean chains 4, match/switch 2 (nesting depth added 9). Of this number, 16 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_request.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"076d184a102bda522a95657adc44f213da60a181fa780a208075f22dabbaabfd"}},{"ruleId":"D2","level":"warning","message":{"text":"util.NormalizeClaudeToolInputSchema (cognitive 25): util.NormalizeClaudeToolInputSchema has cognitive complexity 25 (threshold 15). Drivers by points: if/else 17, loops 6, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/claude_schema.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"655b1a594c7aca2c7c1db3c4de5764f1ff7a34400f49ca8a328c4be0b37ee46a"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.prepareAuthUpdatesLocked (cognitive 25): Watcher.prepareAuthUpdatesLocked has cognitive complexity 25 (threshold 15). Drivers by points: if/else 18, loops 5, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/dispatcher.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2122177d2ab4c429898ea08ad69b5d6c895874763efdea04203a791573569fc"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiAPIHandler.handleStreamGenerateContent (cognitive 25): GeminiAPIHandler.handleStreamGenerateContent has cognitive complexity 25 (threshold 15). Drivers by points: if/else 22, match/switch 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"c393036cdb572d4a3405d9a89e601b22c1d6a754c526c7d24cd4ecac084f218d"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.inputHasCodexLocalCompactionSummary (cognitive 25): openai.inputHasCodexLocalCompactionSummary has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, boolean chains 5, loops 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_requests.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"41cf66cbc7a0a338247450a039fb2b71ef093859b87c69125e82034df599a60e"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.responsesWebsocketAuthAvailableForModel (cognitive 25): openai.responsesWebsocketAuthAvailableForModel has cognitive complexity 25 (threshold 15). Drivers by points: if/else 17, boolean chains 8 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_session.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c0e039c5fe9ed93915785d0e8b0fc84742c51693168f587e1bb420f50fdf72"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.resolveUpstreamModelFromAliasTable (cognitive 25): auth.resolveUpstreamModelFromAliasTable has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21, boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"7480c013f72bb713dec6083212c897e8333fb7ac3f7828595d9de989dceb3bfa"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.expirationFromMap (cognitive 25): auth.expirationFromMap has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16, loops 6, match/switch 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/types.go"},"region":{"startLine":617}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f2b34097a8581024796d74a21de846cf41eec2532b63114ccb68507118f4dc7"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionAffinitySelector.Pick (cognitive 25): SessionAffinitySelector.Pick has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19, loops 5, boolean chains 1 (nesting depth added 10). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5ae6df0a4a60d03985fd506deeb84115881c2c2cb9afbfd9bc356632b4d9a2a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.hasNativeOpenAICompatExecutorConfig (cognitive 25): Service.hasNativeOpenAICompatExecutorConfig has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, loops 3, boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_executors.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"5db7f8aa80def41600f3ad5bce48a73e1013cbafb452fab54a7f0c220b912884"}},{"ruleId":"D2","level":"warning","message":{"text":"session.appendCanonicalParts (cognitive 25): session.appendCanonicalParts has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20, boolean chains 2, loops 2, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"fad29530e93377732a9302a775fef8c0a2c4bc3855c9aafa1aeb964dc61a0eab"}},{"ruleId":"D2","level":"warning","message":{"text":"management.resolveOpenAICompatAPIKeyProxyURL (cognitive 24): management.resolveOpenAICompatAPIKeyProxyURL has cognitive complexity 24 (threshold 15). Drivers by points: if/else 15, loops 7, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"eabf4ad4c6258dc9936bc8a833200d848feecd9a3f1fc5185e3e9a37a5f14e74"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchAuthFileStatus (cognitive 24): Handler.PatchAuthFileStatus has cognitive complexity 24 (threshold 15). Drivers by points: if/else 23, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_fields.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"d794ea19c3016347ebd5f98696b11fc1e428a3fc748589d28f9caa4e1547ca56"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.GetCachedSignatureRequired (cognitive 24): cache.GetCachedSignatureRequired has cognitive complexity 24 (threshold 15). Drivers by points: if/else 24 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/signature_cache.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"a24b26294c52928e1cf54cc26a7f96cb05de99b8f318ed998dd550b4eae68666"}},{"ruleId":"D2","level":"warning","message":{"text":"logging.enforceLogDirSizeLimit (cognitive 24): logging.enforceLogDirSizeLimit has cognitive complexity 24 (threshold 15). Drivers by points: if/else 21, loops 2, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/log_dir_cleaner.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e3320b88b7136c0020d898cb2ab0b08056857db49f43ac5af19fbb8f027e30a"}},{"ruleId":"D2","level":"warning","message":{"text":"FileBodySource.WriteTo (cognitive 24): FileBodySource.WriteTo has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 1, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_body_source.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e128f73212785c56fee72d0f51415f8585ae91375f494268dbde93181fec43e"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.registerRPCPlugin (cognitive 24): pluginhost.registerRPCPlugin has cognitive complexity 24 (threshold 15). Drivers by points: if/else 23, boolean chains 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/rpc_client.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"0160fdbbeb0e0a8d6b58b0432554cd49b85437e206565fc0b04ff44906b42b8d"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.discoverCurrentPluginFiles (cognitive 24): pluginstore.discoverCurrentPluginFiles has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, loops 5, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"342572bf8555c09d53afa61df335c3070dce0e152ce5040664670b8ead03e534"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.writeFileAtomic (cognitive 24): pluginstore.writeFileAtomic has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 2 (nesting depth added 7). Of this number, 17 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d9d8264e3e0d33ff26f9b1d43f00dcacb3a13259bdeef78c4661e55f86d3d4f"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexReasoningReplayInsertIndex (cognitive 24): executor.codexReasoningReplayInsertIndex has cognitive complexity 24 (threshold 15). Drivers by points: if/else 13, loops 7, boolean chains 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba2462ad90568ce173c44f9a7222b1cbf3b334cf213c64befea4ec69963b3084"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexExtractImageResults (cognitive 24): executor.codexExtractImageResults has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11, loops 10, boolean chains 3 (nesting depth added 7). Of this number, 21 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"0301ad9d34e010fe49fb3ccf111317d1d5625ce87af29c6f2bf961fcc4da5dbb"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.payloadModelRulesMatch (cognitive 24): helps.payloadModelRulesMatch has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, loops 3, boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4705a8778fced4e4f816cc8c8965cbbee3ff5ce54a8aca0ffe1ffbbe3c97a25"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.DetectSignatureProviderForBlock (cognitive 24): signature.DetectSignatureProviderForBlock has cognitive complexity 24 (threshold 15). Drivers by points: if/else 21, match/switch 2, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/provider_compatibility.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"41ba47c1850f89bae37c50fadaa1de16d4519ad796beaf76bc64322038a48832"}},{"ruleId":"D2","level":"warning","message":{"text":"store.deepEqualJSON (cognitive 24): store.deepEqualJSON has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16, loops 4, boolean chains 3, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1842}}}],"partialFingerprints":{"codehealthFindingId/v1":"db1567f5d0373f3122c3f44b32192f69cf6c31c45281f1594cfe473f25b23287"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.buildWebSearchCitedTextBlocks (cognitive 24): claude.buildWebSearchCitedTextBlocks has cognitive complexity 24 (threshold 15). Drivers by points: if/else 22, boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/web_search.go"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"72369d5d25486e3e217f2a68f93b124680061bbf404f3d1fea1ee7200128503e"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.captureBracketed (cognitive 24): gemini.captureBracketed has cognitive complexity 24 (threshold 15). Drivers by points: if/else 21, boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/gemini/openai_gemini_response.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"951ade4b22e896dde7a5bff10ed34add859e0b3270ff8478ead03db4d3bc51f9"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.deepEqualJSON (cognitive 24): auth.deepEqualJSON has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16, loops 4, boolean chains 3, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/filestore.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fbae9f09532862423b9e4b151c97ce155199312e4319897b2db88fe3e22d520"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.ExtractCustomHeadersFromMetadata (cognitive 24): auth.ExtractCustomHeadersFromMetadata has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, loops 4, boolean chains 1, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/custom_headers.go"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"918328a2494d72497ece56490c27bd8a2e3e841d50ca5398618d06d29095a6e4"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.isAuthBlockedForModel (cognitive 24): auth.isAuthBlockedForModel has cognitive complexity 24 (threshold 15). Drivers by points: if/else 19, boolean chains 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"e54b7e3da765bfb31264fbf905779fb369f66eaba0b51bdcec897680f3f789e3"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.accessTokenForFingerprint (cognitive 24): auth.accessTokenForFingerprint has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11, loops 8, boolean chains 3, match/switch 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/token_fingerprint.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"13f139c51a6bd59f46a5ff47ec8347b3d00f0815bbb008dcdbe69c0bc2ad0a98"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.ResetQuota (cognitive 24): Manager.ResetQuota has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, boolean chains 4, loops 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"1da3d562ccb4869ddb87f8cebf478aa0cacc402a56e28c48375a2c6ebdb9fdf0"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.ExecuteStream (cognitive 24): Manager.ExecuteStream has cognitive complexity 24 (threshold 15). Drivers by points: if/else 21, boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2dcf0235505d177057892b030100a30a3c76f8090f1c06ce24df16247cc83d3"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.findAllAntigravityCreditsCandidateAuths (cognitive 24): Manager.findAllAntigravityCreditsCandidateAuths has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18, boolean chains 4, loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":972}}}],"partialFingerprints":{"codehealthFindingId/v1":"85317fcf2a3646bc862b00aba6bae05db736ce27270049f4645830e85d1ae2a2"}},{"ruleId":"D2","level":"warning","message":{"text":"main.runOrderedExecutionPlansStream (cognitive 23): main.runOrderedExecutionPlansStream has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18, loops 3, match/switch 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/stream_forward.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d8c9685b99e52dda18a8f86fc4f719237ac8be4d48238b98e1327e4224bffcd"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.authIDForPath (cognitive 23): Handler.authIDForPath has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"354c5781f3924082697bfbb310dcf7b576e3d3bca3a2be3d8cd96ba9414a63c4"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.PatchClaudeKey (cognitive 23): Handler.PatchClaudeKey has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18, boolean chains 3, loops 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"c65d84db08356e67fe62c258fa14faa65e1f3a40b2637e1575955f48ffaeb632"}},{"ruleId":"D2","level":"warning","message":{"text":"antigravity.defaultAntigravityTierID (cognitive 23): antigravity.defaultAntigravityTierID has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, loops 2, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/antigravity/auth.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"e605c99e0a01bf5664a9977b9b15f1e1b3a676b084444a1ff70015e8674caa6c"}},{"ruleId":"D2","level":"warning","message":{"text":"multiagentv2.rewriteCodexAgentMessageContent (cognitive 23): multiagentv2.rewriteCodexAgentMessageContent has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, loops 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8052d4721f8ba0ed8c910e01def45e71f1a87b8d40bfbcd3cd0d7b0e468a746"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.authDataWithDefaults (cognitive 23): pluginhost.authDataWithDefaults has cognitive complexity 23 (threshold 15). Drivers by points: if/else 19, loops 4 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"95bbf0c31e4dc1470d2e1e5224c67f4cf664d48433d19df4279caf4812340f08"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.readTargetLibrary (cognitive 23): pluginstore.readTargetLibrary has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 2, loops 1 (nesting depth added 8). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6668be125c8e6a4d6975637760b7b72a2dc5ed7287985b9be10390a5e50d116"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.uniqueClaudeJSONObjectMember (cognitive 23): helps.uniqueClaudeJSONObjectMember has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18, boolean chains 4, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"43fbd84888eed4d6a36132d406e8e9dfc71f397f0a6ef1ae8df4159d11c14368"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.splitPayloadRulePath (cognitive 23): helps.splitPayloadRulePath has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":564}}}],"partialFingerprints":{"codehealthFindingId/v1":"722557a4af7ddafaecde5c555f54ae96e0bdd79b6b2ec2d1e6d987c348386bd9"}},{"ruleId":"D2","level":"warning","message":{"text":"store.reconcileRemoteWorktree (cognitive 23): store.reconcileRemoteWorktree has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"04f9fd4251dfbc7c524961adb43fed1bcd08a0e76ced6ccb5ef3f4b37d4e415b"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.responsesToolDescriptors (cognitive 23): responses.responsesToolDescriptors has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17, match/switch 3, boolean chains 2, loops 1 (nesting depth added 10). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 840, 816, 801). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"f50749c0521c2f62c49d0ebae593656f0332c09f6339371fafb12eda6322bf58"}},{"ruleId":"D2","level":"warning","message":{"text":"configTabModel.renderContent (cognitive 23): configTabModel.renderContent has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17, match/switch 3, boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/config_tab.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd8ca4874cb6c2d06754838744e0ee7a391553176f9d82259d2045c16b2fa933"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.ImagesGenerations (cognitive 23): OpenAIAPIHandler.ImagesGenerations has cognitive complexity 23 (threshold 15). Drivers by points: if/else 22, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ac0b7e19a57a1e609357d5507cfcdcf2beb4fa1bb079c348055069cc5996fc5"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.pollCodexDeviceToken (cognitive 23): auth.pollCodexDeviceToken has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16, match/switch 5, boolean chains 1, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/codex_device.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1a3bee71837adce6dd3faec57339a6ab9dfaf72c2ee7c3ab16c7164c8862d93"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.configuredModelAliasEntries (cognitive 23): auth.configuredModelAliasEntries has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, boolean chains 2, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae955bc43a4da7a44c898eca559a903874dfb1099e36a3b92e4058ed4dc35ae3"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.resolveModelAliasResultFromConfigModels (cognitive 23): auth.resolveModelAliasResultFromConfigModels has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbd51aa7382f84b10a57d87c2c17db00a089dd09b9cee49d8f3bb9e061282510"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.StartHomeInFlightPublisher (cognitive 23): Manager.StartHomeInFlightPublisher has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16, loops 4, match/switch 2, boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"69d292f071171293302784c31c9f0f079a0ac97ec0a1534991ff69307f298e33"}},{"ruleId":"D2","level":"warning","message":{"text":"Builder.Build (cognitive 23): Builder.Build has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/builder.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"7765eaa3a811c7dc82c02b8588003e4f96599c7bf676ee4e3221f3e9647ad157"}},{"ruleId":"D2","level":"warning","message":{"text":"main.hostModelStreamForwardClaude (cognitive 22): main.hostModelStreamForwardClaude has cognitive complexity 22 (threshold 15). Drivers by points: if/else 20, boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/stream_forward.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e829e15e6c86694cfd24f8e4fb70c3ddbec62fbb24cb353e2f680f0a667443f"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeleteLogs (cognitive 22): Handler.DeleteLogs has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"e679a2218f4ff65071b7fc964501ae2fb861f599d797fdfd43bd40b6f53f226e"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.streamRedisSubscription (cognitive 22): Server.streamRedisSubscription has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/redis_queue_protocol.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"daf43778186d8561a5cba495cdad318998206ab85d1bf11bcd97ccb06cd513dd"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIAuth.PollForToken (cognitive 22): XAIAuth.PollForToken has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, match/switch 2, boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/xai/xai.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"a683478b23e90e4f9464853a763768331c2e9b84b2e1e4267bad8fae46c338ce"}},{"ruleId":"D2","level":"warning","message":{"text":"config.cloneRuntimeValue (cognitive 22): config.cloneRuntimeValue has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13, loops 8, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/clone.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6a2c60667a41e0970924ca9a8d97f49789c5a120b32353c76e5f1a7dabe36ff"}},{"ruleId":"D2","level":"warning","message":{"text":"releaseFlusher.flush (cognitive 22): releaseFlusher.flush has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12, loops 10 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/concurrency_release.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac33aa83b2fe769dd23ae3abcd5b53bba58a15867e90d18d56e1ea0cc2a3128"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.MarkLoadResults (cognitive 22): homeplugins.MarkLoadResults has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, boolean chains 2, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"410eb8f8781894f5dacd0bb19f22b1ed7c88bc0876182b916951d60170984f28"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.commitExecutorState (cognitive 22): Host.commitExecutorState has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12, loops 7, boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fe45ac738f0b6179afd01f5571e6cc6126f13962d1a285bc059479a99ebe7de"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.insertCodexReasoningReplayTurns (cognitive 22): executor.insertCodexReasoningReplayTurns has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 5, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"33f9d8fd6ae4d27a1b274d5a4a7c40350d78849b47212cc52366642b5231b71f"}},{"ruleId":"D2","level":"warning","message":{"text":"claudeCCHJSONScanner.parseObject (cognitive 22): claudeCCHJSONScanner.parseObject has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_signing.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"002ea0c57e7353d347ecfacdfc87b7cf14e579c1738a25b5b3a85db84011dd18"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.RefreshAuthViaHome (cognitive 22): helps.RefreshAuthViaHome has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15, boolean chains 5, match/switch 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/home_refresh.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"085d0b51da0122eba729281078a1bf8f4a7afff3065800b0f6565a6b17eb7b27"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIExecutor.Execute (cognitive 22): XAIExecutor.Execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, match/switch 2, boolean chains 1, loops 1 (nesting depth added 6). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_execute.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff0495e6873464318afa52fe8b533a7305d1a62d351300194766b8e600f3bc41"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.resolveCacheModeSignatureRequired (cognitive 22): claude.resolveCacheModeSignatureRequired has cognitive complexity 22 (threshold 15). Drivers by points: if/else 22 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"be358070333ea79fb08e739cc6170140f1022b33881be78bb2f022fb745372f7"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.parseWebSearchGroundingSupports (cognitive 22): claude.parseWebSearchGroundingSupports has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 5, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/web_search.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c3d50fc87a289c3562595069f0adc8315bfe9f95c2b62baf404aa63e8af5474"}},{"ruleId":"D2","level":"warning","message":{"text":"wsrelay.decodeResponse (cognitive 22): wsrelay.decodeResponse has cognitive complexity 22 (threshold 15). Drivers by points: loops 10, if/else 9, match/switch 3 (nesting depth added 13). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2013fd4db045ebc6bfd644c3e6c2c66fbd64ec44b1a8fdc57e1d29e5c42aced"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.streamImagesFromResponses (cognitive 22): OpenAIAPIHandler.streamImagesFromResponses has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, match/switch 2, loops 1 (nesting depth added 9). Of this number, 20 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1725}}}],"partialFingerprints":{"codehealthFindingId/v1":"4da7a81b30221595baa734def0bd1e52ecf60f4702e26ce0898d5096ab0e15fc"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.addConfiguredModelCapability (cognitive 22): auth.addConfiguredModelCapability has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, loops 6 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/api_key_model_capabilities.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3497585ebc3ca3eb5b06d57218df17ce99670b027265f685afeace45982ed10"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.wrapHomeStream (cognitive 22): auth.wrapHomeStream has cognitive complexity 22 (threshold 15). Drivers by points: if/else 14, match/switch 5, boolean chains 2, loops 1 (nesting depth added 10). Most of this is not in the body itself: 4 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 214). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home_execution.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5e1e630d1ea1b0e0d3545ad6d22ddbb6df387ed01b1f2af73abceef48a702fa"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.resolveUpstreamModelFromAliases (cognitive 22): auth.resolveUpstreamModelFromAliases has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b1f42de5bb2a856b016f2d45b947bfe1311407198ca7d7a62b74c826fce933"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.RestoreCooldownStates (cognitive 22): Manager.RestoreCooldownStates has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cc96a7faf9d97d44b938fd9f3890d96c1ce8bf781f6a21320e1746586dbb136"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.tryAntigravityCreditsExecute (cognitive 22): Manager.tryAntigravityCreditsExecute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18, loops 3, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a983dc5590486d01e16de2790e9f77f072e2e389dd552469b7ab17e4cbff176"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.finalizeHomePluginWork (cognitive 22): Service.finalizeHomePluginWork has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, loops 2, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/home_plugins.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"429829ae56cb98961d6c2218091f4d152059d134ebfbd32bf72c2a78a44c8c5d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.handleAuthUpdates (cognitive 22): Service.handleAuthUpdates has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16, boolean chains 3, match/switch 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_auth.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"59aa910a1827b82bf8870d1d886fd9f07ecc1c246c9fbcdbd08055a91b398a3e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.applyConfigRuntime (cognitive 22): Service.applyConfigRuntime has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, boolean chains 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_config.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"9987ccfec441fb8b575a6331500f9db9cad29a854bfe8459b955650263c6a0a9"}},{"ruleId":"D2","level":"warning","message":{"text":"management.toggleConfigAPIKeyExcludedAll (cognitive 21): management.toggleConfigAPIKeyExcludedAll has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14, loops 6, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_apikey_disable.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"018614b83de2e47f5fd81eb6e46740b0eb15d26facbb3ca85932cbf1fb935665"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.GetRequestLogByID (cognitive 21): Handler.GetRequestLogByID has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"a09351e9614ca8858058bcbc878ca745f39861b930a7e40c8dba5ecda85bfda6"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.ListPlugins (cognitive 21): Handler.ListPlugins has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12, loops 7, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"d955c2a89240645567a50cd0aff9d9e420b6af1ee222b7bb8d654f8ba8877f29"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.DeletePlugin (cognitive 21): Handler.DeletePlugin has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, boolean chains 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"11caf59dd26a59ed6978bcc4312c698cf80c63ab9a0dd13331b8f994a609b9e6"}},{"ruleId":"D2","level":"warning","message":{"text":"live.bundledICECredentials (cognitive 21): live.bundledICECredentials has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/tcp_proxy.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"495e49b1eeeb7566f21e381f4f2ca70550e46af955fac205e4103a8a6e8ce531"}},{"ruleId":"D2","level":"warning","message":{"text":"config.nodesStructurallyEqual (cognitive 21): config.nodesStructurallyEqual has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15, loops 4, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"444165658e578828ca14d8a1995506a95d104c2ce59145c73686c24eb068d7c2"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexLiveMediaRelayConfig.Validate (cognitive 21): CodexLiveMediaRelayConfig.Validate has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13, loops 3, match/switch 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/codex_live.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"275a21dbe887f20ae1b536c8fb6bec53b375c52c3f33dd27edab110e08232afb"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.normalizeCommandLineFlagValue (cognitive 21): pluginhost.normalizeCommandLineFlagValue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/command_line.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc7d2694d0fd1eaa5e4e3b74337e802f91b2f160c7166742d61d2e85ed5b5b4d"}},{"ruleId":"D2","level":"warning","message":{"text":"Manifest.Validate (cognitive 21): Manifest.Validate has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/manifest.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"85fb66d1945956517d8bf6bbb2739c347e1503fb445fa4500aa11612b452e6e1"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityReasoningReplayClientSessionKey (cognitive 21): executor.antigravityReasoningReplayClientSessionKey has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, loops 5 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"c253aa29848524dc80ad1a690a81469c78e8867970d8a24de93b310b79469c7f"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityReasoningReplayItemsFromRequest (cognitive 21): executor.antigravityReasoningReplayItemsFromRequest has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, loops 1 (nesting depth added 9). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to one function literal inside it that branches (line 1589). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1583}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aeb2ce34d91d0930d12d168e2ee820458b13bac61f6b5d3901493548bbfd412"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAIImageRefsValue (cognitive 21): executor.normalizeXAIImageRefsValue has cognitive complexity 21 (threshold 15). Drivers by points: loops 9, boolean chains 4, if/else 4, match/switch 4 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cbbdcc65cb4ad6759b51c8fb0ef73f418f23a46554e3e5484dba7b616067337"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.setPayloadValueIfDifferentTracked (cognitive 21): helps.setPayloadValueIfDifferentTracked has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15, boolean chains 5, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aecd57b40dbb0f22d3767ec75e609de6a074bcef992b740daf944cb37fae163"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAICompatExecutor.Execute (cognitive 21): OpenAICompatExecutor.Execute has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"e68095fe91c083dac4bdb9e76ae80b281d8a068bff986a20de7fa2d086a2123e"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.applySummaryConfigForProvider (cognitive 21): thinking.applySummaryConfigForProvider has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13, loops 4, boolean chains 3, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/summary.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"2959a5aad769f87361b707d54673c2ca153c1365a3c8dd09a9436a40c048275e"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.convertClaudeContentPart (cognitive 21): claude.convertClaudeContentPart has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, match/switch 4, boolean chains 1 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_request.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"96a4d872ef3952796d52e15137a2c208b2a81363f8b2155744c634abfdf346ff"}},{"ruleId":"D2","level":"warning","message":{"text":"dashboardModel.renderDashboard (cognitive 21): dashboardModel.renderDashboard has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/dashboard.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"602c637f2a196ffb0b336b33c731e9387578a14fe1909156fe98e02a2b895f82"}},{"ruleId":"D2","level":"warning","message":{"text":"keysTabModel.renderContent (cognitive 21): keysTabModel.renderContent has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, loops 3, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/keys_tab.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bc769cb5d68654fd5e2407d067d82a19ba2039581845c6f590262cecf829ea2"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.reloadConfig (cognitive 21): Watcher.reloadConfig has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12, boolean chains 6, loops 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/config_reload.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea297f44ca7e18eed93a8f3c78f82172eb474b5bd14ab09e60286ae7cf3d8f8"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.Stream (cognitive 21): Manager.Stream has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14, match/switch 6, loops 1 (nesting depth added 11). Most of this is not in the body itself: 2 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 125). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d79740cc9e14c6ad8aa884d6ca12c4cf67b1dd082366c2fecb1cb5953aec61f"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.setOpenAIVideoErrorFromXAI (cognitive 21): openai.setOpenAIVideoErrorFromXAI has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_videos_handlers.go"},"region":{"startLine":619}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9dc7a6dab2a9e8cc7c44db3c5af5658981a65349b4255a84aa6041295656714"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.forwardRawImageStream (cognitive 21): OpenAIAPIHandler.forwardRawImageStream has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, match/switch 2, boolean chains 1, loops 1 (nesting depth added 12). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1258}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a794883acb7c536c6fec1038f64d07a4e91842714af23007a85856337854e13"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIAuthenticator.Login (cognitive 21): XAIAuthenticator.Login has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/xai.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ff5fbdf223b02d36e90aad13eec73bc282af479803033bf0b86f90fc5c11a2f"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.pickSmoothWeightedScheduled (cognitive 21): auth.pickSmoothWeightedScheduled has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13, boolean chains 5, loops 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":1068}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a8d4d3982b20b4bcd8497bc2868aa9b101e46ffc229510452e5100e0fd8e327"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.SelectHomeAuthWithCredentialPolicy (cognitive 21): Manager.SelectHomeAuthWithCredentialPolicy has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17, boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1116}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffe1ec11ef7f2a87431592c1a896d8496197e99b76c496a471113c6e71de4d1c"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.SelectHomeAuthByKind (cognitive 21): Manager.SelectHomeAuthByKind has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16, boolean chains 4, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1165}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f6d5f05a565b43d657ebb1b4bf3a9fdbaed32883054c9898945738ded806d0b"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resolveConfigVertexCompatKey (cognitive 21): Service.resolveConfigVertexCompatKey has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14, boolean chains 4, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"a28a7e616a4e985efa89eb190f13a57fbd50aee99c44db4870fff3c096ffced7"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 20): main.main has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, boolean chains 1 (nesting depth added 1). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_codex_models/main.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd56a4bf1788498e7f14b354d92aae1d3724919236683f679f565e1777f1c176"}},{"ruleId":"D2","level":"warning","message":{"text":"management.parseLastRefreshValue (cognitive 20): management.parseLastRefreshValue has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, boolean chains 2, loops 2, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fd9b4e08510df55187d6c11edb930cbf33fdb6b2716c1355beb3fa1e054c6a1"}},{"ruleId":"D2","level":"warning","message":{"text":"management.yamlNodeToJSONValue (cognitive 20): management.yamlNodeToJSONValue has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, loops 4, boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":618}}}],"partialFingerprints":{"codehealthFindingId/v1":"71583fb9dfe29893751e7fcdb6f32cbf50c876ec60a98eecbaaf67e6ad85f03a"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.refreshAntigravityOAuthAccessToken (cognitive 20): Handler.refreshAntigravityOAuthAccessToken has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 3. Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bd984a7e82c14caa9c8d33eaa4b1a8dbb306855805284efb704f5ffdfd92a2f"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.findPluginStoreInstallTarget (cognitive 20): Handler.findPluginStoreInstallTarget has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":569}}}],"partialFingerprints":{"codehealthFindingId/v1":"2554489b06c6e25ed188b061cb21707e4fe828cb086a5592171fecefb2ecdb31"}},{"ruleId":"D2","level":"warning","message":{"text":"api.resolveRemoteIP (cognitive 20): api.resolveRemoteIP has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 2, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/redis_queue_protocol.go"},"region":{"startLine":343}}}],"partialFingerprints":{"codehealthFindingId/v1":"324e5b2a5c4a30693e9ec92af7a37ff4d9e9e3dbf1e6687cd7efe3676309cebf"}},{"ruleId":"D2","level":"warning","message":{"text":"pionMediaSession.AcceptUpstreamAnswer (cognitive 20): pionMediaSession.AcceptUpstreamAnswer has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, boolean chains 2, loops 2, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"86e496bf7a3f62ccc719d062a66a204b0b3c089f6d107bd98f2de6057bdb6525"}},{"ruleId":"D2","level":"warning","message":{"text":"multiagentv2.decodeCodexHomeAvailableModels (cognitive 20): multiagentv2.decodeCodexHomeAvailableModels has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"972e0123bf335d2c111d1d28188744dc0589d34fb5ce7b58f3b20501cb17cb64"}},{"ruleId":"D2","level":"warning","message":{"text":"Config.SanitizeOAuthModelAlias (cognitive 20): Config.SanitizeOAuthModelAlias has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, boolean chains 3, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_normalization.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"f89f45461b72b93aad4064845643d1fbaa72057cf63af46141db75202351c290"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.addInstalledVersionStatuses (cognitive 20): homeplugins.addInstalledVersionStatuses has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 5, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4480f067a437a1757306c518a7799561d039e893ceaa0c95902e5c9dde8f9fb"}},{"ruleId":"D2","level":"warning","message":{"text":"executorAdapter.translateExecutorStreamChunks (cognitive 20): executorAdapter.translateExecutorStreamChunks has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 4, match/switch 2, boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 4 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 551). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"25e15b5fb0b0f490b48896c3c385467ffebe2a7a09a03146ba6cefc66b4546da"}},{"ruleId":"D2","level":"warning","message":{"text":"streamBridgeStream.run (cognitive 20): streamBridgeStream.run has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10, match/switch 6, loops 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/stream_bridge.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eade4c2e36a480ddfd487e06bc313f2003da12d0911501bfa31a77cb8064b84"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.ValidateResolvedAuthConfig (cognitive 20): pluginstore.ValidateResolvedAuthConfig has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11, boolean chains 5, match/switch 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/auth.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"436c2ca63aa6eb9d6d8c72398b2639fb3e71c24f3c806ff35cf34e05fd0296c7"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.modelRegistrationAvailability (cognitive 20): registry.modelRegistrationAvailability has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, boolean chains 4, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":841}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1961e2e4700a13f6d6af4c3e8d38aa4432febf5ec0606590b6b7b41dd6b3579"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.repairAntigravityGeminiFunctionResponseNames (cognitive 20): executor.repairAntigravityGeminiFunctionResponseNames has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 3 (nesting depth added 7). Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 250, 227). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"477e22c5709d7fa1dfd8c9cce521a6edbd7825d44d76091eed51483a759f3c50"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityIsInShortCooldownRequired (cognitive 20): executor.antigravityIsInShortCooldownRequired has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"c95de1a545bbe62e022de33919332e67bacce7bca169db703396e2c7fafc6985"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.degradeAntigravityClaudeToolProvenanceIDs (cognitive 20): executor.degradeAntigravityClaudeToolProvenanceIDs has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1036}}}],"partialFingerprints":{"codehealthFindingId/v1":"630d75531920eba98092f55cca3d1cd098f74994e7cca1288e8112bb45e63328"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.validateClaudeTokenCountRequest (cognitive 20): executor.validateClaudeTokenCountRequest has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, boolean chains 3, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_tokens.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"939f4020453f61e1fc18cf6e89335296854ac10a74c7a6e8c982faa32a0087f3"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexPrepareOpenAIImageEditMultipart (cognitive 20): executor.codexPrepareOpenAIImageEditMultipart has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 6). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"da19cdfe2de10716712d37df6f248b8105631e56f864e917b65cfb6847452d77"}},{"ruleId":"D2","level":"warning","message":{"text":"AntigravityExecutor.updateAntigravityCreditsBalance (cognitive 20): AntigravityExecutor.updateAntigravityCreditsBalance has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 2, loops 1 (nesting depth added 4). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e76d16ff33b75863af64a3994fe5bc84adf16602df08f883dc8b7376a22739f"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.rebuildClaudeMetadataUserID (cognitive 20): helps.rebuildClaudeMetadataUserID has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 3, match/switch 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"e83daf71192c7d5b402ed5c8c6a81b68063fe120df43f3431feb426239e13d4c"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.findPayloadQueryClose (cognitive 20): helps.findPayloadQueryClose has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"23540213d91a622eba7f93c1d1ff98d59aee9c7cd49188d9745230a099c60c9b"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.parseOpenAIStyleUsageNode (cognitive 20): helps.parseOpenAIStyleUsageNode has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"069b2d68e83f01633e9f38765d3db5a56e5c0c6c207ce3b8e67d53bb1fb2cd91"}},{"ruleId":"D2","level":"warning","message":{"text":"kimiThinkingReplayStreamAccumulator.content (cognitive 20): kimiThinkingReplayStreamAccumulator.content has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14, boolean chains 4, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_thinking_replay.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cabfe648674fdd07cca73c43f7bbbf359a3b71b3aefb95942c1afb343103a5f"}},{"ruleId":"D2","level":"warning","message":{"text":"ObjectTokenStore.syncAuthFromBucket (cognitive 20): ObjectTokenStore.syncAuthFromBucket has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7c6cbf2991c684f05ebd21f3da79b432760ab3d1a96c49ecd83ba73a6203cab"}},{"ruleId":"D2","level":"warning","message":{"text":"postgresCooldownStateStore.Save (cognitive 20): postgresCooldownStateStore.Save has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres_cooldown_store.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cf956c483311c34c41df703c9f892ef15f36efdf31847126b8880b834bb6635"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.ConvertAntigravityResponseToGemini (cognitive 20): gemini.ConvertAntigravityResponseToGemini has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, loops 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_response.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"394b3ee83c6fca26ad35d8c12368cdb8f08f68ca85e9512f89dc2c3f0897fcd0"}},{"ruleId":"D2","level":"warning","message":{"text":"util.mergeAllOf (cognitive 20): util.mergeAllOf has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13, loops 7 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"102e8793f507593abd2dce4df0ce6da8af1550dc9f738909d47cbced3adde78e"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.handleEvent (cognitive 20): Watcher.handleEvent has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, boolean chains 5 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/events.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f3e856445750f2f682752cd5c768b3bdf02f201298660647027867958639696"}},{"ruleId":"D2","level":"warning","message":{"text":"handlers.wrapModelExecutionChunks (cognitive 20): handlers.wrapModelExecutionChunks has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 2, match/switch 2, boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 272). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/model_execution.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"533d9f47fda2b474793acccd8d855f456c50aa835ef1e2beec24d21977664ea4"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseAPIHandler.getRequestDetailsWithOptions (cognitive 20): BaseAPIHandler.getRequestDetailsWithOptions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16, boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_routing.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc6a4ac3ec36f08da476fa5dadbb064da471dfb8613dca4b9e4b4369b70f17fa"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.convertChatCompletionsResponseToCompletions (cognitive 20): openai.convertChatCompletionsResponseToCompletions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 19, boolean chains 1 (nesting depth added 7). Most of this is not in the body itself: 7 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 287). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f89d245354f97a7335424e0f11f78d07b4d476df83ce7710c534a4f42670b49"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.streamRoutedImages (cognitive 20): OpenAIAPIHandler.streamRoutedImages has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, match/switch 2, loops 1 (nesting depth added 9). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1172}}}],"partialFingerprints":{"codehealthFindingId/v1":"207cc5f760debd1af629444b49b6abf5bc290043bbad1c1db129c69d1816fc1e"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIAPIHandler.streamOpenAICompatImages (cognitive 20): OpenAIAPIHandler.streamOpenAICompatImages has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, match/switch 2, loops 1 (nesting depth added 9). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1301}}}],"partialFingerprints":{"codehealthFindingId/v1":"60922e6760f5027627b72dc380e9133267ffc991c1b2392d68f1b61267baca66"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.compileAPIKeyModelCapabilitiesForAuth (cognitive 20): auth.compileAPIKeyModelCapabilitiesForAuth has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 1, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/api_key_model_capabilities.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ee2242d337bdccf45f921d84824077ebd611897b98072fe130cc4a6d7ab2a94"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.compileOAuthModelAliasTable (cognitive 20): auth.compileOAuthModelAliasTable has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 3, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"d440eb053fc01d41b79b81d5a7e5e453e5dda1bac4b07c52be567a698c9c33bb"}},{"ruleId":"D2","level":"warning","message":{"text":"pprofServer.ApplyContext (cognitive 20): pprofServer.ApplyContext has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/pprof_server.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"c461e61574108b56f287607202e8f8e35f1f8c7f5f1e7d04ce982841f4e6b0ca"}},{"ruleId":"D2","level":"warning","message":{"text":"api.decodeHomeModels (cognitive 19): api.decodeHomeModels has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f27ea89e321990642300858ec57536c0b27ca4b10e4e6c650c58c6fec462442"}},{"ruleId":"D2","level":"warning","message":{"text":"ClaudeAuth.ExchangeCodeForTokens (cognitive 19): ClaudeAuth.ExchangeCodeForTokens has cognitive complexity 19 (threshold 15). Drivers by points: if/else 19 (nesting depth added 4). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/anthropic_auth.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"87be817cfe4ab9e18b3591e88ea19ec26209fdb9965aeafe4de9799ef6e0363d"}},{"ruleId":"D2","level":"warning","message":{"text":"config.isZeroValueNode (cognitive 19): config.isZeroValueNode has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"8234b14575a5547ef23c38594b21548b700027ec946a03988e67253c341d7f5e"}},{"ruleId":"D2","level":"warning","message":{"text":"FileStreamingLogWriter.asyncWriter (cognitive 19): FileStreamingLogWriter.asyncWriter has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9, match/switch 9, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_streaming.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e7eb13fc9bef855a57bdb0f98ae95a6a7bc623e2e00cdbb28e0212b9d380661"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RefreshAuth (cognitive 19): Host.RefreshAuth has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2. Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_provider.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"da3425b519e2134a54e066a6ab095866cc4a644fc8bd35f4ec203bfe41fd2dbc"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.NormalizeAuthConfigs (cognitive 19): pluginstore.NormalizeAuthConfigs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/auth.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"315dbaabea142e5e02f4d96d6170c987253f389d07be4e6ec1f6b964d9cef43a"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.InstallArchive (cognitive 19): pluginstore.InstallArchive has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"805c099612e8c67ef5a4c7fd76ff6fa8ceb89475aa3c5f98ed39a83afde8b000"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.GetModelInfo (cognitive 19): ModelRegistry.GetModelInfo has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, boolean chains 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":1177}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9cb1666f05d8a5e5273c9043cb3235197d99a6f569c47747b1da3b0b7b07fbd"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.insertClaudeMidConversationSystemMessages (cognitive 19): executor.insertClaudeMidConversationSystemMessages has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, loops 5, boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fa678889d4322581e58c65d9657bde5c1d43e918f2da8fcf6ad4f0688a926d2"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.applyCodexHeadersFromSources (cognitive 19): executor.applyCodexHeadersFromSources has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_request.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"f216ca78ce20a2680783db697e20619c45d13675219168c5b5139dc47c883566"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.convertToImagenRequest (cognitive 19): executor.convertToImagenRequest has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 3, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a2a6b95679fe02f3b3c4980ebb258c8831b4a6837facd07ef823e09fc4b2f73"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.xaiUsingAPI (cognitive 19): executor.xaiUsingAPI has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, match/switch 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdd13beea6e56c7dd3f96398597bfe11ce77336767feaab71afa51a14a9bdf34"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.collectXAINamespaceToolRefs (cognitive 19): executor.collectXAINamespaceToolRefs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, loops 5, boolean chains 2 (nesting depth added 8). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 1024). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":1022}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a6e9f0d4427e614644294b6374f5c0ef6891962abbd15f14d7e3833a93a1bbe"}},{"ruleId":"D2","level":"warning","message":{"text":"KimiExecutor.Execute (cognitive 19): KimiExecutor.Execute has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 2 (nesting depth added 3). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"f542b158231321bcd5d825ed75a5f34daea696fde2b9af57dfc7a11136f1c617"}},{"ruleId":"D2","level":"warning","message":{"text":"kimiThinkingReplayStreamAccumulator.observe (cognitive 19): kimiThinkingReplayStreamAccumulator.observe has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, match/switch 2, boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_thinking_replay.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"baec219f8b331f54d402b9dd6abd84c0bfecaa834cf82d4cd0c3152897b755f3"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.resolveToolUseThoughtSignature (cognitive 19): claude.resolveToolUseThoughtSignature has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"1758a28716c4d608c265a11dccf1c4d0d3530360b3c372f0172ca41cda5b9af6"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.consolidateParts (cognitive 19): gemini.consolidateParts has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12, boolean chains 6, loops 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"97315360d6513668bc46276821dad811382c4da6261ae788cb7ad63814bd6212"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.appendCodexFunctionCallQueue (cognitive 19): claude.appendCodexFunctionCallQueue has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":669}}}],"partialFingerprints":{"codehealthFindingId/v1":"8870e90f9fb88a4f154b1d18e574466546000f93da270b9fffcad3a3735a9e3d"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.buildReverseMapFromOriginalOpenAI (cognitive 19): chat_completions.buildReverseMapFromOriginalOpenAI has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10, loops 5, match/switch 3, boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"30bd683c80f26b74da933eb889ba74504946b0e3493859dec8e4644e4b27d365"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.geminiPartToInteractionsStep (cognitive 19): interactions.geminiPartToInteractionsStep has cognitive complexity 19 (threshold 15). Drivers by points: if/else 19 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":1228}}}],"partialFingerprints":{"codehealthFindingId/v1":"64145a65cdec57610d3c54ab87f7f9b8dc5965695b9138ffc3b4c6b1e4884c6e"}},{"ruleId":"D2","level":"warning","message":{"text":"authTabModel.renderContent (cognitive 19): authTabModel.renderContent has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/auth_tab.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"d35f0c0c158ed49c441803ffd829fb04a3270f62b268fec23f18217c781769d6"}},{"ruleId":"D2","level":"warning","message":{"text":"util.addEmptySchemaPlaceholder (cognitive 19): util.addEmptySchemaPlaceholder has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe46cef38c6019bf83bbb947d7f932d0edf48d3714fecc5ca1bc8cf2e8aed0a6"}},{"ruleId":"D2","level":"warning","message":{"text":"handlers.requestExecutionMetadata (cognitive 19): handlers.requestExecutionMetadata has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fde4cb7884d8df68771a9d751253a274c8c2964512b560373542a079b62e9a8"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.Execute (cognitive 19): Manager.Execute has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fb604db7beb9ed026d23728d3409c586ba405f132034a2f2f51a7026c3aa07d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.fetchAntigravityModelCapabilityHintsForAuth (cognitive 19): Service.fetchAntigravityModelCapabilityHintsForAuth has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, boolean chains 3, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/antigravity_models.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d76f3d2f8b462364c6cbd4a81970d15ef2d2b6793d81e801cfb2e9037a81fd4"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.GetAPIKeyUsage (cognitive 18): Handler.GetAPIKeyUsage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_key_usage.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a4c575b6e092c8d74859954d424887ff23150b11f06f80937eba1e966d19267"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.apiCallTransport (cognitive 18): Handler.apiCallTransport has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 3, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"872e3c12cd308d858b01e47ba030b1a00514d5b8c5503141c12d7bf01ca39758"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.patchStringList (cognitive 18): Handler.patchStringList has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ea177021074ba3f6236465d398d1133c078318ff95554cb5a4a3044fc193831"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.installPluginFromStore (cognitive 18): Handler.installPluginFromStore has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, match/switch 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb2136a436f416caf6dbf0717d3315f0304fc12b98dedb9d8296cc3fa1a549cd"}},{"ruleId":"D2","level":"warning","message":{"text":"middleware.decodeCapturedRequestBodyForLogWithLimit (cognitive 18): middleware.decodeCapturedRequestBodyForLogWithLimit has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, boolean chains 3, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/middleware/request_logging.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"81e7422547919d62d77c9f97fffe457a9ef8cc4e7afe36a0250c8875671e96ed"}},{"ruleId":"D2","level":"warning","message":{"text":"cache.GetKimiThinkingReplayWithSnapshotRequired (cognitive 18): cache.GetKimiThinkingReplayWithSnapshotRequired has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/kimi_thinking_replay_cache.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"2052ae019cfeed4465dbe261d9e6ea869619e4167c434fd0d8457bd48c0f7511"}},{"ruleId":"D2","level":"warning","message":{"text":"live.multipartCallRequest (cognitive 18): live.multipartCallRequest has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/live.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"e49d76ee9e547fbbba5368464ba1b29dcfb4f26e58eff2786a8a3cfea95a3fe5"}},{"ruleId":"D2","level":"warning","message":{"text":"config.pruneKnownDefaultsInNewNode (cognitive 18): config.pruneKnownDefaultsInNewNode has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, loops 4, boolean chains 3, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"6aad12a15eed6fb07be2045a1336e3850017a7c8129846f144314cdb757da59e"}},{"ruleId":"D2","level":"warning","message":{"text":"config.ParseConfigBytes (cognitive 18): config.ParseConfigBytes has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/parse.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b282fcb269f8db398f534ff3ef192b2c382dc03a335b912e2da5e7e2c6ebc9a"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexLiveMediaRelayConfig.UnmarshalYAML (cognitive 18): CodexLiveMediaRelayConfig.UnmarshalYAML has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, match/switch 3, loops 2, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/codex_live.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9ed56f0541f60b3c2e93e50405b27d5cb1554bb904656e92431fd6e17249180"}},{"ruleId":"D2","level":"warning","message":{"text":"CredentialConcurrencyConfig.WithDefaults (cognitive 18): CredentialConcurrencyConfig.WithDefaults has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 9. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/credential_concurrency.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"66eab94c57df8849fa558081a2ef0ec7def45f69bd94a4b074a887aab78312a1"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.SyncPlatformWithReport (cognitive 18): homeplugins.SyncPlatformWithReport has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"145b54115f87063e6b7c8698c190e3c473a7fb1b4acbdccf4100ba932d883547"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RouteModelExcept (cognitive 18): Host.RouteModelExcept has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, boolean chains 2, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/model_router.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"c311741bea3870fc19b1115e64a1d3466a523a28180d4b2acb36a45c4e7359af"}},{"ruleId":"D2","level":"warning","message":{"text":"hostHTTPClient.DoStream (cognitive 18): hostHTTPClient.DoStream has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, match/switch 7, loops 1 (nesting depth added 9). Most of this is not in the body itself: 2 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 70). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/http_bridge.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a87288638fb8efe3e81e65ae0623dab7f1ee8e625537ed42c1820a9013e640b"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.fetchCodexClientModelsFromRemote (cognitive 18): registry.fetchCodexClientModelsFromRemote has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/codex_client_models_updater.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"679276e5fd5e86ba2761050d7088d7ec236662c58e799faa425139bd961bba74"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.insertAntigravityReasoningReplayItemsWithSchemas (cognitive 18): executor.insertAntigravityReasoningReplayItemsWithSchemas has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1243}}}],"partialFingerprints":{"codehealthFindingId/v1":"574f1f7ba23218c7dc093cdf826f8925ad423788aaef2eb4659662b7a8a6d8a1"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.restoreAntigravityNativeFunctionCallReplay (cognitive 18): executor.restoreAntigravityNativeFunctionCallReplay has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11, boolean chains 6, loops 1 (nesting depth added 2). Of this number, 15 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1337}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb083737df7429b8f030443c85c49400978dc23eef52ad74aa2d70737344fc6"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.reverseRemapOAuthToolNamesFromStreamLine (cognitive 18): executor.reverseRemapOAuthToolNamesFromStreamLine has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1449}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b5ca4fed0672e20a1ab5b93b72632825512ff2a81b9fab6c7cb22ab37f6a250"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.stripClaudeToolPrefixFromResponse (cognitive 18): executor.stripClaudeToolPrefixFromResponse has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, match/switch 1 (nesting depth added 8). Most of this is not in the body itself: 3 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 1591). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1583}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2612bc0efb806a7f4e8f089589d5585f77b174d16896f5b1fd7085cbfb1679f"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.patchCodexCompletedOutput (cognitive 18): executor.patchCodexCompletedOutput has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8, loops 6, boolean chains 4 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3ee1afcc058794bdd38eaf7f2bf5ebff18106f2f035573f47e59242ccf142b8"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.rewriteXAIWebsocketDownstreamIDValue (cognitive 18): executor.rewriteXAIWebsocketDownstreamIDValue has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, loops 4, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"86f42f0d352b6ee92ad3a38305eaef40797837d227d071746f8f01946ec7a26c"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.readXAIWebsocketMessage (cognitive 18): executor.readXAIWebsocketMessage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1179}}}],"partialFingerprints":{"codehealthFindingId/v1":"d77a72610c62625fc410a5ca01ab9e44f04703e850114b91da5b4e30a60205b0"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.ApplyClaudeCredentialMetadata (cognitive 18): helps.ApplyClaudeCredentialMetadata has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_credential_identity.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"9260544df922d2cc2ea276ff754503670e3c19a9cfb423f6058081f5e0038b90"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.resolveClaudeDeviceProfileLocal (cognitive 18): helps.resolveClaudeDeviceProfileLocal has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, boolean chains 5 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_device_profile.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"768ba7da5f213bcb4d5ccb2284004503fa99c707d5016221172914a10476f399"}},{"ruleId":"D2","level":"warning","message":{"text":"signature.InspectGrokEncryptedContent (cognitive 18): signature.InspectGrokEncryptedContent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 18 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/grok_validation.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"5956bafa0d654e42ce294b91705d8874556540c813ea2d046368c7a63b6ac775"}},{"ruleId":"D2","level":"warning","message":{"text":"PostgresStore.List (cognitive 18): PostgresStore.List has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgresstore.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"945471b274122bd204f11c13f730ae60ef8cc3539b64cf3e778be448bcdc7c19"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.removeEmptyGeminiFunctionTools (cognitive 18): gemini.removeEmptyGeminiFunctionTools has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 4, boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a24acf4ad5a9e80f0d1e9e72d2c364be0179a11d3e6c786d7f683cde4e07b9e"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.copyInteractionsToolsToAntigravity (cognitive 18): interactions.copyInteractionsToolsToAntigravity has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 4 (nesting depth added 4). Most of this is not in the body itself: 6 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 527). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bc4105a28eb63f69f9a662ce0c00d8917783cc4cf41c0aac2616f4ca40e827d"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.ConvertAntigravityResponseToInteractions (cognitive 18): interactions.ConvertAntigravityResponseToInteractions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"25c5cef02e910305e8c70f19f629f38485366e2326c259bf3e1511a52ccf79d1"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.applyResponsesToolResultContent (cognitive 18): responses.applyResponsesToolResultContent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 2 (nesting depth added 9). Of this number, 10 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf46248305f72864c0426155f24f43503c49dbf09578acfadb1b62758211c30"}},{"ruleId":"D2","level":"warning","message":{"text":"authTabModel.handleNormalInput (cognitive 18): authTabModel.handleNormalInput has cognitive complexity 18 (threshold 15). Drivers by points: if/else 17, match/switch 1 (nesting depth added 9). Of this number, 12 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/auth_tab.go"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"041093c96348e48ad6a8436100753d0b722713f49ab089ad3e0ffcac96084626"}},{"ruleId":"D2","level":"warning","message":{"text":"ConfigSynthesizer.synthesizeCodexStyleKeys (cognitive 18): ConfigSynthesizer.synthesizeCodexStyleKeys has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a8044c029285aaaad7756eddcd4094e2495c3b123c227497b21616dac447de0"}},{"ruleId":"D2","level":"warning","message":{"text":"Watcher.dispatchRuntimeAuthUpdate (cognitive 18): Watcher.dispatchRuntimeAuthUpdate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/dispatcher.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"098b264d887adb2abb257bb5fa8f502551ea8acc35bbbd5ab7de5a4e008d2a9e"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.extractXAIImagesResponse (cognitive 18): openai.extractXAIImagesResponse has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1045}}}],"partialFingerprints":{"codehealthFindingId/v1":"acf9b93396c858e5596eec9c1bd88bcc0814431fc04b0e8f69ca0c17c5e0c70a"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.Remove (cognitive 18): Manager.Remove has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_lifecycle.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"89847c616d3f51c2b7e18df2d14127169405c617263086942bd3b35df7e0d6fb"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.retryAllowed (cognitive 18): Manager.retryAllowed has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb1d45f7259ffae87c30c6ac519838523e9f1b66d85e565f53be58d033db48a0"}},{"ruleId":"D2","level":"warning","message":{"text":"homeSessionAliasCache.canonical (cognitive 18): homeSessionAliasCache.canonical has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_session_alias.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"a60dc8f8f9a418173a7c8f9554865ecd298c2d03a1fcf565420a72bf8b498ad9"}},{"ruleId":"D2","level":"warning","message":{"text":"modelScheduler.rebuildIndexesLocked (cognitive 18): modelScheduler.rebuildIndexesLocked has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10, boolean chains 3, loops 3, match/switch 2 (nesting depth added 4). Of this number, 13 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":929}}}],"partialFingerprints":{"codehealthFindingId/v1":"03d0733937209184b6353c34f7fbe0f8bb17a2b7a3e9824b7f0ccfd9fa3854e0"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionCache.Invalidate (cognitive 18): SessionCache.Invalidate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 5, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/session_cache.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"63c3dd6a34856fd71ba0b623c64cf837cdce5e622aca668ed6a2b23d9f3bd6a5"}},{"ruleId":"D2","level":"warning","message":{"text":"management.proxyURLFromAPIKeyConfig (cognitive 17): management.proxyURLFromAPIKeyConfig has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 2, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"d650ae2430b2c4509e2c2431b43acf33253ca75f64b7ec55812c96d12ff45086"}},{"ruleId":"D2","level":"warning","message":{"text":"DeviceFlowClient.PollForToken (cognitive 17): DeviceFlowClient.PollForToken has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/kimi/kimi.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"9de0e50d350adb75a3a1c8fd4a419bfe7ba3b80b80c4a71e7e83bc7d87527e24"}},{"ruleId":"D2","level":"warning","message":{"text":"dataChannelPipe.run (cognitive 17): dataChannelPipe.run has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, match/switch 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"93b00a20738ef065f0264bfef7e817db9c712b1cc3bbc0179c792ab6c142fa35"}},{"ruleId":"D2","level":"warning","message":{"text":"sessionStore.put (cognitive 17): sessionStore.put has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/sideband.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc4cb0f79a9a940c98df16774ddd014b5649d99d730641f31731c502b446bf70"}},{"ruleId":"D2","level":"warning","message":{"text":"models.applyCodexClientModelMetadata (cognitive 17): models.applyCodexClientModelMetadata has cognitive complexity 17 (threshold 15). Drivers by points: if/else 17 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/models/models.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"47c733af76433e1e141ef6483948207cca2113e64dd4bc13b4c5ad14551e274f"}},{"ruleId":"D2","level":"warning","message":{"text":"home.ensureHomeCertificateFiles (cognitive 17): home.ensureHomeCertificateFiles has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/certificate.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf936779332f4e310e1a39f3a29e08643b1e6f375f48a7a4713d8453f235a3d4"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.rPopAuth (cognitive 17): Client.rPopAuth has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 1). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"399a1c46728a7846d1415bc1bbd318867cc4083d64ce7857a58d2e05a771ef8e"}},{"ruleId":"D2","level":"warning","message":{"text":"logging.writeAPIErrorResponses (cognitive 17): logging.writeAPIErrorResponses has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"c404e45c2a93cb9268f3d0878c50dc1164fe450b38d6beb5a1efc10fd6088bb1"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.validateCodexClientModel (cognitive 17): registry.validateCodexClientModel has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/codex_client_models.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc67e56792b6c8d989d17647fb1d4a0a744b45be67ff32f577b915d9b2d031d9"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelRegistry.removeModelRegistration (cognitive 17): ModelRegistry.removeModelRegistration has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":533}}}],"partialFingerprints":{"codehealthFindingId/v1":"b005100db6569de630ae2b0a1441c73c932da14e93c13d98060b0980da1466a5"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.injectMessagesCacheControl (cognitive 17): executor.injectMessagesCacheControl has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 5). Of this number, 13 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1190}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaf1a7ff50cea3c90ba4c314519b06800da2898abd40f89e3bf347d96b8d36d7"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.claudeCodeCLIBetas (cognitive 17): executor.claudeCodeCLIBetas has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 3, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"41d7aceca35e2db3b1e3c77256b807a7721135b05693a3f17a34fb4eff790edb"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.reverseRemapOAuthToolNames (cognitive 17): executor.reverseRemapOAuthToolNames has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 2, match/switch 1 (nesting depth added 7). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 1411). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1403}}}],"partialFingerprints":{"codehealthFindingId/v1":"493e18fa3b5c8f39779cbf2e70fd03b57bfc5fcd55cb6f2dbd14ce19ea3aa98a"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.cacheCodexReasoningReplayFromCompleted (cognitive 17): executor.cacheCodexReasoningReplayFromCompleted has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, loops 4, match/switch 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":760}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b8ec4fcd117fbc08de4287ac1328697ca6ae8eaa838a7230bbc59e4d4a501da"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.readCodexWebsocketMessage (cognitive 17): executor.readCodexWebsocketMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, match/switch 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_connection.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fc22f88bb8ec0f2067b5cd071425ce6cc529809d0840fab3444e17257e404b1"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAITools (cognitive 17): executor.normalizeXAITools has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 2 (nesting depth added 5). Of this number, 12 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":707}}}],"partialFingerprints":{"codehealthFindingId/v1":"866bacce08c489786556b34022ec2896796e5db45180d4483c4f83820ecf7520"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAIToolChoiceForTools (cognitive 17): executor.normalizeXAIToolChoiceForTools has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, boolean chains 3, loops 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":849}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f9b8da8560e286502881f38b515af51525d3bfff499b5661395af74c37d0ca7"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.normalizeXAIInputReasoningItems (cognitive 17): executor.normalizeXAIInputReasoningItems has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"f396ed14e5e6465d8f94111ddcddbc3880281ee77d31bdd9de62fed6c1cad68c"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiExecutor.Execute (cognitive 17): GeminiExecutor.Execute has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 1). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"00f315dd57b3b3fa9da2c5eed421ffac6350ae304c348fb9e83a88ab7eeef7de"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiVertexExecutor.executeWithAPIKey (cognitive 17): GeminiVertexExecutor.executeWithAPIKey has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 1). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1df3ae090d7ceb73634b46396df84ae6bd77a3a2a0bd23dc69c8727121126f1"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.removeToolChoiceFromPayload (cognitive 17): helps.removeToolChoiceFromPayload has cognitive complexity 17 (threshold 15). Drivers by points: if/else 17 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":772}}}],"partialFingerprints":{"codehealthFindingId/v1":"918045070c41f285a36434371f2c1040cea15d13f7a89d7c55e793cc0bed72c1"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.newClaudeCodeRoundTripper (cognitive 17): helps.newClaudeCodeRoundTripper has cognitive complexity 17 (threshold 15). Drivers by points: if/else 16, boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 5 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 301). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/utls_client.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7e40a5143372b0e9d5372aca147be7f610fd54c064e408774abfc7447e4964d"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIExecutor.executeVideos (cognitive 17): XAIExecutor.executeVideos has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 2, match/switch 1 (nesting depth added 3). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_media.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d750c9d6c5b92a5defd575b093aaffce0a2f00f233a254a4441be9fea6de7e1"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.clampLevel (cognitive 17): thinking.clampLevel has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/validate.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"379204f55024b1641d6fee4c60252ba4a1f27c0d18639c9d3e7fd8585d2c91eb"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.RequireCachedThinkingSignatures (cognitive 17): claude.RequireCachedThinkingSignatures has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"2171f37d733c087fc2c472c8745ef3bc58d27069f659829c9f082ba909940a6f"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.copyInteractionsToolChoiceToAntigravity (cognitive 17): interactions.copyInteractionsToolChoiceToAntigravity has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, match/switch 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"63589edd0e854202f405118d3647c785d59b51867d3951ec9b3ea86f8d899737"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.restoreInteractionsFunctionNames (cognitive 17): interactions.restoreInteractionsFunctionNames has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, loops 6, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5593a29bb586c2c28bf73c84d6d145b15f1699323ae2adc53005f0cbf81ed54"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.antigravityPartToInteractionsStep (cognitive 17): interactions.antigravityPartToInteractionsStep has cognitive complexity 17 (threshold 15). Drivers by points: if/else 17 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"46093f0207382494d59c8112af1d969bc272362090b7c3c063cb5402e1bbe0ae"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.convertSystemRoleToDeveloperWithInput (cognitive 17): responses.convertSystemRoleToDeveloperWithInput has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/responses/codex_openai-responses_request.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9da305fe1b8d1a1a3fa074385345557bda77009d39e2e335e46edbc5f5f21b6"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.copyGeminiToolsToInteractions (cognitive 17): interactions.copyGeminiToolsToInteractions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 17 (nesting depth added 4). Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 194). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"62655ba7ea1c6c1e551e3a5e08ba6b296c11ff5a02b00b47d93c47f56ddb7da6"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.copyInteractionsToolChoice (cognitive 17): interactions.copyInteractionsToolChoice has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, match/switch 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea55a759cb0c13e6a050912e14cb080f840a7ed247e752bcc5ce45b347a67b36"}},{"ruleId":"D2","level":"warning","message":{"text":"responses.responsesInputItemToInteractions (cognitive 17): responses.responsesInputItemToInteractions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/responses/interactions_openai_responses_request.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a4918540e879935fc2d050bc14bb5ce8df67e5bb7ae3bc10dd751398150e95"}},{"ruleId":"D2","level":"warning","message":{"text":"Client.GetLogs (cognitive 17): Client.GetLogs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, match/switch 2, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/client.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca889f4f740513be0b700c8467737bccafca73598d20c60c206e42be216bd44c"}},{"ruleId":"D2","level":"warning","message":{"text":"diff.openAICompatSignature (cognitive 17): diff.openAICompatSignature has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/openai_compat.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1df3e76fd589455615128dab87d8aea12972df16b4836c9a4834d15523da01"}},{"ruleId":"D2","level":"warning","message":{"text":"synthesizer.ApplyAuthExcludedModelsMeta (cognitive 17): synthesizer.ApplyAuthExcludedModelsMeta has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 2, boolean chains 1 (nesting depth added 4). Of this number, 11 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/helpers.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d8f8dea96a9392ed9b86eb36ecd3590fdc9d543ed0a41ab53fa892e24e7b3e1"}},{"ruleId":"D2","level":"warning","message":{"text":"GeminiAPIHandler.GeminiModels (cognitive 17): GeminiAPIHandler.GeminiModels has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"30d30d2be3081b872b78a73a8d8639dc62acebeeb755bdc6a29ec3089f239330"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.collectXAIImagesFromJSON (cognitive 17): openai.collectXAIImagesFromJSON has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, loops 2 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"587e091323cf3828d5996f2a4031e92116fb68632af08e2b1e65a48e0427bf29"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenAIResponsesAPIHandler.responsesWebsocketUsesUpstreamWebsocketPassthrough (cognitive 17): OpenAIResponsesAPIHandler.responsesWebsocketUsesUpstreamWebsocketPassthrough has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_session.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dd8f2023d715f398dcc12da46f2c0a22a66e0db24c328919fd2e09305c23b43"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.isExplicitModelNotFoundMessage (cognitive 17): auth.isExplicitModelNotFoundMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10, boolean chains 5, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1456}}}],"partialFingerprints":{"codehealthFindingId/v1":"9233fca999d2db469e541961ca72205be0d8860724e65e2366fd788737aa13aa"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.Update (cognitive 17): Manager.Update has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, boolean chains 6 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_lifecycle.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"93064972d0e8a3c8328d59943399675f977ffd5455fb04bd33149d1507a32688"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.executionModelCandidatesWithAlias (cognitive 17): Manager.executionModelCandidatesWithAlias has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"f939fefdd1621d8278dc9b04a30fccd4980b7f54a8dfdcd192b3cf8d4ec91121"}},{"ruleId":"D2","level":"warning","message":{"text":"main.looksLikeClaudeCodeWebSearchAssistant (cognitive 16): main.looksLikeClaudeCodeWebSearchAssistant has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/detect.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"670fe2a8b9559b08c9767b6a375d2be2103359e877659d0e2130b1649476f8eb"}},{"ruleId":"D2","level":"warning","message":{"text":"management.tailLogFiles (cognitive 16): management.tailLogFiles has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bcf4a2f61fcf9fb2236eb9048e61a4c66213fd634f3451f16ef25aa0428e9b3"}},{"ruleId":"D2","level":"warning","message":{"text":"management.tailStartOffset (cognitive 16): management.tailStartOffset has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 3, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":616}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec8fad4541509d317da3caaa0058ebcebfe50ebf0beadb581ee8ad9120561274"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.GetAuthFileModels (cognitive 16): Handler.GetAuthFileModels has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"53458a000ba74173c976cd5073ae3a30b14aaafa8cecf19036b550c42343fb87"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.RequestXAIToken (cognitive 16): Handler.RequestXAIToken has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 1). Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 533). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbdc8b99729561853811a3df4f2dc550e13b5c576afb1e102c388c42711f3c85"}},{"ruleId":"D2","level":"warning","message":{"text":"credentialweight.ParseValue (cognitive 16): credentialweight.ParseValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, match/switch 1 (nesting depth added 7). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/credentialweight/weight.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"9896bfd2aea9b3cc570abb91bbfa961160c04828ac2cb8f6d2ec16cfaff34eda"}},{"ruleId":"D2","level":"warning","message":{"text":"homeplugins.pluginFileFromPath (cognitive 16): homeplugins.pluginFileFromPath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"95746effe8c62b07b8c17be0cd2c6d3e3ee04f2d76039579566ef5a2a3d0c344"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.pluginFileFromPath (cognitive 16): pluginhost.pluginFileFromPath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/platform.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b8323d5f9bc8d402db96677bf68b364b9301c0abc7f59636316898132319ec8"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginhost.cleanupUnselectedPluginFiles (cognitive 16): pluginhost.cleanupUnselectedPluginFiles has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/platform.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"a50646eaf554aa32fb97f3fc20cecb5d32ecc39c1a2a0066ef856cdba29d32d0"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.RegisterFrontendAuthProviders (cognitive 16): Host.RegisterFrontendAuthProviders has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_auth.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b24b204a56c9fc954a2388eaf773f03df89d4687c12726f9c0c0469fbf5cfcf"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.callParseAuths (cognitive 16): Host.callParseAuths has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_provider.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"482a8c2a4505d8722b4158eac96c0149cee7f7338d78cab7a117af97dcf89914"}},{"ruleId":"D2","level":"warning","message":{"text":"Host.ShutdownAllContext (cognitive 16): Host.ShutdownAllContext has cognitive complexity 16 (threshold 15). Drivers by points: loops 7, if/else 6, boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":582}}}],"partialFingerprints":{"codehealthFindingId/v1":"27035f8fbdfe579f171e368fe246d65186e4b742a0585184d0eaa006ad26ac26"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.pluginFileInfoFromPath (cognitive 16): pluginstore.pluginFileInfoFromPath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/install.go"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"cda364a5f549fa7b1279403a6c0f7609fa32e981f700be4805d9d3d6245fcfc6"}},{"ruleId":"D2","level":"warning","message":{"text":"pluginstore.ValidatePlugin (cognitive 16): pluginstore.ValidatePlugin has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 1, loops 1, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/registry.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0a68d00654fa720ea662ec965409d7748302faba13eae435b01b989c8b1b5f1"}},{"ruleId":"D2","level":"warning","message":{"text":"PluginSyncResponse.Validate (cognitive 16): PluginSyncResponse.Validate has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/home_sync.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b56bfe6c3bf332e590d25d5f2439a24d79ae528f61735af5e450b7fdb2e1736"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.upsertModelInfos (cognitive 16): registry.upsertModelInfos has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_definitions.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e9c638a04f0e43a08c91ff8aa40a198d7654325adbe3490a573c81f1f137bdc"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.antigravityAuthHasCreditsRequired (cognitive 16): executor.antigravityAuthHasCreditsRequired has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bf1bf94cf036e8c8b90c39145c555b3aa0231b9d3fc3b7bd550b1fa6165e379"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.codexReasoningReplaySessionKey (cognitive 16): executor.codexReasoningReplaySessionKey has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb221d686c35bbcf79045a73b3adc24b925a399a8bb78baccd92e74b1a23ff47"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.splitCodexReasoningReplayTurns (cognitive 16): executor.splitCodexReasoningReplayTurns has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 5 (nesting depth added 10). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0b9bc1296aba4b71dad79f6a65a991d4401fcb169cf811727e5ee74b26ebc0a"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.setCodexSessionHeaderCasePreserved (cognitive 16): executor.setCodexSessionHeaderCasePreserved has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, boolean chains 3, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_request.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"382775908b5229fb6c30021ee580f76effd72152e92f0b5a9fe2ba69b5b49803"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.collectXAIAvailableToolChoiceKeys (cognitive 16): executor.collectXAIAvailableToolChoiceKeys has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, loops 3, boolean chains 1 (nesting depth added 7). Most of this is not in the body itself: 6 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 660). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e0d5f6e5ef9d50fc162f6dd54c9e831cb347a0c341aeaa05429612a64fd2b17"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.promoteXAIAdditionalTools (cognitive 16): executor.promoteXAIAdditionalTools has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 5 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":751}}}],"partialFingerprints":{"codehealthFindingId/v1":"055bf0ac238f49908e9ec8cc4e71345561335adc7b37d87ec03659b1c6ddf7ef"}},{"ruleId":"D2","level":"warning","message":{"text":"executor.xaiNormalizeReasoningSummaryData (cognitive 16): executor.xaiNormalizeReasoningSummaryData has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c758bbab8fc4489e2e79821e4f19d249a9a54c3c8f8ce720fdaab047fb5453e"}},{"ruleId":"D2","level":"warning","message":{"text":"CodexWebsocketsExecutor.ensureUpstreamConn (cognitive 16): CodexWebsocketsExecutor.ensureUpstreamConn has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aae5a39914d19197d5e8284a0e2529ab5f4605d701d0105f21e9e1e36fbcb05"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.resolveClaudeDeviceProfileHome (cognitive 16): helps.resolveClaudeDeviceProfileHome has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/claude_device_profile.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2e0273f2b3982ee1f305929c49e763a20e5b4e5bb8b5c40ce4dee22f33f8e94"}},{"ruleId":"D2","level":"warning","message":{"text":"helps.ObfuscateSensitiveWordsInSystemInstruction (cognitive 16): helps.ObfuscateSensitiveWordsInSystemInstruction has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 1, loops 1 (nesting depth added 7). Of this number, 12 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/cloak_obfuscate.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"edbc5f949c2b26b4fabd41a8a59959c0bda9d42928125e7b0b5150f5dc907e06"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIExecutor.Refresh (cognitive 16): XAIExecutor.Refresh has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_auth.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"4be05266e8f9ef899d803192340dc00f18dcfacbf8a29d85bf19cb7918512f6d"}},{"ruleId":"D2","level":"warning","message":{"text":"XAIWebsocketsExecutor.ensureUpstreamConn (cognitive 16): XAIWebsocketsExecutor.ensureUpstreamConn has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1089}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d04c322154bcfda275084cf1101f0280223c99f4436d647645eb36b7497db44"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.PersistAuthFiles (cognitive 16): GitTokenStore.PersistAuthFiles has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"6434ef7c678dbe0408bb70361d8e78259afa2870802046c18cb14d0507952038"}},{"ruleId":"D2","level":"warning","message":{"text":"GitTokenStore.guardWatcherAuthRemovalLocked (cognitive 16): GitTokenStore.guardWatcherAuthRemovalLocked has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":579}}}],"partialFingerprints":{"codehealthFindingId/v1":"efe0fa93cde529b8e55ada2b6e4bf07b85e996289da7e364d853b496be816418"}},{"ruleId":"D2","level":"warning","message":{"text":"thinking.extractClaudeConfig (cognitive 16): thinking.extractClaudeConfig has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, match/switch 5, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7fd4193e2a195eb34a55b5a3a3ed761d391723c1cf85fab111ec99e03af6b81"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.applyCompatibleClaude (cognitive 16): claude.applyCompatibleClaude has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, boolean chains 5, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6719f77eaadce5cce22bc25741dec03f90c70fe6c2ba904ea6700f05bdfa4e"}},{"ruleId":"D2","level":"warning","message":{"text":"Applier.Apply (cognitive 16): Applier.Apply has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, boolean chains 5 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/codex/apply.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"95180eea2eeef213b4ad4691e02c1379b4835bf2508ee8c89252326474a0b50f"}},{"ruleId":"D2","level":"warning","message":{"text":"Applier.Apply (cognitive 16): Applier.Apply has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, boolean chains 5 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/openai/apply.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"491399072d892af619f44298ddce90b0bf8a6cb2cb42647712665ea952c081fb"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.restoreGeminiFunctionNames (cognitive 16): gemini.restoreGeminiFunctionNames has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, loops 6, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_response.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"09ed5c02a3d6824214b04a453d7c036748103b363979b90f49fbb91e55ccf7bd"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.restoreAntigravityOpenAIFunctionNames (cognitive 16): chat_completions.restoreAntigravityOpenAIFunctionNames has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, loops 6, boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e138d575462f940fe4c40d507f95fbc3aa98eb5024a91fc9fdcc677dd40a5bf"}},{"ruleId":"D2","level":"warning","message":{"text":"interactions.convertClaudeSSEToInteractionsNonStream (cognitive 16): interactions.convertClaudeSSEToInteractionsNonStream has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, match/switch 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/interactions/interactions_claude_response.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"50c086c679eb320b93872533821faf4a060c12196323aae5fc346043c920ab20"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.buildShortNameMap (cognitive 16): claude.buildShortNameMap has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 6). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 539, 522). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c37314294cd0d0ed8ea08c7747cfd2d8a6eeff0292422c14ff08bf2ff368e57"}},{"ruleId":"D2","level":"warning","message":{"text":"gemini.buildShortNameMap (cognitive 16): gemini.buildShortNameMap has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 6). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 559, 542). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f30994b408c977350df7116c667444d64ff3ebecee9ae9bd491e3ee0f5e2cfe"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.buildShortNameMap (cognitive 16): chat_completions.buildShortNameMap has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 6). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 681, 664). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":659}}}],"partialFingerprints":{"codehealthFindingId/v1":"70c2712d34a467f7c89b878072294ce2eb9467af03f0a705548c8cc05aec093e"}},{"ruleId":"D2","level":"warning","message":{"text":"claude.convertOpenAIDoneToAnthropic (cognitive 16): claude.convertOpenAIDoneToAnthropic has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"b13812e09263f95d83d6ac7fe47f1c6211ec2e90c35e66f7ab4ee0c5d0929f99"}},{"ruleId":"D2","level":"warning","message":{"text":"chat_completions.appendOpenAIMessageToInteractions (cognitive 16): chat_completions.appendOpenAIMessageToInteractions has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 3, boolean chains 1, match/switch 1 (nesting depth added 8). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/openai_interactions_request.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4697f607ba6a82f2f536e14e131b1e20d8eaa7b3ea0eb7c7aa0e499058e5298"}},{"ruleId":"D2","level":"warning","message":{"text":"handlers.FilterUpstreamHeaders (cognitive 16): handlers.FilterUpstreamHeaders has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/header_filter.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"19e65b2d6bd5500cbc539b5fd45eb6f32ab630462ca2bd76814df0bc3bbc9614"}},{"ruleId":"D2","level":"warning","message":{"text":"openai.extractImagesFromResponsesCompleted (cognitive 16): openai.extractImagesFromResponsesCompleted has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1640}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0db87659ceb1c4c4b9d60bfe60b4add5dfb276efab4e388008798337a180f28"}},{"ruleId":"D2","level":"warning","message":{"text":"KimiAuthenticator.Login (cognitive 16): KimiAuthenticator.Login has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/kimi.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c0798f578786c33891b6b8bf44ad39625c2648e7a80e46e580226bbe6ada2bb"}},{"ruleId":"D2","level":"warning","message":{"text":"cliproxy.applyExcludedModels (cognitive 16): cliproxy.applyExcludedModels has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, loops 4, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"f98f6828978d90e4799b0818f45653c362cfe3e90c6e387c52e6d6ab1088e866"}},{"ruleId":"D2","level":"warning","message":{"text":"cliproxy.buildCodexConfigModels (cognitive 16): cliproxy.buildCodexConfigModels has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"471a51f0f127158315c6679a4baae524bae3343b110ad0920cce2f81b23e7d9c"}},{"ruleId":"D2","level":"warning","message":{"text":"auth.getAvailableAuths (cognitive 16): auth.getAvailableAuths has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"36c89472798597c9ec0eedfb6ebf86e063ddd4eedb26ed8b8a417b884d9c7562"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.drainDetachedHomeLifetime (cognitive 16): Service.drainDetachedHomeLifetime has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"33efd95ef32d766054c2f8ad5760419baedf0f6ba213e75db6a80eef3916a7a9"}},{"ruleId":"D2","level":"warning","message":{"text":"session.interactionsRoot (cognitive 16): session.interactionsRoot has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11, boolean chains 4, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b82c3aef80c04b239df96f2ec37f7ebafad9fa672800794d641e8008871c307"}},{"ruleId":"D2","level":"warning","message":{"text":"session.flattenInteractionEntries (cognitive 16): session.flattenInteractionEntries has cognitive complexity 16 (threshold 15). Drivers by points: loops 8, if/else 6, boolean chains 1, match/switch 1 (nesting depth added 8). Most of this is not in the body itself: 0 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 319). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"2129d7cbda42a2356141b2a7e844fb7549951dfb1221c314063063bc01f17c39"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Handler: TooManyMethods \u2014 179 methods, declared across 19 files: management/config_lists.go (43), management/config_basic.go (29), management/handler.go (21), management/auth_files_crud.go (12), \u002B15 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/handler.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e825ee2a398b9ddd5298004b2e64d71fe3a097131af502e8407b8399dde2c92"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Host: TooManyMethods \u2014 170 methods, declared across 18 files: pluginhost/host.go (28), pluginhost/adapters_interceptors.go (17), pluginhost/auth_callbacks.go (16), pluginhost/auth_provider.go (16), \u002B14 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"acf2e1953efc4d1f5dd6d37d4821d7b535b052e7dc871f117e6177630efef34d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Manager: TooManyMethods \u2014 166 methods, declared across 15 files: auth/conductor_selection.go (40), auth/conductor_home.go (32), auth/conductor_models.go (21), auth/conductor_cooldown.go (20), \u002B11 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"d404287974f4b759691980cf5407d5720fd4e78d4094e29174c99d2ea9354a7d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 102 methods, declared across 11 files: cliproxy/service_auth.go (17), cliproxy/service_home.go (16), cliproxy/service_models.go (14), cliproxy/service_executors.go (13), \u002B7 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"df563182348f554b6d89a1296052f24be99cb1581955e75e59ce951789c5832c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: openai/openai_images_handlers.go: FileTooLong \u2014 1349 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb2742f5e8c9ea9f528e15b0bbdf615b16909a92320ca8e884b5b00affc71e95"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/antigravity_reasoning_replay.go: FileTooLong \u2014 1346 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8da595c03e0f374c07295ea48a1bf6880a0de225b4dc29c253daa10fc355796"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: home/client.go: FileTooLong \u2014 1313 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"126ee3f818e656b2f0342469e0bae3738e23128b50a6bcb734a20af5d5846579"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: store/gitstore.go: FileTooLong \u2014 1293 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"23b0ca264513ad38b1841aec6c11e89f1c10929afda415c68366259cb2b20c56"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 74 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"cce7f7ed27225ca1bb1fcead79dcfc85ad8d52d94ee7c2461e3ebd4a0092c429"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: management/config_lists.go: FileTooLong \u2014 1225 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6ecfb25d94cf9f21ec97d53c7dd3ab9c7eb09e193ef79405af82d9d581528b9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/xai_websockets_executor.go: FileTooLong \u2014 1187 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eed27222cd96b5b52baffd4ecad06f72d918eb69cb2ad870b190e1573cc87361"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/conductor_cooldown.go: FileTooLong \u2014 1186 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_cooldown.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b123deb9bf330b22beed5c48d972daf2831be1ec5d5a6a2633f329176bbeb944"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/claude_executor_request.go: FileTooLong \u2014 1009 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f62830491977d02bb4131e4270a73629af6320bd8b168d8080df0649970b4d6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/conductor_selection.go: FileTooLong \u2014 966 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ffb008c278faf354c3e23dbc999b1bf3fd902892d081ffa78b3194c3123ca22"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: interactions/interactions_gemini_common.go: FileTooLong \u2014 944 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"731cae415fdb40295bdb6d52675fe1eddcf5189f4e42ee6405f28c4d6eda8cb1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/conductor_execution.go: FileTooLong \u2014 901 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2c3b146be16e0ecc147d7bd018c6a42b142af9c1d20026749320a2362aab370"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: management/logs.go: FileTooLong \u2014 894 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e703353b07d2ed30007dc6f51984eae5b8c497f35c453c51cef76483af10894e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/gemini_openai-responses_response.go: FileTooLong \u2014 879 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"34774e236f2dc122a874e612f97672ce57609dbbd459fee2789e50a19219a3a9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: OpenAIAPIHandler: TooManyMethods \u2014 50 methods, declared across 4 files: openai/openai_images_handlers.go (20), openai/openai_videos_handlers.go (19), openai/openai_handlers.go (10), openai/codex_client_models.go (1). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4ce535b48a3085e7ac13c7869d61a3e4328c48ab1e934d49a55d7d25b2fc626"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: registry/model_registry.go: FileTooLong \u2014 830 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"180534a3b0de169dba5dcea1012fce032f102304c0b603cd5140a424894185a0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/conductor_home.go: FileTooLong \u2014 828 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7bda112ee6fdb2ba89561254ddc88bce59bac7b12301cb2bd649ccb97b10582"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/claude_executor_cloaking.go: FileTooLong \u2014 823 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d1e8b4dec0493fb2cacb9a2617650d4af685a0ea2723173f3155414f8a1a9df"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/codex_openai_images.go: FileTooLong \u2014 786 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3c99ce2ca6a49ec6f9df14203b6545b240cbe097fb2449da4d1ffa125bf05aa"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: helps/usage_helpers.go: FileTooLong \u2014 786 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"56632e0ef07aa27dac9474d7c2ddbf9a7253230b773179255727fb41cbc028fe"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/interactions_openai_responses_response.go: FileTooLong \u2014 778 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/responses/interactions_openai_responses_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"485d9019ee68753cd613f5587764ce856a0c75c362de79296c4a2ba6cc241d04"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/gemini_vertex_executor.go: FileTooLong \u2014 776 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"468931a1026240f9a15d0518a297878279db67a582cfcd1cbc9822d4f3563cdf"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/claude_openai-responses_response.go: FileTooLong \u2014 771 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c9359456d1ff9b0a0c5e428773c9ab083de278132763b33194421a46f99bafb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/xai_executor_request.go: FileTooLong \u2014 756 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"28a376e9c8700c468431b591d00ffd279904cb4b47457ffdc055a7206f2344d3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/scheduler.go: FileTooLong \u2014 733 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ee0ff2bf897e72bd70594ac6544985e19b23ef4e4411367a3ad4bb30230083b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/claude_openai-responses_request.go: FileTooLong \u2014 719 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"df7f9d9a48bf85d32beb550be7c3b62ef87985162df37e8b345e4028067478b3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: openai/openai_videos_handlers.go: FileTooLong \u2014 718 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_videos_handlers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"88fd024a8295a4765b56e08f29f2308cfd18701fa7243ad17ffc76b2a4d53b02"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Watcher: TooManyMethods \u2014 42 methods, declared across 5 files: watcher/clients.go (11), watcher/dispatcher.go (11), watcher/watcher.go (8), watcher/events.go (7), \u002B1 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/watcher.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"de309bae9a73e2ec2141829e8127f501231522a52f23ca669f9d62c3002af561"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BaseAPIHandler: TooManyMethods \u2014 42 methods, declared across 9 files: handlers/handlers_execution.go (11), handlers/handlers.go (6), handlers/handlers_interceptors.go (6), handlers/handlers_routing.go (6), \u002B5 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"2eba7da035400de431dae3247f0421079358acef0cf13e5efdbf9c60a5013e6f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: cliproxy/service_models.go: FileTooLong \u2014 695 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c32a41049baafccc38a9a716bdaa88ff41320f03168b94d41bdb71589630e408"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 41 methods, declared across 8 files: api/server_routes.go (14), api/server_management.go (9), api/server_keepalive.go (4), api/server_middleware.go (4), \u002B4 more file(s). That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"11d57b5b0cbcac1bf900a4d8e24557b200d7d590998b68bd4cb430c291c2f036"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: management/plugin_store.go: FileTooLong \u2014 683 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9ce4312d13bed2eaecd7048ea8c0055ca44dbd6afe92d648413097c80e49baf"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/server_routes.go: FileTooLong \u2014 677 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a2664b6299d29bf0da825d3eb4f0eec9fc993e4eb270def8c01b883d4a35e7d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/gemini_executor.go: FileTooLong \u2014 663 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec87aae7afc7b1118c6e64c5b495930687d49ab088e2e344b09c97fe4a8e4ed6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: helps/payload_helpers.go: FileTooLong \u2014 663 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/payload_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eee40144062bd1dd2218e956867ed888cfd7c43ec42d91e6802f5ede92c9226c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/openai_openai-responses_response.go: FileTooLong \u2014 659 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f94dad9485caed986f06731f33100fc9fff048408f5daae74107cf10018122e7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: claude/antigravity_claude_request.go: FileTooLong \u2014 640 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"234d8fabc9b792c780e66868ebf7e856d154a6af453761f1f11ddc763c5f3b2e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: live/media.go: FileTooLong \u2014 639 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b67c7b89a2e8f07e70ec86d9e510387fb53dce8b110e6c3d3614935a8d8a4af4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pluginhost/adapters_executors.go: FileTooLong \u2014 635 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a806099fee7f6004c73ea72d94ed93ebf387e3880e3c0197dab26c907f2591d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pluginhost/host.go: FileTooLong \u2014 634 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0fd08b99db97104f8b1156b7a9e4e0814c0f75cf887097293c13ee41abb855b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/selector.go: FileTooLong \u2014 634 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/selector.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4b2fbf9033bde0087049e461722d2bea82ebf664f1a8b413c4977e60f61e3ad"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: management/auth_files_provider_oauth.go: FileTooLong \u2014 629 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fd04a482c79db812d915e797321c4a69627dcb8879cd77d18d8e2e8ed3891a9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/openai_compat_executor.go: FileTooLong \u2014 623 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b52feff0bdefccf20324296c29ed3389f2e5921a48635cad77837d4c0396a92b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: claude/codex_claude_response.go: FileTooLong \u2014 614 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5de5f0e6444dc3b5d78803dd14a1f31cc2c58e3313a982ae982e31baed1f9f4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: server/main.go: FileTooLong \u2014 608 significant lines (blank, comment-only and punctuation-only lines excluded), about 83% of them inside a single declaration: main (72-758). Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/server/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc5b3e3df865ee66ed2f4b2b28a95e6d8959b1b584c671054aea3f046fc3ee3d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pluginapi/types.go: FileTooLong \u2014 608 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/pluginapi/types.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aea1369030ed6e1ecc3fe5a0958fa8aaca555da3f8140a02d446c2efacf74f0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: responses/gemini_openai-responses_request.go: FileTooLong \u2014 605 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"24655e8c491d52189092f04bdfd0b3b4b623e7b5cc11fe0da58e48ff3c981560"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: homeplugins/sync.go: FileTooLong \u2014 603 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82f3f2741fdfef29e254454cb35d1ca6c50bbb1bf41b5b1bca0869a29d26dc88"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/conductor_models.go: FileTooLong \u2014 597 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a600ccb93d2355fa30e105ab249ea16d55c5501b250cc4fab4b63254cc83515"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: interactions/interactions_antigravity_request.go: FileTooLong \u2014 574 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62b7063dadfefff57c308c1df50ff3ae4a73d1cb80ba5768eba4a0d46685c2ea"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/xai_executor_response.go: FileTooLong \u2014 570 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3be65d9806f31b65e78ad658e1302fa474236134b97fbfb64148c549ab7ed9b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: cliproxy/service_home.go: FileTooLong \u2014 568 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_home.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d025e7ce317a7341cdea2ff400f7e0a2222c5ee20cbaf8a1a9d9f7dcb52ac840"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Client: TooManyMethods \u2014 34 methods. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/client.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"f757a1d47a7dd84f76b0fec5d666a13768c2bc5c0b00144d761541d7c2d7841b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/kimi_executor.go: FileTooLong \u2014 562 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e3c8f353c89d3108737614cf3372d5bc2afefe1c28f7cc9f36691ebeb3c67a4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/codex_executor_reasoning.go: FileTooLong \u2014 560 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b5f0fbbce4331a0d0a74c6820ca51c2dde98454cbf0c8df7ad0b76b319bfda2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/antigravity_executor_credits.go: FileTooLong \u2014 553 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2058463a84f432bb95b443f7db2294975f7639a20f582bf953648ad1b5fed5ad"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: optimize-multi-agent-v2/optimize_multi_agent_v2.go: FileTooLong \u2014 547 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a4f93b2ff42efb573d7990dcf936b9c9304a1f951306e8de4937a2aa9dc6e5a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/codex_websockets_session.go: FileTooLong \u2014 539 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"21fd09254848106e825e97976c69a05819a852ca7f67cd87bb6b090d909d5432"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: executor/antigravity_executor_execute.go: FileTooLong \u2014 535 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3282346d9ae7330b64404075278b7fb6d81c336e60ed9f468819449d919abef9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: util/gemini_schema.go: FileTooLong \u2014 534 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"479058106a5897075a51c2f7cbe913ef97b75c5075b369dcac80381b3e803882"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: interactions/interactions_codex_request.go: FileTooLong \u2014 524 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/interactions/interactions_codex_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"96e873ad3583bce2220576e1a971357a1f30548169738d9a465988a03cba940e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: config/config_yaml.go: FileTooLong \u2014 522 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aef07c3039b5e9e9ecf40728700a066a10105bac178a4143cfccc6d898bbf0f2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: helps/logging_helpers.go: FileTooLong \u2014 521 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/logging_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4c37c223b1c1525a6a1ab5ea4aef2f173e1caaaa5d6bab46d82627ce5fd6ed6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: live/live.go: FileTooLong \u2014 517 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/live/live.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa08937faa25ff53ff591106866528a19e139f8ca6734983a0dd89170cb0a2e9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: handlers/handlers_stream.go: FileTooLong \u2014 514 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_stream.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"12b0b5a37c3ec9b64de605ff5113ed851eef63760b9460e2cc262cbdb6d583e7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: management/plugins.go: FileTooLong \u2014 507 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c6f35ec34cf92d886d3c944f33e84b31b496adb94d87b17fd4d685dbe19d0df"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: claude/antigravity_claude_response.go: FileTooLong \u2014 505 significant lines (blank, comment-only and punctuation-only lines excluded). To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fff5c3b1d6ab1313054966dd29044f1130a47288ac0465c8537f63201e9736f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/auth/claude/errors.go:132-151 | internal/auth/codex/errors.go:136-155 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/errors.go:132\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/errors.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"782f61abd4ce6f466b261379ae9667bb266145208eb02608cea2e861720b82d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:383-402 | internal/translator/gemini/interactions/interactions_gemini_common.go:309-328 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0a9194484440f041a906187afde8912115af9ec87c76b3f8a34ca1b7039f980"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/auth/claude/oauth_server.go:201-219 | internal/auth/codex/oauth_server.go:198-216 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/oauth_server.go:201\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"085411213935345421eedd68c934de4cb2d2ace66060e27be599004e989c8e75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/runtime/executor/codex_executor_reasoning.go:541-559 | internal/runtime/executor/xai_reasoning_replay.go:167-185 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_reasoning.go:541\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"a243153e48419b3b5e1359a515b068d8db3f6aabc099a41a23400478daffc95e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:555-573 | internal/runtime/executor/xai_websockets_executor.go:1250-1268 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:555\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":555}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6de222eecdf29bf536c9b96b1e5d28435ceb46b1461f67bc64aaaee1080897"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:269-287 | sdk/api/handlers/openai/openai_videos_handlers.go:437-455 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:269\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"26def929d3faa1188344a6f9e7bf79844d0dc68c6741edb7e36bb0b3341eb303"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/gitstore.go:1863-1880 | sdk/auth/filestore.go:510-527 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:1863\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1863}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f52acca82fd530cece85cd179162592ae2871abbd0abe9c7e251763f62e35d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): sdk/api/handlers/claude/code_handlers.go:252-269 | sdk/api/handlers/gemini/gemini_handlers.go:205-223 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/claude/code_handlers.go:252\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"18b34c3376d1ffd70fa172fcfcfff1cd1ad09d2c8fd0f13635d59a3201f0a510"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:1193-1210 | sdk/api/handlers/openai/openai_images_handlers.go:1321-1338 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:1193\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1193}}}],"partialFingerprints":{"codehealthFindingId/v1":"a84d8444f1a0e3befa5e9eb37e536a2823d1ba04b9e7b529b53b66692be0df80"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 3): sdk/api/handlers/openai/openai_handlers.go:486-504 | sdk/api/handlers/openai/openai_handlers.go:594-610 | sdk/api/handlers/openai/openai_responses_handlers.go:535-553 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_handlers.go:486\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"68fc72fba9fb1c890dbe346918909a810f2a2433eff239e6db96f124f065373f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/api/handlers/management/logs.go:782-798 | internal/api/handlers/management/logs.go:802-818 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:782\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":782}}}],"partialFingerprints":{"codehealthFindingId/v1":"21c552bf5eafac8a9bb45844f77b1310fbdb0f3e2d97e03a84709d16aa6adae4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/thinking/provider/codex/apply.go:102-118 | internal/thinking/provider/openai/apply.go:99-115 \u2014 \u0060internal/thinking/provider/codex/apply.go\u0060 and \u0060internal/thinking/provider/openai/apply.go\u0060 are the same file name in two sibling directories, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 42 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/codex/apply.go:102\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/codex/apply.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7152bfd53730ffeb6e4dfc959f746d2ecd61b288deba7acb036c62c3dadac39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:598-614 | sdk/api/handlers/openai/openai_images_handlers.go:885-901 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:598\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"021ff72d4fd57c7cdfe8f1232c7c81949e6692e9432e04a5845dd1d40b51ef56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:321-337 | sdk/cliproxy/auth/selector.go:285-301 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:321\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c553d9f480429c2f2abdb2875734a80f2a6176efd3efb7bdb96de737e5fb12d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 3): internal/runtime/executor/codex_websockets_executor.go:128-143 | internal/runtime/executor/xai_websockets_executor.go:1671-1686 | sdk/cliproxy/auth/selector.go:202-217 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_executor.go:128\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_executor.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3046a67f886bb1cc8bbc9ab7e849f9c82344e8cfb2a2705cde3dfc974250600"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 3): internal/translator/codex/claude/codex_claude_request.go:546-561 | internal/translator/codex/gemini/codex_gemini_request.go:566-581 | internal/translator/codex/openai/chat-completions/codex_openai_request.go:688-703 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/claude/codex_claude_request.go:546\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"8095aeaeda7d5435055788ad66bc05d36d1aa04abb0f94993d289d390497de49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1001-1016 | internal/runtime/executor/claude_executor_request.go:1255-1270 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1001\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1001}}}],"partialFingerprints":{"codehealthFindingId/v1":"7045da487344bc0cf128f50387951d26588ee212a30b8621ae8ef8f7335739c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/runtime/executor/helps/usage_helpers.go:780-795 | internal/runtime/executor/helps/usage_helpers.go:823-838 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/helps/usage_helpers.go:780\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/helps/usage_helpers.go"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cac9af9c97b4528fdaec8603f60851e44fb1d09638c48b5022432a98c74a3f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/translator/antigravity/gemini/antigravity_gemini_request.go:385-400 | internal/translator/antigravity/openai/responses/antigravity_openai-responses_request.go:95-111 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/gemini/antigravity_gemini_request.go:385\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"619a57a5cc9189fa0f4ec069fe78342ef9fd86c36bc131eea13c5c43f538ba19"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): sdk/api/handlers/claude/code_handlers.go:71-87 | sdk/api/handlers/claude/code_handlers.go:103-118 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"31afb4e71ce810db90664d7671b3df62958b58b9d1928aec4f9bf6cbf5e81acb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): sdk/api/handlers/openai/openai_responses_websocket.go:438-453 | sdk/api/handlers/openai/openai_responses_websocket_forward.go:110-125 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_responses_websocket.go:438\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket.go"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"c27136ca6b2d976c5f19e9d24a5e2e93c2b4b0298bd72333fed6cc2fe54be262"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:414-429 | sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:450-465 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:414\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d50d23de1b56534ff1bdc86b2688238abe36d138e512fc384f0e337714696a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:385-400 | sdk/cliproxy/auth/conductor_execution.go:520-535 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:385\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecbded4f0af70b18fee1a1c9b862123bfb5122c9fdabfca0a9eb7df2d30100fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/config/config_load.go:60-76 | internal/config/parse.go:20-35 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/config/config_load.go:60\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_load.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"a54bf535d38ab3ad0d2c0ea04ea9141a7855c91df27d38c74eaf16b6962d3d87"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/config/config_load.go:138-157 | internal/config/parse.go:84-99 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/config/config_load.go:138\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_load.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"30b7d6ffbf5e0479643422c153fde0ed67956142a643e902b8ef21c5aeb20e46"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:216-231 | internal/runtime/executor/antigravity_executor_execute.go:453-468 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:216\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"e51229bd7b95d8c695a07c0a7ce01d2050f03aa7aa8d75281f403eb3a8f35886"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:239-254 | internal/runtime/executor/antigravity_executor_execute.go:532-548 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:239\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b320336e102e03ccd6d23e66c3a52525b03ac4501cacbe1450580412f893935"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/auth/claude/oauth_server.go:124-138 | internal/auth/codex/oauth_server.go:121-135 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/oauth_server.go:124\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"342a63011e346fb848cf46a1c046a75edcca3741ef3023dbbb4295e57443f0a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/cmd/anthropic_login.go:27-41 | internal/cmd/openai_login.go:41-55 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cmd/anthropic_login.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ef473f8371ceff9c1d4d04a3133d42974aabce4915e3b82d4fda25a867b1bb9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1078-1092 | internal/runtime/executor/claude_executor_request.go:1315-1329 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1078\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1078}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a1374a67838c676920ed90f1e7c20347cc7aff2b49c60fe9be5c61a4e79384b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:587-601 | internal/runtime/executor/xai_websockets_executor.go:1282-1296 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:587\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"633c20fab42c288a540509b223da4140f11b148779266278d6dabb8ce2e2bc89"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:678-692 | internal/runtime/executor/xai_websockets_executor.go:1369-1383 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":678}}}],"partialFingerprints":{"codehealthFindingId/v1":"193f8b54d2ed31a20156b9716869228a54f39a8245c4070aa26f434e2a202ac6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:759-773 | internal/runtime/executor/xai_websockets_executor.go:1548-1562 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:759\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":759}}}],"partialFingerprints":{"codehealthFindingId/v1":"63aa12ad67633c96438ad594c3990f2695f9e609b62fd6225e915127a2fe1f2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/translator/claude/openai/chat-completions/claude_openai_request.go:106-121 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:96-110 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/chat-completions/claude_openai_request.go:106\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_request.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"55a389299adc2f1f398db0691d5cca06e2d39298e35e8bf857483e590781b313"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/translator/openai/claude/openai_claude_response.go:297-314 | internal/translator/openai/claude/openai_claude_response.go:372-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/claude/openai_claude_response.go:297\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d8ad558bcd4ff579834c79c13f81bbb05ebca4e7ee4a529fc293a5616d74b4d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): sdk/auth/claude.go:121-135 | sdk/auth/codex.go:124-138 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/auth/claude.go:121\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/claude.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"091c3d5b7074a74f32490c2f29b3857076e499c6248fcca5eee431d253e9d1dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:331-345 | sdk/cliproxy/auth/conductor_execution.go:458-472 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:331\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"4462e9f5d6349bbb768d11b490dd87263a0dc8a4709ab2e376dfa08dc1971e69"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:675-689 | sdk/cliproxy/auth/conductor_selection.go:735-749 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:675\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"003a3136d3683ac3ef0ad83b239a437cd13b873229558aaa2de7d92d002573b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): sdk/cliproxy/usage/accounting.go:96-110 | sdk/cliproxy/usage/accounting.go:200-214 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/usage/accounting.go:96\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/usage/accounting.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"b333af13acaee05f0dd65a711255056af6b29215e3bff4426ce031548fb18f4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/api/handlers/management/config_lists.go:288-302 | internal/api/handlers/management/config_lists.go:462-476 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:288\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffa51ac0c9717af1b9d56694ff81cea984a0d55eb187b24e90a5309dae01cd75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 4): internal/api/handlers/management/api_tools.go:525-538 | internal/runtime/executor/gemini_executor.go:745-758 | internal/runtime/executor/gemini_vertex_executor.go:1128-1141 | sdk/cliproxy/service_models.go:379-392 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/api_tools.go:525\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":525}}}],"partialFingerprints":{"codehealthFindingId/v1":"361a303657d1e6db24416ef7c75ff30d18a45dfad4027506e41b5e872ba7f365"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): sdk/auth/antigravity.go:93-106 | sdk/auth/claude.go:119-132 | sdk/auth/codex.go:122-135 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/auth/antigravity.go:93\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/antigravity.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"16a414d28eaa5245e6cfd7ef72bf4719fe5eb0c2865d13e3782f35e9624d5efa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/auth/claude/oauth_server.go:73-86 | internal/auth/codex/oauth_server.go:70-83 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"38246243737a177cf6caed680b399caf34e8b187325ece59fb2d4ea115386745"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/auth/claude/token.go:83-97 | internal/auth/codex/token.go:64-77 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/token.go:83\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/token.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ac99a8f213e17cb460d87490c77ac560c389ebf708b00ca9c85d4427e02a0a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/homeplugins/sync.go:596-609 | internal/pluginstore/install.go:478-491 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/homeplugins/sync.go:596\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":596}}}],"partialFingerprints":{"codehealthFindingId/v1":"9afe64ad09a699be66594e6ae6bebb3b25d27a4798f5be3b0fe94464e0646a5d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1455-1469 | internal/runtime/executor/claude_executor_request.go:1635-1648 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1455\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1455}}}],"partialFingerprints":{"codehealthFindingId/v1":"07eb43826f99b0692a75f116e75ea57ab1f958e2aabccc370dc55015690f366f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:470-483 | internal/runtime/executor/xai_websockets_executor.go:1101-1114 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:470\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ed2cedf81bdd4d5a458a75f9b30506d25a648823dd92b35ce9c559e2a2535f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:532-545 | internal/runtime/executor/xai_websockets_executor.go:1227-1240 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:532\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"10d32efe4ef25198c9dbe57d229b2e64818d2025f3d1526342579bd654c5c995"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/gitstore.go:1394-1407 | internal/store/gitstore.go:1420-1433 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:1394\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":1394}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc958e1b2729b73485c85cb0813ee5bcfb9107a8921002ac1048d1ec36c86e49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/thinking/provider/codex/apply.go:48-61 | internal/thinking/provider/openai/apply.go:45-58 \u2014 \u0060internal/thinking/provider/codex/apply.go\u0060 and \u0060internal/thinking/provider/openai/apply.go\u0060 are the same file name in two sibling directories, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 42 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/codex/apply.go:48\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/codex/apply.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"38c125ee9b2a03d64a5dd9518179d4ad2fb2d7561dab163c8ed8830c1725f6a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:141-154 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:127-140 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:141\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed0c049607fe91b22c10e45bde0c5c072f6d3a84fcb23cb216ce61f23512529f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): sdk/api/handlers/openai/openai_handlers.go:306-319 | sdk/api/handlers/openai/openai_handlers.go:401-414 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_handlers.go:306\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cd5ff5856c7cfd90e8e787353c9ac384187caa9ab2eb63d1872dce58e44e3e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): sdk/cliproxy/service_models.go:743-756 | internal/config/config_normalization.go:264-277 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/service_models.go:743\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b84472592b882e8cc9edb98e2fdf711d891ffc478917121d36f62b3d03e548d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/cmd/antigravity_login.go:18-31 | internal/cmd/xai_login.go:18-31 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cmd/antigravity_login.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"6838a977784db2065fd098c4c4798e6f7a88b5cc47bcf5a24873715add0d1fc7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:93-106 | internal/runtime/executor/antigravity_executor_execute.go:318-331 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:93\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"907e751367da685decbbeb988e167e0faba980c34e3ff184663f17e11d7690ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/pluginhost/adapters_interceptors.go:339-351 | sdk/api/handlers/handlers_interceptors.go:357-369 | sdk/cliproxy/auth/conductor_execution.go:261-273 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_interceptors.go:339\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_interceptors.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"10497a37bd2689a08ba503fc865a370bd3a7da4950af957242cf87592864e287"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/translator/codex/claude/codex_claude_request.go:501-513 | internal/translator/codex/gemini/codex_gemini_request.go:521-533 | internal/translator/codex/openai/chat-completions/codex_openai_request.go:640-653 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/claude/codex_claude_request.go:501\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f79df8fc95f1eb1b15a924f54244b011b970c49a1e44b841a39dfd2b0b0c300"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): examples/plugin/claude-web-search-router/go/execution_fallback.go:203-215 | examples/plugin/claude-web-search-router/go/stream_forward.go:103-115 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/execution_fallback.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"723386054cffd1d42b5602bdfe3eb377791d4c41f7f6ed91570bffe349461e5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/fetch_antigravity_models/main.go:82-94 | cmd/fetch_codex_models/main.go:70-82 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/fetch_antigravity_models/main.go:82\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/fetch_antigravity_models/main.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"79ff561f244c775f61596f8f31c194ee4dd45a67390120b5713e6507d36ee462"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:47-59 | internal/api/handlers/management/auth_files_provider_oauth.go:207-219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:47\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"16bf9023f06f3e4875e4805321b4f26b760d84c5125905420e3f790fa4077c0c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:561-573 | sdk/auth/xai.go:94-106 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:561\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":561}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa72a07da2c46a79d37ab0e5cbddc0b9ab236bb307eb0a20ab016f16752cc7a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/api/handlers/management/config_auth_index.go:88-100 | internal/api/handlers/management/config_auth_index.go:117-129 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_auth_index.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b432796515bd80cd7c35662849a920f1cb136c6c855b8a4ddff4fa3dc39a833"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/auth/claude/anthropic_auth.go:637-649 | internal/auth/codex/openai_auth.go:303-315 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/anthropic_auth.go:637\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/anthropic_auth.go"},"region":{"startLine":637}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a6e818678522b26f94d4cd6e16f7926baf166576ba1428f05ad5967a8e4993c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/auth/claude/oauth_server.go:87-99 | internal/auth/codex/oauth_server.go:84-96 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/oauth_server.go:87\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"d82f442e4504186dbdcd905433dd258cda267038afbcc2fc776428a776a69dc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/claude_executor_cloaking.go:1248-1260 | internal/runtime/executor/claude_executor_cloaking.go:1343-1356 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_cloaking.go:1248\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1248}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c1ef2919437ac91deb7aad8df6a29049fa597a5f003d5b5b4e1fdd933f1de6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/codex_executor_reasoning.go:124-136 | sdk/cliproxy/auth/conductor_execution.go:1002-1014 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_reasoning.go:124\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba2f5d2fa01f7fbb66e9167c5ed2c7c1f09aee814f4da54635ca82d552a17246"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:457-469 | internal/runtime/executor/openai_compat_executor.go:593-605 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:457\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"c13d40fd4501ead6b80c0bbf12ca07ca68f56048df0f0fe22421cf7c05406521"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:1138-1150 | sdk/cliproxy/service_models.go:469-481 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:1138\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":1138}}}],"partialFingerprints":{"codehealthFindingId/v1":"30e1a4a19870d330701b380e4cd20249b1a257c3c891e308ca8ded6ba2033778"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:754-766 | sdk/api/handlers/openai/openai_images_handlers.go:537-550 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:754\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":754}}}],"partialFingerprints":{"codehealthFindingId/v1":"db0ac7a017ffd3e6f86517647cbaea2a10f417c6a2912d3b47886615c2bf85a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/signature/claude_validation.go:262-274 | internal/signature/claude_validation.go:292-304 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/signature/claude_validation.go:262\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"81c4ca687606681e942dc933eb2c88263e7467990ac18efa849d51ab769bfdf9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/translator/antigravity/gemini/antigravity_gemini_request.go:317-329 | internal/translator/antigravity/openai/responses/antigravity_openai-responses_request.go:53-65 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc59c89d8b1ed840ff2a2192e24a7fc23932c31ce0bc140d6649f826f6b94041"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:208-220 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:247-259 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:208\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b7ba3d9b602476862f846524898fabc2765a69d74266be6a966641fe9ae4972"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/watcher/synthesizer/config.go:113-125 | internal/watcher/synthesizer/config.go:174-186 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/config.go:113\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"d54702e37db22caa261c202983474de3efb0ac51dfc0460db2955ad1523cce6f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:60-72 | sdk/api/handlers/handlers_execution.go:125-137 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7c8d79c298b9e1de7cdbf4038421d2576cb1efc51afb370dc72d98867e60def"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): sdk/api/handlers/openai/openai_videos_handlers.go:800-812 | sdk/api/handlers/openai/openai_videos_handlers.go:1021-1033 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_videos_handlers.go"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e9862cfdf634925e7ae7af72e8421339bbbc6671404c7fe3941753d6ad9d29a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): sdk/cliproxy/session/identity.go:224-236 | sdk/cliproxy/session/identity.go:253-265 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/session/identity.go:224\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/session/identity.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b6f483d9cc395e93978a50c6fec9b87a2ac76df7580e280b9f41936fc8c597e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): sdk/cliproxy/usage/accounting.go:164-176 | sdk/cliproxy/usage/accounting.go:197-209 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/usage/accounting.go:164\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/usage/accounting.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"f320bdb871741c8409c13932465f7ca6722b0051f040614ba4799efe84b4108c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:57-69 | internal/runtime/executor/antigravity_executor_execute.go:281-293 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"29f8da13753c3a5aafc6496b7a8995dc086e8d9b7ff972311479f2ec560d8896"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:125-138 | internal/runtime/executor/antigravity_executor_execute.go:349-361 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:125\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"e03b6f974ff77be5db254f460b93af6f09a6b9e4dd551f66fa608f2b73429701"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 17): internal/runtime/executor/gemini_executor.go:194-205 | internal/runtime/executor/gemini_executor.go:303-314 | internal/runtime/executor/gemini_executor.go:420-431 | internal/runtime/executor/gemini_executor.go:496-507 | internal/runtime/executor/gemini_executor.go:657-668 | internal/runtime/executor/gemini_vertex_executor.go:386-397 | internal/runtime/executor/gemini_vertex_executor.go:511-522 | internal/runtime/executor/gemini_vertex_executor.go:625-636 | internal/runtime/executor/gemini_vertex_executor.go:771-782 | internal/runtime/executor/gemini_vertex_executor.go:898-909 | internal/runtime/executor/gemini_vertex_executor.go:989-1000 | internal/runtime/executor/kimi_executor.go:157-168 | internal/runtime/executor/kimi_executor.go:278-289 | internal/runtime/executor/openai_compat_executor.go:167-178 | internal/runtime/executor/openai_compat_executor.go:258-269 | internal/runtime/executor/openai_compat_executor.go:377-388 | internal/runtime/executor/openai_compat_executor.go:541-552 \u2014 there are 17 copies across 4 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 17 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:194\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"13f3afcd0a5dc5560366e643148b5ea8138936860e83601c5e9ae9dc6b47740d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 5): sdk/api/handlers/gemini/gemini_handlers.go:179-190 | sdk/api/handlers/openai/openai_images_handlers.go:1173-1184 | sdk/api/handlers/openai/openai_images_handlers.go:1302-1313 | sdk/api/handlers/openai/openai_images_handlers.go:1435-1446 | sdk/api/handlers/openai/openai_images_handlers.go:1726-1737 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"21efae9b63c38292c392380a8d29c691a141f70d637ea927fbfbf2d1e50605a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/runtime/executor/gemini_vertex_executor.go:372-383 | internal/runtime/executor/gemini_vertex_executor.go:611-622 | internal/runtime/executor/gemini_vertex_executor.go:884-895 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:372\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dee2add89c9488fcb0c9d45a2d9313b5e018659f000bcd8fb27882f91bd945d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/runtime/executor/gemini_vertex_executor.go:493-504 | internal/runtime/executor/gemini_vertex_executor.go:753-764 | internal/runtime/executor/gemini_vertex_executor.go:971-982 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"d18fcea330e63e50c8ecbee43f9e9625edc7155e1e9a588e32318071a2bbe34c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/translator/claude/gemini/claude_gemini_request.go:50-61 | internal/translator/claude/openai/chat-completions/claude_openai_request.go:49-60 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:39-50 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_request.go:50\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a42ce027780bb00be7f10714183220a77ac59a83ce2d253655e15ca6678a52d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): sdk/api/handlers/openai/openai_handlers.go:104-117 | sdk/api/handlers/openai/openai_handlers.go:159-172 | sdk/api/handlers/openai/openai_responses_handlers.go:428-439 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"e29eba0bd505500c1a9226e7b7131b1e3241fc74e3fca042d03c4fbec10426ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): examples/http-request/main.go:104-115 | examples/http-request/main.go:128-139 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060examples/http-request/main.go:104\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/http-request/main.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"d010273a4180eba7e4fd2e876a8c99e78a1aff51da24496000a93547aafeb033"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/api/handlers/management/logs.go:43-54 | internal/api/handlers/management/logs.go:138-149 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:43\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ddedfc32c89298f14011055db07f385e204bd90df3d24bdef1f07caf1e7e882"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/api/handlers/management/logs.go:146-157 | internal/api/handlers/management/logs.go:208-219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:146\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac444368fcdc61512e28019128f63f1cf1dedaa7ea77d6c58274023b757674b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/api/handlers/management/plugins.go:160-171 | internal/api/handlers/management/plugins.go:320-331 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/plugins.go:160\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fbe8a75a5c8474173a3a162186293e6d1d6a0c993c0d5036d30b2062838094b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:390-401 | internal/api/handlers/management/auth_files.go:311-322 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:390\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d102b3a093db3840607db51b80a4a887b55ce2a15865d3f7cff06e1887550a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:505-516 | internal/api/handlers/management/auth_files_crud.go:418-429 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:505\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"12052c3a998bef5db5240b33c3c5c94c167a955743312e9e5b85d5e419b18152"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:548-559 | internal/api/handlers/management/auth_files.go:481-492 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:548\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa90b16721088c44121435d8ad914c8358c5d35e88ac565570a90b8cd9bf60e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:581-592 | internal/api/handlers/management/auth_files.go:450-461 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:581\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":581}}}],"partialFingerprints":{"codehealthFindingId/v1":"435b90e2ec643f62180c6b2a71b57f01fde5b8c6b138c72d97e468a6d364ba97"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/registry/model_registry.go:550-561 | internal/registry/model_registry.go:658-670 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/registry/model_registry.go:550\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":550}}}],"partialFingerprints":{"codehealthFindingId/v1":"4607bb2f46e928c8aabaff7eca046545d195eabe4a0a86a4fcb144fce1536915"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/registry/model_updater.go:284-295 | sdk/cliproxy/auth/scheduler.go:517-528 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/registry/model_updater.go:284\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_updater.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"018f79fa2418dc788895ff7902458316a931811733ee6a8ef5736271b842bd48"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/runtime/executor/aistudio_executor.go:160-172 | internal/runtime/executor/aistudio_executor.go:228-239 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/aistudio_executor.go:160\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e4775e195a21b9d8ead73964f8b7d0ddc585e6c87d93d067d63be33d38b1d4a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/runtime/executor/claude_executor_cloaking.go:1038-1049 | internal/runtime/executor/claude_executor_cloaking.go:1074-1085 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_cloaking.go:1038\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":1038}}}],"partialFingerprints":{"codehealthFindingId/v1":"25792e4d12c93f611c2e34342a1650c082f1b8d391d5f6a41e8a675ecec2b01d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/runtime/executor/codex_executor_reasoning.go:513-524 | internal/runtime/executor/xai_reasoning_replay.go:136-147 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_reasoning.go:513\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"183edfbbed168168d389662292435cb6eaa1c35d8c0ec07a3fec4a60c5a81cd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/runtime/executor/codex_websockets_connection.go:33-45 | internal/runtime/executor/xai_websockets_executor.go:1042-1053 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_connection.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"f74cee3783d050870ee61379da9d2176463da18a4fc3c0613c1e5419b8990362"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/gitstore.go:381-392 | sdk/auth/filestore.go:85-96 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ad2ab60dc50542bc1811360321ff0a712234c3a855dd038bc93625863d5eb4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/gitstore.go:719-730 | sdk/auth/filestore.go:421-432 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:719\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":719}}}],"partialFingerprints":{"codehealthFindingId/v1":"453196c642efc490b49e9bfd7d4650de1e898810ece8bc8fd8d1aed8c9c9ca1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/thinking/apply.go:723-734 | internal/thinking/apply.go:773-784 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/apply.go:723\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b4709047044dbf66681eb89e973285cd8971dbfa2ce4fe778befeb4a6ae2d65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/thinking/provider/kimi/apply.go:64-76 | internal/thinking/provider/kimi/apply.go:105-116 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/kimi/apply.go:64\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/kimi/apply.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ad64a8cc34b2c8045a4eb333407a2592f3a426cdc2628bc352d6df5b0071a83"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:149-160 | internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:260-271 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:149\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0342cfecaeb223fdf89148904df029c08c1acc829fb50d74dc309ccecf7f3c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:176-187 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:218-229 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"49993fc6d4f3c4d8069f1053b434b6e0ef5f3370fe830f1d032610428e886483"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_request.go:87-98 | internal/translator/codex/gemini/codex_gemini_request.go:88-99 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_request.go:87\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d64322f8a59fde7d10e91302b6065fb1429e0278b504f8606fb7f70a7c66900"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_request.go:303-315 | internal/translator/codex/gemini/codex_gemini_request.go:214-225 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"dab20d05b18b3d62a8d54bee8da1fd14f15c0d59291607d02450339633d518bb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/translator/gemini/claude/gemini_claude_response.go:140-151 | internal/translator/gemini/claude/gemini_claude_response.go:168-179 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/claude/gemini_claude_response.go:140\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"27eaddf404ffd452acfea06002040f5ae0b34a6a99a1b4cb7c3a152cb85ff2c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): sdk/api/handlers/gemini/gemini_handlers.go:84-95 | sdk/api/handlers/gemini/gemini_handlers.go:131-142 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/gemini/gemini_handlers.go:84\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"13ea6555c0e19176b6141117402337a68c1f5d0ea854eb68d7d844f86b4e5cb7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:1156-1168 | sdk/api/handlers/openai/openai_images_handlers.go:1554-1565 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1156}}}],"partialFingerprints":{"codehealthFindingId/v1":"d675cfb9b33156a70c1376ec5f7f455c6186cdc4fb7bae52fafe3178cb7caf87"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): sdk/auth/claude.go:139-150 | sdk/auth/codex.go:142-153 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/auth/claude.go:139\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/claude.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"de6dc9eebaf4b87f063647e978467fe30079d6b717394512d57d4e921bcdd6e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:54-65 | sdk/cliproxy/auth/conductor_execution.go:99-110 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:54\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"c001843acf8481337df83ca50b924372ccb2b7300a18fc8b67c83c01e32f76df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): sdk/cliproxy/auth/oauth_model_alias.go:53-64 | internal/config/config_normalization.go:77-88 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/oauth_model_alias.go:53\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/oauth_model_alias.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"468fa85dfb9d85d75a13f2ce191028c2de66bb88c2d187d614e227310a169b42"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:167-178 | internal/runtime/executor/antigravity_executor_execute.go:406-417 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:167\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a320958375ca7bfa72fe67ff125e9fc293e8655490c0b4e6cecca381866ac57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 5): internal/runtime/executor/gemini_executor.go:137-148 | internal/runtime/executor/gemini_executor.go:251-261 | internal/runtime/executor/gemini_vertex_executor.go:445-456 | internal/runtime/executor/gemini_vertex_executor.go:560-571 | internal/runtime/executor/gemini_vertex_executor.go:706-717 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"90f68e416ac5cc189baf86d5ffee8e56820c7886a29e0104818c71d08d125c33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/runtime/executor/gemini_executor.go:369-379 | internal/runtime/executor/gemini_vertex_executor.go:686-696 | internal/runtime/executor/gemini_vertex_executor.go:832-842 | internal/runtime/executor/kimi_executor.go:339-349 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:369\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"9abbe4dc99282e1735832e18e68e381458550b32e66098ac8b540e93af3dc239"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/watcher/synthesizer/config.go:91-101 | internal/watcher/synthesizer/config.go:148-158 | internal/watcher/synthesizer/config.go:218-228 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/config.go:91\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2bcd32f3ec0180a70f651c9154388e4d9c9bf750c0885fa35d8b38c3585b7d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/api/handlers/management/config_lists.go:229-239 | internal/api/handlers/management/config_lists.go:403-413 | internal/api/handlers/management/config_lists.go:906-916 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:229\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0fa798ae0fef225f8e23ff3082208ec5bfd4f01ebfd75a76e9421d3db1bba0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): examples/plugin/claude-web-search-router/go/execution_fallback.go:173-183 | examples/plugin/claude-web-search-router/go/stream_forward.go:77-87 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060examples/plugin/claude-web-search-router/go/execution_fallback.go:173\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/execution_fallback.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5cc18f986b5756cadb97e133daed1c205340f2a246137368ac90745536fae0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:156-166 | sdk/auth/claude.go:207-217 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:156\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d1fa3c7739b366796074c0b83bd824901aff6082859bdeb6268e3374adfe391"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/handlers/management/logs.go:262-272 | internal/api/handlers/management/logs.go:349-359 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:262\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a6b830f34f3791ff0223b08cb281d29d55e6d8fb32ebf85ece8da1b169b05e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/handlers/management/logs.go:334-344 | internal/api/handlers/management/logs.go:390-400 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:334\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"773585a905e314701b3e918c0bc896a31e4f52254c68e590f9d677665f4c7801"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/handlers/management/plugin_store.go:902-912 | internal/homeplugins/sync.go:791-801 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/plugin_store.go:902\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":902}}}],"partialFingerprints":{"codehealthFindingId/v1":"04d3889db322df038209e13c50cde925795a6326879520bd70f7aeaf60107ed6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/server_routes.go:421-431 | internal/client/codex/live/live.go:317-327 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/server_routes.go:421\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"792d38cb451ab2bf3fc518d2db5d7b7e305349b0fe353d40f9da88d94395734c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/api/server_routes.go:609-619 | internal/api/server_routes.go:676-686 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/server_routes.go:609\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce9ed02990e0ad95fe3869c437fbe9af66fdef93f69bfe62ba134cec54b16808"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/auth/claude/oauth_server.go:232-242 | internal/auth/codex/oauth_server.go:229-239 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/oauth_server.go:232\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"f70a62d8e8213c7d7b4359d1a53d3e9f2a6f8a7f2f4148275f31d31e3de06a7d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/auth/claude/oauth_server.go:265-275 | internal/auth/codex/oauth_server.go:262-272 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/claude/oauth_server.go:265\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/claude/oauth_server.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"74127c7e67c15e90662c91196082844ae592fdb844e676506aa33ee976ba64d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/auth/kimi/kimi.go:332-342 | internal/auth/kimi/kimi.go:424-434 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/kimi/kimi.go:332\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/kimi/kimi.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cc817db66504b6587fe4c8ac13155c8767c1d0a8302cdfdb89c7d7ebc6b6f1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/home/client.go:1204-1214 | internal/home/client.go:1230-1240 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/home/client.go:1204\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/home/client.go"},"region":{"startLine":1204}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ecd4dee6bdef8dd388002484918c53bf7c8e6914509da75e80a8d2dd0146272"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:307-317 | internal/api/handlers/management/auth_files_crud.go:466-476 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:307\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b37f7016e262c5eb418a621af20157e6350813ce38b5734c6c2c93c259c8e89"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/pluginhost/management.go:269-279 | internal/pluginhost/management.go:313-323 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/management.go:269\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/management.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a666fe4913043b3fac7a58a702a0f7ae4979cd9cd9b82327756b5af74466b6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/pluginhost/platform.go:82-92 | internal/pluginstore/install.go:492-502 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/platform.go:82\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/platform.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd100fe3dde962a49b40fd1ed30e94210b63fec5c329d5ab9e6ef7728fd6d5de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/registry/model_registry.go:325-335 | internal/registry/model_registry.go:471-482 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_registry.go"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"70b1f45fc7be59b7ab934553849c9b55b050253bb38ee994bc56e17604262ba5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/antigravity_reasoning_replay.go:714-724 | internal/runtime/executor/antigravity_reasoning_replay.go:750-760 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_reasoning_replay.go:714\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":714}}}],"partialFingerprints":{"codehealthFindingId/v1":"30627098335187a1c54dfe18cbafc8e10feb7d9834b82eaf69b3e08b7628032c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:123-133 | internal/runtime/executor/codex_openai_images.go:350-360 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dd5358b6338c20ba62e5639887c286ab5c0751691dcd1b6dda2d56716ae2436"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:325-335 | internal/runtime/executor/codex_openai_images.go:386-396 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"19c5e1830f782b67ca2c048608dd3dd8c368fc1b9600084f32dca2522f424a4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:492-502 | internal/runtime/executor/xai_websockets_executor.go:1123-1133 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:492\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":492}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8b5f19729e599c18a6215147a67382b224f53ba6d287304e59c3307a2ef4af3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/kimi_executor.go:104-114 | internal/runtime/executor/kimi_executor.go:221-231 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"102089ccfdba38fba3702282e1fbd34fc1cf77c0829a82dff125e15aa11af649"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:728-738 | sdk/api/handlers/openai/openai_images_handlers.go:510-521 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:728\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":728}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffe10c2f6647fe5e418284eb1986c3fe6b8b97c068a16e0d51d8d736b819c290"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/signature/claude_validation.go:790-800 | internal/signature/gemini_validation.go:491-501 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/signature/claude_validation.go:790\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude_validation.go"},"region":{"startLine":790}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc86d54132229b148cc82ac384cf87b4134977884198fe8394f6b1bca86cce03"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/signature/gemini_validation.go:439-449 | internal/signature/gemini_validation.go:453-463 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/signature/gemini_validation.go:439\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/gemini_validation.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"739116cbe5594d130981fb1ae9a786e03288a81ae09405c9dc67b5c861adae7e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/gitstore.go:477-487 | internal/store/objectstore.go:248-258 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:477\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f87aaeb963b831007c1f597b6db5da685a446b48ce54ff7b52c23db4d70c9d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/thinking/provider/codex/apply.go:63-73 | internal/thinking/provider/openai/apply.go:60-70 \u2014 \u0060internal/thinking/provider/codex/apply.go\u0060 and \u0060internal/thinking/provider/openai/apply.go\u0060 are the same file name in two sibling directories, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 42 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/codex/apply.go:63\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/codex/apply.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a1a0a085891339b9581fdecb7540f5b7721461ded9d89052ba05f8c7bed0436"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_request.go:866-876 | internal/translator/gemini/claude/gemini_claude_request.go:237-247 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_request.go:866\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":866}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e99c0a5693814444425d4e2658a1d9de477500de2efc8945545c28dcf1e28d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_request.go:898-908 | internal/translator/gemini/claude/gemini_claude_request.go:270-280 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_request.go:898\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7a35c91dbe363cdbca3ab797ac04ed641b0b5bb2fc9e108e23b838d2f3c75e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:362-372 | internal/translator/gemini/interactions/interactions_gemini_common.go:958-968 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"33062aa0906162580c2162209b4e1a2259b1f87b7567dfba863d3966e28ec6bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_request.go:510-520 | internal/translator/codex/gemini/codex_gemini_request.go:451-461 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4c1900b9525083e5907945a08d0d3843b5adc85111c8f007645990e18711f21"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/claude/openai/chat-completions/claude_openai_request.go:61-71 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:51-61 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/chat-completions/claude_openai_request.go:61\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_request.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"0996d113cf68a8c6b12f180137ea4459f150411d7318345a4ba95e7ba199cba8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_request.go:270-280 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:690-700 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/responses/claude_openai-responses_request.go:270\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cd4f3f17ad7169586a08fc3d5f05bf74ce8ede8eefc0ee7babf74dba6bf0dd5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/codex/claude/codex_claude_request.go:177-187 | internal/translator/codex/claude/codex_claude_request.go:238-248 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/claude/codex_claude_request.go:177\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee07a944c9fea5460e2f845a6c459ec9e3bd26b2b584c065869c2eb6e412d1bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/codex/claude/codex_claude_response.go:383-393 | internal/translator/codex/claude/codex_claude_response.go:398-408 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/claude/codex_claude_response.go:383\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"068dea02e6f698f07ee5a7723baf465e1315ba19b174d6e3845eb26da5fb38e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/codex/gemini/codex_gemini_response.go:93-103 | internal/translator/codex/gemini/codex_gemini_response.go:124-134 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/gemini/codex_gemini_response.go:93\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc1ae95ca77eda9bfce10cedd882e20cbfe291b5998eeebe95a63a9a84f7b1c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_response.go:151-161 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:277-287 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/openai/chat-completions/codex_openai_response.go:151\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a6aedca095cd01936707bb3b36749795e9669382eb25342365c7dad94726dba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/util/gemini_schema.go:97-107 | internal/util/gemini_schema.go:480-490 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/util/gemini_schema.go:97\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"edea1b18bc4b3d9088c7e1341b2becec3ca44d05296881c1ba12d515b886d167"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/watcher/synthesizer/config.go:75-85 | internal/watcher/synthesizer/config.go:203-213 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/config.go:75\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"7edf5168cb73153b39e200bb2eebbc6d743f2b3686f25ee7ecfe3148fcaeb9b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/watcher/synthesizer/config.go:293-303 | internal/watcher/synthesizer/config.go:337-347 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/config.go:293\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"231cfc300d034dd16eb4cb7776d3148b53b6d988f8c41c440e4c4d869af40f6c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/api/handlers/gemini/gemini_handlers.go:320-330 | sdk/api/handlers/gemini/interactions_handlers.go:185-195 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/gemini/gemini_handlers.go:320\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"c36bd52a2c4b73249cbb00476a3a58f33b4ab558e578e1d7891fef7e173d507e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:777-787 | sdk/api/handlers/openai/openai_images_handlers.go:801-811 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":777}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fcace4075261d1f99e5ae170f89646d69429b33760c053cc7f68489bd215e1d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/auth/claude.go:93-103 | sdk/auth/codex.go:96-106 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/auth/claude.go:93\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/auth/claude.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"1734c1ec6cde23b0cc7c257bbde6da019ca7979fc02a73cf8906a71b9d564ae5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:361-371 | sdk/cliproxy/auth/conductor_execution.go:488-498 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:361\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e4e6643edfa3f56379d154fd5ef5f064830bf96ab102fc848b3205d0f631224"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:301-311 | sdk/cliproxy/auth/selector.go:257-267 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:301\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"96ae27ccd44554ced72fb804d3b5e0efe3b479fcb811bfa48729f7adaa03beb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:983-993 | sdk/cliproxy/auth/conductor_selection.go:1291-1301 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:983\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":983}}}],"partialFingerprints":{"codehealthFindingId/v1":"9820b2db16a6711eddf1cc61ff53707011f4d999c174baf55d40000e9eeb0843"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 16): internal/runtime/executor/claude_executor_tokens.go:222-231 | internal/runtime/executor/gemini_executor.go:188-197 | internal/runtime/executor/gemini_executor.go:297-306 | internal/runtime/executor/gemini_executor.go:651-660 | internal/runtime/executor/gemini_vertex_executor.go:380-389 | internal/runtime/executor/gemini_vertex_executor.go:505-514 | internal/runtime/executor/gemini_vertex_executor.go:619-628 | internal/runtime/executor/gemini_vertex_executor.go:765-774 | internal/runtime/executor/gemini_vertex_executor.go:892-901 | internal/runtime/executor/gemini_vertex_executor.go:983-992 | internal/runtime/executor/kimi_executor.go:151-160 | internal/runtime/executor/kimi_executor.go:272-281 | internal/runtime/executor/openai_compat_executor.go:161-170 | internal/runtime/executor/openai_compat_executor.go:252-261 | internal/runtime/executor/openai_compat_executor.go:371-380 | internal/runtime/executor/openai_compat_executor.go:535-544 \u2014 there are 16 copies across 5 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 16 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_tokens.go:222\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_tokens.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ca814dff2a727dd522b6e9b4773b46aa0e3f55fb02cd77bfc747d9cb88a581c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/registry/model_updater.go:272-281 | sdk/cliproxy/auth/scheduler.go:516-525 | sdk/cliproxy/service_models.go:741-750 | internal/config/config_normalization.go:262-271 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/registry/model_updater.go:272\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/registry/model_updater.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"63c9f0d6ba8f749584866f0a800c561ef1ca33076bf25b8cec7cc18ddf20d430"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/api/handlers/management/config_lists.go:914-923 | internal/api/handlers/management/config_lists.go:1274-1283 | internal/api/handlers/management/config_lists.go:1461-1470 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:914\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":914}}}],"partialFingerprints":{"codehealthFindingId/v1":"f66db4a9acd090fa66bac3099727d949d2afcebb269f3d1bfbdd34977ee1b52d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:468-477 | sdk/auth/antigravity.go:197-206 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:468\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"60724f0d64abc607e23aff61ff0d30d685593f454dffdd6f46b7e48a71e7cbbe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/api/handlers/management/config_basic.go:210-219 | internal/api/handlers/management/config_basic.go:230-239 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_basic.go:210\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_basic.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"6707d6fc20b1c36a30bc82de1feeac62d71c1e43a740b11e7acafbbc6b897bad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/api/handlers/management/logs.go:234-243 | internal/logging/request_logger_writer.go:363-372 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:234\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9e35eaa482e3a61c84f2e09b21a488f9242410f3a46e7f208f286522d31f414"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/homeplugins/sync.go:152-161 | internal/homeplugins/sync.go:257-266 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/homeplugins/sync.go:152\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"abc9555907dbea7e2431a322e6a86b46264d6f00ca7db275025059936a50eff6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/homeplugins/sync.go:517-526 | internal/pluginstore/install.go:421-430 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/homeplugins/sync.go:517\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e691bf1f2f830785135d6646442112a3089ea5b5196589ffd1c130ce8d4f520"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/adapters.go:404-413 | internal/pluginhost/auth_provider.go:374-383 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters.go:404\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters.go"},"region":{"startLine":404}}}],"partialFingerprints":{"codehealthFindingId/v1":"86ff7ae7d2a7e07f9fc6b8e436423f4161073856844eb07d9de3e2c78a58047b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/adapters_executors.go:48-57 | internal/pluginhost/adapters_executors.go:90-100 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:48\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"85bf45c15eaf9e9e277a7847c9f0362c32de68eae913ed62ae9506bb096d943a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/adapters_usage_translation.go:283-292 | internal/pluginhost/adapters_usage_translation.go:307-316 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_usage_translation.go:283\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_usage_translation.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"9750100faf651c97ef21e4928465f8836e3f08b05bb9e3d2bb204928161fa677"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/adapters_usage_translation.go:333-342 | internal/pluginhost/adapters_usage_translation.go:359-368 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_usage_translation.go:333\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_usage_translation.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"0086780c3db2c67e32f38f2d9608c21abd2b7ea4096ed4e6f17f1e328093ef66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/auth_callbacks.go:528-537 | internal/api/handlers/management/auth_files.go:540-549 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/auth_callbacks.go:528\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/auth_callbacks.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"e51afc460c55c2999034c2faded81ada3b6b041909ddf3d49da593478779f91a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/pluginhost/config.go:49-59 | sdk/cliproxy/home_plugins.go:261-270 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/config.go:49\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/config.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"4228a9b8db26e55993012edf720c9d860f9348cda3736c8e0dcb3e013aaac6af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/aistudio_executor.go:400-409 | internal/runtime/executor/claude_executor_tokens.go:221-230 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/aistudio_executor.go:400\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"75c54a746aa9c55cee77b7d04c1e24d1399fea14311d47f8d169ea22f4190f3a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/antigravity_reasoning_replay.go:1456-1465 | internal/runtime/executor/antigravity_reasoning_replay.go:1488-1497 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_reasoning_replay.go:1456\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":1456}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a1fa7e718393b30a367ef416499e0ea3f336416e93d48873f3209def9f99ee4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/claude_executor_cloaking.go:445-454 | internal/runtime/executor/claude_executor_cloaking.go:512-521 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_cloaking.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"719bad1e553f6afc63f322fe39bdbf852c3c7063d7d6bd2ebb6bda91872cdc5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_executor_reasoning.go:746-755 | internal/translator/codex/claude/codex_claude_request.go:408-417 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_reasoning.go:746\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"330e5260135adec1883dda348f20a23dd062c22a76db10a9e2b16aa381aa5f65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_executor_terminal.go:82-91 | internal/runtime/executor/xai_executor_response.go:817-826 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_terminal.go:82\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"c05149d3949491d601fc7eba795c9a8157419c3351924d1947a6db0eec254f3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:94-103 | internal/runtime/executor/codex_openai_images.go:191-200 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"45e78085b542cd3761d7a4ed726b4363b7bda4e4077a6715d82b2d5540f325c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:932-941 | sdk/api/handlers/openai/openai_images_handlers.go:442-451 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:932\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":932}}}],"partialFingerprints":{"codehealthFindingId/v1":"7633764b1968d5beef3793fe45cd3e6891e6142c1b695ed8d41e44fde348e6c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:943-952 | sdk/api/handlers/openai/openai_images_handlers.go:453-463 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:943\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":943}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d8a35ad9ed763daaa5b273e111cc7e3661005b482679aff2a147a455e01fc52"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:435-444 | internal/runtime/executor/xai_websockets_executor.go:1066-1075 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:435\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"f87f998f1e3bf44f525365b59177388177291f90bdc9c265417666aaf44a2284"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:400-409 | internal/runtime/executor/gemini_vertex_executor.go:525-534 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"996289d4fd44f5aebff09a3407281514451dc8451b78c8563e05c6779edb1163"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:591-600 | internal/runtime/executor/gemini_vertex_executor.go:740-749 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:591\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"84981e47c7c78fbd323c9320ba9f54980d23aaa7f4d6cca5a95f5b3a2e03cbc2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:649-658 | internal/runtime/executor/gemini_vertex_executor.go:795-804 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:649\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"202110d12d5db7b261855ecfbff14a143f2a5256e5f69eca0c7d4d2b058188fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:911-920 | internal/runtime/executor/gemini_vertex_executor.go:1002-1011 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":911}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ec7216b0b56176f83b6e0e454b459fe4a556067646d8a1229bf98b40e901479"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:150-159 | internal/runtime/executor/openai_compat_executor.go:358-367 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"e063f6762fc25481486881205b12f0acd7061844d5fee2997dcfd8ba7c4b39db"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:181-190 | internal/runtime/executor/openai_compat_executor.go:272-281 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"0199dd302a5741016c1b8700d926661834c617bea348731fe788610040d0229e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:310-319 | internal/runtime/executor/openai_compat_executor.go:498-507 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f6059b749ae6e71e2094d4297ccd64cbd68cb57f57d4a6e4a55ad61c381da10"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/gitstore.go:737-746 | sdk/auth/filestore.go:439-448 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:737\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dcf9c46dd85552a5f5c939798912a3de984e4dfd5208a41146c6072edd76f41"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/objectstore.go:175-184 | internal/store/postgresstore.go:226-235 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/objectstore.go:175\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc3d8cbebe83a648287c7951dddf9150780696e1e0298cca05640cd4d24b0fbc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/objectstore.go:279-288 | internal/store/postgresstore.go:372-381 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/objectstore.go:279\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/objectstore.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"a255fa4783b6c5913d791498457ee37d78785b7e3efc23f24b458d8ce590b643"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/thinking/apply.go:254-263 | internal/thinking/apply.go:450-459 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/apply.go:254\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"30f42f5298a588e428d2d2cd81300a7dea86f72faa43ad9d4e2bb4dc352917fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/thinking/apply.go:663-672 | internal/thinking/apply.go:723-732 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/apply.go:663\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/apply.go"},"region":{"startLine":663}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca78c247ed19467d1c207270ab656c08ebae2d47b2fe437bad3a711c450d0665"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_response.go:266-275 | internal/translator/gemini/claude/gemini_claude_response.go:113-122 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"01da4b6993719fe589de272cab599a5327fb3a340b231788438f955a8b565050"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/gemini/antigravity_gemini_request.go:219-228 | internal/translator/antigravity/gemini/antigravity_gemini_request.go:248-257 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"98e7ebbf9ce5dd4691fe60cf40d477892ed09770c41799e36667c73bba12007f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:102-111 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:88-97 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:102\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"f606c9e3e08fe5f25a86712eee56f612dea17670a3c0d03681623c125089e185"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:361-370 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:347-356 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:361\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8792d61b95a70f581110a519cf2709bd21f3970c064f58a9b7f0cb312145377"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:381-390 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:373-382 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:381\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed1dea16707d8949b86a996a12c53dae47e6e29f171f514ba136c3b9072ee5b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:591-600 | internal/translator/codex/openai/responses/codex_openai-responses_request.go:46-56 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:591\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5d60b8689429d0975aaa28928821db68cc803199a60bdbe40b0d0d39dc050d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_request.go:484-493 | internal/translator/codex/gemini/codex_gemini_request.go:416-425 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_request.go:484\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"243bad741420d0d8a4e406ed856695e3f853d001bbe14fb33bb16774f806f5e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_response.go:66-75 | internal/translator/claude/openai/chat-completions/claude_openai_response.go:98-107 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"23200be34caa98ada6d31936a879ad211d6d20e9382327d30df45294f195a151"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/claude/openai/chat-completions/claude_openai_response.go:50-59 | internal/translator/claude/openai/responses/claude_openai-responses_response.go:103-112 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/chat-completions/claude_openai_response.go:50\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffb204f6f81702b9e577a9bfb4b6723ab5ac3e6aba1cd806427bb800ca3d4b7c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_request.go:304-313 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:719-728 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/responses/claude_openai-responses_request.go:304\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf04ca178bf13a6f691bdb6804497cfb82a97a65360f09ac2611333269b7a5dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:310-319 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:369-378 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6c6081f029ad8c5ea6533a60669e0a19f9bf2b5a9a89f6c915a04411c026d22"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/codex/claude/codex_claude_request.go:575-584 | internal/translator/codex/claude/codex_claude_response.go:817-826 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/claude/codex_claude_request.go:575\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_request.go"},"region":{"startLine":575}}}],"partialFingerprints":{"codehealthFindingId/v1":"3adeb4cb6dd8be69e64b607ebca989f3c6e524655d516b460dc2426e3e753566"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/codex/gemini/codex_gemini_request.go:54-63 | internal/translator/codex/gemini/codex_gemini_response.go:395-404 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/gemini/codex_gemini_request.go:54\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcd573f328c0eb6b232da3b01b718a88793a3efcf752d4ae595bffb6942784c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/gemini/claude/gemini_claude_response.go:311-320 | internal/translator/openai/claude/openai_claude_response.go:640-649 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/claude/gemini_claude_response.go:311\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_response.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1ffbfe0e968a16e988d1fe01d77510c921432f380053783c31e81d6f7ca9c5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/translator/gemini/interactions/interactions_gemini_common.go:237-246 | internal/translator/gemini/interactions/interactions_gemini_common.go:689-698 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/interactions/interactions_gemini_common.go:237\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"7712b9c0063b31f272dccc4ff545166e17bcb9bdfe43180ad77892f221b531e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/watcher/clients.go:115-124 | internal/watcher/clients.go:249-258 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/clients.go:115\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/clients.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"a36291b31d54286cd0620d2a666ff205a7b6a88c97cb200ddee6954b0b00b9bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/watcher/synthesizer/config.go:310-319 | internal/watcher/synthesizer/config.go:350-359 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/config.go:310\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4a5dcf71533af202d812cef07db96d7aa729a569563eb3a88f7bae37aadfb32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/watcher/synthesizer/file.go:318-327 | internal/auth/claude/identity.go:58-68 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/file.go:318\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/file.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaa025b2bccb1015f2eb4769c269b3ac376b93aacb586d7d70cd32ee34867e13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/api/handlers/claude/code_handlers.go:493-502 | sdk/api/handlers/handlers.go:566-576 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/claude/code_handlers.go:493\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"06372ee3ab04f738df3e1d5568e0d084699481917bcea1e2812d52b6531765fc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:861-870 | sdk/api/handlers/openai/openai_images_handlers.go:998-1007 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:861\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"638a097b972164f11645e578903aa3bd204081b3289092506cacc754ff66bfa3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/api/handlers/openai/openai_responses_handlers.go:253-262 | sdk/api/handlers/openai/openai_responses_handlers.go:279-288 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_responses_handlers.go:253\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_handlers.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9db6a983490783f4425d602a9e7d100bae726e70c175cfb3593e26ab765a685"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:657-666 | sdk/cliproxy/auth/conductor_selection.go:717-726 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:657\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":657}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1654288bb3971d3c03c136276d4153437311303cd771148464172a643048e6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:1147-1156 | sdk/cliproxy/auth/conductor_selection.go:1194-1203 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:1147\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1147}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9a6b55e6ed4a25645687fd3f2ebae9c45bd6e21a324853f9f18d113f87f1bdb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): sdk/cliproxy/service_models.go:433-442 | sdk/cliproxy/service_models.go:462-471 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/service_models.go:433\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ed1f6db05cc3c98bff124b1a97248fe49d22b3063f625cb0400417a892118f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/config/config_yaml.go:18-28 | internal/config/config_yaml.go:88-97 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"beb757a0ccb0201b4fe73a0bfe672fd94834d728624dcd636632814904e6140e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/config/config_yaml.go:70-79 | internal/config/config_yaml.go:122-131 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config_yaml.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"b725a0513c31aa82919a3d1b4e35898985da000f8d1918addfccfd85c115f546"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 6): internal/api/handlers/management/config_lists.go:195-203 | internal/api/handlers/management/config_lists.go:544-552 | internal/api/handlers/management/config_lists.go:719-727 | internal/api/handlers/management/config_lists.go:872-880 | internal/api/handlers/management/config_lists.go:1241-1249 | internal/api/handlers/management/config_lists.go:1425-1433 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:195\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"62054d9f4aafed20173bceafb6c8accd9e01d509165ba9b5fb8df065942b6c1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 5): internal/runtime/executor/gemini_executor.go:101-109 | internal/runtime/executor/gemini_vertex_executor.go:225-233 | internal/runtime/executor/kimi_executor.go:73-81 | internal/runtime/executor/openai_compat_executor.go:77-85 | internal/runtime/executor/xai_executor.go:100-108 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb13f33ac639e02743de2038273fb2184764a0c1a8957faf0546116741a84eeb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 5): internal/runtime/executor/gemini_executor.go:222-230 | internal/runtime/executor/gemini_vertex_executor.go:414-422 | internal/runtime/executor/gemini_vertex_executor.go:539-547 | internal/runtime/executor/kimi_executor.go:185-193 | internal/runtime/executor/openai_compat_executor.go:195-203 \u2014 there are 5 copies across 4 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:222\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"5811bc766ad97e95839e25a65602021c7e430a9ac9d883a5f64e3211e6baad2a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/store/gitstore.go:412-420 | internal/store/objectstore.go:195-203 | internal/store/postgresstore.go:246-254 | sdk/auth/filestore.go:117-125 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:412\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"215bf75d87a41b046554730d1d7078db533aabc0bbbb210756beff82121fcd3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): sdk/cliproxy/auth/conductor_selection.go:1037-1045 | sdk/cliproxy/auth/conductor_selection.go:1256-1264 | sdk/cliproxy/auth/conductor_selection.go:1360-1368 | sdk/cliproxy/auth/conductor_selection.go:1443-1451 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1037}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d25d2676dc3c9e9cf3fa1f04d2b58ced4abb5fa7c3cd0a126c8ff8d4e40e11f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/auth/vertex/keyutil.go:151-159 | internal/auth/xai/token.go:88-96 | internal/logging/request_logger_body_source.go:44-52 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/vertex/keyutil.go:151\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/vertex/keyutil.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"50d0fdfd65b51a21229e5d36625dc9570b1ae640c264127e258d28de98a1afce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/runtime/executor/codex_executor_reasoning.go:380-388 | internal/runtime/executor/codex_executor_reasoning.go:519-527 | internal/runtime/executor/xai_reasoning_replay.go:142-150 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_reasoning.go:380\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_reasoning.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"f29eb2738093f698f3914460872e978e552abb370a2dea3ffde290f87a593b21"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/runtime/executor/gemini_executor.go:287-295 | internal/runtime/executor/gemini_executor.go:482-490 | internal/runtime/executor/gemini_vertex_executor.go:749-757 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"eef9f85149359b00145616798b95b7f80b8fb51bec187349adf79d97a5e3ad6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/gitstore.go:644-652 | internal/store/objectstore.go:569-577 | sdk/auth/filestore.go:228-236 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:644\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":644}}}],"partialFingerprints":{"codehealthFindingId/v1":"031e24d4e0a0580bf9db8e615dc011df04deb8dee1b1855022c21117e6e1f13c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/translator/antigravity/interactions/interactions_antigravity_response.go:234-242 | internal/translator/codex/interactions/interactions_codex_response.go:295-303 | internal/translator/gemini/interactions/interactions_gemini_common.go:1136-1144 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"fca0d86644da1eb47dbd1cad1b5fda2e4fe8e82c015b793383be286f2a4fae0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/translator/codex/gemini/codex_gemini_request.go:180-188 | internal/translator/codex/gemini/codex_gemini_request.go:253-261 | internal/translator/codex/openai/chat-completions/codex_openai_request.go:454-462 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/gemini/codex_gemini_request.go:180\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b8b6cc436d85a073047a2f1f35fe877b19d4a8fce1cafcd8bfe9dcc6dcf274a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/translator/openai/claude/openai_claude_response.go:460-468 | internal/translator/openai/claude/openai_claude_response.go:681-689 | internal/translator/openai/claude/openai_claude_response.go:738-746 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/claude/openai_claude_response.go:460\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"43a2ac0355183ecb5d0648d858c0f96c867a7792564bd42310f8ee734b544397"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/api_tools.go:610-619 | sdk/cliproxy/auth/conductor_models.go:880-888 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/api_tools.go:610\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ec800cc3da1d61e11feb5bcb9f1436d3d9dbc610536d2eee8c7889bed5607ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:668-676 | sdk/auth/kimi.go:90-99 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:668\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6e037c6e61fe2cb75559cc8e6747e34c4812b1c4110c4caa6e57214a7e4f8ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/logs.go:630-638 | internal/api/handlers/management/logs.go:1181-1189 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/logs.go:630\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/logs.go"},"region":{"startLine":630}}}],"partialFingerprints":{"codehealthFindingId/v1":"f603df9c4a964595fb8058838a3861c06deb79cc66c5a4565f6d0672eb5f2640"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/plugin_store.go:137-145 | internal/api/handlers/management/plugin_store.go:243-251 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/plugin_store.go:137\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugin_store.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad5e2ab775c46734aba6965d6f2492dcc66b5ae219612cc051c8d4f04f89506d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/middleware/request_logging.go:373-381 | internal/api/middleware/request_logging.go:405-413 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/middleware/request_logging.go:373\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/middleware/request_logging.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffbc9c698821d62b7c5ff3d5f6f5ecd87547b6a6821d78e1329378f7f06b7705"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/server_routes.go:383-391 | internal/client/codex/live/live.go:290-298 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/server_routes.go:383\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9b58947c87d15cd926d57da86dbbabf96c63c72d83864eb6a7de0493db62277"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/httpfetch/httpfetch.go:50-58 | internal/pluginstore/github.go:275-283 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/httpfetch/httpfetch.go:50\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/httpfetch/httpfetch.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"d50e25311bec9a467ec9552c9960790336f379abb17c99264f72edb076efc35e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/pluginhost/adapters_executors.go:652-660 | internal/pluginhost/adapters_executors.go:778-786 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:652\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"d92a14da59ff88f8953ecb7d9e2d2c673e5e415ac0439ed5a62c4b0bf120fd8f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/pluginhost/host.go:218-227 | internal/pluginhost/host.go:232-240 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/host.go:218\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/host.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e13f7cd0012ff55b82c6595128537c6f432d239121283bb58b58a1809a54f0c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/pluginstore/github.go:69-77 | internal/pluginstore/github.go:96-104 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginstore/github.go:69\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginstore/github.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc49572e3bdb26d81d321eba8ef17c9d469f42b2e7ca7880b28bf37fd7e171d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/claude_executor.go:239-247 | internal/runtime/executor/codex_executor_request.go:67-75 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2a10029bdc8c8b6155c8ed8ab45bbf236ad3b78107831a52c9e4be20d72f2ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1351-1359 | internal/runtime/executor/claude_executor_request.go:1537-1545 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1351\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1351}}}],"partialFingerprints":{"codehealthFindingId/v1":"77fc6c74b0e36139aeb50fe586e14fce57511d5deef5d578d0c5887c1f0a261f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1405-1413 | internal/runtime/executor/claude_executor_request.go:1585-1593 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1405\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1405}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c0ffe8bb6b63e0dfa57bbb91955f3ffc4f37266357f83bb15495b2f4548b7f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/codex_executor_terminal.go:37-45 | internal/runtime/executor/xai_executor_response.go:803-811 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bd4448b49f704ee42937660dbe4e7291c7359877f28329f2b7278ff03e4cfbf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:226-234 | internal/runtime/executor/codex_openai_images.go:417-425 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"df273e474d03edb8576145536614e242916c306d8f3cbe02d4321ccfaf7a1572"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:658-666 | internal/runtime/executor/xai_websockets_executor.go:1354-1362 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcd70bc21fff1046217bcbf9ddac93b00209d3da18d60c3a3b98a11290766355"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/gemini_executor.go:731-739 | internal/runtime/executor/gemini_vertex_executor.go:1114-1122 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:731\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":731}}}],"partialFingerprints":{"codehealthFindingId/v1":"54915ec4428cad6a42bb2ba784427ddd6aa85183fbd3c741589a49b24260f297"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:231-239 | internal/runtime/executor/openai_compat_executor.go:512-520 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:231\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"957e1b30ef15aced45b16f6b4a0e42d2aee1931d7813b99cf42ef83dfd7ef10a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:740-748 | sdk/api/handlers/openai/openai_images_handlers.go:523-531 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:740\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"14687625bcda879ae319a77fe08e5d6a451eff04fb0c65f91b6f25fc4fec9885"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/xai_executor_request.go:1048-1056 | internal/runtime/executor/xai_executor_response.go:92-100 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/xai_executor_request.go:1048\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_executor_request.go"},"region":{"startLine":1048}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0d923e4cfb5e631a30fd2c3920849ec55849ec22b0b1234258d816376f8ead4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/signature/claude.go:25-33 | internal/signature/claude_messages_sanitize.go:76-86 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/signature/claude.go:25\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/signature/claude.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f92f0aee5b8c0e9d6880212742b142184b9b4bb1528ca62655a7ce8c5d4863c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/gitstore.go:676-684 | sdk/auth/filestore.go:340-348 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/gitstore.go:676\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/gitstore.go"},"region":{"startLine":676}}}],"partialFingerprints":{"codehealthFindingId/v1":"3daf1117447fc518fc77670f42b608fd3e88da9de10a5601b6e4733d405e2a90"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/thinking/provider/antigravity/apply.go:41-49 | internal/thinking/provider/gemini/apply.go:65-73 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/antigravity/apply.go:41\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/antigravity/apply.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"578abd43eb2d62335af6c0128250f06ad36f34efb20303ca060a181aead45487"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:340-348 | internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:357-365 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:340\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":340}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca870b57db40867c7f7452bde5ff2ea8cac8e44cbdb8fd9a55171d9500e1e53a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:103-111 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:118-126 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:103\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cf4ae5f8eae015c39a9220d28721979654cfe549786a3d5c0821b3d3b80ba76"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_request.go:128-136 | internal/translator/claude/openai/chat-completions/claude_openai_request.go:148-156 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_request.go:128\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb4f2e1d0aa078c293241f7f02a8b6aa402828e3452cd5af4a315db70bf69870"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_response.go:184-192 | internal/translator/claude/gemini/claude_gemini_response.go:433-441 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_response.go:184\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c44576b199c9d46435851205e1fb5b19eab21eee33fb1405916dec617f7a4cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/codex/gemini/codex_gemini_request.go:288-296 | internal/translator/codex/gemini/codex_gemini_request.go:299-307 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/gemini/codex_gemini_request.go:288\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_request.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"77b24a8e57ea199d7784d913bfbe85e296e6567897541f22897b4d671dbc0c42"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_response.go:202-210 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:338-346 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d14e25273c104dae40ec1e4c8ebb39fca961c01306872037df95483e538364c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/common/bytes.go:88-96 | internal/translator/common/bytes.go:100-108 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/common/bytes.go:88\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/common/bytes.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"3315fd56d89f8738a37600f15a0c7d639e53a75df471e8617b171b1f72c63b1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/gemini/gemini/gemini_gemini_request.go:235-243 | internal/translator/gemini/gemini/gemini_gemini_request.go:273-281 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/gemini/gemini_gemini_request.go:235\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf22b933610f412e6247cdad578989fb1389b7f97a84d1292c7ecec7e5ba78f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/gemini/interactions/interactions_gemini_common.go:185-193 | internal/translator/gemini/interactions/interactions_gemini_common.go:649-657 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_common.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"6feef14d014baa95991cefb50c44fd0b51f952488b35d18fe170dbca0765fb71"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/gemini/interactions/interactions_gemini_response.go:265-273 | internal/translator/openai/gemini/openai_gemini_response.go:641-649 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/interactions/interactions_gemini_response.go:265\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/interactions/interactions_gemini_response.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"af18881609f1f409a35948261ce0946f24b49cdce2fb104940b6480818b9a9c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:47-55 | internal/translator/gemini/openai/responses/gemini_openai-responses_request.go:378-386 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:47\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"d44e14e91b238a7aced8582d880a8d79ea48708d05d7efca8e4b36da3566abc4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:327-335 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:344-352 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:327\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e5f57fa58e7b67b7dcfa1b9132c1543d7febe57162b445723b684396c77f43d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/translator/interactions/claude/interactions_claude_response.go:330-338 | internal/translator/openai/interactions/chat-completions/openai_interactions_response.go:283-291 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/interactions/claude/interactions_claude_response.go:330\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/interactions/claude/interactions_claude_response.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"92265ee84c2bc72b7788eefdb85388630094898d3ae7592bc3bbb9284e095da3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/tui/auth_tab.go:147-155 | internal/tui/keys_tab.go:266-274 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/tui/auth_tab.go:147\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/auth_tab.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"69db42c588540c0065c03dcb930bd84e02635aaf4c028c54c5a8344f1f461313"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/tui/auth_tab.go:360-368 | internal/tui/keys_tab.go:164-172 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/tui/auth_tab.go:360\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/auth_tab.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"72215b14a073ecd3fcec0ea389b1438e69805c78e8fb9954aa2a639c66dd41c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/claude/code_handlers.go:126-134 | sdk/api/handlers/gemini/gemini_handlers.go:268-276 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/claude/code_handlers.go:126\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/claude/code_handlers.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"581c47e14820503da5085f751c449ebc1c3f73edc02a017a91cf09a2d21aee04"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/gemini/interactions_handlers.go:191-199 | sdk/api/handlers/openai/openai_handlers.go:675-683 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/interactions_handlers.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"19db71bd090fdf7462ff4d0752dd25ab41bbc3d1a804edc87818fb91dea52854"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:91-99 | sdk/api/handlers/handlers_execution.go:155-163 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"d939d86e6d72dc00e9062759d4069e893dacf3f8de18d638ff5f657ecbe014eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/openai/openai_handlers.go:265-273 | sdk/api/handlers/openai/openai_handlers.go:365-373 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_handlers.go:265\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"110c57dc56a46920afc44f9e5d7dd242536d8062c4dd4887309fee73ff0c0919"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/openai/openai_handlers.go:541-549 | sdk/api/handlers/openai/openai_responses_handlers.go:483-492 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c30ec576015ada2f3de5d1f19cc3543f6e550bee18382bb4acdba134d0c4468"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:144-152 | sdk/api/handlers/openai/openai_images_handlers.go:172-180 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:144\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c4321b563e50bdf18e70dda9225e3c9f7820eb9a0c7765b677719af231118e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/cliproxy/auth/conductor_home.go:1104-1112 | sdk/cliproxy/auth/conductor_home.go:1159-1167 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"681af355f17eccaf42d5144091ac502a89af8b40931ee5113f420e57407ac32e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:573-581 | sdk/cliproxy/auth/conductor_selection.go:1381-1389 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:573\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"0688941576a126b9c5f06e7242919db9b7178cd415220f0a979a21cf36a98f31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:1128-1136 | sdk/cliproxy/auth/conductor_selection.go:1174-1182 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:1128\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":1128}}}],"partialFingerprints":{"codehealthFindingId/v1":"056eea90e55b04af2b9697140c86ea56ebb75c8886ac8eb40d1a886753251d67"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): sdk/cliproxy/service_models.go:209-217 | sdk/cliproxy/service_models.go:231-239 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/service_models.go:209\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/service_models.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"162c566b33942e3b8aa0ed07205f4cf494257668cf09e63b5da2b4504e89eecf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/auth_files_crud.go:28-36 | internal/api/handlers/management/auth_files_crud.go:111-119 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_crud.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a220c273df60a76a39df193f1a0ac5dfb3c914e933f27b990db812f03bf6a3a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/config_lists.go:573-581 | internal/api/handlers/management/config_lists.go:1270-1278 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:573\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"31346628a8fdd1ba2a0c0adaac4c86106bfc97f63bc1dd5808e90e26fccbd37d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/config_lists.go:1046-1054 | internal/api/handlers/management/config_lists.go:1074-1082 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:1046\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1046}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cc6ad8ca5aaec7b02843249c741e543474e10cb568c3197f14962f18125e2c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/config_lists.go:1140-1148 | internal/api/handlers/management/config_lists.go:1171-1179 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:1140\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1140}}}],"partialFingerprints":{"codehealthFindingId/v1":"b35553bc886f8a70df7e3bd1ddf2a7c70b9c3a6d0e8bcc52e7988d5885589230"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/api/handlers/management/config_lists.go:1602-1610 | internal/api/handlers/management/config_lists.go:1628-1636 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:1602\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1602}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8b3858ad2527675de357d24acbd0f4ba17206b71c51bdac148b2b125a48927c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:268-276 | internal/runtime/executor/antigravity_executor_stream.go:38-46 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:268\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff74a7c090f5413a1c16ac5aa3c141243a4670530f66349f99840cba109e8e2d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/modelconfig/model_hash.go:16-23 | internal/modelconfig/model_hash.go:31-38 | internal/modelconfig/model_hash.go:46-53 | internal/modelconfig/model_hash.go:61-68 | internal/modelconfig/model_hash.go:76-83 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/modelconfig/model_hash.go:16\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/modelconfig/model_hash.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c230bae0e603242e36a58b24330ba881f87cd27b3fcf9611f21ea6a16873c57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/translator/interactions/claude/interactions_claude_response.go:320-327 | internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:308-315 | internal/translator/openai/interactions/chat-completions/openai_interactions_response.go:311-318 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:889-896 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/interactions/claude/interactions_claude_response.go:320\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/interactions/claude/interactions_claude_response.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"76209b599111f79bb4a36dbc29849325e32b2f05f03f7d8e4f3f9221584f210a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/api/server_routes.go:131-138 | internal/api/server_routes.go:145-152 | internal/api/server_routes.go:159-166 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/server_routes.go:131\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"adea086dd89ab97dc783ac31fc186b41da0c3f1dec7d5ec668ffe2166a78ec5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/runtime/executor/gemini_executor.go:329-336 | internal/runtime/executor/kimi_executor.go:304-311 | internal/runtime/executor/openai_compat_executor.go:403-410 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:329\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"79e166b2c6091be2612aa7c24159c6468cddbea384beb1a30fcf2ca60a2f38aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/runtime/executor/gemini_executor.go:339-346 | internal/runtime/executor/gemini_vertex_executor.go:661-668 | internal/runtime/executor/gemini_vertex_executor.go:807-814 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:339\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"969dbd74eea71cb9f0c5e05819358852a2327c6eaab83943100ab74b158ec30c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/translator/antigravity/claude/antigravity_claude_response.go:601-608 | internal/translator/gemini/claude/gemini_claude_response.go:314-321 | internal/translator/openai/claude/openai_claude_response.go:643-650 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_response.go:601\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"acac1eb74030d4929f8386fe6a4ffb504c670d55d71a665622a776c598cc4f16"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/translator/claude/openai/responses/claude_openai-responses_response.go:629-637 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:759-767 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:133-140 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/responses/claude_openai-responses_response.go:629\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":629}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4ff8bab8286328a4bfad47210bbe3eef7909c3c6a38e3ee132a7e10656e0379"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/translator/gemini/gemini/gemini_gemini_request.go:173-180 | internal/translator/gemini/gemini/gemini_gemini_request.go:234-241 | internal/translator/gemini/gemini/gemini_gemini_request.go:272-279 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/gemini/gemini_gemini_request.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"30b1d2ebd310f60e05ec25459455ff691ef7f37331b4c52abec7ae1786a27e56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/util/gemini_schema.go:130-137 | internal/util/gemini_schema.go:165-172 | internal/util/gemini_schema.go:458-466 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/util/gemini_schema.go:130\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/util/gemini_schema.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfee78b292ffc1a1146e4de694f02289c0525666bbda455837f817c7633249dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): examples/plugin/claude-web-search-router/go/execution_fallback.go:145-152 | examples/plugin/claude-web-search-router/go/execution_fallback.go:157-164 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"examples/plugin/claude-web-search-router/go/execution_fallback.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"42cc8a23664b00f699cb1758579cfa719e296b57f5c8abee5dfa1a178d6feada"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/api/handlers/management/api_tools.go:602-609 | sdk/cliproxy/auth/conductor_models.go:872-879 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/api_tools.go:602\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/api_tools.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb90420d0e837bd583dd22296f49bbd941ab94121e71662af9832ec899d4f6ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/api/handlers/management/auth_files_provider_oauth.go:610-617 | internal/api/handlers/management/auth_files_provider_oauth.go:708-715 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/auth_files_provider_oauth.go:610\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_provider_oauth.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"62d7b0f974a8fe6ab53a42e2712feb8624ef0fabb85743a041a990911d2fed91"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/api/handlers/management/plugins.go:702-709 | internal/pluginhost/config.go:210-217 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/plugins.go:702\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f4b605c7b4f9d72faf450f8efd4dfa1e1259fc075df868969af72d442fae1b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/auth/kimi/kimi.go:189-196 | internal/auth/kimi/kimi.go:379-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/kimi/kimi.go:189\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/kimi/kimi.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f533aea6015cb67e60fed02918058f785aadae4a92d3a592c7a92507734a487"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/cache/codex_reasoning_replay_cache.go:267-274 | internal/cache/xai_reasoning_replay_cache.go:164-171 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cache/codex_reasoning_replay_cache.go:267\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/codex_reasoning_replay_cache.go"},"region":{"startLine":267}}}],"partialFingerprints":{"codehealthFindingId/v1":"121d629da8504c04ae3824a211072b4528dc5fb685f8522ea491cc800fff4f56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/cache/codex_reasoning_replay_cache.go:419-426 | internal/cache/xai_reasoning_replay_cache.go:340-347 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/codex_reasoning_replay_cache.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"d511e17f8bcfb60f0f67292744f108236a2f2c984b404804fa018a0622e85f00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/cache/codex_reasoning_replay_cache.go:434-441 | internal/cache/xai_reasoning_replay_cache.go:355-362 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cache/codex_reasoning_replay_cache.go:434\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/codex_reasoning_replay_cache.go"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f6e610424fd1d806c2d8d5a2f60c5d7b05e4c8db9a18e228ed5db5be6bb7a77"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/cmd/openai_login.go:56-63 | internal/cmd/openai_device_login.go:44-51 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cmd/openai_login.go:56\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cmd/openai_login.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dcafc27b085b1df18639088a36ac6257c43c0b55e32758b19692d227d4680df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/config/vertex_compat.go:92-99 | internal/config/config_normalization.go:185-192 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/vertex_compat.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"24627fa2a41b2ceb07af2d386022adda8d577368099f9ae373f815691f73925e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/homeplugins/sync.go:576-583 | internal/pluginhost/platform.go:48-55 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/homeplugins/sync.go:576\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/homeplugins/sync.go"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"51338b19acf8cf153b3dbbcd53f89b3d7d3c35363c8e9c19b1f198f9731a418f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/pluginhost/adapters_executors.go:702-709 | internal/pluginhost/auth_provider.go:349-356 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:702\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"82e2c9bbc27316c36fd40265105e3cbbda1892f87336364c6a8a4079f1ee3a52"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/pluginhost/adapters_executors.go:716-723 | internal/pluginhost/auth_provider.go:363-370 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:716\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":716}}}],"partialFingerprints":{"codehealthFindingId/v1":"921652d038b47de0568666a3b6786361727a69477a3564fc78625b2abbe062c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/pluginhost/adapters_interceptors.go:177-184 | internal/pluginhost/adapters_interceptors.go:209-216 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_interceptors.go:177\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_interceptors.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cccfa37c5e4d61069a5600aa41f6b9da82b47ec8a2eceeb9d3df7e4deddfa15"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/pluginhost/adapters_interceptors.go:475-482 | internal/pluginhost/adapters_interceptors.go:485-492 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_interceptors.go:475\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_interceptors.go"},"region":{"startLine":475}}}],"partialFingerprints":{"codehealthFindingId/v1":"15227fdbcbd3fc4bda9d92af693692b040a70b515a342b5f87b925b249b62609"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/aistudio_executor.go:274-281 | internal/runtime/executor/aistudio_executor.go:339-346 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/aistudio_executor.go:274\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee80527b128f43ebd32654c2e4bdb9c82eb69e955bebe76e1e7a629c6b8af17c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/aistudio_executor.go:455-462 | internal/runtime/executor/gemini_vertex_executor.go:323-331 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d8316c0632044e3ce3f33091341b27d674512906b54ee301337ba1f1a1281fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/antigravity_reasoning_replay.go:160-167 | sdk/cliproxy/session/identity.go:473-480 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_reasoning_replay.go:160\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"663fdb6ed4c4a76b855cc44044a662d52f74bf23a6bf72f398c32206675faaa5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/antigravity_reasoning_replay.go:547-554 | internal/runtime/executor/antigravity_reasoning_replay.go:1380-1387 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_reasoning_replay.go:547\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_reasoning_replay.go"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"5adf7800c02ed2e2ff9fd2a29e3e20586e0ed9d6c109ef7af1cc0410da21d809"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:987-994 | sdk/api/handlers/openai/openai_images_handlers.go:1665-1672 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:987\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":987}}}],"partialFingerprints":{"codehealthFindingId/v1":"62634042b7c65860bfac2e3b997b154496effec6f52f084cb91651b97d062221"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:1034-1041 | sdk/api/handlers/openai/openai_images_handlers.go:1705-1712 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:1034\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":1034}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d976647b7568840ed86b984cf207d034217ed6a158ab0f2320764ab326c7e09"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/codex_websockets_session.go:188-196 | internal/runtime/executor/xai_websockets_executor.go:1151-1158 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_websockets_session.go:188\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_session.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"038e912b6baf764c08eac17929dc3a7b407e0c7f2273e613742311efcd75e8d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:858-865 | internal/runtime/executor/gemini_vertex_executor.go:949-956 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":858}}}],"partialFingerprints":{"codehealthFindingId/v1":"c945b6e07e1f7b02bfc0aec1ecf67a06bbe342461e140f17bc2a70416fe2a6cf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:93-100 | internal/runtime/executor/openai_compat_executor.go:308-315 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:93\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed835d3d9f69cde0174e0149699ade6220a43b38880b396aaedd830137b01f5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:215-222 | internal/runtime/executor/openai_compat_executor.go:496-503 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:215\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dde4008e4af7720464a02132b3bc34c3b1b76746aa96bacf9e6895facd2419f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/thinking/provider/claude/apply.go:93-101 | internal/thinking/provider/claude/apply.go:247-254 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/claude/apply.go:93\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"364b704be31b85a87067f88391c4ff9ea36e768d2f79c3f17eb4f149bbc0b1e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_request.go:659-666 | internal/translator/antigravity/claude/antigravity_claude_request.go:693-700 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_request.go:659\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":659}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0743f43a13738b1e6b32b68487f881b3758b200c2b8f4f1878c2dbddbdfcf01"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/gemini/antigravity_gemini_request.go:124-131 | internal/translator/gemini/gemini/gemini_gemini_request.go:52-59 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/gemini/antigravity_gemini_request.go:124\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/gemini/antigravity_gemini_request.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"40562a70cf1d646458066e026a42505bcdbb2c0cf1bd7beeb8cd7ac64f32da50"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:213-220 | internal/translator/gemini/interactions/interactions_gemini_common.go:1116-1123 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:213\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"88bbde270d00ead4f6004c12e71b8c6856a89a11a687c088a9597a007d64ec8a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:332-339 | internal/translator/gemini/interactions/interactions_gemini_common.go:1253-1260 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:332\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"83c72be85ad631c24b17ccb32c0cdea56c491f19012b6f439af0629c96afe67c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:190-197 | internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:235-242 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:190\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"27f8bc8fbbaae428eb75dcbc657e20bf81ad841a8c927d6065bc7277198ea043"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:253-260 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:247-254 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:253\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"ace1265ac26db01549bed3345f11211ac467e833223a7c4d23791e4621823b2b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:120-127 | internal/translator/gemini/claude/gemini_claude_response.go:110-119 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:120\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab196b4349bca0302ebb6fb23932b68cb1332b971dd0f087b69635a5b7520234"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/claude/gemini/claude_gemini_response.go:124-132 | internal/translator/claude/gemini/claude_gemini_response.go:379-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/gemini/claude_gemini_response.go:124\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_response.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4ce8d92b96a1c5442e592b700970e45d511b955fe199013d39270d3d370d4e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/claude/openai/chat-completions/claude_openai_response.go:330-338 | internal/translator/claude/openai/responses/claude_openai-responses_response.go:800-807 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/chat-completions/claude_openai_response.go:330\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"13bb19deac9afa06f46c495bc451f8025c027d5fabd57ee1e6c279d5597e3219"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:659-667 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:653-660 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/responses/claude_openai-responses_response.go:659\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":659}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a07bc8d345bc4984efe39df8744e03025aade70f3e1050c21941a32ebf297e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/codex/gemini/codex_gemini_response.go:111-118 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:263-270 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/gemini/codex_gemini_response.go:111\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/gemini/codex_gemini_response.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"207af76b8e770c5dbaf4b9444f310e80d698070618ce218a669dcf0761f68f4b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/codex/interactions/interactions_codex_response.go:424-431 | internal/translator/codex/interactions/interactions_codex_response.go:447-454 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/interactions/interactions_codex_response.go:424\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/interactions/interactions_codex_response.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba49adda2b168ee66d8543cad97a6409b869160d64ecae3573806f455edb8b65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_request.go:346-353 | internal/translator/codex/openai/chat-completions/codex_openai_request.go:358-365 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_request.go"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eee34fef8b74b6f90e52f1f3989855687175169fa88133a5f7f7eea9a6be1a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:178-185 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:230-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:178\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"01cb5c70632034d7272b522059a2f18429b56663de40e5bc841d3db3b1aa9555"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:160-167 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:352-359 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:160\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"51a9edb893e7cca0b09cdd047a374fa079b2405b9c04c48bc675e9d04101bd1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/interactions/claude/interactions_claude_response.go:109-116 | internal/translator/openai/interactions/chat-completions/openai_interactions_response.go:101-108 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/interactions/claude/interactions_claude_response.go:109\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/interactions/claude/interactions_claude_response.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"0033506f8239a2add3026bdb671cf843f90182bef1d52fb905576e65ea069cf0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/translator/openai/openai/responses/openai_openai-responses_response.go:530-537 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:599-606 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/openai/responses/openai_openai-responses_response.go:530\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e0d2455d0948ef05dd48442c3d53292c6f29005a800432ff30ec076b66e9ee7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/watcher/diff/models_summary.go:37-44 | internal/watcher/diff/models_summary.go:58-65 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/diff/models_summary.go:37\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/models_summary.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"3169cb891222985b8e919877cfb915bfa06042deab6aeaa969a039008b4e75e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/watcher/diff/oauth_excluded.go:57-64 | internal/watcher/diff/oauth_model_alias.go:41-48 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/oauth_excluded.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e23d1540ae1e328dd3fc73db4435822cd52b547aa804305594ba4b311ceb944"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/watcher/synthesizer/file.go:239-246 | sdk/auth/filestore.go:363-370 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/watcher/synthesizer/file.go:239\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/file.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"5950c21a80ee27f7ae2d5931d1961a5ba3920d52fde08366939e4bab82081752"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:191-198 | sdk/api/handlers/handlers_execution.go:225-232 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9dc98b9a608097e21eb419f6269b727c647e746dc84d4255971906a9057ae2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:1579-1586 | sdk/api/handlers/openai/openai_responses_handlers.go:290-297 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:1579\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1579}}}],"partialFingerprints":{"codehealthFindingId/v1":"763d8ad8fb5ae1ec54ae6cc73430033ba902cd4cf55f4d3fdb160ed3a26751cf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:353-360 | sdk/cliproxy/auth/conductor_execution.go:480-487 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:353\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"db7df9313172ba79b1be0e0918f897097003afb29ab146b6fd4a49d762eb8564"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/auth/conductor_models.go:402-409 | sdk/cliproxy/auth/conductor_models.go:558-566 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_models.go:402\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_models.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a20224a45901b8ae25db90952b4cec3127f62f1993cd0c3c0d4cc460553f45f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/auth/conductor_selection.go:114-121 | sdk/cliproxy/auth/conductor_selection.go:836-843 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_selection.go:114\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_selection.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bf98496ce5f4d1d81c07f309fb514b120ebaec43bd5de0d3148a32656622bd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/auth/conductor_stream.go:233-240 | sdk/cliproxy/auth/conductor_stream.go:283-290 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_stream.go:233\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"6904ba25abd333d77a052e33b89f0f2970a53a12f9b521d6b1cfb5238deab148"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/auth/scheduler.go:1056-1063 | sdk/cliproxy/auth/scheduler.go:1070-1077 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/scheduler.go:1056\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/scheduler.go"},"region":{"startLine":1056}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d92d73b659e35537113f191d02f1c2f55cf28db0728cd2e7cb13694ae6a0b41"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): sdk/cliproxy/executionregistry/registry.go:391-399 | sdk/cliproxy/executionregistry/registry.go:450-457 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/executionregistry/registry.go:391\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/executionregistry/registry.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa928ea308f0cb36b4e520c458683dd15c2013928ab57c36bde15211dabc3b8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/api/handlers/management/config_lists.go:1614-1621 | internal/api/handlers/management/config_lists.go:1640-1647 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1614}}}],"partialFingerprints":{"codehealthFindingId/v1":"01288a72a1cc7936a52059b8b45f2e59093dcbcd62354307a05248f2be1e94a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/cache/antigravity_reasoning_replay_cache.go:635-641 | internal/cache/codex_reasoning_replay_cache.go:474-480 | internal/cache/kimi_thinking_replay_cache.go:404-410 | internal/cache/xai_reasoning_replay_cache.go:395-401 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cache/antigravity_reasoning_replay_cache.go:635\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cffe0af79e7072d16fbc47561a5d1701750d3438fc31de2eeccca856c1cdb98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/translator/claude/openai/chat-completions/claude_openai_request.go:242-248 | internal/translator/openai/claude/openai_claude_response.go:456-462 | internal/translator/openai/claude/openai_claude_response.go:677-683 | internal/translator/openai/claude/openai_claude_response.go:734-740 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/chat-completions/claude_openai_request.go:242\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_request.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9f8d691b2238424b290ed03da1d8773f6973417621c7d5655494c15851e5796"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/runtime/executor/gemini_executor.go:624-630 | internal/runtime/executor/gemini_vertex_executor.go:857-863 | internal/runtime/executor/gemini_vertex_executor.go:948-954 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae863af8f1cb109eba691dee4cc402a327856fd36f20b2448a94a3727f524793"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/runtime/executor/openai_compat_executor.go:121-127 | internal/runtime/executor/antigravity_executor_execute.go:73-79 | internal/runtime/executor/antigravity_executor_execute.go:297-303 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"39c802a32a989580431a83f3cbe1235dc9bc9d1c504954b46bea291ca1a73448"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/translator/claude/gemini/claude_gemini_request.go:157-163 | internal/translator/claude/openai/chat-completions/claude_openai_request.go:89-95 | internal/translator/claude/openai/responses/claude_openai-responses_request.go:79-85 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/gemini/claude_gemini_request.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"203eee49bc02628c1909fb2f5c2a5c3a3aab8ddea78c5774012d86b2891812c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/api/handlers/management/config_lists.go:1593-1599 | internal/api/handlers/management/config_lists.go:1619-1625 | internal/api/handlers/management/config_lists.go:1645-1651 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":1593}}}],"partialFingerprints":{"codehealthFindingId/v1":"87be0ec38b1ad7027dea0bb3a555ed5618a2422a2e82c0d65ad1ad065edcac82"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/auth/codex/openai_auth.go:170-176 | internal/auth/codex/openai_auth.go:274-280 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/auth/codex/openai_auth.go:170\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/auth/codex/openai_auth.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"429c01f6692f65c543fa42873f7406d1f8ba5ca1db7bbc9ab8bf8065cd71dd4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/logging/request_logger_format.go:278-284 | internal/logging/request_logger_format.go:306-312 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/logging/request_logger_format.go:278\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_format.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"72c609bbd638abbdb472084391b1ffb1bda0960d94b59415ca9dce0e8d0893ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/logging/request_logger_home.go:155-161 | internal/logging/request_logger_streaming.go:112-118 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/logging/request_logger_home.go:155\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/logging/request_logger_home.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"65aa736d76260a1d19aa769cdcd0074ecbfdfc6a60819b7012f161b5fb72fd38"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/pluginhost/config.go:214-220 | sdk/pluginhost/host.go:345-351 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/config.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"7829fe2443d053bead90eb8ac86fabf38ecbb7c3ad84169ac8a62d185bcef16b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/antigravity_executor_credits.go:379-385 | internal/runtime/executor/antigravity_executor_credits.go:414-420 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_credits.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0f0a5e4e54fb02f3a8b9004018b2c8765231916621cbce7e30eef60498b07e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:197-203 | internal/runtime/executor/claude_executor_request.go:231-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:197\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"3af3922ccf07ed255f6ea20659447c9e4f729e203dbca6c7e56d945d6eb8445a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/claude_executor_request.go:1558-1564 | internal/runtime/executor/claude_executor_request.go:1608-1614 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1558\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1558}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d7f0871197dbcb85c76f9ff5d95ee037e547cb77021287c56a9a89734ed255f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/claude_executor_tokens.go:41-47 | internal/runtime/executor/claude_executor_tokens.go:147-153 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_tokens.go:41\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_tokens.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"658ee92b125099bc30cb0df9eae70ad3fa5668081c1bb6e3710d5b8f419ad54f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:341-347 | internal/runtime/executor/codex_openai_images.go:402-408 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"18c7d6963b1604d4c5d2fbec8b5067e1232a0735e774a47799f27705d8248de6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:528-534 | internal/runtime/executor/openai_compat_executor.go:700-706 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:528\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"6df5b7dc0355ec5581a72e58d9d2496e5074e026ef0ddbc95dfdc1bd599c0dfd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/codex_websockets_connection.go:199-205 | sdk/proxyutil/proxy.go:103-109 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_websockets_connection.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"deeda14548da412a13f76c95c315fda609b1b3a585014bde0cc709aff4ffc4de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:927-933 | internal/runtime/executor/gemini_vertex_executor.go:1018-1024 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":927}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a196050fde63278ef2b9ab2197a678a9bb0044e90f9d06dcaa8513e6ba8e210"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/gemini_vertex_executor.go:1117-1123 | sdk/cliproxy/service_models.go:453-459 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:1117\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":1117}}}],"partialFingerprints":{"codehealthFindingId/v1":"523ea5a5eff65197b4fcbe0b5136e47625dc285ff831a1d82501ea263c731573"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/kimi_executor.go:126-132 | internal/runtime/executor/openai_compat_executor.go:121-127 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b5f342614f7928216154789e73d46009bf030089cd2dfbfc66b26b9ac14f640"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:331-337 | internal/runtime/executor/xai_executor_request.go:77-83 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a7c4b26ca44ee180c76fbd743424339000eeb3c1dda3848d03028500e4f6c36"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/runtime/executor/xai_websockets_executor.go:836-842 | internal/runtime/executor/xai_websockets_executor.go:846-852 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":836}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a9375578f1f60cd41a2746aeecfd4364303fc30f3bdfded3e71cd7a28082b90"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/thinking/provider/claude/apply.go:125-131 | internal/thinking/provider/claude/apply.go:149-156 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/claude/apply.go:125\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/claude/apply.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd2356d76e778a6fb1da65ede50a6104dbc35fc81f83504388b2fce5b24bf3cc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:89-95 | internal/translator/gemini/interactions/interactions_gemini_common.go:372-378 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e684915c228d4c09a37633e5e032a24aa19016141e805801559080779c06589"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:272-278 | internal/translator/gemini/interactions/interactions_gemini_common.go:1174-1180 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf89cfd12d83c7c158b13d320a52406d6c7f96e1292cb31f60e7948ff939d73a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:299-305 | internal/translator/gemini/interactions/interactions_gemini_common.go:1201-1207 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:299\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"b17500aba2e79a562a7f4856a7f78df825c322c8ad1e4a8fe6eb6e4ba61338ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:314-320 | internal/translator/gemini/interactions/interactions_gemini_common.go:1235-1241 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:314\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":314}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5c974b6d5f30143889612c6212bafe1a76810f32a9fb929999e2f7cb7ece935"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:527-533 | internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:534-540 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:527\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"dede32e654d8a9c7e684e79e3277a8884d17e61e44057be540f6b1f109b9cbc0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:905-911 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:730-736 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/claude/openai/responses/claude_openai-responses_response.go:905\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":905}}}],"partialFingerprints":{"codehealthFindingId/v1":"b76ab46f46c5243b43ef5b4ea113793280f5946c06e0ce63913c13a143a75571"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/codex/claude/codex_claude_response.go:161-167 | internal/translator/codex/claude/codex_claude_response.go:365-371 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d9b44e19d470cf5bfeb63f942aef88522a52d660d582784d08ca75f681940c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_response.go:248-255 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:318-324 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"65df142df978c9f73cdbdf96be0e9bf9eeb115e18bb0e20d4c48bc85d321ca7c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/interactions/claude/interactions_claude_response.go:296-302 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:491-497 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/interactions/claude/interactions_claude_response.go:296\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/interactions/claude/interactions_claude_response.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"98aa0319e99e70353a09cc54c79e2e20a2183737c70ace6d10907ace1fcfcb9a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/translator/openai/claude/openai_claude_response.go:479-485 | internal/translator/openai/claude/openai_claude_response.go:752-758 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/claude/openai_claude_response.go:479\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"054d68426ad4832bc777fe14521edd932d39fc3447a15c04cd92d96cca4ecb98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/tui/oauth_tab.go:543-550 | internal/tui/oauth_tab.go:587-593 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/tui/oauth_tab.go"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2945e751669d4c3bddb4f347d66ea5314904293d986600e3bb88aeea5fecd5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/wsrelay/http.go:40-46 | internal/wsrelay/http.go:116-122 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/wsrelay/http.go:40\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"705fba1a3ec580ab181e4c59e9b7ded899d30eeea748d1ae1d3b8a650b0087cc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:79-85 | sdk/api/handlers/handlers_execution.go:143-149 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/handlers_execution.go:79\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5cedbf1ad1650e5d31acd18aee5bd516fc3f751d43b0354319cda4b4005029f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:179-185 | sdk/api/handlers/handlers_execution.go:213-219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"e86f7f2197a420aafa2685bf87dc450b9b1ced4938bad39167d41715e35d638f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/api/handlers/openai/openai_handlers.go:287-293 | sdk/api/handlers/openai/openai_handlers.go:383-389 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_handlers.go:287\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_handlers.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e2b3b4732315f89f5965d9e21dc7ff8a31d2d0d0371f154d2b14021c594ac1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:1099-1105 | sdk/api/handlers/openai/openai_images_handlers.go:1513-1519 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:1099\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1099}}}],"partialFingerprints":{"codehealthFindingId/v1":"364e1c6d8f6016950db3da5c50b669fcd1a857fdc1b5c46022d3fd830e6dec35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/api/handlers/openai_responses_stream_error.go:66-72 | sdk/api/handlers/openai_responses_stream_error.go:81-87 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai_responses_stream_error.go:66\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai_responses_stream_error.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"9db7473de95fdf46fc7608b2d9bd5e6dd3d1f64488494cba9f21bb47cd8c163e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/cliproxy/auth/conductor_execution.go:39-45 | sdk/cliproxy/auth/conductor_execution.go:84-90 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/cliproxy/auth/conductor_execution.go:39\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_execution.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"98da1f0f37b51c6b90e81f5272e91416e17ec2622b8594345e193d2f2d917478"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): sdk/cliproxy/auth/conductor_home.go:1096-1102 | sdk/cliproxy/auth/conductor_home.go:1152-1158 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_home.go"},"region":{"startLine":1096}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8355458a86e91e167808cd39b44a3d4731b8da12c8926c705b4d611cabf2869"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/api/handlers/management/config_lists.go:593-599 | internal/api/handlers/management/config_lists.go:1487-1493 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:593\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":593}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5d493e15a76c3be42a9a03f9d9f671134a24386524cade6079546050b6c5146"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 6): internal/api/handlers/management/config_lists.go:262-267 | internal/api/handlers/management/config_lists.go:436-441 | internal/api/handlers/management/config_lists.go:609-614 | internal/api/handlers/management/config_lists.go:950-955 | internal/api/handlers/management/config_lists.go:1313-1318 | internal/api/handlers/management/config_lists.go:1503-1508 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/config_lists.go:262\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/config_lists.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a2511889a56f3143f0e81d0ff78b922b89f062d91398961420b42fbedbd6749"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/api/handlers/management/plugins.go:694-699 | internal/config/config_yaml.go:637-642 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/handlers/management/plugins.go:694\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/plugins.go"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c7a3d01a44a3c2513b1fb767d4dd3458eb394166a6de31b9c94d301dc0d3b17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/api/server_routes.go:306-311 | internal/client/codex/live/live.go:721-726 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/api/server_routes.go:306\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server_routes.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c5566b7d84c6bb41b64db5191e845779ec51361a35a92ffafd648dcf28202e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/cache/antigravity_reasoning_replay_cache.go:542-547 | internal/cache/antigravity_reasoning_replay_cache.go:601-606 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cache/antigravity_reasoning_replay_cache.go:542\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"1af229a52197506fe9b8483ebcaccdcc32ff83b1b66d67053bc89b149b314fd7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/cache/antigravity_reasoning_replay_cache.go:554-559 | internal/cache/antigravity_reasoning_replay_cache.go:607-612 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/cache/antigravity_reasoning_replay_cache.go:554\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/cache/antigravity_reasoning_replay_cache.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4935018dbfdf39b8c2a57451662bdb18ba8c459764d58ca0f2f540fb067866d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/pluginhost/adapters_executors.go:826-831 | internal/pluginhost/rpc_client.go:578-583 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:826\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":826}}}],"partialFingerprints":{"codehealthFindingId/v1":"f54ddda77f0fb7469a5ea638855e538a410aa7865e9060650b781a35d4268a83"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:107-112 | internal/runtime/executor/codex_openai_images.go:204-209 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:107\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6a078e851cddd2b7cdba3fa5120e4a6cabb6a73c0154c03005b91028ae8ebe0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/runtime/executor/codex_openai_images.go:1011-1016 | sdk/api/handlers/openai/openai_responses_websocket_forward.go:294-301 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_openai_images.go:1011\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_openai_images.go"},"region":{"startLine":1011}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb2085da50341b9d6baa33179ea0dde23f5cf50691785909234681c832fe8fd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/runtime/executor/gemini_executor.go:385-390 | internal/runtime/executor/gemini_executor.go:461-466 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"092508c01c90ced06afc41fe67f1dd77cb67134c833a86d894a671b2cbcdbacd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/runtime/executor/openai_compat_executor.go:128-133 | internal/runtime/executor/openai_compat_executor.go:338-343 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/openai_compat_executor.go:128\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/openai_compat_executor.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad193de2b65410344679d6c437f11a053b339242c0376706207f79fd2a8b450c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_response.go:170-175 | internal/translator/antigravity/claude/antigravity_claude_response.go:195-200 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_response.go:170\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d0fa9ee6e2a967135527242d44e81ee71b934b70b194b7f222565bbb5b7ab83"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:264-269 | internal/translator/gemini/interactions/interactions_gemini_common.go:1166-1171 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:264\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"b558e900fa4e7b89eae1479be0cf139e6ffb7df7d5f9cc6911d9f06d5e78f947"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_response.go:106-111 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:406-411 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/openai/chat-completions/codex_openai_response.go:106\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3b7e688347bc41502f2029e2dc9623e73afdd83685f7d1949af342632cc4022"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/codex/openai/chat-completions/codex_openai_response.go:228-233 | internal/translator/codex/openai/chat-completions/codex_openai_response.go:253-258 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/codex/openai/chat-completions/codex_openai_response.go:228\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/openai/chat-completions/codex_openai_response.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbd10b2596dc89ea2f1fad584e9aee4773c585fb041553ee0201d2a2f48f16a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:89-95 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:294-299 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:89\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_response.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"0889cadfe025d55693f9250202c121379d51ab50fb33c522438c974570fc2b9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:619-624 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:677-682 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":619}}}],"partialFingerprints":{"codehealthFindingId/v1":"84d9f0fe88cdac32495a9bda235e36a565551d0750123bbc6218c8c89664d9d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:628-633 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:686-691 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:628\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":628}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7e9f71216137db2203de2e939d749875b88c721aeb131d130ab188baf0b7a0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:930-935 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:797-802 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:930\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":930}}}],"partialFingerprints":{"codehealthFindingId/v1":"e04f247b0f9062ce2be1d41a5b3f18988f4855ea8d193c19d69b8a16c553eee9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:171-176 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:716-721 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"18d5d284ec2cd4e93daa744c7de57f170772c89b6ca7bb077c36d6cb3cb0d6af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:352-357 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:861-866 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:352\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"5230b57ed82645adcbdf50cb7f90161bbb15bd287a44ef9ce29c5bf39f47317a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/translator/openai/openai/responses/openai_openai-responses_response.go:547-552 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:616-621 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/openai/responses/openai_openai-responses_response.go"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ed7f3f5235e38abdad34b65dced887a451470fcf6ea3dc4de2d094ac9c843c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/wsrelay/http.go:60-65 | internal/wsrelay/http.go:101-106 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/wsrelay/http.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d8167b3e8c84d06ca818b55f304d0e96931a3d8b69c6b869f6558f6c7fba2a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): sdk/api/handlers/gemini/gemini_handlers.go:239-244 | sdk/api/handlers/gemini/gemini_handlers.go:313-318 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/gemini/gemini_handlers.go:239\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/gemini/gemini_handlers.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"970cb3feee1919e151d41e8b80ae7903a955c5033e633a7b3757329afb4c44bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): sdk/api/handlers/handlers_execution.go:170-175 | sdk/api/handlers/handlers_execution.go:204-209 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/handlers_execution.go:170\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/handlers_execution.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa40ec5153b1177d7e12b81c1a7b9c4f25407a2256455a49f168b5cb45631b74"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:377-382 | sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:406-411 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go:377\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket_toolcall_repair.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c5e2990b0944f65adc5484fd1171cd90ba1e0c09fa055e84c37e9fad7c1a46"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): sdk/cliproxy/auth/conductor_stream.go:328-333 | sdk/cliproxy/auth/conductor_stream.go:344-349 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/conductor_stream.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"11b3415881e7210b4a44c64f88e6d7ffeabbd468f7a6dfb8687457649b0147dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): sdk/cliproxy/auth/home_in_flight_publisher.go:171-176 | sdk/cliproxy/auth/home_in_flight_publisher.go:207-212 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/cliproxy/auth/home_in_flight_publisher.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"16d93afe3adca304006fe51039e137e42f43ef8eb8a46b44902c98ee1c9c8d49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/api/handlers/management/auth_files_fields.go:109-114 | internal/api/handlers/management/auth_files_fields.go:316-321 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files_fields.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"609aca14714f216ebcfd11a2a8ee5400f44e1b2b8d20b226f3197777a5b37fdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/runtime/executor/antigravity_executor_execute.go:34-39 | internal/runtime/executor/antigravity_executor_execute.go:263-268 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/antigravity_executor_execute.go:34\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/antigravity_executor_execute.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e9bc937b57f4ac819b3e49c85ac328616ac853abeb64d80095f3eb644d5b7ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/runtime/executor/claude_executor_request.go:1376-1380 | internal/runtime/executor/claude_executor_request.go:1560-1564 | internal/runtime/executor/claude_executor_request.go:1610-1614 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/claude_executor_request.go:1376\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/claude_executor_request.go"},"region":{"startLine":1376}}}],"partialFingerprints":{"codehealthFindingId/v1":"fea5c9e76035362977a347c13e131950c6e8763f724bc5e8ee43ebf7ba8db736"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/runtime/executor/gemini_vertex_executor.go:365-369 | internal/runtime/executor/gemini_vertex_executor.go:604-608 | internal/runtime/executor/gemini_vertex_executor.go:877-881 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_vertex_executor.go:365\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_vertex_executor.go"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"295d876f9d592143dff2242608196ced68d8d0be0c8e624c367506b27df2c29b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/thinking/provider/antigravity/apply.go:72-77 | internal/thinking/provider/gemini/apply.go:96-101 | internal/thinking/provider/interactions/apply.go:27-31 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/thinking/provider/antigravity/apply.go:72\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/thinking/provider/antigravity/apply.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ffeb00730edbae5fc8dcd858ce4fcd3486fedda60b849f3725b210b182a51de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/translator/antigravity/interactions/interactions_antigravity_response.go:436-440 | internal/translator/codex/interactions/interactions_codex_response.go:522-526 | internal/translator/gemini/interactions/interactions_gemini_common.go:1108-1112 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:436\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f5371b441acd0c6b713a1ad6d795aca6f8d2cbf2a9c9638df0324bef951a4ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/translator/claude/openai/responses/claude_openai-responses_response.go:453-457 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:211-215 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:508-512 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ae2a6832ad15c78361b3f25cde80fa4747cf41b86bd43aead3032ddec6bdbbc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/translator/claude/openai/responses/claude_openai-responses_response.go:510-514 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:619-624 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:677-682 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":510}}}],"partialFingerprints":{"codehealthFindingId/v1":"e04391705ab81e6a6ca73cf80e9c4ace1adc6b3d7d25b5ef2c164e2478246923"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/translator/claude/openai/responses/claude_openai-responses_response.go:694-698 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:183-187 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:863-867 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"9651c1a53ed30e0317b5f35e217f14d5682172573cffaa450a3c588776a30fc6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go:372-376 | internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go:406-410 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go:372\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/client/codex/optimize-multi-agent-v2/optimize_multi_agent_v2.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcecb3151f1fd1d10df8018840b24db409338d6a95df09b019417d67322e0cd4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/pluginhost/adapters_executors.go:637-641 | internal/pluginhost/adapters_executors.go:763-767 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/adapters_executors.go:637\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/adapters_executors.go"},"region":{"startLine":637}}}],"partialFingerprints":{"codehealthFindingId/v1":"660f5e3d992740cb2e01ce2b5b267d3f0dcca9e117e82b8427ab7becdbce635e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/pluginhost/management.go:330-334 | internal/pluginhost/management.go:352-356 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/pluginhost/management.go:330\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/pluginhost/management.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdb52e8dda31373934c00c48f755e45ded92afe4c1ef8938a56ef5f2d0a9a3a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/runtime/executor/aistudio_executor.go:130-134 | internal/runtime/executor/aistudio_executor.go:199-203 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/aistudio_executor.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc5caf052e98aec5bf0246355934415a6d9c018cc012333ccc66683d1f186f58"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/runtime/executor/codex_executor_terminal.go:225-229 | internal/runtime/executor/codex_executor_terminal.go:230-234 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/codex_executor_terminal.go:225\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor_terminal.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"065f0d7430a24113d33f4241e8f64042b40065b4bce67c28a999859d41e7a8ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/runtime/executor/gemini_executor.go:446-450 | internal/runtime/executor/openai_compat_executor.go:287-292 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/gemini_executor.go:446\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/gemini_executor.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"72446c4e863320adfdf2fb7ed546305065c00c670acc069c9c0afb1a6b72c88d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/runtime/executor/kimi_executor.go:325-329 | internal/runtime/executor/openai_compat_executor.go:455-459 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/runtime/executor/kimi_executor.go:325\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/kimi_executor.go"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5bb0abb4d1b8e0f8d84ace08b140481172ff99f66058a19a4665382b2635645"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_request.go:892-896 | internal/translator/gemini/claude/gemini_claude_request.go:264-268 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_request.go:892\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":892}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a4e065179758226544b9448092842baaec64ef152a257342bbde044f3dbd2a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_request.go:915-919 | internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go:64-68 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/claude/antigravity_claude_request.go:915\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":915}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a0d14e386f34c87a8141a20acc7b511ae3661b568a7c4751015e28cc1977a09"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/claude/antigravity_claude_response.go:338-342 | internal/translator/antigravity/claude/antigravity_claude_response.go:457-461 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_response.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e08aef2d83b4f3e782e0eef1427bdb173005750b17321dcdda46a64831587bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:188-192 | internal/translator/gemini/interactions/interactions_gemini_common.go:345-349 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"afb734624942ab3d77bc25f1b240d97a1930fd33f6f118342bb9d333c780bf69"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:227-231 | internal/translator/gemini/interactions/interactions_gemini_common.go:1129-1133 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/antigravity/interactions/interactions_antigravity_response.go:227\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"221462db37435fbe490be0e2bd45400fc4e555b64e6f6ae0a741d31fe1d3c451"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:257-261 | internal/translator/gemini/interactions/interactions_gemini_common.go:1159-1163 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"48108ccb477b897f3f13c80f8182e10c0c0f94604db7dfc40378858430510847"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/interactions/interactions_antigravity_response.go:287-291 | internal/translator/gemini/interactions/interactions_gemini_common.go:1189-1193 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/interactions/interactions_antigravity_response.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a6ba5269c18510b804f832107be2bc7fd4827fbd1672c098829f8a336dc62f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go:169-173 | internal/translator/gemini/openai/chat-completions/gemini_openai_response.go:211-215 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_response.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"33545192e6bec5da3a967dedc51cfadfa1d03c0721dacb123762a3168febd1e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/claude/openai/chat-completions/claude_openai_response.go:246-250 | internal/translator/claude/openai/chat-completions/claude_openai_response.go:411-415 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/chat-completions/claude_openai_response.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"cab85582bc499a0a50f90a90950fce1ca2932f758bb304f5807ef8184ca5239f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:206-211 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:284-288 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"92643d37b5e030f1851855590c0e274f06f096b694b7e41205f470815886cb5f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:397-401 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:199-203 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a5e201e2b60ff0dd34338ba507e64b2334229d4ba90eb869516870e5a47779e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:402-407 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:204-208 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f053dab120c1198f9cd06b2895dc35e2fc74855f3b2cabc4dad24d0591e9553"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/claude/openai/responses/claude_openai-responses_response.go:524-528 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:229-233 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_response.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"3510a0fd67e4c0b23cd415adaae5d7fea178cd0763a699026621395305a36e51"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/codex/claude/codex_claude_response.go:136-140 | internal/translator/codex/claude/codex_claude_response.go:222-227 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/codex/claude/codex_claude_response.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d9d5d2db80a8a5f4d3a7ceaee5c444354d6083b26529a860cccdd4f9cd5ab9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/gemini/claude/gemini_claude_request.go:295-299 | internal/translator/gemini/openai/chat-completions/gemini_openai_request.go:59-63 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/claude/gemini_claude_request.go:295\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/claude/gemini_claude_request.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1214e1a60b539094bed29c1893a884dc79fd0b33fe4d4c5085a248ab7d29de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:320-324 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:327-331 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"800bc614d19d2d0547016d3e8a6e9ae873d30d573b75e9da20242a2cf294fcb7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:392-396 | internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:1031-1035 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:392\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb572deb55d76206affdc35609c3ac00a37ce5267a681e354c2788679f9f1433"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:880-884 | internal/translator/openai/openai/responses/openai_openai-responses_response.go:747-751 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/gemini/openai/responses/gemini_openai-responses_response.go:880\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_response.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4010346899d30c3814899f6ed0acb1c96981363628e1b0db9cd918045f0efdd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/openai/claude/openai_claude_response.go:669-673 | internal/translator/openai/claude/openai_claude_response.go:726-730 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/claude/openai_claude_response.go:669\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/claude/openai_claude_response.go"},"region":{"startLine":669}}}],"partialFingerprints":{"codehealthFindingId/v1":"93873fecd8a00048259c24bb7494a4df235abcd499aa7ebdf21c17ccd85c4eef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:216-220 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:766-770 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:216\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"c273fd1eaa2dc3cd807f43ce866f3043b554396f5c0ba29298d004458110aed0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/openai/interactions/chat-completions/interactions_openai_response.go:267-271 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:811-815 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/chat-completions/interactions_openai_response.go"},"region":{"startLine":267}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a0c2172abf758aea21c1b48fb6fc457b440b0eee96a3a7f36f0984c9d81b49d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:234-238 | internal/translator/openai/interactions/responses/interactions_openai_responses_response.go:348-352 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/openai/interactions/responses/interactions_openai_responses_response.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e77a24418e1113f654b24aa73c702005af7fde8c1575f939febb1b569763837"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): sdk/api/handlers/openai/openai_images_handlers.go:1843-1847 | sdk/api/handlers/openai/openai_responses_handlers.go:289-293 \u2014 the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_images_handlers.go:1843\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_images_handlers.go"},"region":{"startLine":1843}}}],"partialFingerprints":{"codehealthFindingId/v1":"c247958a97889972c83c3afaa84f2984dfd7b707974977dceb1cec4c44b98bae"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): sdk/api/handlers/openai/openai_responses_handlers.go:455-459 | sdk/api/handlers/openai/openai_responses_handlers.go:479-485 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_handlers.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b75b900ca8da5b1cde5ed33c9e892f04e62991d1e09e996390b2ef0f52b6829"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): sdk/api/handlers/openai/openai_videos_handlers.go:548-552 | sdk/api/handlers/openai/openai_videos_handlers.go:601-605 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060sdk/api/handlers/openai/openai_videos_handlers.go:548\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_videos_handlers.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfea4fc7dc6a74265e7c960de939419a3b2d8f1d26dff81eaa8535d363ebbaa3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: cmd/server/main.go: cmd/server/main.go changed 21 times in last 90 days, max complexity 137. 2 of those changes were fix/bug commits, and the other 19 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/server/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"280240d7789fd822bdd63a32263c4a0c60dda532595cfc548c6879b3207d5f46"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/translator/antigravity/claude/antigravity_claude_request.go: internal/translator/antigravity/claude/antigravity_claude_request.go changed 14 times in last 90 days, max complexity 195. 4 of those changes were fix/bug commits, and the other 10 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/claude/antigravity_claude_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba01c5caadaa48542d8d83db6fc7b8664e446931f129d190c65f4d31732d5e16"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/watcher/diff/config_diff.go: internal/watcher/diff/config_diff.go changed 17 times in last 90 days, max complexity 125. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, behind tests written first."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/config_diff.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"98819fb831660f416251e717853ebe8e50c234a2ca4b25426bd9f0c4cf3656b1"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: sdk/api/handlers/openai/openai_responses_websocket.go: sdk/api/handlers/openai/openai_responses_websocket.go changed 19 times in last 90 days, max complexity 106. 6 of those changes were fix/bug commits, and the other 13 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"sdk/api/handlers/openai/openai_responses_websocket.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca6815bc79f2d016dde78545331f3361accefbb50f9efb5296db76c1317ee2c0"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/runtime/executor/xai_websockets_executor.go: internal/runtime/executor/xai_websockets_executor.go changed 18 times in last 90 days, max complexity 107. 7 of those changes were fix/bug commits, and the other 11 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/xai_websockets_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a0047d85573243b71f57a536200fa92ec1cffe15dc216b05dd386b9e4d9c928"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/translator/gemini/openai/chat-completions/gemini_openai_request.go: internal/translator/gemini/openai/chat-completions/gemini_openai_request.go changed 14 times in last 90 days, max complexity 126. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, behind tests written first."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/chat-completions/gemini_openai_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e573a9747f0b305d82f3cc0bff2fbcc0fd39d8544a443f4286e782f881dcaa4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go: internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go changed 13 times in last 90 days, max complexity 126. 2 of those changes were fix/bug commits, and the other 11 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/antigravity/openai/chat-completions/antigravity_openai_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"57ab34f30de60d45c21e49cc2abb868094e805350e04c76e88dc3e313007f425"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/translator/claude/openai/responses/claude_openai-responses_request.go: internal/translator/claude/openai/responses/claude_openai-responses_request.go changed 14 times in last 90 days, max complexity 113. 3 of those changes were fix/bug commits, and the other 11 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/claude/openai/responses/claude_openai-responses_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"76ba96a054eb576ddfcc3676a2e7684ea0584bed97422c859cbb93c57a1a6fe3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/translator/gemini/openai/responses/gemini_openai-responses_request.go: internal/translator/gemini/openai/responses/gemini_openai-responses_request.go changed 12 times in last 90 days, max complexity 105. 4 of those changes were fix/bug commits, and the other 8 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/translator/gemini/openai/responses/gemini_openai-responses_request.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2640a196eba1327cf2818ce7dc77a1907c82b231ac3f8058788830fa616ee5d7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/api/server.go: internal/api/server.go changed 48 times in last 90 days, max complexity 26. 7 of those changes were fix/bug commits, and the other 41 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"79c138a7ef94a0b915213623e8f098c43882fd48928bec6634041c13fe794798"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 48 significant file(s) lose their only recent owner: sdk/api/handlers/openai/openai_images_handlers.go, sdk/pluginapi/types.go, internal/translator/gemini/interactions/interactions_gemini_common.go, internal/translator/openai/interactions/responses/interactions_openai_responses_response.go, sdk/cliproxy/auth/scheduler.go, internal/translator/claude/gemini/claude_gemini_response.go, internal/translator/openai/gemini/openai_gemini_response.go, internal/translator/codex/interactions/interactions_codex_response.go (\u002B40 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"39dcd431ec1f020d5af90864366511a839f59ee11d149407b3235aa3e03610ad"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #2: If anonymized user #2 becomes unavailable, 12 significant file(s) lose their only recent owner: internal/signature/claude_validation.go, internal/cache/antigravity_reasoning_replay_cache.go, internal/signature/gemini_validation.go, internal/signature/provider_compatibility.go, internal/cache/xai_reasoning_replay_cache.go, internal/runtime/executor/xai_reasoning_replay.go, internal/signature/claude_messages_sanitize.go, internal/translator/antigravity/claude/signature_validation.go (\u002B4 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"5f2f5c777cb2d984037dd5f0269873bd39ce177f6662581ae8abbdad2664883c"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #3: If anonymized user #3 becomes unavailable, 9 significant file(s) lose their only recent owner: internal/pluginstore/auth.go, sdk/pluginhost/host.go, sdk/cliproxy/home_plugins.go, sdk/pluginstore/pluginstore.go, internal/pluginstore/manifest.go, internal/wsrelay/manager.go, internal/thinking/suffix.go, internal/thinking/provider/codex/apply.go (\u002B1 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"18b4f5cfe963f5674700296a813e22057ef079870561f345eca73caaf42be8e0"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 3 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold \u2014 folded into the bus-factor score and metrics (72 single-owned of 421 analysed files in total, counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first). They are anonymized user #4 (1 file(s)), anonymized user #5 (1 file(s)), anonymized user #6 (1 file(s)) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D19","level":"note","message":{"text":"The README briefly mentions \u0027CLIProxyAPI Tray\u0027 but does not describe what the tray does or how to configure it.: Add a short section on the system-tray UI (start/stop, account selection) so users who install the desktop client can find it without reading the plugin docs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"README.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aef9b14fac4b7d649231bf26f42f7c8885f531da2a6528e1d0f541ed2cf62f0f"}},{"ruleId":"D19","level":"note","message":{"text":"The high-frequency handling section mentions \u0027ensureAuthUpdateQueue\u0027 and \u0027consumeAuthUpdates\u0027, but there is no link to where that code lives in the repo.: Add a brief cross-link or inline reference to the ensureAuthUpdateQueue function so readers can find it without leaving the doc."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/sdk-watcher_CN.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"26c8de76e8c3b74f4541b96feb4466f0fb2586818762b61ac74c080055170340"}},{"ruleId":"D19","level":"note","message":{"text":"The minimal embed example uses \u0060WithConfigPath(: Complete the minimal embed example with a trailing line confirming cancellation exits cleanly. Link the Usage Checklist to MANAGEMENT_API_CN.md so readers can find endpoint docs without leaving the page."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"docs/sdk-usage_CN.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c56627f3f40fa371738260c6f6f7cdd4f4fd27edfd1b1142142260d4cab7cd29"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"052e2726cfc3ec9b485f0d71c76e6d2f009b0b87d08e25541a2cac76f68cb835"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a6285a07f7d4a0284a7cc43325fa83f344140c4d42947ff2fb0d17d8481dcef6"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6949a58f01ef90a63354de62b921cc9aebfa07aa2c09d72c78a61ca75d82d502"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ead63eec85db609e125b2a4077c83f39a1bc054d5ba4accb2fbbab30657e51ce"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"662e450e88552e351eac7b0519e739a005e02907ee2c97ff290368500eb75828"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6deefca4b64470c607f1f3b04ae938316eddfb441034fc10984b4a7be99c1977"}},{"ruleId":"D28","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d13564398fd909cf6821549e142f11325c9363334353beb05c34f1a6cfbd730b"}},{"ruleId":"D28","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3cdfd7beb31b791ae18dcb425e21eb157c842e7bbcd522cc330573c1a6538db1"}},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b75ce0446e688526ee23bc26416fe4fef513f37ab3030c240051ce7d5da55938"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f7b0bff5a080b15490cbca2d871cd44d39f8ab575aaab80cd7a34b76a42720f9"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ab1f3ea73d70cfff3dad342b06ea043503c7f7d325f553b021bc27fc4f22f3aa"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1629d91ef1be436ae8057778a4f7b819f5d5d049542a354b14e6fe26c690a600"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b72128afbecdaca8361972ee3c657d4046c2155e34701c8f258188714c409e63"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"48ab0362564b7ef45b5e0b689803670fd613b2d4a479bd92fcfedc012abd449c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"35af72b290af30f781944ef4eaf339d12ce559f09c3b15614ffb10c29ea7d1cb"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b97bcdc0c666452f241ecc9a92c0a9a2d7c626a9c884fd97daeb2042f2f88c5b"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9540b41f6d8b89c35c456a0b625f0cd70dac3ebc09a992a4d873f594b2cbb188"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"afef1bd3ee17e023731374833d077365015d2ecbc40bc83cfc85731b98a62c8a"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6bb0b3f753de34f48279c38973c74421a18f7be1665d2d9ed7689051199822bd"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"90933373bec0003a484886812e2f133afd2408d2724a44a214c3404b8a1c7ed8"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"cb759274fb914a0637c85149966c601b713a0548b843be47f2b2e45537814a5c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8825465de2b4d4954e31dabf9e9a7d26a5ddc7098afeea72cd9a68011793836c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8cb3b0008035af5b9674450f8b1be442223141a2093040dd7f9d1befbb793161"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ee0ff7fb23459ba338ed19cdaf1b7711f2f2025a5537de72cc17e79f90d8b8af"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d27341ae76138bc0c7714b0a9627d6f89bc8fd184bd3447935411c6ac329923d"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f429fcf0d6921297c325d20afe77b8b99a9f07921f92a9f7612110746136d487"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"062db236ba7b454d7bd243cda9e24d3a2a24fe7f5d29ec77af832de446f2e046"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"2b5b61bebc9271f87badad1b6163649189572db55cf6100fd35fe0d282987e25"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9e2c198a759d121289789824238adb878e78dd2f10063119c115694f2549b129"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"39d91d4761c79b9f8815f6628abd171d57cb8431e53d7b545e429cc1642fce1d"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3031c3dc64086dbc6b089763fadeba2750d9a735e537ffca54e73504c48524db"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b981e0c88b0264d74e5d91d816f52d43b3235bb16e214e47c3a2fb41037a55e4"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8c4eb5a2ac31daca68719c28cf48ca49df6861b4552676d00945c87a39574c44"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"60be4386c7682abe6d9d7ba95298f2f3b02ca65bd3fe5a0bca73a26f1279ce2c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3f8be53aea3fb7d696bcc1dc7ec26631ba9df7adb39af6ffcbc8b1eeab34c30a"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"920789719af0827bf5d3f1d2dfae3a313ec5af78b8efd22030d5e83c84a330ca"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7d8f8c175aee7a4b00fe8c0e19548f26a6b9f9def037a52c4f8d22525cdef237"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7bdd77391266228d4291f3294ddc66e44489cb774fd60d4871930d7ca71b5b45"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1a2cd3b300642d2f5a877018722835704cb928fcc3580580a535f350513da628"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"54c536813177b023dced16abf0437c748e31e9acc8f6ab66079a214154ae0eb4"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fb97040c96360e2505088fcb0dfd8d32812bddf35fa1972c32b2e85823f7c78b"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"335d1ee62d46a014260f8a596cd64d23171a4c3cc8e904ee4c09cabc2e3601a2"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f468f2344a4b90ef9bd8e0e5b84d017c5aee2531050d1fdc0f0be9000a914bdc"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"41567c4cb8b5473ed7837eb165edf17fd96229a55ee659a566130ebe4edd1de0"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"22198615eef8c8ad95cc089d96afb8330bdbde8850f845f78ac86a1c5a9e3816"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"58f180fbbe1729229e32fc58de9cdc8a8ceb5ecb15260cb2756cec9b66dfd813"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f6888222f8aad8de30f9c4b9e149e03f75b6c2f28ef3e9a14ef71d91a4f1f680"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1ee829e38a5e7549368553701e7722f24570d8d04e1ba932477b6a18ebba3a07"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"36882598bb4d2cc7aba98bb60ae32284b88eb698cba50e5776ac383b1ed59d8e"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0a501aea60487e1d35ad1f936ad2bda6ef689bf53265bcabbde13047c3319a04"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"4faa260c6fddf2b96b55d6bbc7f6ef10ce0300a37b6845a4197599093ab4fda3"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"2b3261c413ad8decf7c4b5a411d21c03c4ed4508d47936c4f34544f2ece2f58c"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"01ca8ef12c2fea1d5da61028b6d56c33dd24d93c3dcbf9e15fcc15ca3fd9e890"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"49945ea490c51b87cd192f3e5cbab0855959cb7063de855b60ac7d8394ddc1db"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"4f0ebf8fe88c489f53ab7e2d941a2c9161f6ceb42593b302b3af33dd14c28c7e"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"aadb0e77e82ecb437d0b24caa705616de499cc1cd0f57d929d8df52123e8a330"},"taxa":[{"id":"CWE-338","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a50e412b7bed1381b085567217c7121a26c7308ea6c9161c9d7066285236cf30"},"taxa":[{"id":"CWE-338","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"13580d659e85ebd08e114fec1a224f3e98c9f1f21142ac837877519d12e4140c"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fe2d688610b51e0a5a02c7c5dd1724a4986e40f2689fb84510e2ec0164c27d6a"}},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b67787f58bbdcde79a43cc08af597219f8bc8ccd5a82b8588a8f7af6b62ec402"}},{"ruleId":"D31","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1f51a163f26d94ce6b6f473117dde579d091c8cbf9e59810475c94d9fc921120"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 2 of 421 analysed file(s) have no living knowledge left \u2014 their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each \u2014 largest first: internal/tui/styles.go, sdk/api/handlers/stream_forwarder.go. Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ce861fd78f6935114d3a342cb90ad25870f984e1042954fcbbe27c0e23be3658"}},{"ruleId":"D35","level":"error","message":{"text":"Boundary-crossing change coupling: codex_executor.go \u2194 types.go: \u0060internal/runtime/executor/codex_executor.go\u0060 (context internal) and \u0060sdk/cliproxy/executor/types.go\u0060 (context sdk) sit in DIFFERENT parts of the tree yet change together 50% of the time (6 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) \u2014 the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can\u0027t see."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/runtime/executor/codex_executor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c4df04623c200a9c0f0756ecd0a3e9171b97543599524c8bddc0b43b6dc1722"}},{"ruleId":"D35","level":"error","message":{"text":"Boundary-crossing change coupling: config.go \u2194 service.go: \u0060internal/watcher/synthesizer/config.go\u0060 (context internal) and \u0060sdk/cliproxy/service.go\u0060 (context sdk) sit in DIFFERENT parts of the tree yet change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) \u2014 the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can\u0027t see."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/synthesizer/config.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5c6076002f3d057b9c86e9b644c6b5186b68813ea804211fc85db473b6f8c1d"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: auth_files.go \u2194 oauth_sessions.go: \u0060internal/api/handlers/management/auth_files.go\u0060 and \u0060internal/api/handlers/management/oauth_sessions.go\u0060 change together 73% of the time (8 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well). They sit in the same directory, and in this ecosystem sibling files there normally share one namespace/package \u2014 so a direct reference between them needs no import and this pass cannot see whether one exists. Read the pair before acting: if one file only DECLARES what the other consumes (a constants/types file beside its user), the co-change is definitional and the question is whether the split earns its keep; if they duplicate structure, extract the common part into a shared function or type they both call; if neither holds, the coupling is hidden and worth breaking."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/api/handlers/management/auth_files.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"686eb817305f4555a21344ac08576f6df65e13739894e522472cd86d8b0ef055"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: config_diff.go \u2194 config.go: \u0060internal/watcher/diff/config_diff.go\u0060 and \u0060internal/watcher/synthesizer/config.go\u0060 change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well) with no explicit dependency \u2014 the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE \u2014 the registration is the link, and it is meant not to be an import \u2014 and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/watcher/diff/config_diff.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3ad98b3a0a5ef7beb19094a156a3d899030c41217d7cea0f37fb31c4487fcf2"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1b213f6eedd4b140d0bc37bdf1496f72811a643f34064f12518b32e9e83bcfc7"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0e17f71490e4d120a48b2b2881ab866c93b272bef2febb673a3e8e42b2c288ab"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"eb00976a698a5d68999b7ee6d27206fd374e916853e7ff1ead5eed42386f043f"}},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"90f83b4fa27db32740afe9540c905f3c0499caed87f61049a8a903ecc95b41c3"}},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0752d0df7434000fcabf1048e2de30a7a1a8b982b3db9a19898c4dec199856b4"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c3101d36131a52584dde37b042bdfe9fc6a1d1edad6398c91ef166385743b007"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"50c379534161bb30611d421e82af3666b891a67b9a6a35df5a4fc4b4977e653b"}},{"ruleId":"D38","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6b4deab06cd1fc2fb6e57103d1f3ef991634da4c2b7c329a7a2420a12731f08c"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1032","guid":"5f21e517-68aa-a650-9a25-5771ef024637","name":"OWASP Top Ten \u2014 Security Misconfiguration category","shortDescription":{"text":"OWASP Top Ten \u2014 Security Misconfiguration category"},"helpUri":"https://cwe.mitre.org/data/definitions/1032.html"},{"id":"CWE-1357","guid":"e4d2e772-757e-0a5c-bd7d-77052949d866","name":"Reliance on Insufficiently Trustworthy Component","shortDescription":{"text":"Reliance on Insufficiently Trustworthy Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1357.html"},{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-16","guid":"659db3ea-affc-8453-8add-c1218fbfcb92","name":"Configuration","shortDescription":{"text":"Configuration"},"helpUri":"https://cwe.mitre.org/data/definitions/16.html"},{"id":"CWE-242","guid":"5c147e5c-be37-b051-9928-764ef5a8f3d3","name":"CWE-242","shortDescription":{"text":"CWE-242"},"helpUri":"https://cwe.mitre.org/data/definitions/242.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-338","guid":"e89b7604-c3f7-8b53-bc8c-4d4718c28617","name":"CWE-338","shortDescription":{"text":"CWE-338"},"helpUri":"https://cwe.mitre.org/data/definitions/338.html"},{"id":"CWE-353","guid":"09d7e902-d4ee-f05d-ae6c-0a1554d0c18f","name":"CWE-353","shortDescription":{"text":"CWE-353"},"helpUri":"https://cwe.mitre.org/data/definitions/353.html"},{"id":"CWE-494","guid":"b8a65e0d-e459-4a55-a931-fc1136482375","name":"Download of Code Without Integrity Check","shortDescription":{"text":"Download of Code Without Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/494.html"},{"id":"CWE-732","guid":"1da27e8f-b330-7650-ab63-bd61953eae5d","name":"Incorrect Permission Assignment for Critical Resource","shortDescription":{"text":"Incorrect Permission Assignment for Critical Resource"},"helpUri":"https://cwe.mitre.org/data/definitions/732.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Command Injection","shortDescription":{"text":"Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"OS Command Injection","shortDescription":{"text":"OS Command Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Cross-site Scripting (XSS)","shortDescription":{"text":"Cross-site Scripting (XSS)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"SQL Injection","shortDescription":{"text":"SQL Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Code Injection","shortDescription":{"text":"Code Injection"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":69,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}