question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Save new messages to file as they come in

See original GitHub issue

Is there a way to append new messages to the end of a file for a live video as they come in? Right now it only saves when you exit. Also, trying to send the output to a file using > results in an empty file.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:58 (31 by maintainers)

github_iconTop GitHub Comments

2reactions
xenovacommented, Jun 30, 2021

The remaining functionality has been added to the latest version of the software.


Messages are saved as they come in (for all formats, including csv, json and text)


What about showing AM/PM instead of 24 hour time?

The simplest way to do this would be to use the python module like this

Alternatively, you could define a custom formatting json file (e.g., example.json)

{
    "12h": {
        "template": "{time_text|timestamp}{money.text}{author.display_name|author.name}{message}",
        "keys": {
            "time_text": "{} | ",
            "timestamp": {
                "template": "{} | ",
                "format": "%I:%M %p"
            },
            "money.text": "*{}* ",
            "message": ": {}"
        }
    }
}

then you can run the program using the --format and --format_file arguments:

chat_downloader https://www.youtube.com/watch?v=5qap5aO4i9A --format 24h --format_file example.json

which will produce output similar to:

11:40 PM | Wesley: you just lost the game 🙂
11:40 PM | Allan Ferreira: @Mia Alan Io ho 19 anni, e te?
11:40 PM | Giorgio Verzeletti: Vamo raga forza giuve siuuuuuummmm
11:41 PM | Fiore Diaz: @Leonor Meneses muy bien pa
11:41 PM | traw: Stinky monkey water
11:41 PM | Salman Amal: Who is doing their A levels?
11:41 PM | Aman Munjal: okh see ya later
11:41 PM | Leonardo: @Isabela Ramires Abri mão das minhas férias kkkk
11:41 PM | Dictionary: hi vhs

The issue happened again, it was because the connection was lost. Is there a way to auto restart it after this happens?

Restart functionality has been added and the decoding error has also been fixed 👍


Hi, can you add an optional arguments to disable [“Printing out badges of users in messages”]

As described above, you can now specify custom formats.

1reaction
ccdffddfddfdsfedeeecommented, Nov 6, 2020

I will, but it might take a few hours for it to happen

Read more comments on GitHub >

github_iconTop Results From Across the Web

Save a message as a file - Microsoft Support
Double-click to open the message you want to save, and on the File menu, click Save As. Select the File menu, then Save...
Read more >
The Best Ways to Save Text Messages Forever - Android and ...
Android - Quick steps to forever save text messages · Open a Gmail email account if you don't have one. · Enable the...
Read more >
How to Save Files Received in Messages on iPhone and iPad
1. Launch the native Messages app on your iPhone or iPad. 2. Open a conversation, then tap the contact bubble(s) at the top...
Read more >
How To Save Email Messages As Document Files (#1731)
https://macmost.com/e-1731 If you need to save an important email as a document rather than simply marking it in the Mail app, ...
Read more >
Save Selected Email Message as .msg File - Slipstick Systems
Save Selected Email Message as .msg File · Pick the Folder Location · Save messages as they are sent · Use a Userform...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found