-
-
Notifications
You must be signed in to change notification settings - Fork 725
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Workaround for slow search index refreshing & more #584
base: master
Are you sure you want to change the base?
Conversation
Works around Discord taking too long to reload the search page. It sorts messages from start to end while the end to start page is loading so there is no time wasted waiting for pages to load.
Browsers throttle the JS timers when on another tab, therefore leading to delays being longer than they are supposed to
For larger operations with a lot of messages, the tab starts lagging after a couple thousand are deleted
Conclusion: I deleted 650k messages in total with these changes without any interruptions, it took me around 17 days of my computer running 24/7. My account did not get banned in the end. |
This sounds amazing - How would we modify the current script to use the updated files? I assume you could just copy the main JS file, but I'm not sure about the UI files, I never use tampermonkey except for this. |
@Aida-Enna |
Ah, thank you. I had no idea build instructions could sometimes be in the contribution readme. And yeah, I looked over the changes and they looked good, I just didn't know how to put it all in one file. Thank you! |
For my personal testing, I uninstalled my current installation and created a new script on Tampermonkey with the code from the |
I tried this fork and deleted more than 150k messages 24/7 without a ban. The only setting I changed from default is delete delay to 1500 instead of 1400 because it significantly reduces the number of rate limits. As a note:
|
Does this still work fine? Used it on my account and after 4 hours it was still going with very minor ratelimiting |
It should still work perfectly as far as I'm aware, I was told setting both of the delays to 1500ms would be better to avoid rate limiting |
I got ratelimited 90 times in 6 hours using default settings lol, it said total wasted time was only 49 seconds though |
- Resolved ESLint issues and addressed invalid header warnings (victornpb#663). - Implemented autofill for thread channel IDs and restricted message deletion to the corresponding thread (victornpb#610). - Clarified that omitting a time will disable the date filter functionality (victornpb#643). - Added a filter to exclude messages containing files or attachments (victornpb#642). - Fixed various autofill issues (victornpb#631). - Stopped execution when there are remaining messages (victornpb#619). - Addressed API errors related to the Wipe Archive Feature (50024 - 50021) (victornpb#603). - Implemented a workaround for slow search index refreshing (victornpb#584).
I want to preface this by saying that I've deleted over 200k messages with these changes in the span of ~7 days and my account hasn't gotten banned. The fastest I've been able to delete messages without any problems was a little less than 1k per 30 minutes.
This PR has the following changes:
I've also changed search delay and delete delay to 1400ms. Through testing, this was the fastest I could go without getting rate limited all the time.