Bug 5598 - Unhelpful error message when auth.cert or auth.key path is wrong
Summary: Unhelpful error message when auth.cert or auth.key path is wrong
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: Mercurial (show other bugs)
Version: 4.0
Hardware: PC Linux
: wish bug
Assignee: Gregory Szorc
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-06-17 20:51 UTC by Scott Smith
Modified: 2017-07-23 14:47 UTC (History)
3 users (show)

See Also:
Python Version: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Scott Smith 2017-06-17 20:51 UTC
I was getting an "abort: No such file or directory" message whenever I issued an hg command that hit the server (e.g. clone, update, incoming, etc).

It was only after I'd spent two days that I finally noticed the paths to my cert and private key in my .hgrc config file were wrong.

If the message had said something like "cert file specified in /home/scott/hgrc auth.myserver.cert = /etc/ssl/certs/yadda.pem not found", the problem would have been immediately obvious.

Thanks
Comment 1 Yuya Nishihara 2017-06-18 10:22 UTC
Perhaps we'll need to catch IOError somewhere in sslutil.py,
probably load_cert_chain().
Comment 2 Gregory Szorc 2017-07-11 00:11 UTC
I can see how this error could be very annoying.

I'll try to get a fix for this in Mercurial 4.3.
Comment 3 Gregory Szorc 2017-07-23 14:47 UTC
Fixed by the following changeset:

changeset:   46072:3bdbbadddecc
user:        Gregory Szorc <gregory.szorc@gmail.com>
date:        Mon Jul 10 21:09:46 2017 -0700
summary:     sslutil: check for missing certificate and key files (issue5598)

(Where is the bot that is supposed to be updating bugs?)