seveniruby/AppCrawler

appcrawler2.1.3或2.4.0版本运行Exception in thread "main" java.lang.ExceptionInInitializerError

learnertoo opened this issue · 3 comments

可以用python脚本通过appium正常启动app,但在appcrawler-2.4.0或appcrawler-2.1.3输入命令,直接启动指定app
F:\AppCrawler>java -jar appcrawler.jar --capability "appPackage=net.medlinker.medlinker,appActivity=.businese.guide.SplashActivity"
或java -jar appcrawler.jar -a F:\AppCrawler\app.apk安装启动apk
或配置文件启动java -jar appcrawler.jar --capability "appPackage=net.medlinker.medlinker,appActivity=.businese.guide.SplashActivity" -c example.yml都报错,
appium命令行正常启动中,不启动appium也报错,应该是appcrawler这边问题
appium命令行版本1.7.1,java version "1.8.0_101",麻烦看看我是命令有误还是哪里有问题,自己定位不到咯。谢谢!

2019-04-12 18:40:30 INFO [DataRecord.append.13] append 1
2019-04-12 18:40:30 INFO [AppCrawler$.main.87]

AppCrawler 2.1.3 [霍格沃兹测试学院特别纪念版]
Appium 1.7.1 Java8 support
app爬虫, 用于自动遍历测试. 支持Android和iOS, 支持真机和模拟器
帮助文档: https://github.com/seveniruby/AppCrawler
移动测试技术交流: https://testerhome.com
联络作者: seveniruby@testerhome.com (思寒)
致谢: 晓光 泉龙 杨榕 恒温 mikezhou yaming116 沐木
感谢如下公司提供商业支持: Keep

2019-04-12 18:40:30 WARN [AppCrawler$.parseParams.217] can not know what platform, will use default android, please use -p to set the platform
2019-04-12 18:40:30 INFO [AppCrawler$.parseParams.219] Set Platform=Android
2019-04-12 18:40:30 INFO [AppCrawler$.parsePath.336] use app in the config file
2019-04-12 18:40:30 INFO [AppCrawler$.parseParams.234] app path =
2019-04-12 18:40:30 INFO [AppCrawler$.parseParams.245] use default appium address 4723
2019-04-12 18:40:30 INFO [AppCrawler$.parseParams.252] appium address = Some(http://127.0.0.1:4723/wd/hub)
2019-04-12 18:40:30 INFO [AppCrawler$.parseParams.264] result directory = Android_20190412184030
2019-04-12 18:40:31 INFO [DataRecord.initLog.30] alread exist
2019-04-12 18:40:31 INFO [DataRecord.append.13] append 1
2019-04-12 18:40:31 INFO [Crawler.start.126] set xpath attribute with List(name, label, value, resource-id, content-desc, index, text)
2019-04-12 18:40:31 INFO [Crawler.start.129] set xpath
2019-04-12 18:40:31 INFO [Crawler.loadPlugins.82] dynamic load plugin in F:\AppCrawler\plugins
Exception in thread "main" java.lang.ExceptionInInitializerError
at com.testerhome.appcrawler.Crawler.loadPlugins(Crawler.scala:83)
at com.testerhome.appcrawler.Crawler.start(Crawler.scala:130)
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)
Caused by: java.lang.NullPointerException
at java.util.Arrays.sort(Unknown Source)
at scala.tools.nsc.classpath.JFileDirectoryLookup.listChildren(DirectoryClassPath.scala:113)
at scala.tools.nsc.classpath.JFileDirectoryLookup.listChildren$(DirectoryClassPath.scala:97)
at scala.tools.nsc.classpath.DirectoryClassPath.listChildren(DirectoryClassPath.scala:202)
at scala.tools.nsc.classpath.DirectoryClassPath.listChildren(DirectoryClassPath.scala:202)
at scala.tools.nsc.classpath.DirectoryLookup.list(DirectoryClassPath.scala:73)
at scala.tools.nsc.classpath.DirectoryLookup.list$(DirectoryClassPath.scala:69)
at scala.tools.nsc.classpath.DirectoryClassPath.list(DirectoryClassPath.scala:202)
at scala.tools.nsc.classpath.AggregateClassPath.$anonfun$list$1(AggregateClassPath.scala:76)
at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:234)
at scala.collection.Iterator.foreach(Iterator.scala:929)
at scala.collection.Iterator.foreach$(Iterator.scala:929)
at scala.collection.AbstractIterator.foreach(Iterator.scala:1417)
at scala.collection.IterableLike.foreach(IterableLike.scala:71)
at scala.collection.IterableLike.foreach$(IterableLike.scala:70)
at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
at scala.collection.TraversableLike.map(TraversableLike.scala:234)
at scala.collection.TraversableLike.map$(TraversableLike.scala:227)
at scala.collection.AbstractTraversable.map(Traversable.scala:104)
at scala.tools.nsc.classpath.AggregateClassPath.list(AggregateClassPath.scala:74)
at scala.tools.nsc.symtab.SymbolLoaders$PackageLoader.doComplete(SymbolLoaders.scala:271)
at scala.tools.nsc.symtab.SymbolLoaders$SymbolLoader.complete(SymbolLoaders.scala:220)
at scala.reflect.internal.Symbols$Symbol.info(Symbols.scala:1530)
at scala.reflect.internal.Mirrors$RootsBase.init(Mirrors.scala:225)
at scala.tools.nsc.Global.rootMirror$lzycompute(Global.scala:65)
at scala.tools.nsc.Global.rootMirror(Global.scala:63)
at scala.tools.nsc.Global.rootMirror(Global.scala:36)
at scala.reflect.internal.Definitions$DefinitionsClass.ObjectClass$lzycompute(Definitions.scala:267)
at scala.reflect.internal.Definitions$DefinitionsClass.ObjectClass(Definitions.scala:267)
at scala.reflect.internal.Definitions$DefinitionsClass.init(Definitions.scala:1422)
at scala.tools.nsc.Global$Run.(Global.scala:1164)
at com.testerhome.appcrawler.Runtimes.(Runtimes.scala:28)
at com.testerhome.appcrawler.Runtimes$.(Runtimes.scala:53)
at com.testerhome.appcrawler.Runtimes$.(Runtimes.scala)
... 6 more

我今天也遇到了,现在也不知道怎么处理,你哪里知道怎么解决了吗
appcrawler2.1.2

我今天也遇到了,现在也不知道怎么处理,你哪里知道怎么解决了吗
appcrawler2.1.2

环境问题 把java和adb环境全部都重装了吧

好的,谢谢,昨天换成appcrawler2.1.0的版本能跑起来了,如果再报问题,我就把java和adb环境全部都重装