Undetected selenium without chromedriver usage
Project description
Selenium-Driverless
- use selenium without chromedriver
- undetected by cloudfare and others
Feel free to test my code!
Getting Started
Dependencies
- Python >= 3.8
- Chrome-Browser installed
Installing
- Install Chrome-Browser
pip install selenium-driverless
Usage
with asyncio
from selenium_driverless import webdriver
import asyncio
async def main():
options = webdriver.ChromeOptions()
async with webdriver.Chrome(options=options) as driver:
await driver.get('http://nowsecure.nl#relax')
await driver.implicitly_wait(3)
title = await driver.title
url = await driver.current_url
source = await driver.page_source
print(title)
asyncio.run(main())
synchronous
asyncified, might be buggy
from selenium_driverless.sync import webdriver
options = webdriver.ChromeOptions()
with webdriver.Chrome(options=options) as driver:
driver.get('http://nowsecure.nl#relax')
driver.implicitly_wait(3)
title = driver.title
url = driver.current_url
source = driver.page_source
print(title)
Help
Please feel free to open an issue or fork! note: please check the todo's below at first!
Todo
- implementations
-
WebDriverWait
-
EC
(expected-conditions) -
driver.switch_to.frame
workaround -
ActionChains
-
- protocoll
- add cdp event handler
- sync
- move sync to threaded for allowing event_handlers
- remove pycdp dependency -_-
Deprecated
Authors
License
Unless specified differently in a single file, this work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Disclaimer
I am not responsible what you use the code for!!! Also no warranty!
Acknowledgments
Inspiration, code snippets, etc.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
selenium_driverless-1.2.7.tar.gz
(229.2 kB
view hashes)
Close
Hashes for selenium_driverless-1.2.7.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | abce6f62e4768a736b018c7b4f000594eeeccfd5035cd61082e9b9d0a61aadc3 |
|
MD5 | e17b509d8aed22a9bec645d9159e94f8 |
|
BLAKE2b-256 | 6cde5ae3cf73b2d278d9baa5a572cbcf52f830c81c194b8320a87c81349b1f04 |