PrasandP / acra

Automatically exported from code.google.com/p/acra
0 stars 0 forks source link

ACRA crashes when built with ProGuard (and current instructions for proguard.cfg) #61

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I'm not sure if anyone else is seeing this issue, but when I build ACRA (4.2.3) 
with ProGuard, my project fails to initialize, complaining that e.g. 
USER_COMMENT doesn't exist (whichever field is first in the annotation).

The way I got around this was by adding the following line to proguard.cfg:

-keep class org.acra.ReportField {*;}

Is anyone else seeing this issue?

Thanks,

    Daniel

Original issue reported on code.google.com by dbschu...@gmail.com on 8 Jul 2011 at 3:56

GoogleCodeExporter commented 8 years ago
I'm getting the same thing, except with "REPORT_ID".  Your workaround works for 
me as well.

Original comment by mport...@gmail.com on 18 Jul 2011 at 3:58

GoogleCodeExporter commented 8 years ago
I'm having this with 4.3.0, and the reported workaround is actually the fix: it 
can't find the fields because they're obfuscated. Indeed, keeping just the 
names is enough, and will allow stripping the unused fields:

-keepnames class org.acra.ReportField {
    *;
}

For the sake of organization, I've added this under the section:
# keep this around for some enums that ACRA needs

Original comment by andrea.p...@gmail.com on 9 Oct 2012 at 10:46