Compare commits
4 Commits
f84cd3cdfc
...
776df13ed8
| Author | SHA1 | Date | |
|---|---|---|---|
| 776df13ed8 | |||
| 336250ab66 | |||
| c43d79d9a6 | |||
| 66822bdfce |
2
.gitignore
vendored
2
.gitignore
vendored
@ -140,5 +140,5 @@ dmypy.json
|
||||
# End of https://www.toptal.com/developers/gitignore/api/python
|
||||
.idea
|
||||
cqhttp/data
|
||||
session.token
|
||||
device.json
|
||||
session.token
|
||||
|
||||
@ -23,7 +23,7 @@ account: # 账号相关
|
||||
# sign-server: 'http://127.0.0.1:8080' # 本地签名服务器
|
||||
# sign-server: 'https://signserver.example.com' # 线上签名服务器
|
||||
# 服务器可使用docker在本地搭建或者使用他人开放的服务
|
||||
sign-server: 'http://127.0.0.1:5709/'
|
||||
sign-server: 'http://dawang.xiaoyan159.space:5709/'
|
||||
|
||||
heartbeat:
|
||||
# 心跳频率, 单位秒
|
||||
|
||||
BIN
cqhttp/go-cqhttp_windows_amd64.exe
Normal file
BIN
cqhttp/go-cqhttp_windows_amd64.exe
Normal file
Binary file not shown.
@ -74,6 +74,7 @@ def getWenzhangInfo():
|
||||
chrome_option.add_argument('--no-sandbox') # 解决DevToolsActivePort文件不存在的报错
|
||||
chrome_option.add_argument('--disable-gpu') # 谷歌文档提到需要加上这个属性来规避bug
|
||||
chrome_option.add_argument('--hide-scrollbars') # 隐藏滚动条, 应对一些特殊页面
|
||||
chrome_option.add_experimental_option('excludeSwitches', ['enable-automation'])
|
||||
chrome_option.add_argument('--headless')
|
||||
|
||||
browser = Chrome(executable_path=driver_path, options=chrome_option)
|
||||
@ -103,8 +104,9 @@ def getWenzhangInfo():
|
||||
url = data["url"]
|
||||
if url:
|
||||
# 请求文章正文内容
|
||||
wenzhangGet = browser.get(url)
|
||||
print(wenzhangGet.text)
|
||||
browser.get(url)
|
||||
element = browser.find_element(by='XPATH', value="//article")
|
||||
print(element)
|
||||
# author = None
|
||||
# if data.find("太能喵")>0:
|
||||
# weitoutiaoMap["太能喵"] = weitoutiaoMap["太能喵"]+1
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user