Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[weibo][error] Unable to download data: JSONDecodeError: Expecting value: line 2 column 3 (char 3) #4773

Closed
liyiecho opened this issue Nov 5, 2023 · 0 comments

Comments

@liyiecho
Copy link

liyiecho commented Nov 5, 2023

gallery-dl_weibo

date stream content
2023/11/05 11:19:39 stdout requests.exceptions.JSONDecodeError: Expecting value: line 2 column 3 (char 3)
2023/11/05 11:19:39 stdout raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/site-packages/requests/models.py", line 975, in json
2023/11/05 11:19:39 stdout ^^^^^^^^^^^^^^^
2023/11/05 11:19:39 stdout data = response.json()
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/site-packages/gallery_dl/extractor/weibo.py", line 160, in _pagination
2023/11/05 11:19:39 stdout for status in self.statuses():
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/site-packages/gallery_dl/extractor/weibo.py", line 53, in items
2023/11/05 11:19:39 stdout for msg in extractor:
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/site-packages/gallery_dl/job.py", line 124, in run
2023/11/05 11:19:39 stdout Traceback (most recent call last):
2023/11/05 11:19:39 stdout  
2023/11/05 11:19:39 stdout During handling of the above exception, another exception occurred:
2023/11/05 11:19:39 stdout  
2023/11/05 11:19:39 stdout json.decoder.JSONDecodeError: Expecting value: line 2 column 3 (char 3)
2023/11/05 11:19:39 stdout raise JSONDecodeError("Expecting value", s, err.value) from None
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/json/decoder.py", line 355, in raw_decode
2023/11/05 11:19:39 stdout ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2023/11/05 11:19:39 stdout obj, end = self.raw_decode(s, idx=_w(s, 0).end())
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/json/decoder.py", line 337, in decode
2023/11/05 11:19:39 stdout ^^^^^^^^^^^^^^^^^^^^^^^^^^
2023/11/05 11:19:39 stdout return _default_decoder.decode(s)
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/json/init.py", line 346, in loads
2023/11/05 11:19:39 stdout ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2023/11/05 11:19:39 stdout return complexjson.loads(self.text, **kwargs)
2023/11/05 11:19:39 stdout File "/usr/local/lib/python3.12/site-packages/requests/models.py", line 971, in json
2023/11/05 11:19:39 stdout Traceback (most recent call last):
2023/11/05 11:19:39 stdout [weibo][debug]
2023/11/05 11:19:39 stdout [weibo][error] Unable to download data:  JSONDecodeError: Expecting value: line 2 column 3 (char 3)
2023/11/05 11:19:39 stdout [urllib3.connectionpool][debug] https://login.sina.com.cn:443 "GET /sso/login.php?url=https%3A%2F%2Fweibo.com%2Fajax%2Fstatuses%2Fmymblog%3Fuid%3D2219124641%26feature%3D0&_rand=1699154379.584&gateway=1&service=miniblog&entry=miniblog&useticket=1&returntype=META&sudaref=&_client_version=0.6.33 HTTP/1.1" 200 None
2023/11/05 11:19:39 stdout [urllib3.connectionpool][debug] Starting new HTTPS connection (1): login.sina.com.cn:443
2023/11/05 11:19:39 stdout [urllib3.connectionpool][debug] https://weibo.com:443 "GET /ajax/statuses/mymblog?uid=2219124641&feature=0 HTTP/1.1" 302 597
2023/11/05 11:19:39 stdout [urllib3.connectionpool][debug] Starting new HTTPS connection (1): weibo.com:443
2023/11/05 11:19:39 stdout [weibo][debug] Loading cookies from './gallery-dl/cookies/weibo.com_cookies.txt'
2023/11/05 11:19:39 stdout [weibo][debug] Using WeiboFeedExtractor for 'https://weibo.com/u/2219124641?tabtype=feed'
2023/11/05 11:19:39 stdout [weibo][debug] Using WeiboUserExtractor for 'https://weibo.com/u/2219124641'
2023/11/05 11:19:38 stdout [gallery-dl][debug] Starting DownloadJob for 'https://weibo.com/u/2219124641'
2023/11/05 11:19:38 stdout [gallery-dl][debug] Configuration Files ['/etc/gallery-dl.conf']
2023/11/05 11:19:38 stdout [gallery-dl][debug] requests 2.31.0 - urllib3 2.0.7
2023/11/05 11:19:38 stdout [gallery-dl][debug] Python 3.12.0 - Linux-4.4.302+-x86_64-with
2023/11/05 11:19:38 stdout [gallery-dl][debug] Version 1.26.1

Finally, I found out that the cookie had expired.🤣 I hope it will prompt that the cookie has expired.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants