RSSHub icon indicating copy to clipboard operation
RSSHub copied to clipboard

/telegram/channel 某些频道不走代理导致的超时

Open ArenaDruid opened this issue 6 months ago • 7 comments

路由地址

/telegram/channel/:username/:routeParams?

完整路由地址

/telegram/channel/VisualNovelChannel

相关文档

https://docs.rsshub.app/routes/popular#channel

预期是什么?

特别的频道能够经过PROXY_URI指定的代理获取rss

实际发生了什么?

那些没有被风控的频道(即不需要TELEGRAM_SESSION也能访问)能够通过PROXY_URI指定的代理获得rss信息;

info: <-- GET /telegram/channel/SweetSub
info: --> GET /telegram/channel/SweetSub 200 49ms

但是那些被风控的频道不能够获得并且报告超时错误:

info: <-- GET /telegram/channel/R18R18d
[2025-06-27T20:04:48.564] [ERROR] - [WebSocket connection failed attempt: 163]
Error: connect ETIMEDOUT 91.108.56.115:80
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1637:16) {
  errno: -110,
  code: 'ETIMEDOUT',
  syscall: 'connect',
  address: '91.108.56.115',
  port: 80
}
[2025-06-27T20:04:51.567] [INFO] - [Connecting to 91.108.56.115:80/TCPFull...]

我在开启全局透明代理之后,两类频道都可以成功获取rss资讯。

我翻看了过去的关于此问题的讨论https://github.com/DIYgod/RSSHub/issues/17719 ,但是我不太想另外搭建MTProxy。关于MTProxy中转其它协议的方案,我能力不够无法实现(如果有大佬提供一键式部署方案,不胜感激)。

部署

自建

部署相关信息

OS:Linux Node : v22.17.0 Docker: v28.2.2

额外信息

info: <-- GET /telegram/channel/SweetSub
info: --> GET /telegram/channel/SweetSub 200 49ms
info: <-- GET /telegram/channel/VisualNovelChannel
[2025-06-27T20:04:48.564] [ERROR] - [WebSocket connection failed attempt: 163]
Error: connect ETIMEDOUT 91.108.56.115:80
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1637:16) {
  errno: -110,
  code: 'ETIMEDOUT',
  syscall: 'connect',
  address: '91.108.56.115',
  port: 80
}
[2025-06-27T20:04:51.567] [INFO] - [Connecting to 91.108.56.115:80/TCPFull...]

这不是重复的 issue

  • [x] 我已经搜索了 现有 issue,以确保该错误尚未被报告。

ArenaDruid avatar Jun 27 '25 12:06 ArenaDruid

Searching for maintainers:
  • /telegram/channel/:username/:routeParams?: @DIYgod @Rongronggg9 @synchrone @pseudoyu

To maintainers: if you are not willing to be disturbed, list your username in scripts/workflow/test-issue/call-maintainer.js. In this way, your username will be wrapped in an inline code block when tagged so you will not be notified.

If all routes can not be found, the issue will be closed automatically. Please use NOROUTE for a route-irrelevant issue or leave a comment if it is a mistake. 如果所有路由都无法匹配,issue 将会被自动关闭。如果 issue 和路由无关,请使用 NOROUTE 关键词,或者留下评论。我们会重新审核。

github-actions[bot] avatar Jun 27 '25 12:06 github-actions[bot]

Searching for maintainers:
  • /telegram/channel/:username/:routeParams?: @DIYgod @Rongronggg9 @synchrone @pseudoyu

To maintainers: if you are not willing to be disturbed, list your username in scripts/workflow/test-issue/call-maintainer.js. In this way, your username will be wrapped in an inline code block when tagged so you will not be notified.

If all routes can not be found, the issue will be closed automatically. Please use NOROUTE for a route-irrelevant issue or leave a comment if it is a mistake. 如果所有路由都无法匹配,issue 将会被自动关闭。如果 issue 和路由无关,请使用 NOROUTE 关键词,或者留下评论。我们会重新审核。

