mirror of
https://github.com/internetarchive/brozzler.git
synced 2025-08-08 14:32:23 -04:00
Make behavior_timeout configurable
``behavior_timeout`` is hardcoded to 900s. With this MR we make it configurable with a default value of 900. We add a new variable to ``BrozzlerWorker`` and ``Browser``.
This commit is contained in:
parent
18a52f0b15
commit
bb93b04c23
2 changed files with 6 additions and 4 deletions
|
@ -381,7 +381,7 @@ class Browser:
|
|||
on_request=None, on_response=None, on_screenshot=None,
|
||||
username=None, password=None, hashtags=None,
|
||||
skip_extract_outlinks=False, skip_visit_hashtags=False,
|
||||
page_timeout=300):
|
||||
page_timeout=300, behavior_timeout=900):
|
||||
'''
|
||||
Browses page in browser.
|
||||
|
||||
|
@ -448,7 +448,7 @@ class Browser:
|
|||
on_screenshot(jpeg_bytes)
|
||||
behavior_script = brozzler.behavior_script(
|
||||
page_url, behavior_parameters)
|
||||
self.run_behavior(behavior_script, timeout=900)
|
||||
self.run_behavior(behavior_script, timeout=behavior_timeout)
|
||||
if skip_extract_outlinks:
|
||||
outlinks = []
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue