Handle ResourceError in download.py.