Use sys.exit instead of RuntimeError in config.py

This is because RuntimeError is not caught in that file, since it is run at
import time.
Fail gracefully if there is a config file and pyyaml is not installed