PSA: YunoHost throwing 500 on app install

App installation/update failures – Git HTTP/2 issue with GitHub

Hello,

I am experiencing the same issue on several independent YunoHost servers, hosted on different networks.

The problem affects several applications, both when installing a new app and when updating existing apps.

YunoHost fails while fetching application sources, typically with:

Could not fetch source files, is the URL correct?

and:

git ls-remote ... returned non-zero exit status 128

Internet connectivity itself seems fine. For example:

curl -4I https://github.com

returns:

HTTP/2 200

However, Git behaves differently.

With the default configuration:

git ls-remote https://github.com/YunoHost-Apps/synapse_ynh.git HEAD

Git unexpectedly asks for GitHub credentials and then fails with:

error: RPC failed; HTTP 401 curl 22 The requested URL returned error: 401
fatal: expected flush after ref listing

But forcing HTTP/1.1 works immediately:

git -c http.version=HTTP/1.1 ls-remote https://github.com/YunoHost-Apps/synapse_ynh.git HEAD

Output:

2cee01e894e7e6cdbd383635c4f035bfb5147e50    HEAD

Git version on the tested server:

git version 2.39.5

There is no custom Git HTTP/proxy configuration and no proxy environment variable.

Since the same kind of failure occurs on several YunoHost servers and with different applications.

Is this a known issue or a recent regression?

Thanks.