-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add version check to chromedriver and browser #5
base: master
Are you sure you want to change the base?
Conversation
Added bug fixes for selenium 4 updates in Python. Selenium has a chrome driver package manager now so no need for auto-checking chrome driver. Chrome >115 only works with the Chrome for Testing dashboard. |
scraper.py
Outdated
url= GOOGLE_URL + '?q=' + companyName | ||
result = requests.get(url) | ||
# fancy regex courtesy of pbui | ||
urls = re.findall('/url\?q=([^&]*)', result.text) | ||
urls= re.findall('/url\?q=([^&]*)', result.text) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: spacing
scraper.py
Outdated
|
||
# enter email and password. uses getpass to hide password (i.e. not using plaintext) | ||
your_email=raw_input("Please enter your email for magicformulainvesting.com: ") | ||
# Replace with raw_input() with input() for python 3 | ||
your_email= input("Please enter your email for magicformulainvesting.com: ") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spacing :)
scraper.py
Outdated
|
||
date=datetime.datetime.today().strftime('%Y-%m-%d') # current date | ||
wks.append_row([date], table_range='A1') # append the date, starts in first column | ||
wks = gc.open_by_url("YOUR URL HERE" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comma?
Thanks yo just a couple nits/qs |
This would prevent the code from downloading the chromedriver that is a version ahead of your chome browser if for some reason the automatic install has not yet happened (for example, my chrome browser is not yet at version 111, but chromedriver already released a 111 version).