Friday 15 June 2012

Django TypeError: 'int' object is not callable -


I am getting the following error:

Type error: 'int' is not an object File / user / user / document / workspace / livewire sms / sms / model / message

feedback = receiver (sign = self, sender = sender, ** name) file ", Line 156, my_handler example. Charge = instance.length (instance.content)

From this snippet of code:

  @receiver (Pre_save) , Sender = message) def my_handler (sender, ** kwargs): eg Runt = kwargs ['Examples'] If not, in case. Incharge: Example. Charge = instance.length (instance.content)   

This function is its calling:

  @property def Length (self): Return Lane (Self Contents) / 160 + 1   

Can someone explain the error? Thanks.

You found this error because length returns a object and you have Tried to call it.

  example.charge = instance.length # instead of the example. Long (instance.content)    

No comments:

Post a Comment