driver屏蔽回调错误

This commit is contained in:
g1879 2023-03-07 23:52:01 +08:00
parent 34296c1aca
commit 9ef5a263ee

View File

@ -149,8 +149,9 @@ class ChromiumDriver(object):
if event['method'] in self.event_handlers: if event['method'] in self.event_handlers:
try: try:
self.event_handlers[event['method']](**event['params']) self.event_handlers[event['method']](**event['params'])
except Exception as e: except Exception:
raise RuntimeError(f"\n回调函数 {self.event_handlers[event['method']].__name__} 错误:\n{e}") pass
# raise RuntimeError(f"\n回调函数 {self.event_handlers[event['method']].__name__} 错误:\n{e}")
self.event_queue.task_done() self.event_queue.task_done()