Closed TheBITLINK closed 7 years ago
You didn't provide any code samples, so I hope you're not relying on msg.channel
in that eval, because when the message gets uncached (eventually, due to channel cache limits, and default limit is 1000) msg
becomes an invalid reference, thus msg.channel
will return null. Store the actual channel in a variable before accessing it from any async callbacks.
I did use msg.channel
in this case, however, it happened to me under other circumstances as well, i'm clusing this until i have further details
Sometimes channel objects disappear from the cache (they become
null
), making it impossible to send messages on some guilds until i restart the shard. I don't know the details, but the quickest way to achieve this is by making asetInterval()
that sends messages to a channel until it crashes.I tried this on 2 instances of the same bot and they both had this in the logs.
Both instances took around the same amount of time to crash. (~30 minutes, with a 2000ms interval between messages)