0
python Selenium으로 Internet Explorer를 열려고하지만 "PermissionError : [WinError 5] Access denied"오류가 계속 발생합니다.python Selenium PermissionError : [WinError 5] 액세스가 거부되었습니다.
Internet Explorer 드라이버 서버를 다운로드했습니다. 관리자 권한으로 스크립트를 실행했는데 할 수있는 것이 있습니까?
코드
from selenium import webdriver
driver = webdriver.Ie(r"C:\\Users\\N\\Downloads\\IEwebdriver\\IEDriverServer_x64_2.53.1")
driver.get("http://www.hotmail.com")
driver.maximize_window()
driver.implicitly_wait(20)
위의 예외 처리하는 동안 메시지가
C:\Users\N\AppData\Local\Programs\Python\Python35-32\python.exe C:/Users/N/PycharmProjects/first/SeleniumScripts/Myfirstscripts.py
Traceback (most recent call last):
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\common\service.py", line 64, in start
stdout=self.log_file, stderr=self.log_file)
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\subprocess.py", line 947, in __init__
restore_signals, start_new_session)
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\subprocess.py", line 1224, in _execute_child
startupinfo)
PermissionError: [WinError 5] Access is denied
, 다른 예외가 발생한 전체 오류 :
Traceback (most recent call last):
File "C:/Users/N/PycharmProjects/first/SeleniumScripts/Myfirstscripts.py", line 5, in <module>
driver = webdriver.Ie(r"C:\\Users\\N\\Downloads\\IEwebdriver\\IEDriverServer_x64_2.53.1")
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\ie\webdriver.py", line 49, in __init__
self.iedriver.start()
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\common\service.py", line 76, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'IEDriverServer_x64_2.53.1' executable may have wrong permissions. Please download from http://selenium-release.storage.googleapis.com/index.html and read up at https://github.com/SeleniumHQ/selenium/wiki/InternetExplorerDriver
Exception ignored in: <bound method Service.__del__ of <selenium.webdriver.ie.service.Service object at 0x01C9D410>>
Traceback (most recent call last):
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\common\service.py", line 163, in __del__
self.stop()
File "C:\Users\N\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\common\service.py", line 135, in stop
if self.process is None:
AttributeError: 'Service' object has no attribute 'process'
Process finished with exit code 1
내가 사용하고 마이크로 소프트 윈도우 (10) .
오류가 http://selenium-release.storage.googleapis.com/index.html에서 다운로드 및 HTTPS에 읽어주십시오 IEDriverServer_x64_2.53.1 '실행 파일이 잘못된 권한을 가질 수있다 "라고 : // github.com/SeleniumHQ/selenium/wiki/InternetExplorerDriver "를 참조하십시오. 네가 했니? – n1c9
당신의 OS는 무엇입니까 ?? –