Facebot icon indicating copy to clipboard operation
Facebot copied to clipboard

send_person() error on Windows

Open mphilli opened this issue 9 years ago • 0 comments

Just wanted to inform you that when I tried to use the send_person method, I got the following error, and my message would not send:

File ".\Facebot\facebot\message.py", line 127, in send_person
    "message_batch[0][timestamp_relative]": datetime.now().strftime("%I:%M%P"),
ValueError: Invalid format string

However, I saw in this stackoverflow thread that %H is best on Windows OS for where %I is. Also, the 'P' in %P must be lowercase. Therefore, I changed this line of code in message.py to the following, and now it runs fine:

"message_batch[0][timestamp_relative]": datetime.now().strftime("%H:%M%p"),

Just a caution to Windows users.

mphilli avatar May 29 '16 21:05 mphilli