Injabie3 / lui-cogs-v3

Cogs for Red-DiscordBot (v3), used by the SFU Anime Club. Branches for dpy1 and dpy2. See Injabie3/lui-cogs for Redv2/dpy0 cogs.
14 stars 7 forks source link

Doesn't work when discord takes a while to embed original link #14

Open DoctorDinosaur opened 10 months ago

DoctorDinosaur commented 10 months ago
          > Sometimes it fails to notice/fix a link. Reposting usually works. Not sure if thats lag on my test bot or what.

At any rate, the code is a bit of a mess with 3 more servivces, might need restructuring.

CORRECTION: It doesn't work if it takes a while for discord to add the original embed (i.e. for it to load the link + gen the embed)

Not sure how to fix that, beyond switching all the logic from looking for embeds, to just any url whether its embeded or not (like I've had to do for twitter)

Originally posted by @DoctorDinosaur in https://github.com/Injabie3/lui-cogs-v3/issues/12#issuecomment-1806966588

DoctorDinosaur commented 10 months ago

https://discordpy.readthedocs.io/en/stable/api.html#discord.on_raw_message_edit ?

Would that fix it?

I don't code for bots lol, not familiar with dpy