Skip to content Skip to sidebar Skip to footer

'nonetype' Object Has No Attribute 'encode'

I'm trying to use GeoAdmin in GeoDjango. I have a table planet_osm_point and I would like to see it in the admin interface. I'm a beginner in django. I have this problem : Environm

Solution 1:

You have a model class whose __unicode__ method is returning None.

Make sure it actually has a return statement that returns a Unicode value instead.

Solution 2:

return str(self.model_attribute) for the unicode

Post a Comment for "'nonetype' Object Has No Attribute 'encode'"