Skip to content

fix(extensions): support non-GitHub git URLs for extension installation#2539

Open
d191 wants to merge 1 commit intoQwenLM:mainfrom
d191:main
Open

fix(extensions): support non-GitHub git URLs for extension installation#2539
d191 wants to merge 1 commit intoQwenLM:mainfrom
d191:main

Conversation

@d191
Copy link

@d191 d191 commented Mar 20, 2026

TLDR

Fixes extension installation from local domain git servers (GitLab, Bitbucket, etc.) by catching errors from parseGitHubRepoForReleases and falling back to use the source URL directly.

Dive Deeper

When installing an extension from a self-hosted git server (e.g., https://gitlab.company.com/team/my-extension), the installation failed after user confirmation with:

 Invalid GitHub repository source: https://gitlab.company.com/team/my-extension. Expected "owner/repo" or a github repo uri.

The root cause was in packages/core/src/extension/extensionManager.ts - the getExtensionId function unconditionally called parseGitHubRepoForReleases() which only supports GitHub URLs.

Solution: Wrapped the call in try-catch. If parsing fails (non-GitHub URL), use the source URL as-is for generating the extension ID - same behavior as local type installations.

Reviewer Test Plan

  1. Run npm install and npm run build
  2. Try installing an extension from a non-GitHub git URL:
    qwen extensions install https://gitlab.company.com/team/test-extension
  3. Verify the extension installs successfully
  4. Run qwen extensions list to confirm the extension appears

Testing Matrix

🍏 🪟 🐧
npm run
npx
Docker
Podman - -
Seatbelt - -

Linked issues / bugs

Fixes #2538

Fixes extension installation from local domain git servers (GitLab, Bitbucket, etc.)
by catching errors from parseGitHubRepoForReleases and falling back to use the source URL directly.

- Add unit test for non-GitHub git URLs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extension installation fails from non-GitHub git servers

1 participant