我有一款适用于大多数热门设备(Galaxy S3,S4,S5,Note 2,Note 3,HTC Desire,Sony Experia Z2)的Android应用,但在HTC One上运行时会崩溃。奇怪的是,它在Genymotion模拟器中运行虚拟HTC One时运行良好。
我在应用程序内部添加了Bugsense-Splunk Mint,我在错误日志cat中看到了一些Bugsense内容。
以下是崩溃报告:
java.lang.RuntimeException: An error occured while executing doInBackground()
at android.os.AsyncTask$3.done(AsyncTask.java:300)
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:355)
at java.util.concurrent.FutureTask.setException(FutureTask.java:222)
at java.util.concurrent.FutureTask.run(FutureTask.java:242)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
at java.lang.Thread.run(Thread.java:864)
Caused by: com.splunk.mint.network.util.DelegationException: java.net.ConnectException: failed to connect to 162.243.163.162/162.243.163.162 (port 80): connect failed: EHOSTUNREACH (No route to host)
at com.splunk.mint.network.util.Delegator.invoke0(Delegator.java:62)
at com.splunk.mint.network.util.Delegator.invoke(Delegator.java:45)
at com.splunk.mint.network.socket.MonitoringSocketImpl.connect(MonitoringSocketImpl.java:118)
at java.net.Socket.connect(Socket.java:873)
at org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:125)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:144)
at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:164)
at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:119)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:367)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:754)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:519)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:497)
at utilities.RSSParserPosts.getXmlFromUrl(RSSParserPosts.java:216)
at utilities.RSSParserPosts.getRSSFeedItems(RSSParserPosts.java:66)
at com.siliconSarl.CardApp.SearchListFragment$LoadThePostsFromInternet.doInBackground(SearchListFragment.java:131)
at com.siliconSarl.CardApp.SearchListFragment$LoadThePostsFromInternet.doInBackground(SearchListFragment.java:1)
at android.os.AsyncTask$2.call(AsyncTask.java:288)
at java.util.concurrent.FutureTask.run(FutureTask.java:237)
... 4 more
Caused by: java.net.ConnectException: failed to connect to 162.243.163.162/162.243.163.162 (port 80): connect failed: EHOSTUNREACH (No route to host)
at libcore.io.IoBridge.connect(IoBridge.java:114)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:192)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:459)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.splunk.mint.network.util.Delegator.invoke0(Delegator.java:56)
... 21 more
Caused by: libcore.io.ErrnoException: connect failed: EHOSTUNREACH (No route to host)
at libcore.io.Posix.connect(Native Method)
at libcore.io.BlockGuardOs.connect(BlockGuardOs.java:85)
at libcore.io.IoBridge.connectErrno(IoBridge.java:127)
at libcore.io.IoBridge.connect(IoBridge.java:112)
... 26 more
有人可以告诉我这是什么问题吗?是什么导致应用程序仅在HTC One上崩溃?
答案 0 :(得分:1)
这是Splunk Mint的一个问题。这来自their website:
注意:目前,网络监控和某些外部库(如OkHttp)存在已知的兼容性问题,导致崩溃。 Splunk目前正在解决此问题,但在解决之前,如果遇到此问题,请完全禁用网络监控。
要禁用网络监视,请在initAndStartSession()之前使用disableNetworkMonitoring()方法。 (我不确定它是否会起作用,因为我没有尝试这种解决方案......)