HTTPRequest timeout behaivour

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Poolitzer

The docs for this are not clear enough for me, I did a quick search and also didn’t find a satisfying answer, so here I am asking.

What is the behavior if I leave the timeout at 0. What happens if the server doesn’t answer fast enough?

I will have some OAuth stuff going on client side which includes opening the browser and stuff, so I expect some wait time before the server can respond to the request.

:bust_in_silhouette: Reply From: Calinou

If timeout is 0, then HTTPRequest will never timeout as its associated timer will never start.

In Godot 3.4 and prior, timeout is defined in milliseconds with an integer. In Godot 3.5 and later, timeout is defined in seconds with a float.