Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content

Fix: Invalid credentials notification opens debug intent instead of account's settings

Vincent Bourgmayer requested to merge 2145-debug-handle-eeloAdressbook into main

Description

This MR is made to fix this feedback from QA. To summarize:

Context: when account's credential are invalid (changed on devices or on cloud while the account is associated with the phone), the user get notification to ask for updating credentials.

The problem: The notification sometimes sent user to "Debug Intent" instead of opening Account's setting page to let the user update the credentials

Screenshots

Screenshot Screenshot_20240924-215202_Settings

accountmanager_screenrecord3

Technical details

The notification was sending user to "debug intent" when the notification was triggered by Murena Address book account item. Now the notification send to settings in all case.

we limit the scope of this MR to the reported feedback from QA only. If any other request changes, you need to open dedicated issue.

This issue was considered as blocking for some release then not. It will be tested as update through app lounge by QA AFAIK.

Tests

We observed two slightly different situation depending on if account was registered with user ID or with e-mail (as login).

How to test:

  1. Install the APK
  2. Register an account (with mail or id depending on what you awnt)
  3. Wait a little time that everything is setting up (may take longer if you have some files to synchronize)
  4. turn off internet
  5. Add a dummy contact to one of the account's address book
  6. Invalidate credentials; Here there is two option:
    • short one: open settings > account and navigate to change the password on the device side only
    • official one: On laptops or other device, go to cloud server, connect to the account and then change the password on the cloud side
  7. wait 20-30 second
  8. Turn on internet
  9. Wait for sync or force sync.

How to force sync ? I found two kind of synchronization that I don't understand the differences.

  1. Open Settings > Account
  2. Open the account item used for the test
  3. sync 1: Tap on "Account sync" menu item > three dot button at the top right > Sync Now then wait.
  4. Sync 2: from the top menu of the account. Tap on "My Account" > Settings > the blue rectangle with your account mail > two bottom right floating button. Then wait.

You could get two type of notification, and sometimes only the title will be different: "Service detection failed" from sync 2. And "Your account ". It's okay.

For notification that doesn't mention that you need to update the credentials, it is expected to get the debug intent.

What have been tested

  • Test with account registered with account ID
  • Test with account registered with account mail
  • Test with production account
  • Test with staging server account

Issues

https://gitlab.e.foundation/e/os/backlog/-/issues/2145

10 commandments of code reviews

👪 https://gitlab.e.foundation/internal/wiki/-/wikis/mobile-team/guidelines/Code-review

Summary by CodeRabbit

  • New Features

    • Enhanced account type checks in the sync management process for improved handling of specific account types.
  • Bug Fixes

    • Resolved issues related to unauthorized and not found exceptions, improving user experience by directing users to the appropriate settings or debug information.
  • Chores

    • Updated the app version code to reflect the latest changes.
Edited by CodeRabbitAI

Merge request reports

Loading