Closed Torxed closed 7 years ago
I am having trouble reproducing this, are there any more details you can provide?
import fbchat
client = fbchat.Client(None, None, debug=False, do_login=False)
client.loadSession('fb.sesh')
friends = client.getUsers("Friends name")
friend = friends[0]
print(friend) # Verify user_id is the correct one, and it is
client.sendLocalImage(friend.uid, message='duty_calls.png', image='duty_calls.png') # send local image # Raises the exception
What fails is:
jobj = json.loads(r._content[9:])
_content
being a string of nothing, that is ""
.
Basically something in postFile()
returns ""
to uploadImage()
.
[torxed@sidekick ~]$ file duty_calls.png
duty_calls.png: PNG image data, 300 x 330, 8-bit grayscale, non-interlaced
Maybe you could provide us with the actual image (Though I do appreciate your file
output)
Could you perhaps try this in v. 1.0.x
? ;)
Sending a private conversation creates the same problem.