check also the number of retrieved items when determing if we can leave the loop
complain only if really necessary + version bump