android - app is crashing in the first launch

Description

  1. install the app freshly

  2. head to the homepage and download a VC

  3. head to receive cards and the scan screen

Expected :

App shouldn't crash, should open the tabs that have been clicked

Observed :

the app getting crashed in the receive card section or in the scan screen

screen recording :

 

Wallet Device:

  • Phone make/model: pixel 6

  • OS: Android 13

  • BLE version : 5.2

Verifier Device :

  • Phone make/model: N/A

  • OS: N/A

  • BLE version : N/A

Mimoto version:
MOSIP Version: 1.2.0.1
APP link :
IPA test flight version : 0.10.0 ( 18 )

Environment

None

Spillover Reason

None

Attachments

4

Activity

Show:

Aswin February 7, 2024 at 10:25 AM
Edited

Verified the issue in the current build the issue was not occurring, hence closing the Jira.

 

Wallet Device:
Phone make/model: One plus Nord
OS: Android 12.1
BLE version : 5.2
Verifier Device :
Phone make/model: N/A
OS: N/A
BLE version : N/A
Mimoto version:
MOSIP Version: 1.2.0.1
APP link :

Kiruthika J January 19, 2024 at 12:21 PM

Screenshots / Recordings

Kiruthika J January 19, 2024 at 12:05 PM

Issue
App relaunches when nearby permissions is allowed in scan screen and navigated to receive screen and vice versa.

Rootcause
- This was happening due to custom logic handled in MainActivity onRequestPermissionsResult performing activity recreation when requestCode is 1 & is not denied.
- The requestCode for BLUETOOTH_SCAN (in Share screen) permission grant result is 1 (after giving nearby devices permission in receive screen) which satisfied the condition of app relaunch.
In detail,

For receiving a card (Receive screen), we require BLUETOOTH_ADVERTISE, BLUETOOTH_CONNECT permission
For sending a card (share screen), we require BLUETOOTH_ADVERTISE, BLUETOOTH_SCAN permission
What is happening is that,

  1. open receive screen, it shows nearby devices permission prompt, allow this (BLUETOOTH_ADVERTISE, BLUETOOTH_CONNECT are granted now)

  2. Now come back and open share screen, here it requires BLUETOOTH_SCAN & BLUETOOTH_CONNECT (BLUETOOTH_CONNECT already granted in receive screen)  permission but it is not giving any prompt to enable the permissions but it grants the permission (noticed in log cat). This granted permission has requestCode as 1 (attach screenshot) which satisfies the condition of relaunch in onRequestPermissionsResult



Kiruthika J January 19, 2024 at 4:27 AM

Other scenarios having same reload

Scenario 1

  1. install the app freshly

  2. head to the homepage and download a VC

  3. go to scan screen and give nearby devices permission & others

  4. Go to receive screen app crashes here instead of showing receive card QR

Fixed

Details

Assignee

Reporter

Resolved by

Severity

Critical

Rootcause

Coding issue

Sprint

Affects versions

Priority

Created January 10, 2024 at 5:58 AM
Updated April 11, 2024 at 3:47 AM
Resolved January 23, 2024 at 3:50 AM