Commit 101fb02d authored by jimmy's avatar jimmy

提交百度和boss

parent b7d0d80b
...@@ -46,14 +46,13 @@ def CrawlerLaunch(): ...@@ -46,14 +46,13 @@ def CrawlerLaunch():
while True: while True:
now = datetime.datetime.now() now = datetime.datetime.now()
randomtime = random.randint(3, 120) randomtime = random.randint(3, 120)
randomtime =5
print(str(now) + ":启动等待时间"+str(randomtime)) print(str(now) + ":启动等待时间"+str(randomtime))
time.sleep(randomtime) time.sleep(randomtime)
res1 = crawler_baidu.CrawlerBaidu() res1 = crawler_baidu.CrawlerBaidu()
if res1==100: if res1==100:
time.sleep(5)
crawler_boss.CrawlerBoss() crawler_boss.CrawlerBoss()
def Log(dataS): def Log(dataS):
with open(str(datetime.date.today()) + ".txt", "a+") as f: with open(str(datetime.date.today()) + ".txt", "a+") as f:
f.write(dataS + "\n") f.write(dataS + "\n")
......
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