mirror of
https://github.com/pocket-id/pocket-id.git
synced 2025-12-09 14:53:00 +03:00
🐛 Bug Report: Error syncing LDAP groups - invalid input syntax for type uuid (SQLSTATE 22P02) #327
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @user00265 on GitHub.
Reproduction steps
I have LDAP configured and syncing mostly everything. If I remove all LDAP users and groups and sync, it will not display an error. Any syncs after that, however will throw an error on the log.
Part of the issue seems to be it is trying to do something with a local user that does not exist in LDAP who happens to have an empty uuid in the database.
The database backend is PostgreSQL.
Expected behavior
It should successfully sync.
Actual Behavior
Succeeds on initial sync, displays "Something went wrong" on any attempts to sync afterwards.
Version and Environment
v0.35.2Log Output
@stonith404 commented on GitHub:
Thanks for your detailed explanation, this should be fixed in
0.35.3.@user00265 commented on GitHub:
To be specific:
So to answer your question, the user is the default admin local user, which had been using a name that eventually conflicted with LDAP users. This has been cleared, LDAP was disabled, users were removed, and LDAP re-enabled and re-synced.
The database shows 3 users, which is correct. 2 from LDAP and 1 from the local account. The conflicting user show NULL as the value for the
ldap_idcolumn.@stonith404 commented on GitHub:
Could it be that you have a non LDAP user in the Pocket ID database that has the same username as a user on your LDAP server?
@stonith404 commented on GitHub:
Thanks for reporting this.
So there is an user in the database that has an empty uuid? Is anything special about this user? For example can you remember that you've tried to delete this user or did you update it manually in the database?
Also do the other columns of the user look correct or has he also for example an empty username, email or name?