rgfewfger
This commit is contained in:
16
推特/main.py
16
推特/main.py
@@ -278,10 +278,18 @@ class Hub_Web:
|
||||
tab.get(url="https://x.com/i/api/graphql")
|
||||
|
||||
url_id = ""
|
||||
res = tab.listen.wait() # 等待并获取一个数据包
|
||||
for i in res.response.body["data"]['user']['result']["timeline"]['timeline']["instructions"][1]["entries"]:
|
||||
if "tweet" in i["entryId"]:
|
||||
url_id += i["content"]['itemContent']['result']["rest_id"] + ";"
|
||||
|
||||
while True:
|
||||
try:
|
||||
res = tab.listen.wait() # 等待并获取一个数据包
|
||||
for i in res.response.body["data"]['user']['result']["timeline"]['timeline']["instructions"][1][
|
||||
"entries"]:
|
||||
if "tweet" in i["entryId"]:
|
||||
url_id += i["content"]['itemContent']['result']["rest_id"] + ";"
|
||||
|
||||
break
|
||||
except:
|
||||
continue
|
||||
|
||||
self.xstart_info.url_id = url_id
|
||||
self.xstart_info.save()
|
||||
|
||||
Reference in New Issue
Block a user