Code Monkey home page Code Monkey logo

Comments (3)

ultrafunkamsterdam avatar ultrafunkamsterdam commented on May 13, 2024

good find!
I've got a patch implemented locally which also fixes the need for that first page. that means you can skip the data:, url alltogether, and use chrome.get(url) on the newly opened (and switched_to) tab. Will merge it tomorrow.

In [1]: import undetected_chromedriver as uc

In [2]: chrome = uc.Chrome()
Selenium patched. Safe to import Chrome / ChromeOptions
Selenium patched. Safe to import Chrome / ChromeOptions

DevTools listening on ws://127.0.0.1:12188/devtools/browser/2405e496-6c7f-4caa-ae40-9e4daa0fddd3

In [3]: chrome.execute_script('return navigator.webdriver')
Out[3]: True

In [4]: chrome.get('https://www.example.com')

In [5]: chrome.execute_script('return navigator.webdriver')

In [6]: chrome.execute_script('window.open();')

In [7]: chrome.switch_to.window(chrome.window_handles[-1])

In [8]: chrome.execute_script('return navigator.webdriver')
Out[8]: True

In [9]: chrome.execute_script('return navigator.webdriver')
Out[9]: True

In [10]: chrome.get('https://www.example.com')

In [11]: chrome.execute_script('return navigator.webdriver')

In[12]: 

from undetected-chromedriver.

claudio0603 avatar claudio0603 commented on May 13, 2024

Ok thanks. I´m looking forward to that fix. ;)

from undetected-chromedriver.

ultrafunkamsterdam avatar ultrafunkamsterdam commented on May 13, 2024

fixed

from undetected-chromedriver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.