CYBYOB / python-GUI-mini-tool-kit

python GUI 百度文库、知网直接下载保存、wifi破解器(内含8200+个密码)、古诗生成器(目前只录入了一部分)
41 stars 16 forks source link

抓百度文库的时候报错了 #1

Open VoidMainR opened 5 years ago

VoidMainR commented 5 years ago

按给的图示填了url和文件名 运行报错了

点击百度、知网等 正在下载。。。 Exception in Tkinter callback Traceback (most recent call last): File "C:\Python37\lib\site-packages\selenium\webdriver\common\service.py", line 76, in start stdin=PIPE) File "C:\Python37\lib\subprocess.py", line 769, in init restore_signals, start_new_session) File "C:\Python37\lib\subprocess.py", line 1172, in _execute_child startupinfo) FileNotFoundError: [WinError 2] 系统找不到指定的文件。

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python37\lib\tkinter__init.py", line 1705, in call return self.func(*args) File "C:\projects\githubPrj\python-GUI-mini-tool-kit\GUI\Baidu.py", line 35, in self.downloadLinkBtn = tk.Button(self, text='下载', command= lambda : self.clickdownloadLinkBtn()) File "C:\projects\githubPrj\python-GUI-mini-tool-kit\GUI\Baidu.py", line 62, in clickdownloadLinkBtn crawler = Crawler.Crwaler(self.linkEntry.get()) File "..\Crawler.py", line 18, in init__ self.driver = webdriver.Chrome(executable_path='C:\chromedriver.exe', chrome_options=chrome_options) File "C:\Python37\lib\site-packages\selenium\webdriver\chrome\webdriver.py", line 73, in init self.service.start() File "C:\Python37\lib\site-packages\selenium\webdriver\common\service.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

chrome驱动也放环境变量了

CYBYOB commented 5 years ago

你下载了 'chromedriver.exe' 和设置环境变量对了吗?代码里面相关路径也需要进行设置的哈~