When I try TextBlobDE(u"").sentiment I get an exception:
Traceback (most recent call last):
File "", line 1, in
File "/usr/lib/python2.7/site-packages/textblob/decorators.py", line 24, in get
value = obj.dict[self.func.name] = self.func(obj)
File "/usr/lib/python2.7/site-packages/textblob_de/blob.py", line 631, in sentiment
polarity = _polarity / len(self.sentences)
ZeroDivisionError: integer division or modulo by zero
I think it would be better to get a neutral sentiment back (Sentiment(polarity=0.0, subjectivity=0.0)) like in textblob.
When I try
TextBlobDE(u"").sentiment
I get an exception:Traceback (most recent call last): File "", line 1, in
File "/usr/lib/python2.7/site-packages/textblob/decorators.py", line 24, in get
value = obj.dict[self.func.name] = self.func(obj)
File "/usr/lib/python2.7/site-packages/textblob_de/blob.py", line 631, in sentiment
polarity = _polarity / len(self.sentences)
ZeroDivisionError: integer division or modulo by zero
I think it would be better to get a neutral sentiment back (
Sentiment(polarity=0.0, subjectivity=0.0)
) like in textblob.