TLSharp icon indicating copy to clipboard operation
TLSharp copied to clipboard

cannot connect to [2001:b28:f23f:f005::a]:443 - ipV4 and ipv6 problem

Open anthonychoi01 opened this issue 4 years ago • 5 comments

Been using the windows version of the Bot, and when connect through API, it shows

`

Problem when trying to connect to [2001:b28:f23f:f005::a]:443; either there's no internet connection or the IP address version is not compatible (if the latter, consider using DataCenterIPVersion enum)

`

My internet was ipV4 only and I would like to know how to solve it? Is that related to the .ddl mistakes? How can I modify it as I am not familiar with coding Thanks.

anthonychoi01 avatar May 13 '20 21:05 anthonychoi01

It says how to solve this problem in the error message, use the DataCenterIPVersion enum.

knocte avatar May 14 '20 01:05 knocte

Thanks for the help. As I am using the telegram bot in Windows, where and how should I modify the file or the code? Sorry I am just not familiar with this. Thanks again

anthonychoi01 avatar May 14 '20 04:05 anthonychoi01

I have the same error. Problem when trying to connect to 149.154.175.100:443; either there's no internet connection or the IP address version is not compatible (if the latter, consider using DataCenterIPVersion enum)

I tried all possible DataCenterIPVersion enum values, but the issue dot't resolve.

in my api configuration i have the following Available MTProto servers: Test configuration: 149.154.167.40:443 Production configuration: 149.154.167.50:443 May be this is the reason?

bretbas avatar Jun 05 '20 17:06 bretbas

IPv6 is not supported, so : new TelegramClient(api_id, api_hash, dcIpVersion: DataCenterIPVersion.OnlyIPv4); DataCenterIPVersion enum => set OnlyIPv4 as above.

Hope this help.

SambathM avatar Jun 04 '21 08:06 SambathM

Fix this please!!!! Nothing works

ralphwald0 avatar Jun 29 '21 12:06 ralphwald0