Traceback (most recent call last):
File "main.py", line 64, in <module>
go('config.ini')
File "main.py", line 39, in go
habitation, district, street, capture, path, wechat, sckey)
File "G:\PKUData\PKUAutoSubmit\func.py", line 245, in run
go_to_application_out(driver)
File "G:\PKUData\PKUAutoSubmit\func.py", line 57, in go_to_application_out
go_to_simso(driver)
File "G:\PKUData\PKUAutoSubmit\func.py", line 46, in go_to_simso
driver.find_element_by_id('all').click()
File "D:\Anaconda3\lib\site-packages\selenium\webdriver\remote\webelement.py", line 80, in click
self._execute(Command.CLICK_ELEMENT)
File "D:\Anaconda3\lib\site-packages\selenium\webdriver\remote\webelement.py", line 693, in _execute
return self._parent.execute(command, params)
File "D:\Anaconda3\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 418, in execute
self.error_handler.check_response(response)
File "D:\Anaconda3\lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 243, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted:
Element <a id="all" href="#/bizCenterAll" ng-click="click()" target="" class="biz-item" portlet-href="#/bizCenterAll" portlet-id="all" portlet-class="biz-item" portlet-lang="zh" portlet-name="全部" portlet-name-en="All" is-finished="Y" portlet-target="" style="background-image: url("./img/biz-icon-all.svg");">...</a> is not clickable at point (689, 433). Other element would receive the click: <div class="lightbox_back ng-scope" ng-click="closeInfoTip()" id="infoTipBg" style="display: block;"></div>
(Session info: headless chrome=94.0.4606.81)
当portal未绑定手机号时登录portal会出现绑定微信公众号的全屏提示,只有关闭这个提示框才能进行下一步操作。
但在func.py->go_to_simso()函数中没有相应的处理(这种情况也确实比较少),因此会出现如下错误:
以下两种方法可消除这个错误: 1、绑定微信公众号,即可使登录portal时不再弹框。 2、将func.py->go_to_simso()中第一行改为driver.get('https://portal.pku.edu.cn/portal2017/#/bizCenterAll')
建议将这个情况写入README.md中,谢谢!