galnir / Master-Bot

A Discord music bot and dashboard with slash commands, playlist support, Spotify, music quiz, saved playlists, lyrics, gifs and more
MIT License
464 stars 373 forks source link

Discussion - bot compatibility with other bots #776

Closed Bacon-Fixation closed 1 year ago

Bacon-Fixation commented 1 year ago
          Ok technically this isn't related to this bot, but I still need help, because it causes this code to throw errors at me, and I can't find anything about it anywhere. Whenever my bot goes online, it somehow thinks it's still in servers it's been removed from, which causes the invalid prisma.guild.delete() invocation error, any idea how to get around this?

Originally posted by @Natemo6348 in https://github.com/galnir/Master-Bot/issues/667#issuecomment-1442541331

Not really norm to start a Discussion :D, I wanted to help ya and #667 shorter <3, as technically could potential effect Master-Bot Are both bots sharing a Client ID, Secret and/or Token? (can lead to state mismatch with discord or multiple events) Are they sharing a DB and/or Redis with Master-Bot? (potential conflicts with caching and Db management)

generally not a good idea to share credentials and DB's think of any other info, let me know and I can see what is up

Much Love -Bacon

Natemo2625 commented 1 year ago

Honestly I'm not sure how to check to see if any of that is shared. Even though I don't think anything is shared, could you tell me how I could check? Edit: I also had this issue with the old v12 version, in which I was able to log the ids of the guilds it thought it was in without making too many changes, could go back to that code to get the ids

Bacon-Fixation commented 1 year ago

My apologise for the delay, do both bots use the same values used in the .env file, like the DISCORD_CLIENT_ID

Much Love -Bacon

Natemo2625 commented 1 year ago

Sorry for the even longer delay, I didn't notice that you responded. They do not share the same values in the .env file, I made sure they were changed before first startup.

Natemo2625 commented 1 year ago

@Bacon-Fixation do you have any other ideas as for what is causing this?

Bacon-Fixation commented 1 year ago

Unfortunately, i dont :( i haven't been able to replicate the scenario reliably to determine why or how to fix, I still work this issue on my downtime as a curiosity.

Much Love -Bacon

Natemo2625 commented 1 year ago

@Bacon-Fixation I'm beginning to think that it's on discords end, because I used a different client login token, and the issue was just gone without a trace.

Natemo2625 commented 1 year ago

@Bacon-Fixation I have found on other github pages that there are other people having this issue, and that someone from the discord developers server said it had something to do with soft deleted guilds, a.k.a servers they were removed from without triggering a full deletion. I guess I'll just have to find a workaround. Just in case you might be able to find one before me, the guild used to be logged as undefined in discord.js v12

Bacon-Fixation commented 1 year ago

@Natemo6348 Nice find, I will do some testing to see if that issue is still present in discord.js v14.9 (the version currently used in Master-Bot)

Much Love -Bacon

Bacon-Fixation commented 1 year ago

Going to go a head and close this discussion, I will still be working on trying to replicate it if I can, but at the moment haven't been able to trigger this scenario

If I run across it or have new info, I will add it here

Much Love -Bacon