Handle EOFError and IOError with the loading of cache files.