#Hey guys need some assistance in
1 messages · Page 1 of 1 (latest)
Willing to pay if someone is able to help us optimize all of this - reach out via DM if you have a lot of experience with larger discord bots and handling sharding
How many server is this bot on?
over 2500 I believe
the ram for that bot(if you aren't using something like voice or etc) shouldn't be more than ~300mb I think
which intents do you have?
also, the issue is in the ram or that webhook triggers twice?
My intents/partials are probably unecessary:
partials: [Partials.Message, Partials.Channel, Partials.Reaction, Partials.GuildMember, Partials.User],
intents: [GatewayIntentBits.GuildMembers, GatewayIntentBits.Guilds, GatewayIntentBits.DirectMessages, GatewayIntentBits.GuildMessages, GatewayIntentBits.MessageContent]
The main issue is the event being processed twice (I believe sharding issue?), but if we can knock out two birds with one stone regarding resource usage that would be awesome
The events I currently listen to are
Events.InteractionCreate
Events.GuildMemberAdd
Events.UserUpdate
Events.ClientReady
Events.MessageCreate
I'm not sure tbh, your sharding configuring doesn't looks bad as for me.
Is whole bot running twice, or only webhook(message create event) part?
I'm seeing the ClientReady event fire twice - but I only have one Dyno running which is why I'm confused
if only message create, and it happens often/you know how to reproduce - add some debug, which should log shard id
multiple shards can cause multiple ready events
each event for each shard