Discord-Scraper icon indicating copy to clipboard operation
Discord-Scraper copied to clipboard

Bug in GrabData [experimental]

Open ch40s opened this issue 5 years ago • 2 comments

Traceback (most recent call last):
  File "Discord/Client.py", line 43, in GetData
    raise Exception()
Exception

Traceback (most recent call last):
  File "Discord/Discord.py", line 261, in GrabData
    raise Exception(f'Unable to grab data between {day:02d}-{month:02d}-{year} and {day+1:02d}-{month:02d}-{year}')
Exception: Unable to grab data between 31-12-2019 and 32-12-2019

ch40s avatar Jan 22 '20 13:01 ch40s

Give the updated script a try, I found an issue with the exception handling that I was writing (it would pretty much halt once it reaches a ValueError exception).

Dracovian avatar Jan 22 '20 14:01 Dracovian

I don't get the same error anymore, however the script is going back to grab data since 2015 and then it starts again from 2020. Actually, this infinite loop only happens when the server or channel ID are incorrect.

The script also tries for every single day going back to 2015 regardless of how many messages exist in that channel. If a channel was recently created and only has a few messages in there, I think it would make sense to stop the attempts so it's overall more efficient.

ch40s avatar Jan 22 '20 15:01 ch40s