Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/tiktokapi.py", line 95, in getTrending return self.send_get_request(url, params) File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/tiktokapi.py", line 75, in send_get_request data = get_req_json(url, params=None, headers=self.headers) File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/utils.py", line 28, in get_req_json return json.loads(r.text) File "/usr/lib/python3.7/json/__init__.py", line 348, in loads return _default_decoder.decode(s) File "/usr/lib/python3.7/json/decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/lib/python3.7/json/decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
python3.7
code:
from TikTokAPI import TikTokAPI
api = TikTokAPI()
retval = api.getTrending(count=5)
it worked until last week. Found similar issues on the other unofficial tiktok python API, but no one could solve it at the moment.
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/tiktokapi.py", line 95, in getTrending return self.send_get_request(url, params) File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/tiktokapi.py", line 75, in send_get_request data = get_req_json(url, params=None, headers=self.headers) File "/home/erre4/.local/lib/python3.7/site-packages/TikTokAPI/utils.py", line 28, in get_req_json return json.loads(r.text) File "/usr/lib/python3.7/json/__init__.py", line 348, in loads return _default_decoder.decode(s) File "/usr/lib/python3.7/json/decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/lib/python3.7/json/decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
python3.7
code:
it worked until last week. Found similar issues on the other unofficial tiktok python API, but no one could solve it at the moment.