The algorithm does not store every package in `dups_` directly but only when a duplicate package is found. At that point it adds the previously found one (line 1421-1426) and the new package (line 1427). For any further duplicate (the third, fourth etc.) it only appends the new one (line 1427). Does that make sense?