Closed paweenwat-man closed 1 year ago
This feature was removed in version 0.2.0. If I forgot to remove it from the documentation, then I'll have to remove it. TikTok supplies videos under a certain tag according to its algorithm, so there's no direct way to get the video list sorted by create time. The removed solution just sorted a fixed number of grabbed videos. To get the same effect you can use:
sorted(challenge.videos, key=...)
to collect all of the videos tagged with a challenge and sort them (this is a bad idea).
Or you can use:
sorted(challenge.videos.limit(20), key=...)
to collect the first 20 videos and sort them. This number can obviously be changed just by changing the limit parameter.
To Reproduce
Expected behavior a sorted iterator of TikTok videos
Version Information pydantic==2.0.3 pydantic_core==2.3.0 playwright==1.36.0 tiktokapipy==0.2.0.post2
System Information OS: Windows 11 on desktop computer
Region Information Thailand