O IntegrityError no valor da chave duplicado viola o detalhe de restrição exclusivo: o ID da chave já existe.

# Reset the counter of a table named yourTable to start at id # 1453
ALTER SEQUENCE yourTable_id_seq RESTART WITH 1453
Trained Tuna