question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Seems to stop listening after a few days

See original GitHub issue

Hi. Thanks for this library - it’s excellent. Absolutely the best I’ve seen.

We have a bot running on zeit/now.sh, which listens for /commands in a channel.

it seems like every few days, the bot gets a few HTTP errors from Telegram’s API, and stops listening.

The only way to get the bot to respond to commands again is to remove it from the channel and re-add it.

Is this a known issue?

These may not even be related, but it’s all the logs contain:

09/03 04:03 AM (2d)
Failed to get updates. Waiting: 1s { Error: 500: Unsupported message from Telegram
    at buildPayload.then.then.then.then (/home/nowuser/src/node_modules/telegraf/lib/network/client.js:102:17)
    at <anonymous>
    at process._tickDomainCallback (internal/process/next_tick.js:228:7)
  code: 500,
  response: 
   { error_code: 500,
     description: 'Unsupported message from Telegram',
     response: '<html>\r\n<head><title>502 Bad Gateway</title></head>\r\n<body bgcolor="white">\r\n<center><h1>502 Bad Gateway</h1></center>\r\n<hr><center>nginx/1.10.1</center>\r\n</body>\r\n</html>\r\n' },
  description: 'Unsupported message from Telegram',
  parameters: {} }
09/03 04:03 AM (2d)
Failed to get updates. Waiting: 1s { Error: 500: Unsupported message from Telegram
    at buildPayload.then.then.then.then (/home/nowuser/src/node_modules/telegraf/lib/network/client.js:102:17)
    at <anonymous>
    at process._tickDomainCallback (internal/process/next_tick.js:228:7)
  code: 500,
  response: 
   { error_code: 500,
     description: 'Unsupported message from Telegram',
     response: '<html>\r\n<head><title>502 Bad Gateway</title></head>\r\n<body bgcolor="white">\r\n<center><h1>502 Bad Gateway</h1></center>\r\n<hr><center>nginx/1.10.0</center>\r\n</body>\r\n</html>\r\n' },
  description: 'Unsupported message from Telegram',
  parameters: {} }
09/03 04:03 AM (2d)
Failed to get updates. Waiting: 1s { Error: 500: Unsupported message from Telegram
    at buildPayload.then.then.then.then (/home/nowuser/src/node_modules/telegraf/lib/network/client.js:102:17)
    at <anonymous>
    at process._tickDomainCallback (internal/process/next_tick.js:228:7)
  code: 500,
  response: 
   { error_code: 500,
     description: 'Unsupported message from Telegram',
     response: '<html>\r\n<head><title>502 Bad Gateway</title></head>\r\n<body bgcolor="white">\r\n<center><h1>502 Bad Gateway</h1></center>\r\n<hr><center>nginx/1.10.0</center>\r\n</body>\r\n</html>\r\n' },
  description: 'Unsupported message from Telegram',
  parameters: {} }
09/03 04:03 AM (2d)
Failed to get updates. Waiting: 1s { Error: 500: Unsupported message from Telegram
    at buildPayload.then.then.then.then (/home/nowuser/src/node_modules/telegraf/lib/network/client.js:102:17)
    at <anonymous>
    at process._tickDomainCallback (internal/process/next_tick.js:228:7)
  code: 500,
  response: 
   { error_code: 500,
     description: 'Unsupported message from Telegram',
     response: '<html>\r\n<head><title>502 Bad Gateway</title></head>\r\n<body bgcolor="white">\r\n<center><h1>502 Bad Gateway</h1></center>\r\n<hr><center>nginx/1.10.0</center>\r\n</body>\r\n</html>\r\n' },
  description: 'Unsupported message from Telegram',
  parameters: {} }

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
dotcypresscommented, Sep 4, 2017

Hey 👋

Do you use LongPolling? If yes, you need to config your now instance to prevent freezing. But my advice is using Webhooks for that.

0reactions
antonycommented, Apr 29, 2018

@jjhesk the fix is listed above, you have to use webhooks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Google assistant is suddenly not listening
All of a sudden the Google Assistant just stops listening after a few seconds. It responds when I say "hey Google" or "ok...
Read more >
Disable Follow-Up Mode on Your Alexa Device to Save Your ...
When you use Amazon's Alexa with Follow-up Mode enabled, more audio is recorded than you think. Here is how to make sure it's...
Read more >
How to Stop Google From Listening to You Constantly
1. Open your Android Settings menu and tap Google. · 2. On the next menu, select Settings for Google apps. · 3. Select...
Read more >
How to Stop Google From Listening - MakeUseOf
Tapping the microphone icon on the search bar, or otherwise launching Google Assistant, will both immediately prompt you for a voice command.
Read more >
Is My Phone Listening to Me? How to Stop It - NordVPN
Discuss the topic out loud next to your phone. You can do this alone or with someone else for several minutes at a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found