You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Django users
When I try to update_or_create model object with primary key that is also a foreign key in some other model I get DoesNotExist error and then IntegrityError duplicate entry error. My way around this is to try get the object and then update it without the primary key or create it (with primary key of course) on exception. Is it a bug or am i doing something wrong?