Django – TypeError: unhashable type: ‘list’

unhashable

Se você recebeu o erro TypeError: unhashable type: ‘list’ if not cls._meta.get_field(cls.USERNAME_FIELD).unique and not any( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Isso pode ser por que você colocou o atributo USERNAME_FIELD do models de User como list ou tuple, este campo deve ter valor unico, caso esteja USERNAME_FIELD = [‘username’] basta subustituir por USERNAME_FIELD = ‘username’ Espero que tenha ajudado.