問題:selenium3 使用move_to_element()報錯,報錯信息如下圖所示:
網上沒有找到合適的解決辦法,回退到穩定的selenium2可以解決。 pip install selenium==2.53.6
selenium和firefox版本對應關系:
selenium2+firefox46及以下版本
selenium3+firefox47及以上版本
如何下載老版本firefox瀏覽器?
1、打開鏈接:https://www.mozilla.org/en-US/firefox/new/
2、點擊 need help? ,如下圖所示:
3、選擇firefox產品
4、點擊 安裝和更新
5、點擊 安裝firefox以前的版本
6、點擊 其他版本和語言目錄
7、選擇firefox46以下的版本就可以了,我的環境是selenium2.53.6 + firefox46 + python3