0

Can you please tell me, if there exists a solution to run a Tkinter Gui and a TikTok live Client in the same time, because when I run the program only first of them starts.

import tkinter as tk
from TikTokLive import TikTokLiveClient

root = tk.Tk()
client = TikTokLiveClient(unique_id="<user_name>")

@client.on("like")
async def on_like(event):
    print(f"{event.user.nickname} liked the video")


if __name__ == "__main__":
    root.mainloop()
    client.run()
  • Why not run `tkinter` or `TikTokLiveClient` in another thread? – TheLizzard Jan 13 '23 at 00:11
  • Does this help? import tkinter as tk from TikTokLive.types.events import LikeEvent : : : @client.on("like") async def on_like(event: LikeEvent): print(f"{event.user.nickname} ----------> liked the video") new_like = event.user.nickname – toyota Supra Jan 13 '23 at 00:47

0 Answers0