Commit 3e7242b1 authored by lixiaofang's avatar lixiaofang

update hj

parent 7be38d8c
This diff is collapsed.
......@@ -8,20 +8,11 @@ import traceback
from log_settings import *
import logging
auto_click_url = "http://earth.igengmei.com/api/v1/like"
auto_reply_url = "http://earth.igengmei.com/api/v1/reply/create"
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
auto_click_url = "http://earth.gmeiapp.com/api/v1/like"
auto_reply_url = "http://earth.gmeiapp.com/api/v1/reply/create"
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
def get_majia():
......
......@@ -7,19 +7,7 @@ import traceback
from log_settings import *
import logging
auto_click_url = "http://earth.igengmei.com/api/v1/like"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_click_url = "http://earth.gmeiapp.com/api/v1/like"
def get_majia():
......
......@@ -6,19 +6,7 @@ import random
import traceback
from log_settings import *
import logging
auto_click_url = "http://earth.igengmei.com/api/v1/like"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_click_url = "http://earth.gmeiapp.com/api/v1/like"
def get_majia():
......
......@@ -8,20 +8,8 @@ import traceback
from log_settings import *
import logging
auto_reply_url = "http://earth.igengmei.com/api/v1/reply/create"
auto_reply_url = "http://earth.gmeiapp.com/api/v1/reply/create"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
def get_majia():
......
......@@ -6,21 +6,12 @@ import random
import traceback
from log_settings import *
import logging
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
auto_pick_url = "http://earth.igengmei.com/api/v1/pick/do_pick"
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
auto_pick_url = "http://earth.gmeiapp.com/api/v1/pick/do_pick"
logging.error("index_first:%s" % traceback.format_exc())
return None
def get_majia():
......
......@@ -6,19 +6,7 @@ import random
import traceback
from log_settings import *
import logging
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def get_majia():
......
......@@ -7,22 +7,11 @@ import pandas as pd
import traceback
from log_settings import *
import logging
auto_click_url = "http://earth.igengmei.com/api/v1/like"
auto_reply_url = "http://earth.igengmei.com/api/v1/reply/create"
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
auto_click_url = "http://earth.gmeiapp.com/api/v1/like"
auto_reply_url = "http://earth.gmeiapp.com/api/v1/reply/create"
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
def get_cookies(user_id):
try:
......
......@@ -6,19 +6,7 @@ import random
import traceback
from log_settings import *
import logging
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def get_majia():
......
......@@ -7,19 +7,7 @@ import traceback
from log_settings import *
import logging
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
def get_majia():
......@@ -107,9 +95,7 @@ def time_conv(numtime):
def get_data(numtime):
try:
db = pymysql.connect(host="rm-2zej7rzxnj036zxt3.mysql.rds.aliyuncs.com", user='work',
passwd='oars152!traipseize738',
db="alpha", port=3306)
db = pymysql.connect(host="rm-2zej7rzxnj036zxt3.mysql.rds.aliyuncs.com", user='work',passwd='oars152!traipseize738',db="alpha", port=3306)
cursor = db.cursor()
cursor.execute("select user_id from account_user_auth where user_id not in (select user_id from pv_maidian where page_name ='home' and partiton_date >= %s )" ,(numtime))
data = cursor.fetchall()
......
......@@ -6,19 +6,11 @@ import random
import traceback
from log_settings import *
import logging
login_url = "http://earth.igengmei.com/api/account/login_pwd"
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
logging.error("index_first:%s" % traceback.format_exc())
return None
def get_majia():
......
......@@ -7,21 +7,9 @@ import traceback
from log_settings import *
import logging
auto_follow_url = "http://earth.igengmei.com/api/v1/follow"
auto_follow_url = "http://earth.gmeiapp.com/api/v1/follow"
auto_click_url = "http://earth.igengmei.com/api/v1/like"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_click_url = "http://earth.gmeiapp.com/api/v1/like"
def get_majia():
......
......@@ -7,19 +7,7 @@ import pandas as pd
import traceback
from log_settings import *
import logging
auto_urge_url = "http://earth.igengmei.com/api/v1/user/urge"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_urge_url = "http://earth.gmeiapp.com/api/v1/user/urge"
def get_majia():
......
......@@ -7,19 +7,7 @@ import pandas as pd
import traceback
from log_settings import *
import logging
auto_urge_url = "http://earth.igengmei.com/api/v1/user/urge"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_urge_url = "http://earth.gmeiapp.com/api/v1/user/urge"
def get_majia():
......
......@@ -7,19 +7,7 @@ import traceback
from log_settings import *
import logging
auto_urge_url = "http://earth.igengmei.com/api/v1/user/urge"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
return r1.cookies.get_dict()
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
auto_urge_url = "http://earth.gmeiapp.com/api/v1/user/urge"
def get_majia():
......@@ -134,7 +122,7 @@ if __name__ == "__main__":
for j in range(urge_num):
time.sleep(random.randint(10, 50))
time.sleep(random.randint(1, 15))
cook = logins()
......
This diff is collapsed.
......@@ -7,9 +7,8 @@ import traceback
# from log_settings import *
import logging
import json
auto_urge_url = "http://earth.igengmei.com/api/v1/user/urge"
login_url = "http://earth.igengmei.com/api/account/login_pwd"
login_url = "http://earth.gmeiapp.com/api/account/login_pwd"
def index_first():
try:
......
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