Commit 8809504d authored by lixiaofang's avatar lixiaofang

ad

parent 5b89b140
import requests
import traceback
import logging
<<<<<<< HEAD
import json
=======
>>>>>>> sentry
from libs.cache import redis_client
login_url = "http://earth.iyanzhi.com/api/account/login_pwd"
......@@ -26,10 +23,8 @@ def get_cook():
data = open("/srv/apps/physical/vest/data/vest_user_email.txt")
list = []
dicts = {}
for i in data:
list.append(i.strip('\n').strip(','))
for i in list:
cookies = index_first()
post_dict = {
......@@ -43,18 +38,13 @@ def get_cook():
cookies=cookies
)
headers = response.headers
print(response.text)
cook = headers['Set-Cookie'].split(";")
cook = cook[0].split('=')[1]
logging.info("response.text :%s" % response.text)
dicts[i] = cook
return dicts
except:
logging.error("index_first:%s" % traceback.format_exc())
return None
......
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