-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
credential-cache error "fatal: unable to connect to cache daemon: Unknown error" #5314
Comments
On another computer this bug occurs intermittently. |
Workaround: delete empty directory |
@rimrul Try this to reproduce (corrected path):
Expected: empty output What actually happens: "fatal: unable to connect to cache daemon: Unknown error". Interestingly To workaround: delete empty directory |
That does reproduce for me, with a slight difference. The |
And the mistery |
@rimrul Unfortunately error message "unable to connect to cache daemon" has two possible sources: git/builtin/credential-cache.c Lines 108 to 114 in f1241af
Assuming the error comes from the first source, perhaps the fix is to add extra error codes to function connection_fatally_broken: git/builtin/credential-cache.c Lines 24 to 27 in f1241af
|
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do sometimes encounter ECONNREFUSED on Windows aswell, though. we should handle these cases like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do sometimes encounter ECONNREFUSED on Windows aswell, though. we should handle these cases like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do sometimes encounter ECONNREFUSED on Windows aswell, though. we should handle these cases like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
How did you determine that? For me exit code %errorlevel% was 128. Is that equal to errno? I can't see how die_errno works. |
I wrote a small wrapper around |
Looking over the code of Lines 73 to 79 in f1241af
|
Thanks! So it was just a coincidence that errno 128 happens to relates to sockets. I'll cancel my PR. |
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do sometimes encounter ECONNREFUSED on Windows aswell, though. we should handle these cases like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do sometimes encounter ECONNREFUSED on Windows aswell, though. we should handle these cases like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
In 245670c (credential-cache: check for windows specific errors, 2021-09-14) we concluded that on Windows we would always encounter ENETDOWN where we would expect ECONNREFUSED on POSIX systems, when connecting to unix sockets. As reported in [1], we do encounter ECONNREFUSED on Windows if the socket file doesn't exist, but the containing directory does and ENETDOWN if neither exists. We should handle this case like we do on non-windows systems. [1] git-for-windows#4762 (comment) This fixes git-for-windows#5314 Helped-by: M Hickford <mirth.hickford@gmail.com> Signed-off-by: Matthias Aßhauer <mha1993@live.de>
Setup
Windows 11
Details
cmd
Credential saved and retrieved.
Error "fatal: unable to connect to cache daemon: Unknown error"
The text was updated successfully, but these errors were encountered: