utdal / profiles

A simple CRUD/search profile system for research profiles, providing user-editable information and basic pages to aesthetically promote and highlight researcher activities and achievements.
MIT License
6 stars 0 forks source link

Duplicate entry related to user role association #145

Open shukla-m opened 3 months ago

shukla-m commented 3 months ago

See Sentry error PROFILES-63.

Illuminate\Database\QueryException

SQLSTATE[23000]: Integrity constraint violation: Duplicate entry for key 'role_user.PRIMARY' (SQL: insert into role_user (role_id, user_id) values (*, ****))

wunc commented 3 months ago

Related to #92. (Not really duplicate, but it's an error that would likely be mitigated by implementing a submit button disable). Another solution is to maybe refactor the LdapAttributeHandler@syncUserRoles() method to more gracefully handle mismatched roles (maybe cached?) between closely-spaced requests.