Rongronggg9 / RSS-to-Telegram-Bot

A Telegram RSS bot that cares about your reading experience
https://t.me/RSStT_Bot
GNU Affero General Public License v3.0
1.53k stars 278 forks source link

telethon.network.mtprotosender - Attempt 1 at connecting failed: TimeoutError: #429

Closed Newfpv closed 7 months ago

Newfpv commented 7 months ago

rsstt | 2024-03-05-22:12:51:INFO:RSStT.env - Config folder: /app/config rsstt | 2024-03-05-22:12:52:INFO:RSStT.db - Successfully connected to the DB rsstt | 2024-03-05-22:13:02:WARNING:telethon.network.mtprotosender - Attempt 1 at connecting failed: TimeoutError: rsstt | 2024-03-05-22:13:13:WARNING:telethon.network.mtprotosender - Attempt 2 at connecting failed: TimeoutError: rsstt | 2024-03-05-22:13:24:WARNING:telethon.network.mtprotosender - Attempt 3 at connecting failed: TimeoutError:

Rongronggg9 commented 7 months ago

Check your network connection

Newfpv commented 7 months ago

Network connection is good

Rongronggg9 commented 7 months ago

It may be good but probably out of order somewhere invisible, which makes RSStT unable to connect to Telegram DC. So far, you haven't included any helpful information for debugging (TBH, it shouldn't be a bug of RSStT).

Try

curl -v https://149.154.167.51

It should look like this

$ curl -v https://149.154.167.51
*   Trying 149.154.167.51:443...
* Connected to 149.154.167.51 (149.154.167.51) port 443 (#0)
* ALPN: offers h2,http/1.1
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
*  CAfile: /etc/ssl/certs/ca-certificates.crt
*  CApath: /etc/ssl/certs
* OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to 149.154.167.51:443
* Closing connection 0
curl: (35) OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to 149.154.167.51:443
Newfpv commented 7 months ago

newfpv@CodeBreakers:~/rsstt$ curl -v https://149.154.167.51

How to fix this?

Rongronggg9 commented 7 months ago

So it is proven that:

probably out of order somewhere invisible

Use a proxy, migrate to another ISP, or simply deploy RSStT on a VPS without network issues.

That's not an RSStT bug, so I can't help you further.

Newfpv commented 7 months ago

Another telegram bot is working for me. And it works perfectly

Rongronggg9 commented 7 months ago

That you can connect to a Telegram DC doesn't mean that you can connect to another. Other Telegram bots, if using HTTP bot API, connect to Telegram DC4. RSStT uses MTProto API, which ties to the DC your account belonged to (in your case, DC2). It is impossible to invoke MTProto API from a foreign DC, that's why RSStT didn't work.

In short, you are facing a network issue preventing RSStT from connecting to Telegram DC2. That's not an RSStT bug, so I can't help you further.