Skip to content

Commit

Permalink
feat: modify weibo cookie
Browse files Browse the repository at this point in the history
  • Loading branch information
huifeng-kooboo committed May 22, 2024
1 parent 2210604 commit 321b83d
Show file tree
Hide file tree
Showing 8 changed files with 1,464 additions and 99 deletions.
Binary file modified .DS_Store
Binary file not shown.
3 changes: 3 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

40 changes: 0 additions & 40 deletions ChatGPT_开始时间2023-02-03-23_2023-02-05-23.csv

This file was deleted.

2 changes: 1 addition & 1 deletion config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# 微博请求头
g_weibo_headers = {
"user-agent":'''Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/123.0.0.0 Safari/537.36''',
"cookie": '''SINAGLOBAL=8442133158314.253.1626682443637; _ga=GA1.1.1931104488.1679164002; _ga_34B604LFFQ=GS1.1.1680396980.3.1.1680396980.60.0.0; SUBP=0033WrSXqPxfM725Ws9jqgMF55529P9D9WWqQKicwefG8NILG0Ep.eDf5JpX5KMhUgL.Foz0ShnNSh2f1Kz2dJLoIpjLxKqL1-BL1-eLxKnLB.-L1h.LxK.L1KBL12zt; UOR=login.sina.com.cn,weibo.com,www.google.com.hk; SCF=Aogk9bIUTRGH0-90pf0cHgo6aTBNG1Ja9dzC7fr27WMOo9vspUc-M4gLlCiXJFDfCSAW6kKIbevF6JTUu6dy3qk.; SUB=_2A25LD9GwDeRhGeRN71oW9C_Jwj6IHXVoZWt4rDV8PUNbmtAGLUnkkW9NU7PGeCV2MK7_zltmUsybAKrv6pCwz6Sh; ALF=1714630368; SSOLoginState=1712038369; XSRF-TOKEN=AvXDheiLHz1B-ZrQ3_gPuY6r; _s_tentry=-; Apache=5231598716270.725.1712283759731; ULV=1712283759783:23:1:1:5231598716270.725.1712283759731:1711805459329; WBPSESS=5wJyffL-CzuDMohJ6cqKmF941RsEE4ggDzsxBzyjKB7pczGaNYUiSAeqajQuIn0ZxrUX0Tk8_ME19k8WDwWCORh_tIQMYwcwYr5lQlPMVdXs0m-5pzc4lSK6xc1fnz75''',
"cookie": '''SINAGLOBAL=8442133158314.253.1626682443637; UOR=login.sina.com.cn,weibo.com,www.google.com.hk; SCF=Aogk9bIUTRGH0-90pf0cHgo6aTBNG1Ja9dzC7fr27WMOo9vspUc-M4gLlCiXJFDfCSAW6kKIbevF6JTUu6dy3qk.; ALF=1718948954; SUB=_2A25LSfcLDeRhGeRN71oW9C_Jwj6IHXVoJ3bDrDV8PUJbkNAGLXb3kW1NU7PGeHXAsQFUlpwb7qqQrEmb2jxeVpGH; SUBP=0033WrSXqPxfM725Ws9jqgMF55529P9D9WWqQKicwefG8NILG0Ep.eDf5JpX5KMhUgL.Foz0ShnNSh2f1Kz2dJLoIpjLxKqL1-BL1-eLxKnLB.-L1h.LxK.L1KBL12zt; _s_tentry=-; Apache=8781883208.852648.1716356956647; ULV=1716356956655:29:2:1:8781883208.852648.1716356956647:1714660326941; XSRF-TOKEN=UtIXy8Df-3vteZ8hPUWAby0R; WBPSESS=5wJyffL-CzuDMohJ6cqKmF941RsEE4ggDzsxBzyjKB4_qTigjjb5npyvd4hzq1ZJo3QE0GH0Fxr_aQOjFZ7VvJCWK7KpFQsKFY1BtTlAg6RqdUBJRwEF1X7O8BruXQff''',
"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9",
"accept-encoding":"gzip, deflate, br",
"accept-language":"zh-CN,zh;q=0.9,ko;q=0.8,en;q=0.7",
Expand Down
6 changes: 3 additions & 3 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ def parse_weibo_time_list(begin_time:str, end_time: str, day_interval: int = 4):
return time_list


search_key_list = ['ChatGPT','清华大学']
search_key_list = ['干旱']

search_config = {
"begin_time":"2023-02-03-23", # 开始时间 2022-11-08-1 : 表示2022年11月8号1时
"end_time":"2023-03-02-23", # 结果时间: 2022-11-25-1:表示2022年11月25号1时
"begin_time":"2021-01-04-23", # 开始时间 2022-11-08-1 : 表示2022年11月8号1时
"end_time":"2022-01-01-23", # 结果时间: 2022-11-25-1:表示2022年11月25号1时
"page" : "4" # 页码
}

Expand Down
64 changes: 9 additions & 55 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,56 +1,10 @@
async-generator==1.10
attrs==22.1.0
Automat==22.10.0
autopep8==2.0.0
beautifulsoup4==4.11.1
bs4==0.0.1
certifi==2022.9.24
cffi==1.15.1
charset-normalizer==2.1.1
constantly==15.1.0
cryptography==38.0.4
exceptiongroup==1.0.4
filelock==3.8.0
h11==0.14.0
hyperlink==21.0.0
idna==3.4
incremental==22.10.0
itemadapter==0.7.0
itemloaders==1.0.6
jmespath==1.0.1
lxml==4.9.1
outcome==1.2.0
packaging==21.3
parsel==1.7.0
Protego==0.2.1
pyasn1==0.4.8
pyasn1-modules==0.2.8
pycodestyle==2.10.0
pycparser==2.21
PyDispatcher==2.0.6
pyOpenSSL==22.1.0
pyparsing==3.0.9
PySocks==1.7.1
python-dateutil==2.8.2
queuelib==1.6.2
requests==2.28.1
requests-file==1.5.1
Scrapy==2.7.1
selenium==4.7.2
service-identity==21.1.0
beautifulsoup4==4.12.3
bs4==0.0.2
certifi==2024.2.2
charset-normalizer==3.3.2
idna==3.7
python-dateutil==2.9.0.post0
requests==2.32.2
six==1.16.0
sniffio==1.3.0
sortedcontainers==2.4.0
soupsieve==2.3.2.post1
tldextract==3.4.0
tomli==2.0.1
trio==0.22.0
trio-websocket==0.9.2
Twisted==22.10.0
typing_extensions==4.4.0
urllib3==1.26.13
w3lib==2.1.0
wsproto==1.2.0
zope.interface==5.5.2

-i https://pypi.tuna.tsinghua.edu.cn/simple
soupsieve==2.5
urllib3==2.2.1
1,075 changes: 1,075 additions & 0 deletions 干旱_开始时间2021-01-01-23_2021-01-03-23.csv

Large diffs are not rendered by default.

373 changes: 373 additions & 0 deletions 干旱_开始时间2021-01-04-23_2021-01-06-23.csv

Large diffs are not rendered by default.

0 comments on commit 321b83d

Please sign in to comment.