

In this seminar, I have mainly covered how we can start Selenium WebDriver with Python .
This video will mainly cover
1- Introduction to Python
2- Install Python
3- Install PyCharm (IDE for Python)
4- First program in Python
5- First Webdriver script.
6- How to run selenium script in Chrome browser
7- How to run selenium script in IE browser
8- Capture screenshot in Selenium using Python
-~-~~-~~~-~~-~-
Please watch: “How To Create Maven build For Selenium Framework”
-~-~~-~~~-~~-~-
source
When I try to run a piece of code on pycharm i get this error, can someone help what could be the issu
C:UsersfoldernameAppDataLocalProgramsPythonPython38NewPycharmScriptspython.exe C:/Users/foldername/PycharmProjects/firtsPython/SeleniumPrograms/FirstSeleniumCode.py
Traceback (most recent call last):
File "C:/Users/foldername/PycharmProjects/firtsPython/SeleniumPrograms/FirstSeleniumCode.py", line 7, in <module>
browser.get("http://www.facebook.com")
AttributeError: module 'selenium.webdriver.firefox' has no attribute 'get'
program is (username and password in the real program were given as values)
from selenium import webdriver
from selenium.webdriver.support.ui import WebDriverWait
# Step 1) Open Firefox
browser = webdriver.Firefox()
# Step 2) Navigate to Facebook
browser.get("http://www.facebook.com")
# Step 3) Search & Enter the Email or Phone field & Enter Password
username = browser.find_element_by_id("usrname")
password = browser.find_element_by_id("pass")
submit = browser.find_element_by_id("loginbutton")
username.send_keys("YOUR EMAILID")
password.send_keys("YOUR PASSWORD")
# Step 4) Click Login
submit.click()
wait = WebDriverWait( browser, 5 )
page_title = browser.title
assert page_title == "Facebook"
39:17 The mistake is that you used one dot insted of two. One dot would be right if the directory "Screenshots" was inside "SeleniumScripts". However, both "Screenshots" and "SeleniumScripts" were sub-directories of the same parent-directory. For that reason, you should have written "../Screenshots/Facebook.png".
16:14 So, the very first line has the author thing. Is that just an ordinary string variable or a system variable?
30:27 What is the Home directory?
25:50
How did you copy as xpath I can only copy
I have a problem…my chrome opens up but does not go ahead to open facebook website. I did ***driver.get("http://www facebook.com")
Thanks it is very nice video for beginner.
Please share Python automation videos!!!!
these are my errors plss help me
C:Pythonpython.exe "C:/Users/Nishant-PC/PycharmProjects/nikkipython/Selenium Script/MyFirstSeleniumScript.py"
Traceback (most recent call last):
File "C:/Users/Nishant-PC/PycharmProjects/nikkipython/Selenium Script/MyFirstSeleniumScript.py", line 3, in <module>
driver = webdriver.chrome("D:seleniumchrome driverchromedriver.exe")
TypeError: 'module' object is not callable
Process finished with exit code 1
thank you bro
13:15 though i have specified.. i see error when i click on new projects saying not able to save.
And am not able to trace y it is so from logs too…
Help me
sir, for the screen shot directory you should start with "../screenshots/filename.png"
Help!!!! Im getting an error
Traceback (most recent call last):
File "C:/Users/domoj/PycharmProjects/traffic/configurex.py", line 4, in <module>
driver = webdriver.Chrome('C:Selenium\76chromedriver.exe')
File "C:UsersdomojAppDataLocalProgramsPythonPython37-32libsite-packagesseleniumwebdriverchromewebdriver.py", line 81, in _init_
desired_capabilities=desired_capabilities)
File "C:UsersdomojAppDataLocalProgramsPythonPython37-32libsite-packagesseleniumwebdriverremotewebdriver.py", line 157, in _init_
self.start_session(capabilities, browser_profile)
File "C:UsersdomojAppDataLocalProgramsPythonPython37-32libsite-packagesseleniumwebdriverremotewebdriver.py", line 252, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File "C:UsersdomojAppDataLocalProgramsPythonPython37-32libsite-packagesseleniumwebdriverremotewebdriver.py", line 321, in execute
self.error_handler.check_response(response)
File "C:UsersdomojAppDataLocalProgramsPythonPython37-32libsite-packagesseleniumwebdriverremoteerrorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 76
i m getting error when running the facebook thing..can u tell me the path where to save the python file
hi mukesh thank you for wonderful session . i am facing problem in passing value to date range picker
like trivago date range picker ..can you help me
can you pls upload video on selenium web driver interview questions real time
sir i have a doubt pls kindly help me i just wanted to check with you this is complete knowledge of selenium webdriver or do we have to follow any other videos i need complete knowledge of selenium webdriver
Hi Mukesh,
Getting below error while running the script to open Google Chrome.Please assist.
Traceback (most recent call last):
File "C:/Users/SuganyaPalanivel/PycharmProjects/Wwebinar/SeleniumScripts/MyFirstSeleniumScript.py", line 3, in <module>
driver=webdriver.Chrome("C:\Python27Users\chromedriver.exe")
File "C:Python27libsite-packagesseleniumwebdriverchromewebdriver.py", line 73, in _init_
self.service.start()
File "C:Python27libsite-packagesseleniumwebdrivercommonservice.py", line 83, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home
how to download web driver for chrome
plz help me
python installed successfully but wheel is not available. when i tried installing wheel and selenium, getting error as below:
Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001B7FE1A3860>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed',)': /simple/wheel/
Please help me on this.
i tried – pip install wheel
and pip install selenium using command prompt
Awsum video. Kindly upload other videos too.
Hi ,
After running first selenium script in Pycharm for opening Google Chrome, I got error message :Traceback (most recent call last):
File "C:/Users/HP/PycharmProjects/Webinar/SeleniumScripts/MyFirstSeleniumScript.py", line 1, in <module>
from selenium import webdriver
ModuleNotFoundError: No module named 'selenium'
Hi Mukesh, Awesome video as usual 😄 but is there only this 1 video as I am unable to find any other videos on selenium using Python. Thank you for clarifying this doubt
I got this message "'pip' is not recognized as an internal or external command,'
"
Hi Mukesh, in command prompt, python installed but for pip showing fatal error. How to solve this?