sentanos / roblox-js

!!!THIS PROJECT IS NO LONGER MAINTAINED!!! Execute ROBLOX website actions in node.js
MIT License
45 stars 46 forks source link

Unhandled rejection Error: Initialization failed: operation timed out #97

Closed DamonOnYT closed 6 years ago

DamonOnYT commented 6 years ago

Unhandled rejection Error: Initialization failed: operation timed out at /home/ubuntu/workspace/node_modules/roblox-js/lib/util/shortPoll.js:76:23 at tryCatcher (/home/ubuntu/workspace/node_modules/bluebird/js/release/util.js:16:23) at Promise._settlePromiseFromHandler (/home/ubuntu/workspace/node_modules/bluebird/js/release/promise.js:512:31) at Promise._settlePromise (/home/ubuntu/workspace/node_modules/bluebird/js/release/promise.js:569:18) at Promise._settlePromise0 (/home/ubuntu/workspace/node_modules/bluebird/js/release/promise.js:614:10) at Promise._settlePromises (/home/ubuntu/workspace/node_modules/bluebird/js/release/promise.js:689:18) at Async._drainQueue (/home/ubuntu/workspace/node_modules/bluebird/js/release/async.js:133:16) at Async._drainQueues (/home/ubuntu/workspace/node_modules/bluebird/js/release/async.js:143:10) at Immediate.Async.drainQueues (/home/ubuntu/workspace/node_modules/bluebird/js/release/async.js:17:14) at runCallback (timers.js:672:20) at tryOnImmediate (timers.js:645:5) at processImmediate [as _immediateCallback] (timers.js:617:5)

DamonOnYT commented 6 years ago

const Discord = require("discord.js") const client = new Discord.Client() const config = require('./config.json'); const rbx = require("roblox-js") const colors = require("colors") const request = require('request-promise', 'request') var evt = rbx.onShout({ group: config.group })

client.on('ready', () => { console.log(Logged in as ${client.user.tag}!.green) rbx.login({ username: config.username }, { password: config.password }).then(() => { console.log(Roblox: Successfully logged in!.blue) }) })

evt.on('data', function (shout) { var hook = new Discord.WebhookClient('', '') var embed = new Discord.RichEmbed() .setAuthor("Group Shout") .setColor("RANDOM") .addField("Shout", shout.message) .addField("Author", shout.author.name) .addField("Date", shout.date) hook.send(embed) })

client.login(config.token)

DamonOnYT commented 6 years ago

I think its to do with the timeout. I want to know how to set it.

DamonOnYT commented 6 years ago
    setTimeout(run, delay, current); how is this ran?
suufi commented 6 years ago

Close this issue and ask on our Discord server found in the README.md file.