try not caching file if anything goes wrong during rendering.