xenova / chat-downloader

A simple tool used to retrieve chat messages from livestreams, videos, clips and past broadcasts. No authentication needed!
https://chat-downloader.readthedocs.io/
MIT License
948 stars 132 forks source link

[QUESTION] How to get certain message objects? #166

Closed RCECoder closed 1 year ago

RCECoder commented 2 years ago

What is your question?

Is there an option to specify only the message objects we are interested in? An example would be to specify only

"id"
"name"
"message"
"timestamp"

So that it only saves those items and not any other.

Also, why is UTF saved in a escaping format?

"name": "\ud83d\udc51\u0627\u0628" 
"message": "\u064a\u0640\u0640\u064e"

Why not in a readable format?

Update: How can we run this chat downloader script in a debugger? It seems to have error

from .metadata import __version__
ImportError: attempted relative import with no known parent package

I have tried both IDLE and winpdb. Any ideas?

xenova commented 1 year ago

Is there an option to specify only the message objects we are interested in?

You would have to do this with a custom python script.

Also, why is UTF saved in a escaping format?

That is how unicode characters are encoded in JSON.

How can we run this chat downloader script in a debugger?

You cannot run the file directly. You must run it as a module using the -m flag. For example, you can run it using the command python -m chat_downloader --version. Check out this for more information.