Crashes app when hitting Discord rate limit
See original GitHub issueGet this error when I get a 429 from Discord. Running in a Docker container on a Raspberry Pi 3. Node version is 7.4.0.
/usr/src/app/node_modules/discord.js/src/client/rest/RequestHandlers/Sequential.js:79
this.restManager.client.setTimeout(() => {
^
TypeError: this.restManager.client.setTimeout is not a function
at item.request.gen.end (/usr/src/app/node_modules/discord.js/src/client/rest/RequestHandlers/Sequential.js:79:37)
at Request.callback (/usr/src/app/node_modules/superagent/lib/node/index.js:619:12)
at /usr/src/app/node_modules/superagent/lib/node/index.js:795:18
at Stream.<anonymous> (/usr/src/app/node_modules/superagent/lib/node/parsers/json.js:16:7)
at emitNone (events.js:86:13)
at Stream.emit (events.js:185:7)
at Unzip.<anonymous> (/usr/src/app/node_modules/superagent/lib/node/utils.js:112:12)
at emitNone (events.js:91:20)
at Unzip.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
This was on the latest release. Hit the same bug on the latest commit as well. Here’s the stack trace.
/usr/src/app/node_modules/discord.js/src/client/rest/RequestHandlers/Sequential.js:68
this.restManager.client.setTimeout(
^
TypeError: this.restManager.client.setTimeout is not a function
at item.request.gen.end (/usr/src/app/node_modules/discord.js/src/client/rest/RequestHandlers/Sequential.js:68:37)
at Request.callback (/usr/src/app/node_modules/superagent/lib/node/index.js:652:14)
at /usr/src/app/node_modules/superagent/lib/node/index.js:866:18
at Stream.<anonymous> (/usr/src/app/node_modules/superagent/lib/node/parsers/json.js:16:7)
at emitNone (events.js:86:13)
at Stream.emit (events.js:185:7)
at Unzip.<anonymous> (/usr/src/app/node_modules/superagent/lib/node/unzip.js:53:12)
at emitNone (events.js:91:20)
at Unzip.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Discord rate-limiting again... : r/discordapp - Reddit
The rate-limit is way too sensitive apparently. And Canary is hammering the server when the rate limit drops.
Read more >Discord API Rate Limiting: A Troubleshooting Guide - Fusebit
Generally, developers hit this rate limit when their community grows and their Discord bots need to process more requests.
Read more >How to Fix Discord's Crash Issues - Online Tech Tips
Fix Discord Keeps Crashing by Deleting the AppData · Right-click the Windows taskbar and select Task Manager. · Choose Discord in the app...
Read more >Rate Limits - Discord Developer Portal — Documentation
Rate limits exist across Discord's APIs to prevent spam, abuse, and service overload. Limits are applied to individual bots and users both on...
Read more >What to do when you are being rate limited
Usually, once a grace-period has passed, the rate limit penalties are removed and you can resume what you were doing. The only surefire...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
not at the moment, we are gearing for 11.1.0 release right now.
But then I’d have to keep track of every breaking change in
master
– or are there none?