Skip to content
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

Ended because API returned an empty page. #598

Open
4 tasks done
Justman100 opened this issue Feb 27, 2024 · 9 comments
Open
4 tasks done

Ended because API returned an empty page. #598

Justman100 opened this issue Feb 27, 2024 · 9 comments

Comments

@Justman100
Copy link

Justman100 commented Feb 27, 2024

Undiscord Version

v5.2.3

Browser

Mozilla Firefox 123.0

Extension

TamperMonkey

Reproduction steps

  1. Install TemperMonkey
  2. Install script
  3. Let delete messages

Actual results

UnDiscord stopping on 25 deleted messages with the quota:

Ended because API returned an empty page.

After that, one must always wait a little to be able to continue

Expected results

Delete all messages without interruption

Bug affects

  • DMs
  • DMs (group)
  • Channels
  • Channel (NSFW)
@ugotopia123
Copy link

I'm getting this exact same issue on Firefox. I thought maybe one of my other extensions was interfering with the script so I did a fresh install of Chrome and only had Tampermonkey installed. Same problem. Dunno why, I'm forced to check in constantly to restart the process.

@ugotopia123
Copy link

ugotopia123 commented Mar 28, 2024

Seems to be an API problem. In a related thread someone suggested to set the Search Delay to 60000ms and the Delete Delay to 350ms. So far it seems to be working without stopping prematurely... it just now more than doubled the time it should've taken with a much shorter Search Delay. It appears if there's not enough time between the Search Delay it doesn't pull the next page properly. I'll tamper with gradually reducing the Search Delay to a faster but still stable value cause waiting a whole minute between pages is painful.

@dran1x
Copy link

dran1x commented Apr 6, 2024

I'm using a 44 second search and a 550ms delete delay, it runs without stopping.

@OCircles
Copy link

gm112's fix works.

It seems like fetching pages are a bit inconsistent. Sometimes it works perfectly even on 10s search delay, other times it fails 3 times before working. Failures happen on the default 40s search delay as well.

@moralsow
Copy link

I'm very new to GitHub and I'm no coder, so I just have a simple, quick question, for gm112's solution, how do I input the solution/script into my Undiscord? I've been having the same problem of messages not getting deleted after 25 deleted messages with the issue of "ended because api returned an empty page"

@Justman100
Copy link
Author

I'm very new to GitHub and I'm no coder, so I just have a simple, quick question, for gm112's solution, how do I input the solution/script into my Undiscord? I've been having the same problem of messages not getting deleted after 25 deleted messages with the issue of "ended because api returned an empty page"

Navigate into an empty directory and run:

git init
git pull https://github.com/gm112/undiscord
git checkout -B fix/stopping-run-when-messages-remain

yarn
yarn rollup -c

Then replace the content of your current undiscord script with the content of the new file deleteDiscordMessages.user.js

@ChettRipley
Copy link

Works, it just auto refreshes when the API fails instead of you having to manually hit DELETE again

keeps it moving, can fail 4-5 times and it still auto searches and picksup fine no issues thanks @gm112

@ozoneusol
Copy link

I'm very new to GitHub and I'm no coder, so I just have a simple, quick question, for gm112's solution, how do I input the solution/script into my Undiscord? I've been having the same problem of messages not getting deleted after 25 deleted messages with the issue of "ended because api returned an empty page"

Navigate into an empty directory and run:

git init
git pull https://github.com/gm112/undiscord
git checkout -B fix/stopping-run-when-messages-remain

yarn
yarn rollup -c

Then replace the content of your current undiscord script with the content of the new file deleteDiscordMessages.user.js

I don't get this. Empty directory where?

@Justman100
Copy link
Author

I'm very new to GitHub and I'm no coder, so I just have a simple, quick question, for gm112's solution, how do I input the solution/script into my Undiscord? I've been having the same problem of messages not getting deleted after 25 deleted messages with the issue of "ended because api returned an empty page"

Navigate into an empty directory and run:

git init
git pull https://github.com/gm112/undiscord
git checkout -B fix/stopping-run-when-messages-remain

yarn
yarn rollup -c

Then replace the content of your current undiscord script with the content of the new file deleteDiscordMessages.user.js

I don't get this. Empty directory where?

You must first create one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants