checking first there are duplciates ids before changing to unique names
This commit is contained in:
parent
412042d987
commit
c66aedfa65
|
@ -1153,9 +1153,9 @@ def _idvalset(idx, valset, argnames, idfn, ids):
|
||||||
def idmaker(argnames, argvalues, idfn=None, ids=None):
|
def idmaker(argnames, argvalues, idfn=None, ids=None):
|
||||||
ids = [_idvalset(valindex, valset, argnames, idfn, ids)
|
ids = [_idvalset(valindex, valset, argnames, idfn, ids)
|
||||||
for valindex, valset in enumerate(argvalues)]
|
for valindex, valset in enumerate(argvalues)]
|
||||||
duplicates = [testid for testid in ids if ids.count(testid) > 1]
|
if len(set(ids)) != len(ids):
|
||||||
if duplicates:
|
|
||||||
# The ids are not unique
|
# The ids are not unique
|
||||||
|
duplicates = [testid for testid in ids if ids.count(testid) > 1]
|
||||||
counters = collections.defaultdict(lambda: 0)
|
counters = collections.defaultdict(lambda: 0)
|
||||||
for index, testid in enumerate(ids):
|
for index, testid in enumerate(ids):
|
||||||
if testid in duplicates:
|
if testid in duplicates:
|
||||||
|
|
Loading…
Reference in New Issue