rubycdp / ferrum

Headless Chrome Ruby API
https://ferrum.rubycdp.com
MIT License
1.69k stars 120 forks source link

Clarification on `network.intercept` #380

Closed decaffeinatedio closed 12 months ago

decaffeinatedio commented 12 months ago

Am I correct in understanding that there can only be a single network.intercept block per context? That is my takeaway from the following in the readme:

You used to call authorize method without block, but since it's implemented using request interception there could be a collision with another part of your code that also uses request interception, so that authorize allows the request while your code denies but it's too late. The block is mandatory now.

But I'm not asking exclusively about the authorize case -- will having two network.intercept blocks operating on the same context cause unexpected behavior?

Thanks!