Open aswanyaugustine opened 5 years ago
Same here with the api. api.loggedIn() return true, but when I try to do api.get request it return error: "you must be logged into do this". Any help?
Same problem as @galshiff wrote.. Very strange because the api.loggedIn() return true so i think maybe there is a socket which got somehow disconneced ? Help plz :)
Same problem here.. my solution is add an event on_close in asteroid.ddp. This event call main function, and then, reconnect bot.
export const runbot = async () => {
asteroid = await driver.connect();
asteroid.ddp.on('socket_close', async () => await runbot());
await driver.login();
await driver.subscribeToMessages();
await driver.respondToMessages(__processMessages);
}
SDK ver. 0.2.9-2
after a particular may be a specific time after there is no new change in subscribed collection (no new message ), the driver getting automatically disconnected due to which new message is not detected