Commit 8d53bc3 1 parent 8c29d2e commit 8d53bc3 Copy full SHA for 8d53bc3
File tree 1 file changed +6
-0
lines changed
1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -449,6 +449,7 @@ def run_local_server(
449
449
success_message = _DEFAULT_WEB_SUCCESS_MESSAGE ,
450
450
open_browser = True ,
451
451
redirect_uri_trailing_slash = True ,
452
+ timeout_seconds = None ,
452
453
** kwargs
453
454
):
454
455
"""Run the flow using the server strategy.
@@ -478,6 +479,10 @@ def run_local_server(
478
479
in the user's browser.
479
480
redirect_uri_trailing_slash (bool): whether or not to add trailing
480
481
slash when constructing the redirect_uri. Default value is True.
482
+ timeout_seconds (int): It will raise an error after the timeout timing
483
+ if there are no credentials response. The value is in seconds.
484
+ When set to None there is no timeout.
485
+ Default value is None.
481
486
kwargs: Additional keyword arguments passed through to
482
487
:meth:`authorization_url`.
483
488
@@ -503,6 +508,7 @@ def run_local_server(
503
508
504
509
print (authorization_prompt_message .format (url = auth_url ))
505
510
511
+ local_server .timeout = timeout_seconds
506
512
local_server .handle_request ()
507
513
508
514
# Note: using https here because oauthlib is very picky that
You can’t perform that action at this time.
0 commit comments