Skip to content

[🐛 Bug]: Pages are much slower to load when Network monitoring is enabled #14300

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

Closed
mmalandra-kb4 opened this issue Jul 24, 2024 · 7 comments
Labels
C-dotnet .NET Bindings I-defect Something is not working as intended

Comments

@mmalandra-kb4
Copy link

What happened?

When using dotnet bindings with network monitoring enabled, pages with a lot of network calls can be extremely slow to load.

driver.Quit();
Relevant log output

Operating System

Selenium version
4.22

What are the browser(s) and version(s) where you see this issue?
Chrome

What are the browser driver(s) and version(s) where you see this issue?

Are you using Selenium Grid?
This occurs with and without grid.

How can we reproduce the issue?

using OpenQA.Selenium.Chrome;

var driver = new ChromeDriver();

var network = driver.Manage().Network;

await network.StartMonitoring();

driver.Url = "https://yahoo.com";

Relevant log output

There are no logs related to this, but if you compare the time it takes for the page to load with monitoring enabled vs disabled, it can be different by a magnitude of about 10-20x.

Operating System

MacOS/Linux

Selenium version

dotnet 4.22

What are the browser(s) and version(s) where you see this issue?

Chrome 126

What are the browser driver(s) and version(s) where you see this issue?

chromedriver 126

Are you using Selenium Grid?

Occurs with and without grid (

@mmalandra-kb4 mmalandra-kb4 added I-defect Something is not working as intended A-needs-triaging A Selenium member will evaluate this soon! labels Jul 24, 2024
Copy link

@mmalandra-kb4, thank you for creating this issue. We will troubleshoot it as soon as we can.


Info for maintainers

Triage this issue by using labels.

If information is missing, add a helpful comment and then I-issue-template label.

If the issue is a question, add the I-question label.

If the issue is valid but there is no time to troubleshoot it, consider adding the help wanted label.

If the issue requires changes or fixes from an external project (e.g., ChromeDriver, GeckoDriver, MSEdgeDriver, W3C), add the applicable G-* label, and it will provide the correct link and auto-close the issue.

After troubleshooting the issue, please add the R-awaiting answer label.

Thank you!

@diemol
Copy link
Member

diemol commented Jul 29, 2024

@nvborisenko, do you know why this could happen?

@diemol diemol added C-dotnet .NET Bindings and removed A-needs-triaging A Selenium member will evaluate this soon! labels Jul 29, 2024
@nvborisenko
Copy link
Member

I reproduced it with listening to network traffic via CDP, and via BiDi.

The issue is not reproducible in Firefox browser - everything works smoothly (BiDi implementation). Sometimes it works smoothly in Chrome. But each time when page loads slower than usual I see strange error in chromedriver:

[7060:9628:0729/190802.723:ERROR:ssl_client_socket_impl.cc(883)] handshake failed; returned -1, SSL error code 1, net_error -100
[7060:9628:0729/190802.746:ERROR:ssl_client_socket_impl.cc(883)] handshake failed; returned -1, SSL error code 1, net_error -100
[7060:9628:0729/190803.622:ERROR:ssl_client_socket_impl.cc(883)] handshake failed; returned -1, SSL error code 1, net_error -101

No issues in selenium code. This issue can be easily reproduced on https://yahoo.com page, not on https://youtube.com

@mmalandra-kb4 if you observe the similar symptoms, then this issue should be addressed by chrome webdriver team.

@mmalandra-kb4
Copy link
Author

I'll try with other bindings first to see if this is potentially something related to the dotnet code exclusively.

@nvborisenko
Copy link
Member

@mmalandra-kb4 success?

@mmalandra-kb4
Copy link
Author

I haven't gone back to investigate unfortunately. we found a way around the issue by limiting the amount of urls the listeners listen to.

@diemol
Copy link
Member

diemol commented May 8, 2025

I will close this because there was no activity, and the OP found a workaround.

@diemol diemol closed this as not planned Won't fix, can't repro, duplicate, stale May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-dotnet .NET Bindings I-defect Something is not working as intended
Projects
None yet
Development

No branches or pull requests

3 participants