【发布时间】:2021-04-25 21:57:42
【问题描述】:
这个问题的追求:Instagram have 2 type of xpath? How it could be remedied?我没有解决我的else-statement什么时候得到一个“私人档案”
它返回一个错误:
我的代码:
for follower in followers:
#Iterate into the list
browser.get(follower)
sleep(2)
if browser.find_element_by_css_selector("li:nth-of-type(2) a.-nal3 span").get_attribute("title"):
print("Public profil")
pass
else:
print("private profil")
pass
感谢您的支持
【问题讨论】:
标签: python selenium if-statement instagram