question

Dan avatar image
Dan asked Dan commented

Platform toasts do not disappear if multiple calls to Toast.show() are made on gen 2 mini

Hi folks,

There is an issue I've just spent the last 3 hours getting to the bottom of. I only have a gen 2 mini close to hand. It would be great if someone could run this app exhibiting the issue on a gen 2, Oreo mini (not an emulator).


Issue:

The issue is that if you show a toast, and then show another one before the first one has disappeared, the first toast comes back and will not go away without killing the app from memory. It's a very annoying bug for me as there are multiple places a toast might show itself so to be sure I don't accidentally do this, I will have to remove toasts from my apps or build something to ensure no toast is being displayed before displaying one.


Can anyone confirm the bug exists for them as well? If so I will kill all toasts in our apps.


Some notes:

  • I believe this is a Clover bug. Run the app on a standard Oreo emulator or phone, and the bug does exist.
  • I can also see that setting the targetSDKVersion to 26 or greater (which we are not supposed to do), makes the bug go away.
  • A targetSDKVersion of 17, 19, 21 and 25 all exhibit the same issue.
  • Here is a very boring video showing a toast not disappearing
Clover Mini
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Jacob Abrams avatar image
Jacob Abrams answered Dan commented

This is indeed a bug in the Android OS that was present at the time we obtained our copy of the OS code for this particular device. We have found and applied the appropriate fixes from Google. It will take a few months for the fix to be released to our devices since we only update the Android OS on our devices a few times a year.

1 comment
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Dan avatar image Dan commented ·

That's great Jacob thanks for the update I shall ignore the issue and try to make sure I don't go crazy over-toasting merchants

0 Likes 0 ·
Dan avatar image
Dan answered Dan commented

This is reproducible on Mini gen 2s with clover apps as well. We made an internal ticket, but I do not have a timeline on any fixes.

1 comment
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Dan avatar image Dan commented ·

Thanks Dan that is good news. Let me know if you do figure it out. Tbh I would be surprised if this is truly a Clover-Android problem and not just an issue with this particular build of Android, because I can't think of anything Clover might be doing behind the scenes that could cause it.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community