Comments (3)
AddProxy
will return response after the request will be completed, no matter from which thread it is sent. But the request can't be complited before the TDLib instance is initialized (SetTdlibParameters
is called). If the request isn't return, then it is because SetTdlibParameters
is never called.
from td.
Hi @levlam, thanks a lot for the prompt answer!
It seems that I may not have grasped the correct sequence for utilizing the proxy API.
So what you have to do is initiate the library using SetTdlibParameters
call and subsequently incorporate your proxies with AddProxy. Those proxies are kept into the session/cache so if you restart the program they are saved. I guess its clear now.
Just one question, why dont you just raise exception on AddProxy
when the lib is not initialized?
That would make it easier to spot the API misusage.
from td.
It is better to call AddProxy
before SetTdlibParameters
. This is supported and intended order of the calls, otherwise you may try to connect without proxy first. But you must not wait synchronously for AddProxy
response. Waiting synchronously for request response is a bad idea most of the time.
from td.
Related Issues (20)
- Application goes down with error: database disk image is malformed for database HOT 1
- Tonkif
- Account getting banned after successful login using phone code or qr code HOT 6
- Лежим прямо сейчас. Почините уже.
- example/cpp/td_example.cpp can not run, td/telegram/td_api.h can not found HOT 1
- The updateNewMessage event is not triggered unless you enter the message in the Telegram application and see it. HOT 14
- Is there a way to send function packget in telegram_api.tl directly? HOT 1
- Build failed HOT 1
- Download file getting Error 400: File download has failed or was canceled HOT 3
- Client seems to stop receiving most updates after some time in operation HOT 1
- Mon numero est 15814810947
- Bot Answering Chat Join Requests Conditions HOT 3
- mac compile tdlib problem HOT 1
- Application Build Failure, Error: undefined reference HOT 2
- Help in DownloadFile API HOT 1
- After a while my app doesn't receive updateNewMessage events HOT 11
- File (all media) handling HOT 1
- Taligram HOT 2
- Clarification on Telegram account irreversible bans on basis of third party app use HOT 2
- td_send({'@type': 'checkAuthenticationPassword', 'password': password})
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from td.