I have declared a signal for the UserProfile model which updates some other fields. The stored data are coming from a web service.
post_save.connect(user_profile_update, sender=UserProfile)
in user_profile_update, i did this:
profile = get_object_or_404(UserProfile, user=instance)
profile.province = xml.duzeltilmisil #this comes from a web service
profile.save()
and i got this error:
'NoneType' object is not callable
profile.save()
There is an other error but what did I do was also recursive. When I update UserProfile, it should trig user_profile_update again.
Is there any reasonable way to update those fields during the save?