Closed mengguiyouziyi closed 3 years ago
With the pyppeteer version, try adding a custom verifyFp cookie (like so https://github.com/davidteather/TikTok-Api/pull/342#issuecomment-727009300). It should look something like:
from TikTokApi import TikTokApi
api = TikTokApi(debug=True)
results = 10
trending = api.trending(count=results, custom_verifyFp="your_cookie")
for tiktok in trending:
# Prints the id of the tiktok
print(tiktok['id'])
print(len(trending))
With the pyppeteer version, try adding a custom verifyFp cookie (like so #342 (comment)). It should look something like:
from TikTokApi import TikTokApi api = TikTokApi(debug=True) results = 10 trending = api.trending(count=results, custom_verifyFp="your_cookie") for tiktok in trending: # Prints the id of the tiktok print(tiktok['id']) print(len(trending))
Q1:
if I not use pyppeteer, how can I resolve this issue, like this ERROR: No matching distribution found for playwright (from TikTokApi)
Q2:
what difference between TikTokApi() and TikTokApi.get_instence()?
Q3:
I add cookie like this
trending = api.trending(count=results, custom_verifyFb='verify_khg0pb1s_aQs4uSWx_g3NC_4ToC_A9f2_dYgkITkKcyab')
but I get the same result
AttributeError: 'browser' object has no attribute 'signature'
I'm running into the same issue when I try to install playwright in a docker container with certain python versions. I can get it to install when I have python 3.8.5 installed, but not 3.8.0 or 3.9.0.
What version of python are you running @mengguiyouziyi ?
python --version
If you don't know how to get that easily
I'm running into the same issue when I try to install playwright in a docker container with certain python versions. I can get it to install when I have python 3.8.5 installed, but not 3.8.0 or 3.9.0.
What version of python are you running @mengguiyouziyi ?
python --version
If you don't know how to get that easily
Me too, but with the pypeeter version. I solved it downloading with curl the TikTokApi file from pypi and doing "pip install file" on Dockerfile.
Regarding Q3 it should be "custom_verifyFp" not "custom_verifyFb". Let me know if that fixes it for puppeteer!
I'm running into the same issue when I try to install playwright in a docker container with certain python versions. I can get it to install when I have python 3.8.5 installed, but not 3.8.0 or 3.9.0.
What version of python are you running @mengguiyouziyi ?
python --version
If you don't know how to get that easily
Python 3.6.2 :: Continuum Analytics, Inc. I change it to python3.7.4, pip install TikTokApi --upgrade is succeed. thanks. see blow: https://github.com/davidteather/TikTok-Api/issues/360#issuecomment-728652991
Regarding Q3 it should be "custom_verifyFp" not "custom_verifyFb". Let me know if that fixes it for puppeteer!
pip install TikTokApi --upgrade
is succeed.pip install TikTokApi-pyppeteer
is succeed too, and I run
from TikTokApi import TikTokApi
api = TikTokApi(debug=True)
results = 10
trending = api.trending(count=results, custom_verifyFp='verify_khg0pb1s_aQs4uSWx_g3NC_4ToC_A9f2_dYgkITkKcyab')
for tiktok in trending:
print(tiktok['id'])
print(len(trending))
the result is:
Class initialized
[W:pyppeteer.chromium_downloader] start chromium download.
Download may take a few minutes.
100%|█████████████████████████████████████████████████████████████| 108773488/108773488 [00:12<00:00, 8662063.86it/s]
[W:pyppeteer.chromium_downloader]
chromium download done.
[W:pyppeteer.chromium_downloader] chromium extracted to: /search/odin/meng/.local/share/pyppeteer/local-chromium/588429
The following error occurred, but it was ignored.
'browser' object has no attribute 'timezone_name'
Traceback (most recent call last):
File "test.py", line 6, in
See this comment as your main issue is now AttributeError: 'browser' object has no attribute 'signature'
Describe the error
My English is not good, you can see blow.
The buggy code
pip install TikTokApi --upgrade
Error Trace (if any)
Desktop (please complete the following information):
Additional context
try1: pip install playwright -- upgrade
try2: npm i -D playwright
try 3: pip install TikTokApi-pyppeteer I write
to test.py. when I python test.py, I got this code: