improving coverage for error.py