A python package for login google by selenium
Project description
Google login with Selenium
Overview
This is a small package to log in to Google account with Selenium. After signin, Chrome profile of that user will be create and stored. With Chrome profile you can do so many automatic things with it.
Always active extension is installed by default. To store the profile with minimum size on disk, WorkerService cache, OptimizationGuide and cache is cleared when quitting driver.
This has been developed for testing purposes only. Any action you take using this script is strictly at your own risk. I will not be liable for any losses or damages you face using this script.
Requirement
Must have Python <= 3.9 and Google Chrome installed.
Usage
pip install login_gmail_selenium
And then on example.py
from login_gmail_selenium.util.profile import ChromeProfile
profile = ChromeProfile(email, password, backup_email)
# To allow downloads add insecure=True to ChromeProfile
# To handle false email with custom functions, use param false_email_callback
driver = profile.retrieve_driver()
profile.start()
# Do whatever with driver afterward
driver.get('https://www.google.com/')
driver.quit()
...
- Add folder extension/ if you want custom extensions for Chrome (.crx or .zip)
- The temp folder's content will be generated by the library. Your folder should look like this
/temp
/profiles
/profile1
/profile2
/extension
/custom_extension
extension1.zip
extension2.crx
example.py
License
Copyright © 2022 MoliGroup, MIT license. For an improvement or a bug please feel free to open a PR
For work information please contact ngminhhoang1412@gmail.com or LinkedIn.
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
Built Distribution
Hashes for login_gmail_selenium-1.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a0635364581f88be5eba633a35146937f2de3378c9f30e2b90a3fefc9754e527 |
|
MD5 | 7b844230788bf68dfb99bceac2248e92 |
|
BLAKE2b-256 | fed25b7cda60bdef88c996f8ec6245905ffe028acccbc573b507d825a70b4788 |
Hashes for login_gmail_selenium-1.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 93f5ba236ae7ab375cfa1aa448d715908fdc0412bda6f61b0adc784d793176ae |
|
MD5 | 3947beac3b785231c08faf98dfff3e45 |
|
BLAKE2b-256 | 7db213b67acea7090128b12c623b14a84e0bde7b29662b3bd5aae1f459be4ff0 |