Crash reports sent according to logcat but didn't show in Arcalyzer Dashboard?

299 views Asked by At

I am creating an arithmetic exception to receive crash report using ARCA. I have set up back end at Cloudant using arcalyzer. After a crash, According to logcat, the crash report has been sent but no report is being shown at the arcalyzer dashboard. Couldn't figure out what is wrong with this code.

MainApp:

@ReportsCrashes(
    formUri = "https://terrybogard911.cloudant.com/acra-faheemcallrecorder/_design/acra-storage/_update/report",
    reportType = HttpSender.Type.JSON,
    httpMethod = HttpSender.Method.POST,
    formUriBasicAuthLogin = ""//Login,
    formUriBasicAuthPassword = ""//Password,
    customReportContent = {
            ReportField.APP_VERSION_CODE,
            ReportField.APP_VERSION_NAME,
            ReportField.ANDROID_VERSION,
            ReportField.PACKAGE_NAME,
            ReportField.REPORT_ID,
            ReportField.BUILD,
            ReportField.STACK_TRACE
    },
    mode = ReportingInteractionMode.TOAST,
    resToastText = R.string.toast_crash

)
public class MainApp extends Application {

@Override
public void onCreate() {
    super.onCreate();
    ACRA.init(this);
}
}

Logcat:

09-14 01:32:08.546 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder E/ACRA: ACRA caught a ArithmeticException for com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder
                                                                                                                                                      java.lang.ArithmeticException: divide by zero
                                                                                                                                                          at com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder.MainActivity.onOptionsItemSelected(MainActivity.java:228)
                                                                                                                                                          at android.app.Activity.onMenuItemSelected(Activity.java:2644)
                                                                                                                                                          at android.support.v4.app.FragmentActivity.onMenuItemSelected(FragmentActivity.java:408)
                                                                                                                                                          at android.support.v7.app.AppCompatActivity.onMenuItemSelected(AppCompatActivity.java:195)
                                                                                                                                                          at android.support.v7.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:113)
                                                                                                                                                          at android.support.v7.app.AppCompatDelegateImplV9.onMenuItemSelected(AppCompatDelegateImplV9.java:679)
                                                                                                                                                          at android.support.v7.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:822)
                                                                                                                                                          at android.support.v7.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:156)
                                                                                                                                                          at android.support.v7.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:969)
                                                                                                                                                          at android.support.v7.view.menu.MenuPopup.onItemClick(MenuPopup.java:127)
                                                                                                                                                          at android.widget.AdapterView.performItemClick(AdapterView.java:299)
                                                                                                                                                          at android.widget.AbsListView.performItemClick(AbsListView.java:1158)
                                                                                                                                                          at android.widget.AbsListView$PerformClick.run(AbsListView.java:2957)
                                                                                                                                                          at android.widget.AbsListView$3.run(AbsListView.java:3849)
                                                                                                                                                          at android.os.Handler.handleCallback(Handler.java:733)
                                                                                                                                                          at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                                                                                                          at android.os.Looper.loop(Looper.java:136)
                                                                                                                                                          at android.app.ActivityThread.main(ActivityThread.java:5107)
                                                                                                                                                          at java.lang.reflect.Method.invokeNative(Native Method)
                                                                                                                                                          at java.lang.reflect.Method.invoke(Method.java:515)
                                                                                                                                                          at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:792)
                                                                                                                                                          at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:608)
                                                                                                                                                          at dalvik.system.NativeStart.main(Native Method)
