fix: Handle SSH over HTTPS GitHub remote URLs#2049
Open
charlesvien wants to merge 12 commits into05-05-onboarding_nitsfrom
Open
fix: Handle SSH over HTTPS GitHub remote URLs#2049charlesvien wants to merge 12 commits into05-05-onboarding_nitsfrom
charlesvien wants to merge 12 commits into05-05-onboarding_nitsfrom
Conversation
Member
Author
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Contributor
Prompt To Fix All With AIFix the following 1 code review issue. Work through them one at a time, proposing concise fixes.
---
### Issue 1 of 1
packages/git/src/utils.test.ts:71-85
**Identical org and repo values hide swap bugs**
Every successful-parse test case uses `"posthog"` for both `organization` and `repository`. If `segments[0]` and `segments[1]` (or `scpMatch[2]` and `scpMatch[3]`) were ever transposed, all tests would still pass. Using distinct values like `"my-org"` / `"my-repo"` in at least one test per code path would catch that class of regression. This violates the simplicity rule "expresses every idea that we need to express."
Reviews (1): Last reviewed commit: "Handle SSH over HTTPS GitHub remote URLs" | Re-trigger Greptile |
k11kirky
approved these changes
May 6, 2026
Contributor
k11kirky
left a comment
There was a problem hiding this comment.
woof, i expect there is some libs to handle this, but fine for now.
7bbd3cb to
23df09d
Compare
9065fa0 to
131321a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Problem
GitHub URL parsing relied on hand-rolled regex that missed SSH-over-HTTPS forms and didn't handle nullable input.
Changes
pathon parseGitHubUrl and reuse it for parsePrUrlparsed.pathdirectly in git service compare and PR list callsHow did you test this?
Manually
Publish to changelog?