souji
souji
DIAdiscord.js - Imagine an app
Created by Lokdei / Bert on 4/20/2025 in #djs-questions
Fix Welcome @unknown-user with guildMemberAdd
assign the return of the awaited #send to something and log it - you should have the new member in message.mentions.users from what i can see here that should work, provided they are still on the server when you check also consider the debug steps regarding logging the result and making sure those ids are what you expect them to be
9 replies
DIAdiscord.js - Imagine an app
Created by Lokdei / Bert on 4/20/2025 in #djs-questions
Fix Welcome @unknown-user with guildMemberAdd
side note: if you are trying to get a collection member from a key (in most cases discord.js that's the ID), you should not use find since it iterates the collection until it finds one - but instead .get(key), so .get(config.discordGuildId) the find predicate is useful when you are trying to find by anything but the key but that's not causing any issues, just a performance hit, especially if the collection is very large
9 replies
DIAdiscord.js - Imagine an app
Created by Lokdei / Bert on 4/20/2025 in #djs-questions
Fix Welcome @unknown-user with guildMemberAdd
the <@id> format is resolved to a name to show as "mention" by the viewing client if the user is not cached, it won't be able to resolve it if you allow a notification (allowed_mentions) the user is included in the message itself, is immediately cached and resolved if you do not allow a notification, the user is not included in the message payload and the client has to rely on other events to cache it -# note: "client" means the discord app of the user viewing the welcome text (you) -# note2: if the member leaves your client may also decide to remove the user and it will resolve with "unknown-user" yet again if you are causing notifications with these and the user is still in the server, it may also mean that the id in the <@id> format is not actually one. in your code the only way that could happen is if some other part of your code does an assignment instead of a comparison (have seen people do something like if (member.id = "owner_id_here") {} instead of === or ==) which could result in a corrupted member object when it enters this code - if you can show the raw message data for these test welcome messages, we can easily rule that out though
9 replies
DIAdiscord.js - Imagine an app
Created by Blazing on 4/16/2025 in #djs-questions
Is there a way to reset placeholder value and not have the message labelled as edited?
no
4 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
https://discord.com/channels/222078108977594368/1361721360207843448/1361721360207843448
https://discord.com/channels/222078108977594368/1361721360207843448/1361721360207843448
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
i cannot do it anywhere
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
just broken on discord atm
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
the limiting factor here is the rate limit on PATCH /guilds/:id/members/:id - the same issue one may run into when assigning roles to a ton of people
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
if it's not that, then i'd suggest trying how fast it goes with 1 app and if that's already sufficient
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
have you implemented this feature? what is the current, real problem? if "it's moving people, but slowly", then what Q mentioned may be a solution: A moves 1-5, 16-20 B moves 10-15, 21-25 or whatever measure/split you want, with 2 that'd cut the total time it takes to move all in half
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
that isn't really... what
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
based on cache
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
if you can do it on a per-user basis as they join the issue basically vanishes apart from rate limits making it take some time - substantial time at larger scales the case that hurts performance wise is knowing the current members of a vc after ready - also not an issue on smaller servers, can just take very substantial time at scale
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
your use case has some additional issues regarding scaling there is no "get members in this vc" endpoint, so indeed you will need to witness the voice channel update or fetch all members and filter by or associate to a given voice channel (here comes the scaling issue - a gateway request to receive all members can cause a ton of guild member chunk events to be sent, which may even back up the event queue to the point that the 3s-initial response for application commands cannot be sent (i have experienced that myself on servers with multiple million users))
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
no, just spreads guilds across shards, so everything happening within a guild will go to the same shard
28 replies
DIAdiscord.js - Imagine an app
Created by rohan on 4/15/2025 in #djs-questions
What's the most effective way to handle hundreds (300+) of users who join a single VC to be sorted?
- is sharding a (...) solution for this? no - bulk move? not a thing
28 replies
DIAdiscord.js - Imagine an app
Created by thiago on 4/6/2025 in #djs-questions
Passing data between interactions
the above (collectors) is less versatile but can make sense to keep state between steps where you expect an answer/action to be coming along shortly (collectors are just temporary event listeners with some exit condition that removes that instance of the collector after it is met)
7 replies
DIAdiscord.js - Imagine an app
Created by thiago on 4/6/2025 in #djs-questions
Passing data between interactions
if you really want to cram data into the custom id there is https://www.npmjs.com/package/@sapphire/string-store if that doesn't suffice you can always use a unique id (for example the interaction id) to associate in-memory or data at rest (database) with it.
7 replies
DIAdiscord.js - Imagine an app
Created by Sol on 4/4/2025 in #djs-questions
More information in modals
also to answer the original question clearly again: modals are limited to text input components and cannot have a description or other input elements
28 replies
DIAdiscord.js - Imagine an app
Created by Sol on 4/4/2025 in #djs-questions
More information in modals
components v2 will take some more time until discord flips the experiment switch off - the library is ready for it
28 replies