Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions lib/grover/js/processor.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,12 @@ const _processPage = (async (convertAction, uriOrHtml, options) => {
launchParams.timeout = launchTimeout;
}

// Set protocol timeout if given (controls CDP message round-trip timeout)
const protocolTimeout = options.protocolTimeout; delete options.protocolTimeout;
if (protocolTimeout !== undefined) {
launchParams.protocolTimeout = protocolTimeout;
}

// Launch the browser and create a page
browser = await puppeteer.launch(launchParams);
}
Expand Down
2 changes: 1 addition & 1 deletion lib/grover/options_fixer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def fix_boolean_options!
def fix_integer_options!
fix_options!(
'viewport.height', 'viewport.width',
'timeout', 'launch_timeout', 'request_timeout', 'convert_timeout', 'wait_for_timeout',
'timeout', 'launch_timeout', 'protocol_timeout', 'request_timeout', 'convert_timeout', 'wait_for_timeout',
&:to_i
)
end
Expand Down