If mercurial gives an error message like abort: cannot import module _ssl, it is because your python doesn't have ssl support. For example, the python inside sage is not built with ssl support. To fix this, you might be able to upgrade your python installation, or, if you are using the sage supplied mercurial, you can install openssl inside sage and then recompile python.
To do this, you should be able to do:
Optional: You are about to compile openssl and python, so if you have multiple cpus and want this to go faster, first type export MAKE="make -jX", where X is the number of threads that you want to use.
sage -i openssl
sage -f python
The package names might need to be changed to refer to specific versions. To see what the exact package names are, you can type sage -i and sage -o.
