解决ImportError: cannot import name webdriver
来源:互联网 发布:蛋鸡存栏量数据 编辑:程序博客网 时间:2024/06/08 06:10
最近在写一个Python程序的时候,使用from selenium import webdriver,在run的时候却出现ImportError: cannot import name webdriver的提示,但是在Python IDLE里面跑却没有错误。很是疑惑,谷歌一下才发现有人已经在stackoverflow里面提出类似问题了,原因如下,在当前目录有个明教selenium的文件,Python会先导入这个文件,然后再导入标准库里面的selenium.py可以使用import selenium print selenium.file去看打印出的文件路径,如果不是下面类似的C:\Python27\lib\site-packages\selenium-2.31.0-py2.7.egg\selenium__init__.pyc,需要把当前目录下的文件删除或者重命名。
0 0
- 解决ImportError: cannot import name webdriver
- ImportError: cannot import name webdriver
- ImportError: cannot import name webdriver解决方案
- 'ImportError: cannot import name IncompleteRead' 错误解决
- 解决ImportError:cannot import name xmlrpc_client问题
- 解决pdfminer ImportError: cannot import name process_pdf
- 解决ImportError: cannot import name xxx
- selenium报错ImportError: cannot import name 'webdriver'
- ImportError: cannot import name Pseudo
- Python ImportError: cannot import name *
- ImportError: cannot import name IncompleteRead
- ImportError: cannot import name HTTPSHandler
- importError: cannot import name 'izip_longest'
- ImportError: cannot import name mkdtemp
- ImportError: cannot import name HTTPSHandler
- ImportError:cannot import name game
- ImportError: cannot import name Process
- ImportError: cannot import name 'NUMPY_MKL'
- Unity3D Pattern not found 破解失败解决方法
- STM32的OSC和OSC32的差別
- C++中按行读取文本数据
- Android中NestedScrollingParent嵌套ListView
- POJ
- 解决ImportError: cannot import name webdriver
- 【C语言】关于宏定义中#和##符号的使用和宏定义展开问题
- libsvm 中文文本分类 java版本
- Python 批处理文件(全)
- poj 3190 Stall Reservations (贪心+优先队列)
- 好记性不如烂笔头
- 输出位数的填充C++
- Heaters
- HDOJ--2032 杨辉三角问题(水题)