islice and iterator bug fix