작성
·
1.5K
0
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
chromedriver = 'C:/dev_python/Webdriver'
driver = webdriver.Chrome(chromedriver)
이렇게 작성했는데
--------------------------------------------------------------------------- PermissionError Traceback (most recent call last) C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\common\service.py in start(self) 71 cmd.extend(self.command_line_args()) ---> 72 self.process = subprocess.Popen(cmd, env=self.env, 73 close_fds=platform.system() != 'Windows', C:\ProgramData\Anaconda3\lib\subprocess.py in __init__(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds, encoding, errors, text) 857 --> 858 self._execute_child(args, executable, preexec_fn, close_fds, 859 pass_fds, cwd, env, C:\ProgramData\Anaconda3\lib\subprocess.py in _execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, unused_restore_signals, unused_start_new_session) 1310 try: -> 1311 hp, ht, pid, tid = _winapi.CreateProcess(executable, args, 1312 # no special security PermissionError: [WinError 5] 액세스가 거부되었습니다 During handling of the above exception, another exception occurred: WebDriverException Traceback (most recent call last) <ipython-input-1-02e09ad0301c> in <module> 3 4 chromedriver = 'C:/dev_python/Webdriver' ----> 5 driver = webdriver.Chrome(chromedriver) C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\chrome\webdriver.py in __init__(self, executable_path, port, options, service_args, desired_capabilities, service_log_path, chrome_options, keep_alive) 71 service_args=service_args, 72 log_path=service_log_path) ---> 73 self.service.start() 74 75 try: C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\common\service.py in start(self) 84 ) 85 elif err.errno == errno.EACCES: ---> 86 raise WebDriverException( 87 "'%s' executable may have wrong permissions. %s" % ( 88 os.path.basename(self.path), self.start_error_message) WebDriverException: Message: 'Webdriver' executable may have wrong permissions. Please see https://sites.google.com/a/chromium.org/chromedriver/home
이런 오류가 뜨네요...원인이 뭘까요?
아하!!감사합니다:)