我想用Selenium来寻找一个div。
My code is :
self.browser.find_element_by_xpath('//div[@class="bh-headerBar-nav-item"]').click()
But I got the error:
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//div[@class="bh-headerBar-nav-item"]"}
我应该怎样做才能找到这个div?