counter.py removes duplicate ids