Kallithea issues archive

Issue #65: Cloning git repository fails if repo type is set to hg

Reported by: Michael DePalatis
State: new
Created on: 2014-12-18 09:32
Updated on: 2014-12-18 09:32


If creating a new repository and trying to import from a git repository, the operation fails with an error such as this:

URLError: <urlopen error [https://:*****@github.com/redodo/tortilla] org_exc: HTTP Error 406: Not Acceptable>

The error in browser is only invalid clone url. This only occurs if the repository type is set to hg (as per the default). A better solution would be to have a separate form for importing a repository which detects the repo type (which is usually trivial for a URL which will almost always end in .git or .hg). Alternatively, simply ignoring the "type" option would work. Additionally, when importing repositories, the repo name should be filled out automatically based on the remote URL.

I am listing this as a "minor" bug instead of "trivial" mostly because the error messages aren't very helpful in explaining what the problem is, which can be solved with two mouse clicks.