1👍
I used perform_create method instead of pre_save
def perform_create(self, serializer):
serializer.save(owner=self.request.user)
0👍
Set ipdb in your code
def pre_save(self, obj):
import ipdb; ipdb.set_trace()
obj.owner = self.request.user
print obj.owner
And check the request.user attribute to understand the error.
Source:stackexchange.com