Skip to content

[Bug]: Remote URL parser breaks for PRs when using a custom git SSH alias #9458

Description

@RafaelScharf

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

apps/desktop

Steps to reproduce

Description

When asking T3 Coder to read or interact with a Pull Request, the URL parser breaks if the local git repository uses a custom SSH alias. This is a very common setup for developers using ~/.ssh/config to manage multiple GitHub accounts on the same machine.

Instead of parsing the base domain (github.com), the tool uses the literal SSH host alias string to construct the HTTPS web URL, leading to an invalid domain and a fetch failure.

Steps to reproduce

  1. Configure a custom SSH alias in ~/.ssh/config, for example:
    Host github.com-customalias
    HostName github.com
    User git
    IdentityFile ~/.ssh/id_rsa_custom
    
  2. Set a repository's remote URL using this alias:
    git remote set-url origin git@github.com-customalias:organization/repository.git
  3. Prompt T3 Coder to read or review a specific Pull Request (e.g., PR Add Expo mobile client and wire up dev:mobile workflow #123).

Expected behavior

The tool should recognize the base GitHub host, strip the custom alias suffix (-customalias), and construct the correct web URL to fetch the PR data:
https://github.com/organization/repository/pull/123

Actual behavior

The tool incorrectly injects the full alias string into the HTTPS URL, resulting in a DNS/fetch error. It attempts to access:
https://github.com-customalias/organization/repository/pull/123

Impact

Minor bug or occasional failure.
Prevents PR analysis for developers working in multi-tenant/multi-account GitHub environments.

Version or commit

v0.0.38

Environment

macOS 15.7.4 (24G517)

Logs or stack traces

Screenshots, recordings, or supporting files

Captura de Tela 2026-09-03 às 14.44.19.png

Workaround

Changing the remote URL back to standard HTTPS/SSH (git@github.com:...) fixes the AI tool, but this breaks the developer's local SSH routing for pushes/pulls. The tool needs a more robust remote parsing logic to ignore SSH host aliases.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is broken or behaving incorrectly.needs-triageIssue needs maintainer review and initial categorization.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions