Crash when opening OCR window
ClockGen opened this issue · comments
ClockGen commented
I'm using Develop gradle flavor, tried both this commit and the most recent one, after starting the app and clicking on "Open image" button, after selecting the image the app crashes. Same happens when I take a photo.
renard314 commented
I'm not actively maintaining this repo anymore but maybe I can give you some pointers if you post a stack trace.
ClockGen commented
@renard314 it seems I figured it out on my own, it happens on release builds, but not debug, seems proguard is removing something it shouldn't.
02-17 13:34:48.718 I/ActivityManager( 1443): START u0 {cmp=com.renard.ocr/.documents.creation.crop.CropImageActivity} from uid 10716
02-17 13:34:48.759 I/e (23775): onCreate: class com.renard.ocr.documents.creation.crop.CropImageActivity
02-17 13:34:48.763 E/AndroidRuntime(23775): Process: com.renard.ocr, PID: 23775
02-17 13:34:48.763 E/AndroidRuntime(23775): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.renard.ocr/com.renard.ocr.documents.creation.crop.CropImageActivity}: l.a.a.e: Subscriber class com.renard.ocr.documents.creation.crop.CropImageActivity has no public methods called onEvent
02-17 13:34:48.763 E/AndroidRuntime(23775): Caused by: l.a.a.e: Subscriber class com.renard.ocr.documents.creation.crop.CropImageActivity has no public methods called onEvent
02-17 13:34:48.763 E/AndroidRuntime(23775): at com.renard.ocr.documents.creation.crop.CropImageActivity.onCreate(Unknown Source:7)
02-17 13:34:48.768 W/ActivityManager( 1443): Force finishing activity com.renard.ocr/.documents.creation.crop.CropImageActivity
02-17 13:34:48.810 I/ActivityManager( 1443): Process com.renard.ocr (pid 23775) has died: fore TOP
02-17 13:34:48.810 I/WindowManager( 1443): WIN DEATH: Window{4e9a346 u0 com.renard.ocr/com.renard.ocr.documents.viewing.grid.DocumentGridActivity}
02-17 13:34:48.814 I/WindowManager( 1443): WIN DEATH: Window{ebf3248 u0 com.renard.ocr/com.renard.ocr.documents.viewing.grid.DocumentGridActivity EXITING}
02-17 13:34:48.822 W/ActivityManager( 1443): Force removing ActivityRecord{c32ff7d u0 com.renard.ocr/.documents.viewing.grid.DocumentGridActivity t602}: app died, no saved state
renard314 commented
you can just add a Keep annotation to CropImageActivity to retain the onEvent method