09-14 01:32:08.546 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Building report
09-14 01:32:08.556 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Using custom Report Fields
09-14 01:32:08.646 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder I/ACRA: READ_LOGS granted! ACRA can include LogCat and DropBox data.
09-14 01:32:08.646 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Writing crash report file 1505334728000.stacktrace.
09-14 01:32:08.656 19876-19876/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: About to start ReportSenderWorker from #handleException
09-14 01:32:08.666 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Mark all pending reports as approved.
09-14 01:32:08.666 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Looking for error files in /data/data/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder/files
09-14 01:32:08.676 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: #checkAndSendReports - start
09-14 01:32:08.696 19876-20037/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Waiting for 2000 millis from 1505334728625 currentMillis=1505334728707
09-14 01:32:08.696 19876-20039/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Waiting for Toast
09-14 01:32:08.696 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Looking for error files in /data/data/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder/files
09-14 01:32:08.696 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder I/ACRA: Sending file 1505334728000-approved.stacktrace
09-14 01:32:08.766 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Connect to https://terrybogard911.cloudant.com/acra-faheemcallrecorder/_design/acra-storage/_update/report
09-14 01:32:08.796 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Sending request to https://terrybogard911.cloudant.com/acra-faheemcallrecorder/_design/acra-storage/_update/report
09-14 01:32:08.806 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder E/DataScheduler: isDataSchedulerEnabled():false
09-14 01:32:09.576 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder V/TlsSniSocketFactory: Setting allowed TLS protocols: TLSv1, TLSv1.1, TLSv1.2
09-14 01:32:09.576 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder V/TlsSniSocketFactory: Setting allowed TLS ciphers: TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA, TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA, TLS_DHE_RSA_WITH_AES_128_CBC_SHA, TLS_ECDH_RSA_WITH_AES_128_CBC_SHA, TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA, SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA, SSL_RSA_EXPORT_WITH_RC4_40_MD5, SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA, TLS_DHE_RSA_WITH_AES_256_CBC_SHA, TLS_ECDH_RSA_WITH_AES_256_CBC_SHA, SSL_RSA_WITH_RC4_128_SHA, TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA, SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA, TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA, TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA, SSL_DHE_DSS_WITH_DES_CBC_SHA, TLS_ECDHE_RSA_WITH_RC4_128_SHA, TLS_ECDH_ECDSA_WITH_RC4_128_SHA, TLS_DHE_DSS_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_128_CBC_SHA, SSL_DHE_RSA_WITH_DES_CBC_SHA, TLS_ECDHE_ECDSA_WITH_RC4_128_SHA, TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA, TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA, TLS_RSA_WITH_AES_256_CBC_SHA, SSL_RSA_WITH_DES_CBC_SHA, TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA, TLS_EMPTY_RENEGOTIATION_INFO_SCSV, TLS_ECDH_RSA_WITH_RC4_128_SHA, SSL_RSA_EXPORT_WITH_DES40_CBC_SHA, TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA, SSL_RSA_WITH_RC4_128_MD5, TLS_DHE_DSS_WITH_AES_128_CBC_SHA, SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA, SSL_RSA_WITH_3DES_EDE_CBC_SHA
09-14 01:32:09.576 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/TlsSniSocketFactory: Using documented SNI with host name terrybogard911.cloudant.com
09-14 01:32:10.266 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder I/TlsSniSocketFactory: Established TLSv1.2 connection with terrybogard911.cloudant.com using TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA
09-14 01:32:10.636 19876-20036/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: #checkAndSendReports - finish
09-14 01:32:10.706 19876-20039/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Finished waiting for Toast
09-14 01:32:10.706 19876-20039/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Waiting for Worker
09-14 01:32:10.706 19876-20039/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Finished waiting for Worker
09-14 01:32:10.706 19876-20039/com.tookmesomuchtime.javaprogramming.rashidfaheem.hybridsoftwaresolutions.hbss.rashidfaheem.faheemcallrecorder D/ACRA: Wait for Toast + worker ended. Kill Application ? true
2

There are 2 answers

0
F43nd1r On BEST ANSWER

W/ACRA: 403: Client error - request will be discarded

This means the server was reached but denied the action.

Possible reasons include:

  • Your authentication is for a user without the required role (which is reporter)
  • The server denied the connection because of a faulty https configuration

See Http 403 Forbidden

7
Zumry Mohamed On

Add this version

dependencies {
    testCompile 'junit:junit:4.12'
    compile 'ch.acra:acra:4.9.2'
}

Don't forget to add

<uses-permission android:name="android.permission.INTERNET"/>

add the ACRA init in the following overrides method

    @Override
protected void attachBaseContext(Context base) {
    super.attachBaseContext(base);

    // The following line triggers the initialization of ACRA
    ACRA.init(this);
    System.out.println("application initialized  ACRA");
}