Hi there,
Network.setRequestInterceptionEnabled is removed in Chrome DevTools Protocol
I'm tested in HeadlessChrome/64.0.3248.0
Please update puppeteer for new CDP, Thanks.
How to fix?
- Edit
puppeteer/lib/NetworkManager.js
- Change
Network.setRequestInterceptionEnabled to Network.setRequestInterception
async _updateProtocolRequestInterception() {
const enabled = this._userRequestInterceptionEnabled || !!this._credentials;
if (enabled === this._protocolRequestInterceptionEnabled) return;
this._protocolRequestInterceptionEnabled = enabled;
await this._client.send("Network.setRequestInterception", {
patterns: [{ urlPattern: '*' }]
});
}