v 0.102.0
Yes
I'm starting multiple clients that share hashes and ids. When I start to the new client, according to this example, use bg.Connect
method, I found that blocking happens, I go to connect debug and find that initDone
cannot be executed.But when I rebooted, I found that the existing clients started bg.Connect
normally and did not block, as if this only happened when I had started and wanted to add an account client. And occasionally it gets to initDone
when I debug. I mean is it asynchronous processing?
My code snippet is like this, every time I start an client, I will batch execute this code, and it will normally reach the bg Connect done
log, but when I batch start successfully, I want to add another instance, and then execute this code, I will block at resolver done
.
client := telegram.NewClient(apiID, apiHash, options)
fmt.Println("[Start] CManager done")
resolver := storage.NewResolverCache(peer.Plain(api), peerDB)
_ = resolver
fmt.Println("[Start] resolver done")
_, err = bg.Connect(client, bg.WithContext(ctx))
if err != nil {
fmt.Println("Connect err", err)
return err
}
fmt.Println("[Start] bg Connect done")
I want to be able to add new instances after I've started an existing one without blocking
go v1.21
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too