I mispasted something that was 500,000 lines and sent it to a friend in qTox.
Now, whenever I switch to them it says "Resizing" in bold and takes nearly a minute for anything to show up. It's also crashed as a result. I don't know if this is causing the same issues for him as I have no way to contact him due to this catastrophe.
Is there anything I can do (I'm in linux), such as some kind of command like Sudo Qtox Remove Crap and have it fix the database?
I've tried opening the username.db with sqlitebrowser but I get invalid file format error with that. Is this because I use a password to sign in to that qtox ID?
@avirunes Yes, it's because database is encrypted (IDK is there any way to open it by external tool). As hotfix you can remove db file (make backup of old file)
For me it's incredibly slow with just over 20 words on the screen, takes some time to display text after startup, or adjust when resizing. CPU usage gets 100% for a few seconds, which of course depends on the length of the text being displayed.
@avirunes if you don't care about the chat history, deleting it for this particular friend should fix the problem.
OP, looks like you broke the Internet.
Jokes aside, shouldn't there be some sort of safeguard against such "mispastings"?
@Hasshu Yeah, they should just limit the maximum length of text to 1, or disable messaging altogether instead of fixing how the text is displayed.
@zolk3ri People don't normally write messages comprising 500,000 lines... I'm not sure what prompted your sarcasm.
Duplicate of https://github.com/qTox/qTox/issues/4215
To work around:
Proposed solution: ask user whether they really want to paste something that is really big, e.g:
Are you sure that you want to paste 100 MB of text? (y/N)
User would be asked whether they actually want to paste the text if text size exceeds 100 KB.
Thoughts?
I like this idea.
a simple proposal: display only first 100 chars of a chat posts longer than some treshold, and make a separate table for long posts. In the DB add a field like long_ref_fulltext to the id in that table. if it's zero - then msg is OK, if its greater than zero - add a button like "read full message" and display the long post separately. It won't slow the things down(main chat log table is OK) and won't destroy rarely used but very useful ability for a long pastes
Any update on this? I have not checked it myself, just out of sheer curiosity.
The chatlog now only loads a limited number of messages, so this shouldn't happen anymore.
Most helpful comment
a simple proposal: display only first 100 chars of a chat posts longer than some treshold, and make a separate table for long posts. In the DB add a field like long_ref_fulltext to the id in that table. if it's zero - then msg is OK, if its greater than zero - add a button like "read full message" and display the long post separately. It won't slow the things down(main chat log table is OK) and won't destroy rarely used but very useful ability for a long pastes