Skip to content

Add options to set protocol timeout #865

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 5, 2024

Conversation

zarulizham
Copy link
Contributor

@zarulizham zarulizham commented Aug 5, 2024

When generating large PDF, getting error:

ProtocolError: Page.printToPDF timed out. Increase the 'protocolTimeout' setting in launch/connect calls for a higher timeout if needed.

This PR can specify protocolTimeout() on Browsershot. Example usage:

$browsershot->protocolTimeout(60); // 60 seconds

By default the value of protocolTimeout is 30 seconds.

@freekmurze freekmurze merged commit 11e36b8 into spatie:main Aug 5, 2024
1 of 5 checks passed
@freekmurze
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants