fixed thumbnail generation caught stopiteration