Skip to content
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

update state on update_protocol_request_interception #247

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

henry-spanka
Copy link

When updating protocol request interception we do not actual update the current state.

This causes a number of issues.

While supplying credentials via the page.authenticate() method, protocol interception is enabled. However the variable protocol_request_interception_enabled is never updated and remains false.

During page visit the on_fetch_request_paused method is called. However the check whether we should continue with the request fails due to protocol_request_interception_enabled being false. The request never continues and times out.

pub fn on_fetch_request_paused(&mut self, event: &EventRequestPaused) {
if !self.user_request_interception_enabled && self.protocol_request_interception_enabled {
self.push_cdp_request(ContinueRequestParams::new(event.request_id.clone()))
}

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.

1 participant