Bot is offline, while my other one is online

I have 2 bots running on different EC2 instances using pm2. They have the same code base, just some different env stuff and questions I use in them. One appears online while the other is offline. They both have the same settings in the dev portal and everything, so it's quite confusing. I'm sure I missed something, but I don't know what.
No description
4 Replies
d.js toolkit
d.js toolkit•3w ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
jaka šŸ‰
jaka šŸ‰OP•3w ago
[email protected] with node v21.6.2. Bot of my bots are identical, except ofcourse the things I require to make them work for their specific trivia genre and the few .env changes for them to work as seperate bots. Ever since I launched the "Blitzcrank's Trivia" it has been offline and things like client.user.setPresence({status: 'online'... have not fixed it
d.js docs
d.js docs•3w ago
Please add the following code to your code base outside of any other event listeners and provide the full log output relevant to your issue.
client
.on("debug", console.log)
.on("warn", console.log)
client
.on("debug", console.log)
.on("warn", console.log)
- Note: if you initialize your Client as bot or other identifiers you need to use these instead of client - If the output is too long to post consider using a bin instead: gist | paste.gg | sourceb.in | hastebin If you aren't getting any errors, try to place console.log checkpoints throughout your code to find out where execution stops. - Once you do, log relevant values and if-conditions - More sophisticated debugging methods are breakpoints and runtime inspections: learn more
jaka šŸ‰
jaka šŸ‰OP•2w ago
šŸŒ Production environment detected. Skipping ngrok tunnel.
[WS => Manager] Fetched Gateway Information
URL: wss://gateway.discord.gg
Recommended Shards: 1
[WS => Manager] Session Limit Information
Total: 1000
Remaining: 1000
[WS => Shard 0] Connecting to wss://gateway.discord.gg?v=10&encoding=json
[WS => Shard 0] Waiting for event hello for 60000ms
[WS => Shard 0] Preparing first heartbeat of the connection with a jitter of 0.9785107148733732; waiting 40363ms
[WS => Shard 0] Waiting for identify throttle
[WS => Shard 0] Identifying
shard id: 0
shard count: 1
intents: 4097
compression: none
[WS => Shard 0] Waiting for event ready for 15000ms
[WS => Shard 0] Shard received all its guilds. Marking as fully ready.
šŸ¤– Logged in as Blitzcrank's Trivia#5104!
šŸŒ Global Commands: [ 'register', 'unregister', 'profile', 'scoreboard', 'privacy' ]
šŸŒ Production environment detected. Skipping ngrok tunnel.
[WS => Manager] Fetched Gateway Information
URL: wss://gateway.discord.gg
Recommended Shards: 1
[WS => Manager] Session Limit Information
Total: 1000
Remaining: 1000
[WS => Shard 0] Connecting to wss://gateway.discord.gg?v=10&encoding=json
[WS => Shard 0] Waiting for event hello for 60000ms
[WS => Shard 0] Preparing first heartbeat of the connection with a jitter of 0.9785107148733732; waiting 40363ms
[WS => Shard 0] Waiting for identify throttle
[WS => Shard 0] Identifying
shard id: 0
shard count: 1
intents: 4097
compression: none
[WS => Shard 0] Waiting for event ready for 15000ms
[WS => Shard 0] Shard received all its guilds. Marking as fully ready.
šŸ¤– Logged in as Blitzcrank's Trivia#5104!
šŸŒ Global Commands: [ 'register', 'unregister', 'profile', 'scoreboard', 'privacy' ]
same thing as on my other bot i must also clarify, my bot is DMs only. could that be causing it? the workaround i found is enabling guild installs, inviting it to a private server, then disabling the guild installs. seems to work just for people who share that server tho I wanted the bot to look like a normal discord bot, appearing online so I could display custom status messages for when the game would refresh. I was hoping there would be a way to make it "friend" the user by authenticating it via webhooks, but that seems to not be the case. I was not aware of how the DM bot system works, so thanks for the info

Did you find this page helpful?