github-actions[bot] avatar Jun 27 '25 12:06 github-actions[bot]

Searching for maintainers:
  • /telegram/channel/:username/:routeParams?: @DIYgod @Rongronggg9 @synchrone @pseudoyu

To maintainers: if you are not willing to be disturbed, list your username in scripts/workflow/test-issue/call-maintainer.js. In this way, your username will be wrapped in an inline code block when tagged so you will not be notified.

If all routes can not be found, the issue will be closed automatically. Please use NOROUTE for a route-irrelevant issue or leave a comment if it is a mistake. 如果所有路由都无法匹配,issue 将会被自动关闭。如果 issue 和路由无关,请使用 NOROUTE 关键词,或者留下评论。我们会重新审核。

github-actions[bot] avatar Jun 27 '25 13:06 github-actions[bot]

除此之外,那些使用TELEGRAM_SESSION才能访问的频道也似乎无法很好响应searchQuery搜索,待我以后进一步研究之后,可能会另外开一个issue。

ArenaDruid avatar Jun 29 '25 17:06 ArenaDruid

So when you set the global transparent proxy, you can directly visit channel like R18R18d? Could you please provide more info about your global transparent proxy info? (no need to provide specific credential, just proxy type or some general settings). I'll follow this issue.

@ArenaDruid

pseudoyu avatar Jul 09 '25 09:07 pseudoyu

@pseudoyu

I use the mzz2017/v2rayA and the setting info about transparent proxy are as shown in the following image.

Image Image

After using the above settings and rebuilding the Rsshub container. I can easily and quickly get rss feed from the /telegram/channel/VisualNovelChannel and /telegram/channel/R18R18d and the following are the logs.

info: <-- GET /telegram/channel/VisualNovelChannel
[2025-07-09T19:46:33.705] [INFO] - [Running gramJS version 2.26.21]
[2025-07-09T19:46:33.712] [INFO] - [Connecting to 91.108.56.115:80/TCPFull...]
[2025-07-09T19:46:33.715] [INFO] - [Connection to 91.108.56.115:80/TCPFull complete!]
[2025-07-09T19:46:33.716] [INFO] - [Using LAYER 198 for initial connect]
info: --> GET /telegram/channel/VisualNovelChannel 200 19s
info: <-- GET /healthz
info: --> GET /healthz 200 3ms
info: <-- GET /telegram/channel/R18R18d
info: <-- GET /healthz
info: --> GET /healthz 200 3ms
info: --> GET /telegram/channel/R18R18d 200 10s

ArenaDruid avatar Jul 09 '25 11:07 ArenaDruid

@pseudoyu

I use the mzz2017/v2rayA and the setting info about transparent proxy are as shown in the following image.

Image Image After using the above settings and rebuilding the Rsshub container. I can easily and quickly get rss feed from the /telegram/channel/VisualNovelChannel and /telegram/channel/R18R18d and the following are the logs.

info: <-- GET /telegram/channel/VisualNovelChannel
[2025-07-09T19:46:33.705] [INFO] - [Running gramJS version 2.26.21]
[2025-07-09T19:46:33.712] [INFO] - [Connecting to 91.108.56.115:80/TCPFull...]
[2025-07-09T19:46:33.715] [INFO] - [Connection to 91.108.56.115:80/TCPFull complete!]
[2025-07-09T19:46:33.716] [INFO] - [Using LAYER 198 for initial connect]
info: --> GET /telegram/channel/VisualNovelChannel 200 19s
info: <-- GET /healthz
info: --> GET /healthz 200 3ms
info: <-- GET /telegram/channel/R18R18d
info: <-- GET /healthz
info: --> GET /healthz 200 3ms
info: --> GET /telegram/channel/R18R18d 200 10s

Thank you for your information. I'm working on it.

pseudoyu avatar Jul 09 '25 15:07 pseudoyu