Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: App crashes when deleting browser favorites on android devices #10598

Conversation

Daniel-Cross
Copy link
Contributor

@Daniel-Cross Daniel-Cross commented Aug 13, 2024

Description

Added a resolve() to the metamask_removeFavorite function to stop Hermes from crashing when trying to handle the Promise.

Hermes would crash when trying to handle the Promise of the Alert method. Adding a resolve() fixes this issue and stops the app from crashing.

Related issues

Fixes: #10583

Manual testing steps

  1. Go to the web browser and visit a random website of your choosing.
  2. Add said site to favourites (or favorites if you're based in North America).
  3. Go back to favourites tab and delete the bookmark you just added.
  4. Observe that an alert is displayed and the app does not crash to desktop.

Screenshots/Recordings

Before

357208383-a1358227-d735-4136-8b80-c7c837cef5d4.mov

After

fix

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@Daniel-Cross Daniel-Cross added needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) team-mobile-platform Run Smoke E2E Triggers smoke e2e on Bitrise labels Aug 13, 2024
@Daniel-Cross Daniel-Cross self-assigned this Aug 13, 2024
Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@Daniel-Cross Daniel-Cross marked this pull request as ready for review August 13, 2024 14:52
@Daniel-Cross Daniel-Cross requested review from a team as code owners August 13, 2024 14:52
Copy link
Contributor

github-actions bot commented Aug 13, 2024

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: ccf3552
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/52fb89a6-e456-44ef-94a2-3993ef51b004

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Copy link
Contributor

@sethkfman sethkfman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link

@sethkfman sethkfman added Run Smoke E2E Triggers smoke e2e on Bitrise and removed needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) Run Smoke E2E Triggers smoke e2e on Bitrise labels Aug 13, 2024
Copy link
Contributor

github-actions bot commented Aug 13, 2024

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: 2201211
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/b3f7bd02-e398-4ba4-844c-71da37232bf3

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

@Daniel-Cross Daniel-Cross merged commit 0ba2cbf into main Aug 13, 2024
42 checks passed
@Daniel-Cross Daniel-Cross deleted the 10583-bug-app-crashes-when-deleting-browser-favorites-on-android-devices branch August 13, 2024 19:01
@github-actions github-actions bot locked and limited conversation to collaborators Aug 13, 2024
@metamaskbot metamaskbot added the release-7.30.0 Issue or pull request that will be included in release 7.30.0 label Aug 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-7.30.0 Issue or pull request that will be included in release 7.30.0 Run Smoke E2E Triggers smoke e2e on Bitrise team-mobile-platform
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

[Bug]: App crashes when deleting browser favorites on android devices
3 participants