我得到了以下函数:def infinite_count():
a = 1
while a <= int(reciever_runtime):
send_message(float(reciever_sleeptime),a)
print_stats()
else:
print ("All the messages have been sent")
每当我运行代码时,都会出现以下错误:
^{pr2}$
以下是send_message()函数的代码:def send_message(sleep_time, send_msg):
#Entering the message
#Setting path to the textbox
message_textbox = driver.find_element_by_xpath("""//*[@id="composerInput"]""")
#Typing the message
message_textbox.send_keys(send_msg)
#Sending the message
#Setting path
send_button = driver.find_element_by_xpath("""//*[@id="u_0_5"]""")
#Clicking the button in order to send the message
send_button.click()
#Wait time before sending another message IN SECONDS!
time.sleep( sleep_time )
怎么回事?我使用的是python3.5