Adding id field to tuple and adjusting hashcode accordingly. Found and f...

...ixes small bug with range criterias