When I run a program (code is below) in C#-Selenium-Visual Studio Code 2019, I get a 'Failed to read descriptor from node connection: A device attached to the system is not functioning.' The program launches the browser, I get an "Windows Defender Antivirus wants to reset your settings" pop-up for a few seconds, 'Failed to read...' message comes up in a console, and the program ends. Based on my online research, this issue is triggered by Chrome attempting to read properties of USB devices that are currently suspended.
I tried the following to troubleshoot:
Checked browser version - up-to-date - and if Windows Updates are needed - none are.
Other users here at Stack had similar issues. For someone, unplugging USBs worked. I unplugged all USB devices from my PC and re-ran the program but no luck.
I put 'executable_path=r' in front of "https:/..." but that doesn't work either.
I went to chrome://flags to see if I can enable 'Enable new USB backend option' but there isn't this option or any option with USB.
class EntryPoint { static void Main() {
IWebDriver driver = new ChromeDriver(); driver.Navigate().GoToUrl("https://testing.todorvachev.com/"); Thread.Sleep(5000); driver.Quit(); } }