mmnode-ticker: support --http-timeout option
This commit is contained in:
parent
0b79ef719b
commit
b9957f9182
2 changed files with 5 additions and 1 deletions
|
|
@ -75,6 +75,7 @@ class DataSource:
|
|||
['--compressed'], # adds 'Accept-Encoding: gzip'
|
||||
['--proxy', cfg.proxy, isinstance(cfg.proxy, str)],
|
||||
['--silent', not cfg.verbose],
|
||||
['--connect-timeout', str(gcfg.http_timeout), gcfg.http_timeout],
|
||||
[self.api_url])
|
||||
|
||||
if gcfg.testing:
|
||||
|
|
@ -290,6 +291,9 @@ class DataSource:
|
|||
if gcfg.test_suite:
|
||||
kwargs.update({'timeout': 1, 'retry': 0})
|
||||
|
||||
if gcfg.http_timeout:
|
||||
kwargs.update({'timeout': gcfg.http_timeout})
|
||||
|
||||
if gcfg.testing:
|
||||
Msg('\nyahooquery.Ticker(\n {},\n {}\n)'.format(
|
||||
self.symbols,
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
3.6.dev1
|
||||
3.6.dev2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue