이것은 지금까지 제 코드입니다.
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
# create a new Firefox session
driver = webdriver.Firefox()
및 오류 발생하는이 도와주세요
Traceback (most recent call last):
File "C:\Users\yash\AppData\Local\Programs\Python\Python36-32\lib\site-packages\selenium\webdriver\common\service.py", line 74, in start
stdout=self.log_file, stderr=self.log_file)
File "C:\Users\yash\AppData\Local\Programs\Python\Python36-32\lib\subprocess.py", line 707, in __init__
restore_signals, start_new_session)
File "C:\Users\yash\AppData\Local\Programs\Python\Python36-32\lib\subprocess.py", line 990, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "A:\python\webscrapping\seltry.py", line 5, in <module>
driver = webdriver.Firefox()
File "C:\Users\yash\AppData\Local\Programs\Python\Python36-32\lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 148, in __init__
self.service.start()
File "C:\Users\yash\AppData\Local\Programs\Python\Python36-32\lib\site-packages\selenium\webdriver\common\service.py", line 81, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable needs to be in PATH.
입니다!
[Selenium with Python - Geckodriver 실행 파일이 PATH에 있어야 함] (https://stackoverflow.com/questions/40208051/selenium-using-python-geckodriver-executable-needs-to-be-in- 경로) – JeffC
[selenium.common.exceptions.WebDriverException의 가능한 복제본 : 메시지 : 'chromedriver'실행 파일이 PATH 오류가 있어야합니다.] (https://stackoverflow.com/questions/46085270/selenium-common-exceptions-webdriverexception -message-chromedriver-executabl) – DebanjanB