Skip to content

Commit

Permalink
获取用户名生成callback参数缺少占位符 (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
huanghyw committed Dec 28, 2020
1 parent 24520eb commit 3971b56
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions jd_spider_requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ def get_username(self):
"""获取用户信息"""
url = 'https://passport.jd.com/user/petName/getUserInfoForMiniJd.action'
payload = {
'callback': 'jQuery'.format(random.randint(1000000, 9999999)),
'callback': 'jQuery{}'.format(random.randint(1000000, 9999999)),
'_': str(int(time.time() * 1000)),
}
headers = {
Expand Down Expand Up @@ -617,4 +617,4 @@ def submit_seckill_order(self):
if global_config.getRaw('messenger', 'enable') == 'true':
error_message = '抢购失败,返回信息:{}'.format(resp_json)
send_wechat(error_message)
return False
return False

0 comments on commit 3971b56

Please sign in to comment.