Commit 16db11dd authored by lixiaofang's avatar lixiaofang

add

parent 2c6edb5e
This diff is collapsed.
......@@ -4,7 +4,7 @@ import random
import traceback
from log_settings import *
import logging
from auto_request import login, click, time_conv
from auto_request import login, click
def write_id_file():
......@@ -34,7 +34,7 @@ if __name__ == "__main__":
randoms_id = []
for i in range(lenn % 2):
for i in range(lenn/2):
rand_num = random.randint(0, len(user_ids)-1)
randoms_id.append(user_ids[rand_num])
......
......@@ -33,7 +33,7 @@ if __name__ == "__main__":
randoms_id = []
for i in range(lenn % 2):
for i in range(lenn/2):
rand_num = random.randint(0, len(user_ids) - 1)
randoms_id.append(user_ids[rand_num])
if randoms_id:
......
......@@ -2,9 +2,9 @@ import time
import pymysql
import random
import traceback
from log_settings import *
# from log_settings import *
import logging
from auto_request import login, click, time_conv,get_comment,reply
from auto_request import login, time_conv, get_comment, reply
from auto_request import host, user, db, passwd
......@@ -81,7 +81,6 @@ if __name__ == "__main__":
comment = get_comment()
if cook is not None:
write_id_file(rand_id)
reply(cook, rand_id, comment)
......
......@@ -4,7 +4,7 @@ import random
import traceback
from log_settings import *
import logging
from auto_request import login, click, time_conv,reply,get_comment
from auto_request import login, reply, get_comment
def write_id_file():
......@@ -34,8 +34,8 @@ if __name__ == "__main__":
randoms_id = []
for i in range(lenn % 2):
rand_num = random.randint(0, len(user_ids)-1)
for i in range(lenn / 2):
rand_num = random.randint(0, len(user_ids) - 1)
randoms_id.append(user_ids[rand_num])
......@@ -50,7 +50,6 @@ if __name__ == "__main__":
cook = login()
if cook is not None:
reply(cook, i, comment)
except:
logging.error("catch exception,main:%s" % traceback.format_exc())
......@@ -2,7 +2,7 @@ import time
import pymysql
import random
import traceback
from log_settings import *
# from log_settings import *
import logging
from auto_request import login, click, time_conv, get_comment, reply
......@@ -32,12 +32,10 @@ if __name__ == "__main__":
lenn = len(user_ids)
randoms_id = []
for i in range(lenn % 2):
for i in range(int(lenn / 2)):
rand_num = random.randint(0, len(user_ids) - 1)
randoms_id.append(user_ids[rand_num])
if randoms_id:
for i in randoms_id:
time.sleep(random.randint(10, 50))
......
213
13
13
13
31
1
3
13
13
13
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment