溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊(cè)×
其他方式登錄
點(diǎn)擊 登錄注冊(cè) 即表示同意《億速云用戶(hù)服務(wù)條款》

使用robotframework無(wú)法連接webdriver

發(fā)布時(shí)間:2020-07-09 09:13:09 來(lái)源:網(wǎng)絡(luò) 閱讀:543 作者:ivan_duoceshi1 欄目:軟件技術(shù)

在保證RF安裝環(huán)境都是正確安裝的前提,今天發(fā)現(xiàn)一個(gè)問(wèn)題,就是無(wú)論我怎么使用open browser都報(bào)錯(cuò),提示無(wú)法連接webdriver,網(wǎng)上有很多人都說(shuō)是下載的webdriver版本不匹配,我也嘗試去下載了最新版本,還是無(wú)法解決,最后訪問(wèn)了國(guó)外的一個(gè)網(wǎng)站,https://stackoverflow.com/

解決了這個(gè)問(wèn)題

原因是本機(jī)127.0.0.1  與localhost  不匹配

你可以在命令行中輸入:drivers

點(diǎn)擊/etc/hosts/查看

# Additionally, comments (such as these) may be inserted on individual

# lines or following the machine name denoted by a '#' symbol.

#

# For example:

#

#      102.54.94.97     rhino.acme.com          # source server

#       38.25.63.10     x.acme.com              # x client host


# localhost name resolution is handled within DNS itself.

# 127.0.0.1       localhost

# ::1             localhost


把注釋去掉保存

再去嘗試在RF中運(yùn)行,查看能否打開(kāi)瀏覽器


向AI問(wèn)一下細(xì)節(jié)

免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如果涉及侵權(quán)請(qǐng)聯(lián)系站長(zhǎng)郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。

AI