File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -191,6 +191,7 @@ def cmd_convert(args: argparse.Namespace) -> None:
191191 cmd .add_argument ("-p" , "--parameters" )
192192 cmd .add_argument ("-d" , "--data" )
193193 cmd .add_argument ("-f" , "--format" )
194+ cmd .add_argument ("-t" , "--timeout" , type = int , default = 15 )
194195
195196 def cmd_call (args : argparse .Namespace ) -> None :
196197 loader = loader_prepare (args , session_factory )
@@ -311,7 +312,9 @@ def log_(s):
311312 tracemalloc .start ()
312313
313314 def session_factory (* args_ , ** kwargs ) -> httpx .Client :
314- return httpx .Client (* args_ , verify = args .disable_ssl_validation is False , ** kwargs )
315+ return httpx .Client (
316+ * args_ , verify = args .disable_ssl_validation is False , timeout = httpx .Timeout (args .timeout ), ** kwargs
317+ )
315318
316319 if args .func :
317320 args .func (args )
You can’t perform that action at this time.
0 commit comments