Repository navigation
fix(checkouts): Basic auth for every git transport; a checkout names its origin - #327
Conversation
Code Review by Qodo🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)
Great, no issues found!Qodo reviewed your code and found no material issues that require reviewPowered by Qodo |
I can’t fetch or inspect GitHub PR 326 from the tools available in this review, so I can’t reliably confirm whether it duplicates this PR. This PR contains two distinct changes:
If PR 326 changes either of those same code paths, it likely overlaps and should be compared commit-by-commit; please paste its diff or key files here and I can compare them precisely. |
|
Overlap check with Michele’s #326: its Basic Git auth change duplicates this PR’s auth hunk, but #326 does not preserve |
282ebbe to
7b7bab6
Compare
|
Rebased onto current development |
Code Review by Qodo🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)
Great, no issues found!Qodo reviewed your code and found no material issues that require reviewTip of the day💡 Did you know, you can keep summaries lean with Findings visible per group, which tucks the rest behind a View link |
Fix-forward for the two findings in Michele's review of traust#336 (chubirka, CHANGES_REQUESTED) — both independently verified before fixing.
1. Git transport auth (her P1). Verified read-only against a real GitHub upload-pack advertisement with a valid token:
Authorization: Bearer→ 401 invalid credentials (even for public repos);Authorization: Basic x-access-token:<token>→ 200. The mergedForgeApi.git_headerssent Bearer for GitHub hosts (the earlier Qodo fix covered GitLab's PRIVATE-TOKEN case only), so every authenticated deployment's mirror fetch failed.git_headersnow sends Basic for every forge kind:x-access-tokenfor GitHub kinds,oauth2for GitLab.2. A checkout names its origin (her P2). Verified: mirror worktrees carried no
remote.origin(the bare mirror is fetched by explicit URL), whilesession run --checkoutdispatches only the workspace path and vuln-scan/threat-model derive repository identity fromgit remote get-url originin the checkout — a regression from the clone-based flow, which had origin. The mirror now recordsremote.origin.url, which every worktree shares, restoring the identity contract for sessions, skills and hand runs.Changed tests
tests/v1/providers/test_forge_api.py::test_git_transport_auth…· old: github expected Bearer · new: expects Basicx-access-token· why: Bearer is refused by git smart-HTTPtests/v1/providers/test_mirror.pytoken test · old: raw token asserted in the env value · new: asserts the exact Basic header · why: the token now rides base64-encodednew:
test_a_checkout_names_its_origin_the_skills_derive_identity_fromA person reviewed each changed test and the behaviour change is intended