Note that there are some explanatory texts on larger screens.

plurals
  1. POProguard crashes app when trying to send picture with camera
    primarykey
    data
    text
    <p>My app is tested and working fine. But when I try to test a release apk, it crashes. I am including my proguard file and the error log I get while testing the release apk. Basically It crashes after I take a picture thru intent and then try to send the picture to a recipient over the internet. Again, my app is working fine: until proguard got into the mix.</p> <p>A NOTE:</p> <p>The code that sends the image is a <code>Runnable</code> that is started by a <code>Thread</code> as in <code>new Thread(runnable).start()</code>; very basic stuff. Again, the code works outside of proguard.</p> <p>My <code>project.properties</code> file is using the default android file and mine.</p> <p>android proguard:</p> <pre><code># This is a configuration file for ProGuard. # http://proguard.sourceforge.net/index.html#manual/usage.html -dontusemixedcaseclassnames -dontskipnonpubliclibraryclasses -verbose # Optimization is turned off by default. Dex does not like code run # through the ProGuard optimize and preverify steps (and performs some # of these optimizations on its own). -dontoptimize -dontpreverify # Note that if you want to enable optimization, you cannot just # include optimization flags in your own project configuration file; # instead you will need to point to the # "proguard-android-optimize.txt" file instead of this one from your # project.properties file. -keepattributes *Annotation* -keep public class com.google.vending.licensing.ILicensingService -keep public class com.android.vending.licensing.ILicensingService # For native methods, see http://proguard.sourceforge.net/manual/examples.html#native -keepclasseswithmembernames class * { native &lt;methods&gt;; } # keep setters in Views so that animations can still work. # see http://proguard.sourceforge.net/manual/examples.html#beans -keepclassmembers public class * extends android.view.View { void set*(***); *** get*(); } # We want to keep methods in Activity that could be used in the XML attribute onClick -keepclassmembers class * extends android.app.Activity { public void *(android.view.View); } # For enumeration classes, see http://proguard.sourceforge.net/manual/examples.html#enumerations -keepclassmembers enum * { public static **[] values(); public static ** valueOf(java.lang.String); } -keep class * implements android.os.Parcelable { public static final android.os.Parcelable$Creator *; } -keepclassmembers class **.R$* { public static &lt;fields&gt;; } # The support library contains references to newer platform versions. # Don't warn about those in case this app is linking against an older # platform version. We know about them, and they are safe. -dontwarn android.support.** </code></pre> <p>project proguard:</p> <pre><code># My addition -keepclassmembers class com.mycompany.mygame.** { public static &lt;fields&gt;; } # -keep public class com.mycompany.mygame.** { *; } -dontwarn com.mycompany.mygame.** # -keep public class android.support.** { *; } -dontwarn android.support.** # -keep public class com.google.android.gms.** { *; } -dontwarn com.google.android.gms.** # -keep public class com.google.common.** { *; } -dontwarn com.google.common.** # -keep public class org.apache.commons.** { *; } -dontwarn org.apache.commons.** # -keep public class org.apache.http.impl.** { *; } -dontwarn org.apache.http.impl.** # -keep public class android.net.http.AndroidHttpClient { *; } -dontwarn android.net.http.AndroidHttpClient </code></pre> <p>ERROR LOG:</p> <pre><code>05-03 17:40:45.704: E/CameraApp(5068): [SoundController.java:468:onDestroy()] onDestroy-end, sound_pool release 2/2 05-03 17:40:52.829: E/AndroidRuntime(5327): FATAL EXCEPTION: Thread-514 05-03 17:40:52.829: E/AndroidRuntime(5327): xb: The chosen LogFactory implementation does not extend LogFactory. Please check your configuration. (Caused by java.lang.ClassCastException: The application has specified that a custom LogFactory implementation should be used but Class 'org.apache.commons.logging.impl.LogFactoryImpl' cannot be converted to 'xc'. Please check the custom implementation. Help can be found @http://commons.apache.org/logging/troubleshooting.html.) 05-03 17:40:52.829: E/AndroidRuntime(5327): at xc.a(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at xe.run(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at java.security.AccessController.doPrivileged(AccessController.java:45) 05-03 17:40:52.829: E/AndroidRuntime(5327): at xc.a(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at xc.a(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at xc.b(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at afj.&lt;init&gt;(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at afr.&lt;init&gt;(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at gu.a(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at ha.a(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at ha.run(Unknown Source) 05-03 17:40:52.829: E/AndroidRuntime(5327): at java.lang.Thread.run(Thread.java:856) 05-03 17:40:52.829: E/AndroidRuntime(5327): Caused by: java.lang.ClassCastException: The application has specified that a custom LogFactory implementation should be used but Class 'org.apache.commons.logging.impl.LogFactoryImpl' cannot be converted to 'xc'. Please check the custom implementation. Help can be found @http://commons.apache.org/logging/troubleshooting.html. 05-03 17:40:52.829: E/AndroidRuntime(5327): ... 12 more 05-03 17:41:13.829: E/Trace(5606): error opening trace file: No such file or directory (2) </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload