mirror of
https://github.com/internetarchive/brozzler.git
synced 2025-04-20 23:56:34 -04:00
handle timeout trying to extract tertiary assets
This commit is contained in:
parent
2c29dc0333
commit
bbd2bd71bf
@ -609,9 +609,14 @@ class Browser:
|
||||
'extract-tertiary-assets.js').render()
|
||||
msg_id = self.send_to_chrome(
|
||||
method='Runtime.evaluate', params={'expression': js})
|
||||
self._wait_for(
|
||||
lambda: self.websock_thread.received_result(msg_id),
|
||||
timeout=timeout)
|
||||
try:
|
||||
self._wait_for(
|
||||
lambda: self.websock_thread.received_result(msg_id),
|
||||
timeout=timeout)
|
||||
except brozzler.browser.BrowsingTimeout:
|
||||
self.logger.error(
|
||||
'time out trying to extract tertiary assets')
|
||||
return frozenset()
|
||||
message = self.websock_thread.pop_result(msg_id)
|
||||
if ('result' in message and 'result' in message['result']
|
||||
and 'value' in message['result']['result']):
|
||||
|
Loading…
x
Reference in New Issue
Block a user