The PostgreSQL unique index has no data but the hint value already exists?

-sharp-sharp 
+------------+--------------------------+-----------------------------------------------------+
| Column     | Type                     | Modifiers                                           |
|------------+--------------------------+-----------------------------------------------------|
| id         | bigint                   |  not null default nextval("users_id_seq"::regclass) |
| name       | character varying(50)    |  not null                                           |
| email      | character varying(200)   |  not null                                           |
| mobile     | character varying(20)    |                                                     |
| created_at | timestamp with time zone |  not null default now()                             |
| password   | character varying        |  not null                                           |
| _2fa       | character varying(32)    |                                                     |
+------------+--------------------------+-----------------------------------------------------+
Indexes:
    "users_pkey" PRIMARY KEY, btree (id)
    "idx_users_email" UNIQUE, btree (lower("email"::text))
    "idx_users_name" UNIQUE, btree (lower("name"::text))
-sharp-sharp 
+------+--------+-----------------------+----------+-------------------------------+--------------------------------------------------------------+--------+
| id   | name   | email                 | mobile   | created_at                    | password                                                     | _2fa   |
|------+--------+-----------------------+----------+-------------------------------+--------------------------------------------------------------+--------|
| 2    | test1  | xx@gmail.com | <null>   | 2018-07-24 21:07:10.387633+08 | $2b$10$BdgYhkiJbEihnOYqpjPrxOO06HOJgKOsLI.n9TS0VQpL4..GT5R6. | <null> |
+------+--------+-----------------------+----------+-------------------------------+--------------------------------------------------------------+--------+
-- sql
INSERT INTO users (name, email, password, _2fa, created_at) VALUES ("test", "test@gmail.com", "$2b$10$Vj9tmaebstoLovqlgQ/a9ucM/RJjSoSVG2dYbk.LqxIn6AC/e37oa", Null, "2018-07-24 13:44:26+00:00") RETURNING users.id

get an error:

ERROR: duplicate key value violates unique constraint "idx_users_email"
DETAIL: Key (lower ("email"::text)) = (email) already exists.
Mar.30,2021

lower('email'::text) 'email'
-- create unique index idx_users_email on users USING btree(lower('email'::text))
--
create unique index idx_users_email on users USING btree(lower(email))
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-7b7141-1ed1f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-7b7141-1ed1f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?