Closed KitsuneRal closed 1 day ago
Fun fact: the default timeout for Connection::syncLoop()
is also 30 seconds, but it's the server-side time, so the library might be giving up on waiting just before the empty response arrives, due to the network latency. Merely increasing the default timeout to 40s could remove those failures.
Describe the bug It can be seen in logs and client UIs that syncing frequently times out. This is most likely because of the smaller timeout values set in f26e3ed924a4699964572972ae487ad8cd1ac1cb to address unit tests occasionally failing when the first request gets stuck for some reason. Long polling implies that sync requests may stay with the server for quite some time, and the current 30 seconds are definitely not long enough to support that.
Expected behavior It's probably best to revert timeouts to their original values and adjust timeouts in unit tests instead. They might run longer but network requests getting stuck are not a normal situation anyway.