Skip to content


ofURLFileLoader doesn't timeout or handle exceptions #1312

damiannz opened this Issue · 3 comments

4 participants


If you issue a URL to ofURLFileLoader and the http subsystem triggers an exception (no route to host is the easiest to test -- just unplug your network), then the URL request will sit in the request queue forever. Turn on OF_LOG_VERBOSE and watch the console output.

There should be better exception handling, and/or there should be a timeout of some kind.


Right bilderbchi, seems connected with this. One think that i didn't understand is why ofLoadURL and the async version differs in the error catching

openFrameworks member

there's actually a timeout, if not the connection will last forever, when the timeout is triggered if the response is asynchronous the status should be -1 indicating that the server is not available, you can catch that response in the newResponse event and remove the request from the queue using ofRemoveURLRequest( if you want or just let the class keep retrying till the connection is available again.

in my opinion setting an arbitrary timeout for every response when the connection is not available can make some applications not work as intended. what we could do is add a method to activate that kind of timeout?


if i understand correctly, it seems like the timeout should be present by default. then there should be a method to disable that timeout for special applications.

if we did that, would it also close #1344? or is that a separate issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.