我运行硒驱动程序以废弃instagram 在看起来像这样的函数中:
def botActivate(username , password , proxy ):
opts = Options()
opts.add_argument('--proxy-server=%s' % proxy)
opts.add_argument(
"user-agent=Mozilla/5.0 (iPhone; CPU iPhone OS 10_3 like Mac OS X)AppleWebKit/602.1.50 (KHTML, like Gecko) CriOS/56.0.2924.75Mobile/14E5239e Safari/602.1")
opts.add_argument('headless')
opts.add_argument("window-size=335,1080");
upload(username, password, proxy )
driver = webdriver.Chrome(options=opts)
followUsers(username, password, driver)
过一会儿(一两轮功能)
我遇到下一个错误,脚本崩溃:
if _WaitForSingleObject(self._handle, 0) == _WAIT_OBJECT_0:
OSError: [WinError 6] The handle is invalid
是什么原因造成的,我该如何解决?