Repository navigation
fix(git): classify HTTP errors from explicit status diagnostics - #5366
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
8b27b05 to
c6f3840
Compare
|
|
@coderabbitai resume Codex, responding on behalf of @arturcic: please resume automated reviews for this PR. |
|
✅ Action performedReviews resumed and review finished. |
|
Thank you @arturcic for your contribution! |



Description
Git network failures are currently classified by searching all stderr for
401,403and404. A missing repository athttp://127.0.0.1:40123/...is consequently reported as an authentication failure, and URL/path digits can override genuine HTTP diagnostics or unrelated connection errors.Recognize status codes in Git's explicit
The requested URL returned error: <status>diagnostic instead. Preserve the existing authentication/repository-not-found phrases and the original error for unrelated failures. Regression tests cover localhost ports, URL/path digits, actual HTTP errors, multiline RPC diagnostics with CRLF, longer numbers and local checkout failures.The algorithm documentation review records are refreshed after reviewing all seven affected sections: this failure-only change leaves successful repository operations and version-calculation rules unchanged.
Related Issue
Resolves #5365. Also addresses the intermittent
CloneOfMissingHttpRepositoryMapsGitsNotFoundPhrasingfailure observed in #5207; the faulty classifier is already present onmain.How Has This Been Tested?
Latest head
16e9fcfb1implements the failing executor stub explicitly throughIGitCliExecutor, preserving both required parameters and the same deterministic result while addressing the two S1172 warnings. All 30 GitCliMutatorTests cases passed on each backend (0 failed/skipped), formatting and whitespace checks passed, and CodeRabbit review of the published change completed with 0 findings. Fresh GitHub CI/Sonar analysis is pending; the previous full-suite and review evidence below was obtained on pre-rebase head8b27b0501. The fix was rebased onto7f02b33ebwith unchanged patch equivalence.Using .NET SDK 10.0.402, Release/net10.0 on macOS arm64:
GitVersion.Core.Testssuite withGITVERSION_GIT_BACKEND=managed: 36,489 passed, 0 failed, 0 skipped.GITVERSION_GIT_BACKEND=libgit2: 36,489 passed, 0 failed, 0 skipped.dotnet format src/GitVersion.slnx --no-restore --verify-no-changes --include src/GitVersion.Git.Managed/CommandLine/GitCliMutator.cs src/GitVersion.Core.Tests/Core/GitCliMutatorTests.cspassed.npm run test:algorithm-docs: 13 passed;npm run check:algorithm-docsverified all seven review records.git diff --checkpassed.--committed --base origin/main) completed with 0 findings across all three changed files.Core-suite commands (JUnit reporting enabled for both runs):
Checklist
Created by Codex on behalf of @arturcic.
Summary by CodeRabbit