cleanup and raise RuntimeError on missing thumbnail