|
@@ -241,9 +241,19 @@ def get_commerce_rank_list_data(room_id, sec_anchor_id, anchor_id, result):
|
241
|
241
|
def scrape(room_id,sec_anchor_id,anchor_id):
|
242
|
242
|
rds_list = RdsDouyinHourlyRankList()
|
243
|
243
|
|
|
244
|
+ key = 'DOUYIN_SCRAPE_DID_IID_TTREQ_1221'
|
|
245
|
+ rdid = DbRedis.connect().rpop(key)
|
|
246
|
+ if rdid:
|
|
247
|
+ result = rdid.split('@@@')
|
|
248
|
+ else:
|
|
249
|
+ result = []
|
|
250
|
+ return None
|
|
251
|
+
|
|
252
|
+ DbRedis.connect().lpush(key, rdid)
|
|
253
|
+
|
244
|
254
|
try:
|
245
|
255
|
# 带货小时榜
|
246
|
|
- commerce_response_json = get_commerce_rank_list_data(room_id=room_id, sec_anchor_id=sec_anchor_id, anchor_id=anchor_id)
|
|
256
|
+ commerce_response_json = get_commerce_rank_list_data(room_id=room_id, sec_anchor_id=sec_anchor_id, anchor_id=anchor_id, result=result)
|
247
|
257
|
|
248
|
258
|
if commerce_response_json is None:
|
249
|
259
|
print(
|