A clear and concise description of what the bug is.
The buggy code
Please add any relevant code that is giving you unexpected results.
Preferably the smallest amount of code to reproduce the issue.
SET LOGGING LEVEL TO INFO BEFORE POSTING CODE OUTPUT
import os
import asyncio
from TikTokApi import TikTokApi
video_id = 7248300636498890011
ms_token = os.environ.get("ms_token", None) # set your own ms_token
async def get_comments():
async with TikTokApi() as api:
await api.create_sessions(ms_tokens=[ms_token], num_sessions=1, sleep_after=3)
video = await api.get_video_by_id(video_id)
count = 0
async for comment in video.comments(count=30):
print(comment)
print(await comment.as_dict())
if __name__ == "__main__":
asyncio.run(get_comments())
# Hopefully the info level will help you debug or at least someone else on the issue
# Code Goes Here
Expected behavior
A clear and concise description of what you expected to happen.
Error Trace (if any)
Put the error trace below if there's any error thrown.
# Error Trace Here
Desktop (please complete the following information):
OS: [e.g. Windows 10]
TikTokApi Version [e.g. 5.0.0] - if out of date upgrade before posting an issue
Fill Out the template :)
Describe the bug
A clear and concise description of what the bug is.
The buggy code
Please add any relevant code that is giving you unexpected results.
Preferably the smallest amount of code to reproduce the issue.
SET LOGGING LEVEL TO INFO BEFORE POSTING CODE OUTPUT
Expected behavior
A clear and concise description of what you expected to happen.
Error Trace (if any)
Put the error trace below if there's any error thrown.
Desktop (please complete the following information):
Additional context
Add any other context about the problem here.