Using new selenium / chrome with proxy authentication

已查看 65 次
跳至第一个未读帖子

Carl

未读,
2024年3月2日 23:19:303月2日
收件人 Selenium Users
Hello, in previous chrome versions I was able to use proxy authentication using devtools with this code

  options = Selenium::WebDriver::Chrome::Options.new
  options.add_argument("--proxy-server=IP:PORT")

  driver = Selenium::WebDriver.for :chrome, options: options
  driver.devtools.new

  driver.register(username: 'USER', password: 'PASSWORD')

But with new versions I'm getting this error
undefined method `devtools' for #<Selenium::WebDriver::Chrome::Driver:0x000002718782c170> (NoMethodError)

Can anyone help me understand how this work now? Not finding updated documentation about this

I also tried with this code and it still showing the undefined method 'devtools' error
  require 'selenium/devtools'
  Selenium::DevTools.version = 122
  Selenium::DevTools.load_version 



Thanks you

Soos Laszlo

未读,
2024年6月14日 08:35:13 (12天前) 6月14日
收件人 Selenium Users
Hello did you find a solution to this?
回复全部
回复作者
转发
0 个新帖子