Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_file_dup(filename):
with data.open_text(data, filename) as particle_data:
p = pd.read_csv(particle_data, comment="#")
duplicates = {item for item, count in Counter(p.ID).items() if count > 1}
assert duplicates == set()