try to handle missing files better