soberhacker / obsidian-telegram-sync

Transfer messages and files from Telegram to Obsidian
GNU Affero General Public License v3.0
341 stars 31 forks source link

Always connecting, never connected #225

Closed yenan3 closed 1 year ago

yenan3 commented 1 year ago

Hi soberhacker,

I entered Bot token and my username in Bot(requied) in Obsidian V1.4.16 and Telegram Sync 2.2.0 plugin settings page. But it is always shows connecting... It never connected, not even once.

Firstly, I thought the root cause is the parameters of bot token or username is invalid. So I tried the same parameters in logseq plugin named Indox Telegram v0.1.4. And the parameters worked fine.

Secondly, I thought it's casued by network blocks in China. I changed VPNs but the plugin is still not working. I also tried logseq Inbox Telegram plugin in the same PC via same VPN I used for Obsidian Telegram Sync, it works well. I believed the network is not the root cause.

soberhacker commented 1 year ago

Hi Yenan3:

  1. Please, check the developer console (Ctrl+Shift+I) for any errors
  2. Check your access to the Telegram API by checking the bot's message queue in any browser. Visit the following link: https://api.telegram.org/bot{YOUR:BOT:TOKEN}/getUpdates
  3. Send me screenshots of all the actions you described
yenan3 commented 1 year ago

Hi soberhacker,

Thanks for the quick reply.

  1. I'm not familar with how to find errors in developer console. I tried and the console said 20 errors and 2 issues, you can see in the following screenshot. image

  2. The browser shows the following screenshot after I visit the link you provided. image

3.1. Tried to connect my telegram bot, but it's always connecting image 3.2. The logseq plugin works fine. See the following screenshot for plugin setting page. image 3.3. You may find more detials in following screenshots. image 3.4. The logseq plugin work well with telegram, but in the same PC the obsidian plugin doesn't image

soberhacker commented 1 year ago

Thanks for your report.

  1. The 'Issues' tab is not what I was expecting. Please refer to the Console tab. image

  2. I'm 90% sure that the issue lies either with your system settings (such as antivirus software or firewall) or with the compatibility between your VPN and Obsidian. Try to seek help in the China Telegram group: https://t.me/obsidiangroup

yenan3 commented 1 year ago
  1. Please see the errors in Console tab image

  2. I update the result of visiting the link. image

yenan3 commented 1 year ago

I found more errors in Console tab, you can see the following screenshots: image

image

image

image

yenan3 commented 1 year ago

Here are more details of error about Telegram Sync. image

yenan3 commented 1 year ago

Hi Soberhacker.

I have TUN mode turned on in Clash and it can be CONNECTED!

soberhacker commented 1 year ago

Great job! Now if anyone asks, I'll definitely point them your way for guidance. Thanks

yenan3 commented 1 year ago

If this issue will come in handy for others, let me expand on how to turn on TUN mode. I'm using Clash for Windows, and using version 0.20.19 as an example

  1. General --> Service Mode --> Manage --> Install image

  2. Turn on TUN mode

  3. Turn on Mixin

  4. Turn off System Proxy

soberhacker commented 1 year ago

Brilliant! I've already started adding this explanation to the plugin.