Android app crashes

Platform: Android, Google Pixel 8, Android version 16

App version number, if a mobile app issue:1.38.2

Browser, if a website issue:

URLs (aka web addresses) of any relevant observations or pages:

Screenshots of what you are seeing:

Description of problem:

Step 1: upload images

Step 2: identify

Step 3: after doing the above 2 steps about ten times the app freezes or crashes

This has been ongoing for years. I clear cache and try again. I finally rated it on the play store and decided a bug needs to be reported. It’s so frustrating. I use the app daily but I can see why people would decide to just give up. This should be a number one priority. I read reviews on the play store. Many people complain about the app being buggy. I agree. It crashes for me many times a day.

Can you please clarify? You’re uploading the images to iNat, then identifying them after you upload them? Are you identifying other users’ observations using Explore?

I have had similar issues in the past where uploading observations from images I’ve taken outside of the app (did not try using the camera through the app) would take forever and it would crash multiple times during each observation upload. I uninstalled the app and reinstalled it and that seemed to fix it for now.

I take pictures. The upload pictures through app using the plus sign. Click to identify. Repeat about three times and the app crashes. It’s always done this. I’ve just ignored it. I haven’t tried uninstalling the app. Should I. But if you read Google reviews many people have this problem. It’s not just me.

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS

I’ve had problems identifying other people’s observations as well where it never takes my identification.. It gets in a loop where it just keeps displaying the suggested identifications. When you pick one out it ignore your choice and gives you the list again. I haven’t written a bug report for that.

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS

My primary issue is the slowness and crash that occurs when exploring observations (load observation, then back), ID’ing, and annotating observations. I think there was a comment along the lines of: well, the app was not designed to be used for that.

That’s a 100% reproducible case. Load an observation, set Life Stage, go back. Repeat 100 times. Or Load an Observation, go back. Load next, go back, keep doing it until the app crashes.

So a few months ago I looked at the android app code, built it and ran it in an emulator. The primary issue in that case is that objects keep being accumulated. You can see that in the Android Studio Profiler.

The slowness occurs when the JVM starts reclaiming memory (which is normal in Java apps) you can see that in Logcat. At some point, the JVM spends a lot of time looking for objects to free up. Then, it has to free up objects more often. That progresses until it can’t and the app crashes.

These are the typical symptoms of “memory leaks”. In Java, it means that objects are kept alive because they are referenced somewhere and because of that they are not candidates to be freeed by the JVM. e.g. add a map, reference bitmaps and never clear them, keep that map alive and see what happens (even if you don’t use those bitmaps).

Here’s what the LLM had to say as I was debugging it (yes, I know… but we’re all “a bit” busy these days and I’m not going to learn a huge codebase right now):

1. Observation photo memory leak (the big one)

Symptom: Large bitmaps (~16 MB each) stayed in memory after viewing observations, especially Explore → open obs → back.

Root cause: The inner PhotosViewPagerAdapter in ObservationViewerFragment kept every loaded photo in a mBitmaps HashMap for Zoomy. destroyItem only removed views; close() only closed cursors. Off-screen pages and swiped-away photos kept full decoded bitmaps alive. CustomTarget loads were not tied to the ImageView, so Glide.clear(imageView) did not cancel them.

Fixes prototyped:

  • Removed mBitmaps; zoom reads the ImageView drawable.
  • Glide.with(imageView).into(imageView) instead of anonymous CustomTarget.
  • destroyItem: Zoomy.unregister, Glide.clear (later: app context — see below), setImageDrawable(null).
  • onDestroyView: clear photos pager adapter, destroy() + close() on photo adapter.
  • reloadPhotos(): set new adapter first, then tear down the old one.
  • ObservationViewerSlider.onDestroy(): clear outer pager, destroy() on slider adapter (receivers + cursor), clear fragment map.
  • Same Glide/Zoomy pattern in standalone PhotosViewPagerAdapter.java and teardown in TaxonSuggestionsActivity.

After I looked at it, I truly believe it can be fixed or at least eliminate most of hte pain points. But the changes are unfortunately large enough that it essentially brings that app into active development.

The memory issues appear app-wide and also there seems to be that there is no will to invest time and money in this app because the new one is under development. And any contributions need to be QA’d which also costs time and money. All of this is 100% reasonable, no blame on that.

I think iNaturalist could get a Cursor account and have someone (in iNaturalist) + Opus 4.6 (or even one of the cheaper models like Composer 2.5) look at this and have some of these issues fixed with under $1000 or $2000 dollars. Take a hot shower after that to get rid of the LLM stench :)

Anyway, it was ‘fun’…

As long as it’s corrected in the new version of the app. A friend said the apple app also crashes. I just think people don’t want to use inaturalist if the app is buggy. It’s uses up so much of my time having to start over repeatedly. I just want the development team to know how important this is.

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS

TYSM for looking into this, I’ve seen the many reviews with the same bug issues as OP, I’ve experienced and reported them as well.

Quite honestly I think the staff is ignoring this issue (and Android users in general) and choosing to gaslight us that it doesn’t exist rather than fixing it, which is a shame, since identifying is much easier (for me) on mobile overall, no squinting at pictures or waiting for slow refreshes (at least until the bug occurs). Not trying to be confrontational, but they all seem smart enough to understand that if there’s a lot of people reporting an issue, the fix isn’t to pretend it doesn’t exist!

As I’ve mentioned before, nothing fixes it, not a refresh, not quitting, not cache-clearing, reinstalling..I think I’ve tried just about every fix that’s out there, none seems to have any real effect on it.

I’m hopeful the planned investments into Android will help, but not holding my breath since this has been an ongoing issue for YEARS.

Would it be beneficial to exit the app every so many pictures

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS

I’ve tried this, the only thing that seems to help is a “cool-down” of not identifying for a couple hours, which made me wonder if there’s a limiting function built into the app, or whether it’s a server side issue of refreshing and clearing the cache there every hour or so.

Clearing cache is what I do when it crashes but maybe that is pointless.. Good to hear from others having save frustrating problem. I do dozens of observations a day and having it slow and crash is not helpful. I’m going to do some insects now. I’ll count how many before it crashes.

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS

I just uploaded 6 observations, photographed more, uploaded eight observations. The app never crashed. But it’s 630am.

These are my steps…

  1. Click plus sign to add ob
  2. Choose image
  3. Pick from my files
  4. Crop image
  5. Identify using app vision model
  6. Select identification
  7. Click check Mark to save
  8. Repeat

These are same steps I follow when it crashes

Jeff Hansen
https://www.youtube.com/BackyardBirdsUS