报错信息:求大神指导
com.testerhome.appcrawler.driver.AppiumClient.getPageSource(AppiumClient.scala:310)
com.testerhome.appcrawler.Crawler.refreshPage(Crawler.scala:555)
com.testerhome.appcrawler.Crawler.start(Crawler.scala:146)
com.testerhome.appcrawler.AppCrawler$.startCrawl(AppCrawler.scala:344)
com.testerhome.appcrawler.AppCrawler$.parseParams(AppCrawler.scala:312)
com.testerhome.appcrawler.AppCrawler$.main(AppCrawler.scala:92)
com.testerhome.appcrawler.AppCrawler.main(AppCrawler.scala)
2019-07-24 19:35:14 WARN [AppiumClient.$anonfun$getPageSource$1.340] get page source error
2019-07-24 19:35:14 WARN [Crawler.refreshPage.562] page source get fail, go back
2019-07-24 19:35:14 INFO [Crawler.setElementAction.660] set action to back
2019-07-24 19:35:14 INFO [Crawler.runStartupScript.236] first refresh
2019-07-24 19:35:14 INFO [Crawler.doElementAction.976] current element = _startupActions-Start-0
2019-07-24 19:35:14 INFO [Crawler.doElementAction.977] current index = 0
2019-07-24 19:35:14 INFO [Crawler.doElementAction.978] current action =
2019-07-24 19:35:14 INFO [Crawler.doElementAction.979] current url =
2019-07-24 19:35:14 INFO [Crawler.doElementAction.980] current xpath = startupActions-Start-0
2019-07-24 19:35:14 INFO [Crawler.doElementAction.981] current tag path = _startupActions-Start-0
2019-07-24 19:35:14 INFO [Crawler.doElementAction.982] current file name = _
2019-07-24 19:35:14 INFO [Crawler.doElementAction.983] current uri = startupActions-Start-0 startupActions
Exception in thread "main" java.util.NoSuchElementException: last of empty ListBuffer
at scala.collection.mutable.ListBuffer.last(ListBuffer.scala:401)
at com.testerhome.appcrawler.DataRecord.last(DataRecord.scala:40)
at com.testerhome.appcrawler.Crawler.doElementAction(Crawler.scala:985)
at com.testerhome.appcrawler.Crawler.runStartupScript(Crawler.scala:238)
at com.testerhome.appcrawler.Crawler.start(Crawler.scala:152)
at com.testerhome.appcrawler.AppCrawler$.startCrawl(AppCrawler.scala:344)
at com.testerhome.appcrawler.AppCrawler$.parseParams(AppCrawler.scala:312)
at com.testerhome.appcrawler.AppCrawler$.main(AppCrawler.scala:92)
at com.testerhome.appcrawler.AppCrawler.main(AppCrawler.scala)
遇到同样的问题,期待楼主给解答一下,万分感谢
很有帮助,赞!